From 8c5e881904c30de5dbc03536ea67bbe2d48088fd Mon Sep 17 00:00:00 2001 From: Vladimir Marko Date: Thu, 6 Oct 2022 13:46:55 +0200 Subject: Remove `CompiledCode::CodePointer()`. And clean up some related test helpers in preparation for moving `CompiledMethod` to dex2oat/. Test: m test-art-host-gtest Test: run-gtests.sh Change-Id: I13b42bfb4f6ee3a7f7f22bbc8d22203c5d56e00b --- compiler/optimizing/codegen_test_utils.h | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'compiler/optimizing/codegen_test_utils.h') diff --git a/compiler/optimizing/codegen_test_utils.h b/compiler/optimizing/codegen_test_utils.h index 95cb548905..8e93f4d55a 100644 --- a/compiler/optimizing/codegen_test_utils.h +++ b/compiler/optimizing/codegen_test_utils.h @@ -254,15 +254,11 @@ static void Run(const InternalCodeAllocator& allocator, Runtime* GetRuntime() override { return nullptr; } }; CodeHolder code_holder; - const void* code_ptr = + const void* method_code = code_holder.MakeExecutable(allocator.GetMemory(), ArrayRef(), target_isa); using fptr = Expected (*)(); - fptr f = reinterpret_cast(reinterpret_cast(code_ptr)); - if (target_isa == InstructionSet::kThumb2) { - // For thumb we need the bottom bit set. - f = reinterpret_cast(reinterpret_cast(f) + 1); - } + fptr f = reinterpret_cast(reinterpret_cast(method_code)); VerifyGeneratedCode(target_isa, f, has_result, expected); } -- cgit v1.2.3-59-g8ed1b