diff options
-rw-r--r-- | runtime/interpreter/shadow_frame.h | 62 | ||||
-rw-r--r-- | tools/cpp-define-generator/shadow_frame.def | 8 |
2 files changed, 2 insertions, 68 deletions
diff --git a/runtime/interpreter/shadow_frame.h b/runtime/interpreter/shadow_frame.h index 6b3ec915df..0c542f0173 100644 --- a/runtime/interpreter/shadow_frame.h +++ b/runtime/interpreter/shadow_frame.h @@ -108,30 +108,9 @@ class ShadowFrame { return number_of_vregs_; } - uint32_t GetDexPC() const { - return (dex_pc_ptr_ == nullptr) ? dex_pc_ : dex_pc_ptr_ - dex_instructions_; - } - - int16_t GetCachedHotnessCountdown() const { - return cached_hotness_countdown_; - } - - void SetCachedHotnessCountdown(int16_t cached_hotness_countdown) { - cached_hotness_countdown_ = cached_hotness_countdown; - } - - int16_t GetHotnessCountdown() const { - return hotness_countdown_; - } - - void SetHotnessCountdown(int16_t hotness_countdown) { - hotness_countdown_ = hotness_countdown; - } + uint32_t GetDexPC() const { return dex_pc_; } - void SetDexPC(uint32_t dex_pc) { - dex_pc_ = dex_pc; - dex_pc_ptr_ = nullptr; - } + void SetDexPC(uint32_t dex_pc) { dex_pc_ = dex_pc; } ShadowFrame* GetLink() const { return link_; @@ -167,10 +146,6 @@ class ShadowFrame { return &vregs_[i + NumberOfVRegs()]; } - const uint16_t* GetDexInstructions() const { - return dex_instructions_; - } - float GetVRegFloat(size_t i) const { DCHECK_LT(i, NumberOfVRegs()); // NOTE: Strict-aliasing? @@ -304,22 +279,6 @@ class ShadowFrame { return OFFSETOF_MEMBER(ShadowFrame, vregs_); } - static constexpr size_t DexPCPtrOffset() { - return OFFSETOF_MEMBER(ShadowFrame, dex_pc_ptr_); - } - - static constexpr size_t DexInstructionsOffset() { - return OFFSETOF_MEMBER(ShadowFrame, dex_instructions_); - } - - static constexpr size_t CachedHotnessCountdownOffset() { - return OFFSETOF_MEMBER(ShadowFrame, cached_hotness_countdown_); - } - - static constexpr size_t HotnessCountdownOffset() { - return OFFSETOF_MEMBER(ShadowFrame, hotness_countdown_); - } - // Create ShadowFrame for interpreter using provided memory. static ShadowFrame* CreateShadowFrameImpl(uint32_t num_vregs, ArtMethod* method, @@ -328,14 +287,6 @@ class ShadowFrame { return new (memory) ShadowFrame(num_vregs, method, dex_pc); } - const uint16_t* GetDexPCPtr() { - return dex_pc_ptr_; - } - - void SetDexPCPtr(uint16_t* dex_pc_ptr) { - dex_pc_ptr_ = dex_pc_ptr; - } - bool NeedsNotifyPop() const { return GetFrameFlag(FrameFlags::kNotifyFramePop); } @@ -407,12 +358,8 @@ class ShadowFrame { ShadowFrame(uint32_t num_vregs, ArtMethod* method, uint32_t dex_pc) : link_(nullptr), method_(method), - dex_pc_ptr_(nullptr), - dex_instructions_(nullptr), number_of_vregs_(num_vregs), dex_pc_(dex_pc), - cached_hotness_countdown_(0), - hotness_countdown_(0), frame_flags_(0) { memset(vregs_, 0, num_vregs * (sizeof(uint32_t) + sizeof(StackReference<mirror::Object>))); } @@ -442,14 +389,9 @@ class ShadowFrame { // Link to previous shadow frame or null. ShadowFrame* link_; ArtMethod* method_; - const uint16_t* dex_pc_ptr_; - // Dex instruction base of the code item. - const uint16_t* dex_instructions_; LockCountData lock_count_data_; // This may contain GC roots when lock counting is active. const uint32_t number_of_vregs_; uint32_t dex_pc_; - int16_t cached_hotness_countdown_; - int16_t hotness_countdown_; // This is a set of ShadowFrame::FrameFlags which denote special states this frame is in. // NB alignment requires that this field takes 4 bytes no matter its size. Only 7 bits are diff --git a/tools/cpp-define-generator/shadow_frame.def b/tools/cpp-define-generator/shadow_frame.def index f7e8243fca..654f45a931 100644 --- a/tools/cpp-define-generator/shadow_frame.def +++ b/tools/cpp-define-generator/shadow_frame.def @@ -18,16 +18,8 @@ #include "interpreter/shadow_frame.h" #endif -ASM_DEFINE(SHADOWFRAME_CACHED_HOTNESS_COUNTDOWN_OFFSET, - art::ShadowFrame::CachedHotnessCountdownOffset()) -ASM_DEFINE(SHADOWFRAME_DEX_INSTRUCTIONS_OFFSET, - art::ShadowFrame::DexInstructionsOffset()) ASM_DEFINE(SHADOWFRAME_DEX_PC_OFFSET, art::ShadowFrame::DexPCOffset()) -ASM_DEFINE(SHADOWFRAME_DEX_PC_PTR_OFFSET, - art::ShadowFrame::DexPCPtrOffset()) -ASM_DEFINE(SHADOWFRAME_HOTNESS_COUNTDOWN_OFFSET, - art::ShadowFrame::HotnessCountdownOffset()) ASM_DEFINE(SHADOWFRAME_LINK_OFFSET, art::ShadowFrame::LinkOffset()) ASM_DEFINE(SHADOWFRAME_LOCK_COUNT_DATA_OFFSET, |