diff options
author | Nikita Popov <npopov@redhat.com> | 2025-08-15 18:06:07 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-08-15 18:06:07 +0200 |
commit | 01bc7421855889dcc3b10a131928e3a4a8e4b38c (patch) | |
tree | 80bbb9dd9cd8717e5d9bc654bceadad42164d907 /llvm/lib/CodeGen/SelectionDAG/FastISel.cpp | |
parent | 1d1e52e614f95eed5ee440b43fa1992e46976629 (diff) | |
download | llvm-01bc7421855889dcc3b10a131928e3a4a8e4b38c.zip llvm-01bc7421855889dcc3b10a131928e3a4a8e4b38c.tar.gz llvm-01bc7421855889dcc3b10a131928e3a4a8e4b38c.tar.bz2 |
[CodeGen] Give ArgListEntry a proper constructor (NFC) (#153817)
This ensures that the required fields are set, and also makes the
construction more convenient.
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/FastISel.cpp')
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/FastISel.cpp | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp b/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp index ac1913b..9467ba1 100644 --- a/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp @@ -729,9 +729,7 @@ bool FastISel::lowerCallOperands(const CallInst *CI, unsigned ArgIdx, assert(!V->getType()->isEmptyTy() && "Empty type passed to intrinsic."); - ArgListEntry Entry; - Entry.Val = V; - Entry.Ty = V->getType(); + ArgListEntry Entry(V); Entry.setAttributes(CI, ArgI); Args.push_back(Entry); } @@ -978,9 +976,7 @@ bool FastISel::lowerCallTo(const CallInst *CI, MCSymbol *Symbol, assert(!V->getType()->isEmptyTy() && "Empty type passed to intrinsic."); - ArgListEntry Entry; - Entry.Val = V; - Entry.Ty = V->getType(); + ArgListEntry Entry(V); Entry.setAttributes(CI, ArgI); Args.push_back(Entry); } @@ -1116,7 +1112,6 @@ bool FastISel::lowerCall(const CallInst *CI) { Type *RetTy = CI->getType(); ArgListTy Args; - ArgListEntry Entry; Args.reserve(CI->arg_size()); for (auto i = CI->arg_begin(), e = CI->arg_end(); i != e; ++i) { @@ -1126,9 +1121,7 @@ bool FastISel::lowerCall(const CallInst *CI) { if (V->getType()->isEmptyTy()) continue; - Entry.Val = V; - Entry.Ty = V->getType(); - + ArgListEntry Entry(V); // Skip the first return-type Attribute to get to params. Entry.setAttributes(CI, i - CI->arg_begin()); Args.push_back(Entry); |