OSDN Git Service
(root)
/
android-x86
/
external-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e5f4e9f
)
Avoid re-evaluating MI.getNumOperands() every iteration of the loop.
author
Jim Grosbach
<grosbach@apple.com>
Sat, 30 Oct 2010 01:40:16 +0000
(
01:40
+0000)
committer
Jim Grosbach
<grosbach@apple.com>
Sat, 30 Oct 2010 01:40:16 +0000
(
01:40
+0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@117766
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Target/ARM/ARMMCCodeEmitter.cpp
patch
|
blob
|
history
diff --git
a/lib/Target/ARM/ARMMCCodeEmitter.cpp
b/lib/Target/ARM/ARMMCCodeEmitter.cpp
index
b74fa73
..
d22f9b0
100644
(file)
--- a/
lib/Target/ARM/ARMMCCodeEmitter.cpp
+++ b/
lib/Target/ARM/ARMMCCodeEmitter.cpp
@@
-293,7
+293,7
@@
unsigned ARMMCCodeEmitter::getRegisterListOpValue(const MCInst &MI,
// Convert a list of GPRs into a bitfield (R0 -> bit 0). For each
// register in the list, set the corresponding bit.
unsigned Binary = 0;
- for (unsigned i = Op
; i < MI.getNumOperands()
; ++i) {
+ for (unsigned i = Op
, e = MI.getNumOperands(); i < e
; ++i) {
unsigned regno = getARMRegisterNumbering(MI.getOperand(i).getReg());
Binary |= 1 << regno;
}