aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp12
1 files changed, 4 insertions, 8 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp b/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
index 911bbab..ca10a6e 100644
--- a/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
@@ -162,14 +162,13 @@ TargetLowering::makeLibCall(SelectionDAG &DAG, RTLIB::Libcall LC, EVT RetVT,
TargetLowering::ArgListTy Args;
Args.reserve(Ops.size());
- TargetLowering::ArgListEntry Entry;
ArrayRef<Type *> OpsTypeOverrides = CallOptions.OpsTypeOverrides;
for (unsigned i = 0; i < Ops.size(); ++i) {
SDValue NewOp = Ops[i];
- Entry.Node = NewOp;
- Entry.Ty = i < OpsTypeOverrides.size() && OpsTypeOverrides[i]
+ Type *Ty = i < OpsTypeOverrides.size() && OpsTypeOverrides[i]
? OpsTypeOverrides[i]
- : Entry.Node.getValueType().getTypeForEVT(*DAG.getContext());
+ : NewOp.getValueType().getTypeForEVT(*DAG.getContext());
+ TargetLowering::ArgListEntry Entry(NewOp, Ty);
Entry.IsSExt =
shouldSignExtendTypeInLibCall(Entry.Ty, CallOptions.IsSigned);
Entry.IsZExt = !Entry.IsSExt;
@@ -10713,7 +10712,6 @@ SDValue TargetLowering::LowerToTLSEmulatedModel(const GlobalAddressSDNode *GA,
SDLoc dl(GA);
ArgListTy Args;
- ArgListEntry Entry;
const GlobalValue *GV =
cast<GlobalValue>(GA->getGlobal()->stripPointerCastsAndAliases());
SmallString<32> NameString("__emutls_v.");
@@ -10722,9 +10720,7 @@ SDValue TargetLowering::LowerToTLSEmulatedModel(const GlobalAddressSDNode *GA,
const GlobalVariable *EmuTlsVar =
GV->getParent()->getNamedGlobal(EmuTlsVarName);
assert(EmuTlsVar && "Cannot find EmuTlsVar ");
- Entry.Node = DAG.getGlobalAddress(EmuTlsVar, dl, PtrVT);
- Entry.Ty = VoidPtrType;
- Args.push_back(Entry);
+ Args.emplace_back(DAG.getGlobalAddress(EmuTlsVar, dl, PtrVT), VoidPtrType);
SDValue EmuTlsGetAddr = DAG.getExternalSymbol("__emutls_get_address", PtrVT);