Thread
:
index of lowest set bit
View Single Post
06 November 2021, 20:52
#
28
Photon
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,604
This code does that trick for your example input value in OP.
Code:
move.l d0,d1 subq.l #1,d1 and.l d0,d1 eor.l d1,d0
For the purpose of use with bfffo this can be reduced to
Code:
move.l d0,d1 subq.l #1,d1 eor.l d1,d0
Last edited by Photon; 06 November 2021 at
21:48
.
Photon
View Public Profile
Visit Photon's homepage!
Find More Posts by Photon
Page generated in
0.31470
seconds with
11
queries