diff options
| author | Francis Visoiu Mistrih <fvisoiumistrih@apple.com> | 2017-05-17 01:07:53 +0000 |
|---|---|---|
| committer | Francis Visoiu Mistrih <fvisoiumistrih@apple.com> | 2017-05-17 01:07:53 +0000 |
| commit | b52e0366008436f6f994ce94cb6ad0f51d65ba8a (patch) | |
| tree | c6067844f69347f2f77a9094caff2644ddcffcf6 /llvm/lib/Target/WebAssembly | |
| parent | de83fec0299ac4bae25d7e36ef30feddba2b48ad (diff) | |
| download | bcm5719-llvm-b52e0366008436f6f994ce94cb6ad0f51d65ba8a.tar.gz bcm5719-llvm-b52e0366008436f6f994ce94cb6ad0f51d65ba8a.zip | |
BitVector: add iterators for set bits
Differential revision: https://reviews.llvm.org/D32060
llvm-svn: 303227
Diffstat (limited to 'llvm/lib/Target/WebAssembly')
| -rw-r--r-- | llvm/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp b/llvm/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp index 5fd4a8d1949..ba39b6cdb56 100644 --- a/llvm/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp +++ b/llvm/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp @@ -140,8 +140,7 @@ bool WebAssemblyRegColoring::runOnMachineFunction(MachineFunction &MF) { // Check if it's possible to reuse any of the used colors. if (!MRI->isLiveIn(Old)) - for (int C(UsedColors.find_first()); C != -1; - C = UsedColors.find_next(C)) { + for (unsigned C : UsedColors.set_bits()) { if (MRI->getRegClass(SortedIntervals[C]->reg) != RC) continue; for (LiveInterval *OtherLI : Assignments[C]) |

