From 70bba9c9f5fbba03c62a4542411e1d938375f14e Mon Sep 17 00:00:00 2001 From: Nicolas Geoffray Date: Fri, 16 Jun 2023 12:18:27 +0100 Subject: Remove CodeAllocator and the extra copy of generated code. The code used to copy the final generated code twice: from assembler to CodeAllocator, and then to CodeAllocator to SwapAllocator/JitMemory. The assemblers never depended on the exact location of the generated code, so just drop that feature. Test: test.py Change-Id: I8dc82e4926097092b9aac336a5a5d40f79dc62ca --- compiler/utils/jni_macro_assembler.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'compiler/utils/jni_macro_assembler.h') diff --git a/compiler/utils/jni_macro_assembler.h b/compiler/utils/jni_macro_assembler.h index 0c729705dc..286c378670 100644 --- a/compiler/utils/jni_macro_assembler.h +++ b/compiler/utils/jni_macro_assembler.h @@ -92,7 +92,7 @@ class JNIMacroAssembler : public DeletableArenaObject { virtual size_t CodeSize() const = 0; // Copy instructions out of assembly buffer into the given region of memory - virtual void FinalizeInstructions(const MemoryRegion& region) = 0; + virtual void CopyInstructions(const MemoryRegion& region) = 0; // Emit code that will create an activation on the stack virtual void BuildFrame(size_t frame_size, @@ -266,8 +266,8 @@ class JNIMacroAssemblerFwd : public JNIMacroAssembler { return asm_.CodeSize(); } - void FinalizeInstructions(const MemoryRegion& region) override { - asm_.FinalizeInstructions(region); + void CopyInstructions(const MemoryRegion& region) override { + asm_.CopyInstructions(region); } DebugFrameOpCodeWriterForAssembler& cfi() override { -- cgit v1.2.3-59-g8ed1b