Skip to content

Commit 78aec9b

Browse files
gustavoSNPSvineetgarc
authored andcommitted
ARC: bitops: Remove unecessary operation and value
The 1-bit shift rotation to the left on x variable located on 4 last if statement can be removed because the computed value is will not be used afront. Signed-off-by: Gustavo Pimentel <gustavo.pimentel@synopsys.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
1 parent 3b57533 commit 78aec9b

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

arch/arc/include/asm/bitops.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -243,10 +243,8 @@ static inline int constant_fls(unsigned int x)
243243
x <<= 2;
244244
r -= 2;
245245
}
246-
if (!(x & 0x80000000u)) {
247-
x <<= 1;
246+
if (!(x & 0x80000000u))
248247
r -= 1;
249-
}
250248
return r;
251249
}
252250

0 commit comments

Comments
 (0)