diff options
author | David Srbecky <dsrbecky@google.com> | 2019-01-16 23:18:30 +0000 |
---|---|---|
committer | David Srbecky <dsrbecky@google.com> | 2019-01-17 16:26:14 +0000 |
commit | 2259f1c008bee88902057ecc2ca1b91fe4e74bd7 (patch) | |
tree | 376098e43ea9cacbfd4aa5360f7cfd7c3df96c84 /runtime/stack_map.h | |
parent | 4706ff08bd26dc958d3f162894b92036b02cdeb7 (diff) | |
download | art-2259f1c008bee88902057ecc2ca1b91fe4e74bd7.tar.gz art-2259f1c008bee88902057ecc2ca1b91fe4e74bd7.tar.bz2 art-2259f1c008bee88902057ecc2ca1b91fe4e74bd7.zip |
Extend lifetime of CodeInfo in StackVisitor.
Users of the visitor may use the API after WalkStack is finished.
Test: test.py -b --host
Bug: 120844051
Change-Id: Ia445d3b4c5c338402c92f1d29b522a33cd5baa14
Diffstat (limited to 'runtime/stack_map.h')
-rw-r--r-- | runtime/stack_map.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/runtime/stack_map.h b/runtime/stack_map.h index 811e23b2d2..87133cf59c 100644 --- a/runtime/stack_map.h +++ b/runtime/stack_map.h @@ -301,6 +301,8 @@ class CodeInfo { InlineInfoOnly = 2, }; + CodeInfo() {} + explicit CodeInfo(const uint8_t* data, DecodeFlags flags = AllTables) { Decode(reinterpret_cast<const uint8_t*>(data), flags); } @@ -445,8 +447,6 @@ class CodeInfo { } private: - CodeInfo() {} - // Returns lower bound (fist stack map which has pc greater or equal than the desired one). // It ignores catch stack maps at the end (it is the same as if they had maximum pc value). BitTable<StackMap>::const_iterator BinarySearchNativePc(uint32_t packed_pc) const; @@ -486,10 +486,10 @@ class CodeInfo { callback(&CodeInfo::dex_register_catalog_); } - uint32_t packed_frame_size_; // Frame size in kStackAlignment units. - uint32_t core_spill_mask_; - uint32_t fp_spill_mask_; - uint32_t number_of_dex_registers_; + uint32_t packed_frame_size_ = 0; // Frame size in kStackAlignment units. + uint32_t core_spill_mask_ = 0; + uint32_t fp_spill_mask_ = 0; + uint32_t number_of_dex_registers_ = 0; BitTable<StackMap> stack_maps_; BitTable<RegisterMask> register_masks_; BitTable<StackMask> stack_masks_; |