Bug 703531 - Fix ARMAssembler::getOp2RegScale on < ARMv5. r=cdleary

This commit is contained in:
Mike Hommey 2011-12-08 09:13:12 +01:00
parent 17d09c5aec
commit b0618a0c3f

View File

@ -112,10 +112,10 @@ ARMWord ARMAssembler::getOp2RegScale(RegisterID reg, ARMWord scale)
: // No clobbers.
);
#else
ARMWord lz = 0; // Accumulate leading zeroes.
lz = 0; // Accumulate leading zeroes.
for (ARMWord s = 16; s > 0; s /= 2) {
ARMWord mask = 0xffffffff << (32-lz-s);
if ((x & mask) == 0) {
if ((scale & mask) == 0) {
lz += s;
}
}