summaryrefslogtreecommitdiff
path: root/runtime/oat_quick_method_header.h
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/oat_quick_method_header.h')
-rw-r--r--runtime/oat_quick_method_header.h23
1 files changed, 9 insertions, 14 deletions
diff --git a/runtime/oat_quick_method_header.h b/runtime/oat_quick_method_header.h
index 1e4ca3e450..3b9f466220 100644
--- a/runtime/oat_quick_method_header.h
+++ b/runtime/oat_quick_method_header.h
@@ -32,12 +32,13 @@ class ArtMethod;
class PACKED(4) OatQuickMethodHeader {
public:
OatQuickMethodHeader() = default;
- explicit OatQuickMethodHeader(uint32_t vmap_table_offset,
- uint32_t method_info_offset,
- uint32_t frame_size_in_bytes,
- uint32_t core_spill_mask,
- uint32_t fp_spill_mask,
- uint32_t code_size);
+ OatQuickMethodHeader(uint32_t vmap_table_offset,
+ uint32_t method_info_offset,
+ uint32_t code_size)
+ : vmap_table_offset_(vmap_table_offset),
+ method_info_offset_(method_info_offset),
+ code_size_(code_size) {
+ }
static OatQuickMethodHeader* FromCodePointer(const void* code_ptr) {
uintptr_t code = reinterpret_cast<uintptr_t>(code_ptr);
@@ -151,7 +152,7 @@ class PACKED(4) OatQuickMethodHeader {
template <bool kCheckFrameSize = true>
uint32_t GetFrameSizeInBytes() const {
- uint32_t result = frame_info_.FrameSizeInBytes();
+ uint32_t result = GetFrameInfo().FrameSizeInBytes();
if (kCheckFrameSize) {
DCHECK_ALIGNED(result, kStackAlignment);
}
@@ -160,11 +161,7 @@ class PACKED(4) OatQuickMethodHeader {
QuickMethodFrameInfo GetFrameInfo() const {
DCHECK(IsOptimized());
- QuickMethodFrameInfo frame_info = CodeInfo::DecodeFrameInfo(GetOptimizedCodeInfoPtr());
- DCHECK_EQ(frame_info.FrameSizeInBytes(), frame_info_.FrameSizeInBytes());
- DCHECK_EQ(frame_info.CoreSpillMask(), frame_info_.CoreSpillMask());
- DCHECK_EQ(frame_info.FpSpillMask(), frame_info_.FpSpillMask());
- return frame_info;
+ return CodeInfo::DecodeFrameInfo(GetOptimizedCodeInfoPtr());
}
uintptr_t ToNativeQuickPc(ArtMethod* method,
@@ -194,8 +191,6 @@ class PACKED(4) OatQuickMethodHeader {
// would be lost from doing so. The method info memory region contains method indices since they
// are hard to dedupe.
uint32_t method_info_offset_ = 0u;
- // The stack frame information.
- QuickMethodFrameInfo frame_info_;
// The code size in bytes. The highest bit is used to signify if the compiled
// code with the method header has should_deoptimize flag.
uint32_t code_size_ = 0u;