diff options
author | Erik Verbruggen <erik.verbruggen@digia.com> | 2016-01-15 09:54:29 +0100 |
---|---|---|
committer | Erik Verbruggen <erik.verbruggen@theqtcompany.com> | 2016-01-19 15:29:56 +0000 |
commit | de846aec97647862c98419a3f37a432031d9a245 (patch) | |
tree | 8f965b5c67b9c3144c345fac18b57f0728664329 | |
parent | 45bd04ba73bd3e71c070e5724535ba87f6771323 (diff) |
V4: Rename StackFrameRegister to FramePointerRegister.
Because that's what CPU documentation calls it.
Change-Id: I36efd9f424f9b4f4a8b7cbc65a2e63c67be80b95
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
-rw-r--r-- | src/qml/jit/qv4assembler.cpp | 6 | ||||
-rw-r--r-- | src/qml/jit/qv4assembler_p.h | 4 | ||||
-rw-r--r-- | src/qml/jit/qv4isel_masm_p.h | 4 | ||||
-rw-r--r-- | src/qml/jit/qv4targetplatform_p.h | 40 |
4 files changed, 27 insertions, 27 deletions
diff --git a/src/qml/jit/qv4assembler.cpp b/src/qml/jit/qv4assembler.cpp index 9706815daa..3da1aaa010 100644 --- a/src/qml/jit/qv4assembler.cpp +++ b/src/qml/jit/qv4assembler.cpp @@ -240,12 +240,12 @@ void Assembler::enterStandardStackFrame(const RegisterInformation ®ularRegist { platformEnterStandardStackFrame(this); - move(StackPointerRegister, StackFrameRegister); + move(StackPointerRegister, FramePointerRegister); const int frameSize = _stackLayout->calculateStackFrameSize(); subPtr(TrustedImm32(frameSize), StackPointerRegister); - Address slotAddr(StackFrameRegister, 0); + Address slotAddr(FramePointerRegister, 0); for (int i = 0, ei = fpRegistersToSave.size(); i < ei; ++i) { Q_ASSERT(fpRegistersToSave.at(i).isFloatingPoint()); slotAddr.offset -= sizeof(double); @@ -261,7 +261,7 @@ void Assembler::enterStandardStackFrame(const RegisterInformation ®ularRegist void Assembler::leaveStandardStackFrame(const RegisterInformation ®ularRegistersToSave, const RegisterInformation &fpRegistersToSave) { - Address slotAddr(StackFrameRegister, -regularRegistersToSave.size() * RegisterSize - fpRegistersToSave.size() * sizeof(double)); + Address slotAddr(FramePointerRegister, -regularRegistersToSave.size() * RegisterSize - fpRegistersToSave.size() * sizeof(double)); // restore the callee saved registers for (int i = regularRegistersToSave.size() - 1; i >= 0; --i) { diff --git a/src/qml/jit/qv4assembler_p.h b/src/qml/jit/qv4assembler_p.h index 3ffc994070..e175acbecd 100644 --- a/src/qml/jit/qv4assembler_p.h +++ b/src/qml/jit/qv4assembler_p.h @@ -225,7 +225,7 @@ public: // sp was aligned before executing the call instruction. So, calculate all contents // that were saved after that aligned stack...: const int stackSpaceAllocatedOtherwise = StackSpaceAllocatedUponFunctionEntry - + RegisterSize; // saved StackFrameRegister + + RegisterSize; // saved FramePointerRegister // ... then calculate the stuff we want to store ...: int frameSize = RegisterSize * normalRegistersToSave + sizeof(double) * fpRegistersToSave; @@ -278,7 +278,7 @@ public: Q_ASSERT(offset < savedRegCount); // Get the address of the bottom-most element of our frame: - Address ptr(Assembler::StackFrameRegister, -calculateStackFrameSize()); + Address ptr(Assembler::FramePointerRegister, -calculateStackFrameSize()); // This now is the element with offset 0. So: ptr.offset += offset * sizeof(QV4::Value); // and we're done! diff --git a/src/qml/jit/qv4isel_masm_p.h b/src/qml/jit/qv4isel_masm_p.h index c46aa1c324..366d510072 100644 --- a/src/qml/jit/qv4isel_masm_p.h +++ b/src/qml/jit/qv4isel_masm_p.h @@ -142,10 +142,10 @@ protected: #if !defined(ARGUMENTS_IN_REGISTERS) Address addressForArgument(int index) const { - // StackFrameRegister points to its old value on the stack, and above + // FramePointerRegister points to its old value on the stack, and above // it we have the return address, hence the need to step over two // values before reaching the first argument. - return Address(Assembler::StackFrameRegister, (index + 2) * sizeof(void*)); + return Address(Assembler::FramePointerRegister, (index + 2) * sizeof(void*)); } #endif diff --git a/src/qml/jit/qv4targetplatform_p.h b/src/qml/jit/qv4targetplatform_p.h index cef1366b24..878c1dd9fd 100644 --- a/src/qml/jit/qv4targetplatform_p.h +++ b/src/qml/jit/qv4targetplatform_p.h @@ -85,7 +85,7 @@ public: #if CPU(X86) && (OS(LINUX) || OS(WINDOWS) || OS(QNX) || OS(FREEBSD)) enum { RegAllocIsSupported = 1 }; - static const JSC::MacroAssembler::RegisterID StackFrameRegister = JSC::X86Registers::ebp; + static const JSC::MacroAssembler::RegisterID FramePointerRegister = JSC::X86Registers::ebp; static const JSC::MacroAssembler::RegisterID StackPointerRegister = JSC::X86Registers::esp; static const JSC::MacroAssembler::RegisterID LocalsRegister = JSC::X86Registers::edi; static const JSC::MacroAssembler::RegisterID EngineRegister = JSC::X86Registers::esi; @@ -122,8 +122,8 @@ public: static const int StackAlignment = 16; static const int StackShadowSpace = 0; static const int StackSpaceAllocatedUponFunctionEntry = RegisterSize; // Return address is pushed onto stack by the CPU. - static void platformEnterStandardStackFrame(JSC::MacroAssembler *as) { as->push(StackFrameRegister); } - static void platformLeaveStandardStackFrame(JSC::MacroAssembler *as) { as->pop(StackFrameRegister); } + static void platformEnterStandardStackFrame(JSC::MacroAssembler *as) { as->push(FramePointerRegister); } + static void platformLeaveStandardStackFrame(JSC::MacroAssembler *as) { as->pop(FramePointerRegister); } #if OS(WINDOWS) || OS(QNX) || \ ((OS(LINUX) || OS(FREEBSD)) && (defined(__PIC__) || defined(__PIE__))) @@ -145,7 +145,7 @@ public: Q_ASSERT(ebxIdx >= 0); ebxIdx += 1; } - return JSC::MacroAssembler::Address(StackFrameRegister, ebxIdx * -int(sizeof(void*))); + return JSC::MacroAssembler::Address(FramePointerRegister, ebxIdx * -int(sizeof(void*))); } #endif @@ -154,7 +154,7 @@ public: #if CPU(X86_64) && (OS(LINUX) || OS(MAC_OS_X) || OS(FREEBSD)) enum { RegAllocIsSupported = 1 }; - static const JSC::MacroAssembler::RegisterID StackFrameRegister = JSC::X86Registers::ebp; + static const JSC::MacroAssembler::RegisterID FramePointerRegister = JSC::X86Registers::ebp; static const JSC::MacroAssembler::RegisterID StackPointerRegister = JSC::X86Registers::esp; static const JSC::MacroAssembler::RegisterID LocalsRegister = JSC::X86Registers::r12; static const JSC::MacroAssembler::RegisterID EngineRegister = JSC::X86Registers::r14; @@ -209,8 +209,8 @@ public: static const int StackAlignment = 16; static const int StackShadowSpace = 0; static const int StackSpaceAllocatedUponFunctionEntry = RegisterSize; // Return address is pushed onto stack by the CPU. - static void platformEnterStandardStackFrame(JSC::MacroAssembler *as) { as->push(StackFrameRegister); } - static void platformLeaveStandardStackFrame(JSC::MacroAssembler *as) { as->pop(StackFrameRegister); } + static void platformEnterStandardStackFrame(JSC::MacroAssembler *as) { as->push(FramePointerRegister); } + static void platformLeaveStandardStackFrame(JSC::MacroAssembler *as) { as->pop(FramePointerRegister); } #endif // Linux/MacOS on x86_64 #if CPU(X86_64) && OS(WINDOWS) @@ -219,7 +219,7 @@ public: // incoming function parameters to the shadow space is missing. enum { RegAllocIsSupported = 0 }; - static const JSC::MacroAssembler::RegisterID StackFrameRegister = JSC::X86Registers::ebp; + static const JSC::MacroAssembler::RegisterID FramePointerRegister = JSC::X86Registers::ebp; static const JSC::MacroAssembler::RegisterID StackPointerRegister = JSC::X86Registers::esp; static const JSC::MacroAssembler::RegisterID LocalsRegister = JSC::X86Registers::r12; static const JSC::MacroAssembler::RegisterID EngineRegister = JSC::X86Registers::r14; @@ -266,8 +266,8 @@ public: static const int StackAlignment = 16; static const int StackShadowSpace = 32; static const int StackSpaceAllocatedUponFunctionEntry = RegisterSize; // Return address is pushed onto stack by the CPU. - static void platformEnterStandardStackFrame(JSC::MacroAssembler *as) { as->push(StackFrameRegister); } - static void platformLeaveStandardStackFrame(JSC::MacroAssembler *as) { as->pop(StackFrameRegister); } + static void platformEnterStandardStackFrame(JSC::MacroAssembler *as) { as->push(FramePointerRegister); } + static void platformLeaveStandardStackFrame(JSC::MacroAssembler *as) { as->pop(FramePointerRegister); } #endif // Windows on x86_64 #if CPU(ARM) @@ -286,10 +286,10 @@ public: // is used for the subroutine: r7 for Thumb or Thumb2, and r11 for ARM. We assign the constants // accordingly, and assign the locals-register to the "other" register. #if CPU(ARM_THUMB2) - static const JSC::MacroAssembler::RegisterID StackFrameRegister = JSC::ARMRegisters::r7; + static const JSC::MacroAssembler::RegisterID FramePointerRegister = JSC::ARMRegisters::r7; static const JSC::MacroAssembler::RegisterID LocalsRegister = JSC::ARMRegisters::r11; #else // Thumbs down - static const JSC::MacroAssembler::RegisterID StackFrameRegister = JSC::ARMRegisters::r11; + static const JSC::MacroAssembler::RegisterID FramePointerRegister = JSC::ARMRegisters::r11; static const JSC::MacroAssembler::RegisterID LocalsRegister = JSC::ARMRegisters::r7; #endif static const JSC::MacroAssembler::RegisterID StackPointerRegister = JSC::ARMRegisters::r13; @@ -363,12 +363,12 @@ public: static void platformEnterStandardStackFrame(JSC::MacroAssembler *as) { as->push(JSC::ARMRegisters::lr); - as->push(StackFrameRegister); + as->push(FramePointerRegister); } static void platformLeaveStandardStackFrame(JSC::MacroAssembler *as) { - as->pop(StackFrameRegister); + as->pop(FramePointerRegister); as->pop(JSC::ARMRegisters::lr); } #endif // ARM (32 bit) @@ -376,7 +376,7 @@ public: #if CPU(ARM64) enum { RegAllocIsSupported = 1 }; - static const JSC::MacroAssembler::RegisterID StackFrameRegister = JSC::ARM64Registers::fp; + static const JSC::MacroAssembler::RegisterID FramePointerRegister = JSC::ARM64Registers::fp; static const JSC::MacroAssembler::RegisterID LocalsRegister = JSC::ARM64Registers::x28; static const JSC::MacroAssembler::RegisterID StackPointerRegister = JSC::ARM64Registers::sp; static const JSC::MacroAssembler::RegisterID ScratchRegister = JSC::ARM64Registers::x9; @@ -477,19 +477,19 @@ public: static void platformEnterStandardStackFrame(JSC::MacroAssembler *as) { - as->pushPair(StackFrameRegister, JSC::ARM64Registers::lr); + as->pushPair(FramePointerRegister, JSC::ARM64Registers::lr); } static void platformLeaveStandardStackFrame(JSC::MacroAssembler *as) { - as->popPair(StackFrameRegister, JSC::ARM64Registers::lr); + as->popPair(FramePointerRegister, JSC::ARM64Registers::lr); } #endif // ARM64 #if defined(Q_PROCESSOR_MIPS_32) && defined(Q_OS_LINUX) enum { RegAllocIsSupported = 1 }; - static const JSC::MacroAssembler::RegisterID StackFrameRegister = JSC::MIPSRegisters::fp; + static const JSC::MacroAssembler::RegisterID FramePointerRegister = JSC::MIPSRegisters::fp; static const JSC::MacroAssembler::RegisterID StackPointerRegister = JSC::MIPSRegisters::sp; static const JSC::MacroAssembler::RegisterID LocalsRegister = JSC::MIPSRegisters::s0; static const JSC::MacroAssembler::RegisterID EngineRegister = JSC::MIPSRegisters::s1; @@ -551,12 +551,12 @@ public: static void platformEnterStandardStackFrame(JSC::MacroAssembler *as) { as->push(JSC::MIPSRegisters::ra); - as->push(StackFrameRegister); + as->push(FramePointerRegister); } static void platformLeaveStandardStackFrame(JSC::MacroAssembler *as) { - as->pop(StackFrameRegister); + as->pop(FramePointerRegister); as->pop(JSC::MIPSRegisters::ra); } #endif // Linux on MIPS (32 bit) |