These three function are similar to ffs but find the last bit set. They're available (at least) on FreeBSD. I'm not sure they're availalble elsewhere, I don't have a machine to test. A quick search shows Linux hasn't them.
I would like top perform fairly basic transformations on these, e.g. constant folding, so this patch can be seen as a preliminary step for those.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
OK. Could probably use a testcase, but this is probably where you're going with the next one.
-eric
Comment Actions
Yes, my next patch will add a testcase. I have still some pending reviews in SimplifyLibCalls but once I get approval for them I'll a new patch to optimize fls & friends.
Thanks for reviewing!