Stoorx added a comment.

> easier in what respect?

I mean, easier for CPU :-)

The division operation reasonably seems to be more complex than bitwise AND. 
And since this function is pretty hot it can save a bit of performance.
(Actually that's just my assumption. I did not make benchmark really.)

Side thought: I suspect some advanced CPUs can optimize such kind of divisions 
by powers of 2 by themselves.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D149006/new/

https://reviews.llvm.org/D149006

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to