diff options
| author | 2017-01-18 12:54:44 +0000 | |
|---|---|---|
| committer | 2017-01-18 13:01:55 +0000 | |
| commit | af35a25df922e21c04e323c81fac1fa7c5fc7bee (patch) | |
| tree | 97277a14ac47d681fe09c91951768c11b386da49 | |
| parent | 4ca818c31cc38746332e68a89ca48be88aa9d7b6 (diff) | |
Fix IP register usage in LoadClassSlowPathARMVIXL.
Request a temporary from a UseScratchRegisterScope instead
of explicitly specifying the IP register to avoid assetion
failure in VIXL.
Test: Build aosp_flounder-userdebug with ART_USE_VIXL_ARM_BACKEND=true
Bug: 34340177
Bug: 30627598
Change-Id: Ie39fbbb66165d752634cde8d2963129641558b93
| -rw-r--r-- | compiler/optimizing/code_generator_arm_vixl.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/compiler/optimizing/code_generator_arm_vixl.cc b/compiler/optimizing/code_generator_arm_vixl.cc index 83c289e866..f496d29b59 100644 --- a/compiler/optimizing/code_generator_arm_vixl.cc +++ b/compiler/optimizing/code_generator_arm_vixl.cc @@ -431,10 +431,12 @@ class LoadClassSlowPathARMVIXL : public SlowPathCodeARMVIXL { // TODO: Change art_quick_initialize_type/art_quick_initialize_static_storage to // kSaveEverything and use a temporary for the .bss entry address in the fast path, // so that we can avoid another calculation here. + UseScratchRegisterScope temps(down_cast<CodeGeneratorARMVIXL*>(codegen)->GetVIXLAssembler()); + vixl32::Register temp = temps.Acquire(); CodeGeneratorARMVIXL::PcRelativePatchInfo* labels = arm_codegen->NewTypeBssEntryPatch(cls_->GetDexFile(), type_index); - arm_codegen->EmitMovwMovtPlaceholder(labels, ip); - __ Str(OutputRegister(cls_), MemOperand(ip)); + arm_codegen->EmitMovwMovtPlaceholder(labels, temp); + __ Str(OutputRegister(cls_), MemOperand(temp)); } __ B(GetExitLabel()); } |