diff options
author | Owen Anderson <resistor@mac.com> | 2014-03-13 21:25:10 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2014-03-13 21:25:10 +0000 |
commit | b8b4d3e0eb19fb80ce826a6a70fb44f9eff19cf4 (patch) | |
tree | 76ab9a610a2e88d2d36c54f052243ec866d85719 /include | |
parent | c5888b8d1be53aaf4d430928361da0a6bc1587bc (diff) | |
download | llvm-b8b4d3e0eb19fb80ce826a6a70fb44f9eff19cf4.tar.gz llvm-b8b4d3e0eb19fb80ce826a6a70fb44f9eff19cf4.tar.bz2 llvm-b8b4d3e0eb19fb80ce826a6a70fb44f9eff19cf4.tar.xz |
Fix a subtle issue introduced my my recent changes to MachineRegisterInfo iterators.
When initializing an iterator, we may have to step forward to find the first
operand that passes the current filter set. When doing that stepping, we should
always step one operand at a time, even if this is by-instr or by-bundle iterator,
as we're stepping between invalid values, so the stride doesn't make sense there.
Fixes a miscompilation of YASM on Win32 reported by Hans Wennborg. I have not
yet figured out how to reduce it to something testcase-able, because it's sensitive
to the details of how the registers get spilled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203852 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r-- | include/llvm/CodeGen/MachineRegisterInfo.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/llvm/CodeGen/MachineRegisterInfo.h b/include/llvm/CodeGen/MachineRegisterInfo.h index 01fa00fe24..7167595ec7 100644 --- a/include/llvm/CodeGen/MachineRegisterInfo.h +++ b/include/llvm/CodeGen/MachineRegisterInfo.h @@ -677,7 +677,7 @@ public: if ((!ReturnUses && op->isUse()) || (!ReturnDefs && op->isDef()) || (SkipDebug && op->isDebug())) - ++*this; + advance(); } } friend class MachineRegisterInfo; |