aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/X86
diff options
context:
space:
mode:
authorChad Rosier <mcrosier@apple.com>2012-02-15 00:36:26 +0000
committerChad Rosier <mcrosier@apple.com>2012-02-15 00:36:26 +0000
commit15b4497333430fbc3e20e5fb7718d4e0d838168b (patch)
tree5bf95d3fe9816059e0280bed1940e7b6063226c2 /lib/Target/X86
parent9989a63818581bcfeed730e42055af425fdf9353 (diff)
downloadexternal_llvm-15b4497333430fbc3e20e5fb7718d4e0d838168b.zip
external_llvm-15b4497333430fbc3e20e5fb7718d4e0d838168b.tar.gz
external_llvm-15b4497333430fbc3e20e5fb7718d4e0d838168b.tar.bz2
Use a temporary variable, rather then a series of redundant calls.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150538 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/X86')
-rw-r--r--lib/Target/X86/X86FastISel.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/Target/X86/X86FastISel.cpp b/lib/Target/X86/X86FastISel.cpp
index 13e20f4..952cd60 100644
--- a/lib/Target/X86/X86FastISel.cpp
+++ b/lib/Target/X86/X86FastISel.cpp
@@ -1576,10 +1576,11 @@ bool X86FastISel::DoSelectCall(const Instruction *I, const char *MemIntName) {
SmallVector<unsigned, 8> Args;
SmallVector<MVT, 8> ArgVTs;
SmallVector<ISD::ArgFlagsTy, 8> ArgFlags;
- Args.reserve(CS.arg_size());
- ArgVals.reserve(CS.arg_size());
- ArgVTs.reserve(CS.arg_size());
- ArgFlags.reserve(CS.arg_size());
+ unsigned arg_size = CS.arg_size();
+ Args.reserve(arg_size);
+ ArgVals.reserve(arg_size);
+ ArgVTs.reserve(arg_size);
+ ArgFlags.reserve(arg_size);
for (ImmutableCallSite::arg_iterator i = CS.arg_begin(), e = CS.arg_end();
i != e; ++i) {
// If we're lowering a mem intrinsic instead of a regular call, skip the