diff options
Diffstat (limited to 'runtime/oat_quick_method_header.h')
-rw-r--r-- | runtime/oat_quick_method_header.h | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/runtime/oat_quick_method_header.h b/runtime/oat_quick_method_header.h index 6c123c4eb5..8798c6968c 100644 --- a/runtime/oat_quick_method_header.h +++ b/runtime/oat_quick_method_header.h @@ -35,8 +35,6 @@ class PACKED(4) OatQuickMethodHeader { uint32_t code_size) : vmap_table_offset_(vmap_table_offset), code_size_(code_size) { - DCHECK_NE(vmap_table_offset, 0u); - DCHECK_NE(code_size, 0u); } static OatQuickMethodHeader* FromCodePointer(const void* code_ptr) { @@ -60,7 +58,7 @@ class PACKED(4) OatQuickMethodHeader { } bool IsOptimized() const { - return (code_size_ & kCodeSizeMask) != 0 && vmap_table_offset_ != 0; + return GetCodeSize() != 0 && vmap_table_offset_ != 0; } const uint8_t* GetOptimizedCodeInfoPtr() const { @@ -78,11 +76,7 @@ class PACKED(4) OatQuickMethodHeader { } uint32_t GetCodeSize() const { - DCHECK(IsOptimized()); - size_t code_size1 = code_size_ & kCodeSizeMask; - size_t code_size2 = CodeInfo::DecodeCodeSize(GetOptimizedCodeInfoPtr()); - DCHECK_EQ(code_size1, code_size2); - return code_size2; + return code_size_ & kCodeSizeMask; } const uint32_t* GetCodeSizeAddr() const { |