diff options
author | Kazu Hirata <kazu@google.com> | 2025-03-20 22:24:06 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-03-20 22:24:06 -0700 |
commit | 599005686a1c27ffe97bb4eb07fcd98359a2af99 (patch) | |
tree | 044944abd13d5134772d7507fef23ac7a6a52a21 /llvm/lib/CodeGen/CodeGenPrepare.cpp | |
parent | 13bb2f450ef9f64f393fe5527e5ac68362af8ccd (diff) | |
download | llvm-599005686a1c27ffe97bb4eb07fcd98359a2af99.zip llvm-599005686a1c27ffe97bb4eb07fcd98359a2af99.tar.gz llvm-599005686a1c27ffe97bb4eb07fcd98359a2af99.tar.bz2 |
[llvm] Use *Set::insert_range (NFC) (#132325)
DenseSet, SmallPtrSet, SmallSet, SetVector, and StringSet recently
gained C++23-style insert_range. This patch replaces:
Dest.insert(Src.begin(), Src.end());
with:
Dest.insert_range(Src);
This patch does not touch custom begin like succ_begin for now.
Diffstat (limited to 'llvm/lib/CodeGen/CodeGenPrepare.cpp')
-rw-r--r-- | llvm/lib/CodeGen/CodeGenPrepare.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/CodeGenPrepare.cpp b/llvm/lib/CodeGen/CodeGenPrepare.cpp index d5fbd4c..1a791f0 100644 --- a/llvm/lib/CodeGen/CodeGenPrepare.cpp +++ b/llvm/lib/CodeGen/CodeGenPrepare.cpp @@ -7577,7 +7577,7 @@ bool CodeGenPrepare::optimizeSelectInst(SelectInst *SI) { FalseBlock = StartBlock; SmallPtrSet<const Instruction *, 2> INS; - INS.insert(ASI.begin(), ASI.end()); + INS.insert_range(ASI); // Use reverse iterator because later select may use the value of the // earlier select, and we need to propagate value through earlier select // to get the PHI operand. |