diff options
author | 2018-12-20 19:15:11 +0000 | |
---|---|---|
committer | 2019-07-15 09:30:36 +0000 | |
commit | 2808be84a8f86542450670acdb5e6b55498ff5f0 (patch) | |
tree | f41b63e3109a6a6a9bd534f32b8d92f20eb9ef35 /compiler/optimizing/stack_map_stream.cc | |
parent | 460f05480379d5c75555d06c4938bc990ce6ff83 (diff) |
ART: Introduce stackmap with no DexRegInfo.
Some of safepoints don't need to have DexRegisterMap info;
this will decrease the stackmap size.
.oat file size reduction:
- boot.oat: -233 kb (-5.4%)
- boot-framework.oat: -704 kb (-4.9%)
Test: 461-get-reference-vreg, 466-get-live-vreg.
Test: 543-env-long-ref, 616-cha*.
Test: test-art-target, +gc-stress.
Change-Id: Idbad355770e30a30dcf14127642e03ee666878b8
Diffstat (limited to 'compiler/optimizing/stack_map_stream.cc')
-rw-r--r-- | compiler/optimizing/stack_map_stream.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/compiler/optimizing/stack_map_stream.cc b/compiler/optimizing/stack_map_stream.cc index afb6071cd1..3f6010d7af 100644 --- a/compiler/optimizing/stack_map_stream.cc +++ b/compiler/optimizing/stack_map_stream.cc @@ -81,7 +81,8 @@ void StackMapStream::BeginStackMapEntry(uint32_t dex_pc, uint32_t native_pc_offset, uint32_t register_mask, BitVector* stack_mask, - StackMap::Kind kind) { + StackMap::Kind kind, + bool needs_vreg_info) { DCHECK(in_method_) << "Call BeginMethod first"; DCHECK(!in_stack_map_) << "Mismatched Begin/End calls"; in_stack_map_ = true; @@ -114,7 +115,7 @@ void StackMapStream::BeginStackMapEntry(uint32_t dex_pc, lazy_stack_masks_.push_back(stack_mask); current_inline_infos_.clear(); current_dex_registers_.clear(); - expected_num_dex_registers_ = num_dex_registers_; + expected_num_dex_registers_ = needs_vreg_info ? num_dex_registers_ : 0u; if (kVerifyStackMaps) { size_t stack_map_index = stack_maps_.size(); |