From 9a46db689afdceee943faf9c7bb9df4bb0f135ad Mon Sep 17 00:00:00 2001 From: Sanjoy Das Date: Wed, 6 May 2015 23:53:24 +0000 Subject: [PATCH] [X86MCInst] Clean up LowerSTATEPOINT: variable names. NFC. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236675 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/X86/X86MCInstLower.cpp | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) diff --git a/lib/Target/X86/X86MCInstLower.cpp b/lib/Target/X86/X86MCInstLower.cpp index 9ad03ae383b..b98e4879de3 100644 --- a/lib/Target/X86/X86MCInstLower.cpp +++ b/lib/Target/X86/X86MCInstLower.cpp @@ -816,32 +816,31 @@ static void LowerSTATEPOINT(MCStreamer &OS, StackMaps &SM, assert(Is64Bit && "Statepoint currently only supports X86-64"); // Lower call target and choose correct opcode - const MachineOperand &call_target = StatepointOpers(&MI).getCallTarget(); - MCOperand call_target_mcop; - unsigned call_opcode; - switch (call_target.getType()) { + const MachineOperand &CallTarget = StatepointOpers(&MI).getCallTarget(); + MCOperand CallTargetMCOp; + unsigned CallOpcode; + switch (CallTarget.getType()) { case MachineOperand::MO_GlobalAddress: case MachineOperand::MO_ExternalSymbol: - call_target_mcop = MCInstLowering.LowerSymbolOperand( - call_target, - MCInstLowering.GetSymbolFromOperand(call_target)); - call_opcode = X86::CALL64pcrel32; + CallTargetMCOp = MCInstLowering.LowerSymbolOperand( + CallTarget, MCInstLowering.GetSymbolFromOperand(CallTarget)); + CallOpcode = X86::CALL64pcrel32; // Currently, we only support relative addressing with statepoints. // Otherwise, we'll need a scratch register to hold the target // address. You'll fail asserts during load & relocation if this // symbol is to far away. (TODO: support non-relative addressing) break; case MachineOperand::MO_Immediate: - call_target_mcop = MCOperand::CreateImm(call_target.getImm()); - call_opcode = X86::CALL64pcrel32; + CallTargetMCOp = MCOperand::CreateImm(CallTarget.getImm()); + CallOpcode = X86::CALL64pcrel32; // Currently, we only support relative addressing with statepoints. // Otherwise, we'll need a scratch register to hold the target // immediate. You'll fail asserts during load & relocation if this // address is to far away. (TODO: support non-relative addressing) break; case MachineOperand::MO_Register: - call_target_mcop = MCOperand::CreateReg(call_target.getReg()); - call_opcode = X86::CALL64r; + CallTargetMCOp = MCOperand::CreateReg(CallTarget.getReg()); + CallOpcode = X86::CALL64r; break; default: llvm_unreachable("Unsupported operand type in statepoint call target"); @@ -849,10 +848,10 @@ static void LowerSTATEPOINT(MCStreamer &OS, StackMaps &SM, } // Emit call - MCInst call_inst; - call_inst.setOpcode(call_opcode); - call_inst.addOperand(call_target_mcop); - OS.EmitInstruction(call_inst, STI); + MCInst CallInst; + CallInst.setOpcode(CallOpcode); + CallInst.addOperand(CallTargetMCOp); + OS.EmitInstruction(CallInst, STI); // Record our statepoint node in the same section used by STACKMAP // and PATCHPOINT -- 2.40.0