From 1809a72a66d245ae598582d658b93a24ac3bf01e Mon Sep 17 00:00:00 2001 From: Ian Rogers Date: Fri, 9 Aug 2013 22:05:32 -0700 Subject: Uleb128 compression of vmap and mapping table. Bug 9437697. Change-Id: I30bcb97d12cd8b46d3b2cdcbdd358f08fbb9947a --- runtime/stack.cc | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'runtime/stack.cc') diff --git a/runtime/stack.cc b/runtime/stack.cc index 7f3f40c..e1a752a 100644 --- a/runtime/stack.cc +++ b/runtime/stack.cc @@ -24,6 +24,7 @@ #include "object_utils.h" #include "thread_list.h" #include "throw_location.h" +#include "vmap_table.h" namespace art { @@ -135,10 +136,10 @@ uint32_t StackVisitor::GetVReg(mirror::AbstractMethod* m, uint16_t vreg, VRegKin if (cur_quick_frame_ != NULL) { DCHECK(context_ != NULL); // You can't reliably read registers without a context. DCHECK(m == GetMethod()); - const VmapTable vmap_table(m->GetVmapTableRaw()); + const VmapTable vmap_table(m->GetVmapTable()); uint32_t vmap_offset; // TODO: IsInContext stops before spotting floating point registers. - if (vmap_table.IsInContext(vreg, vmap_offset, kind)) { + if (vmap_table.IsInContext(vreg, kind, &vmap_offset)) { bool is_float = (kind == kFloatVReg) || (kind == kDoubleLoVReg) || (kind == kDoubleHiVReg); uint32_t spill_mask = is_float ? m->GetFpSpillMask() : m->GetCoreSpillMask(); @@ -160,10 +161,10 @@ void StackVisitor::SetVReg(mirror::AbstractMethod* m, uint16_t vreg, uint32_t ne if (cur_quick_frame_ != NULL) { DCHECK(context_ != NULL); // You can't reliably write registers without a context. DCHECK(m == GetMethod()); - const VmapTable vmap_table(m->GetVmapTableRaw()); + const VmapTable vmap_table(m->GetVmapTable()); uint32_t vmap_offset; // TODO: IsInContext stops before spotting floating point registers. - if (vmap_table.IsInContext(vreg, vmap_offset, kind)) { + if (vmap_table.IsInContext(vreg, kind, &vmap_offset)) { bool is_float = (kind == kFloatVReg) || (kind == kDoubleLoVReg) || (kind == kDoubleHiVReg); uint32_t spill_mask = is_float ? m->GetFpSpillMask() : m->GetCoreSpillMask(); const uint32_t reg = vmap_table.ComputeRegister(spill_mask, vmap_offset, kReferenceVReg); -- cgit v1.1