mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
DebugInfo: Don't lose unreferenced non-trivial by-value parameters
A FastISel optimization was causing us to emit no information for such parameters & when they go missing we end up emitting a different function type. By avoiding that shortcut we not only get types correct (very important) but also location information (handy) - even if it's only live at the start of a function & may be clobbered later. Reviewed/discussion by Evan Cheng & Dan Gohman. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184604 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -1732,8 +1732,6 @@ bool X86FastISel::FastLowerArguments() {
|
||||
const TargetRegisterClass *RC64 = TLI.getRegClassFor(MVT::i64);
|
||||
for (Function::const_arg_iterator I = F->arg_begin(), E = F->arg_end();
|
||||
I != E; ++I, ++Idx) {
|
||||
if (I->use_empty())
|
||||
continue;
|
||||
bool is32Bit = TLI.getValueType(I->getType()) == MVT::i32;
|
||||
const TargetRegisterClass *RC = is32Bit ? RC32 : RC64;
|
||||
unsigned SrcReg = is32Bit ? GPR32ArgRegs[Idx] : GPR64ArgRegs[Idx];
|
||||
|
Reference in New Issue
Block a user