[llvm] [Analysis] Add cost model for experimental.cttz.elts intrinsic (PR #90720)

David Sherwood via llvm-commits llvm-commits at lists.llvm.org
Wed May 1 06:03:02 PDT 2024


david-arm wrote:

> I haven't looked or seen much codegen yet for this intrinsic, but is this "as cheap as an add instruction"?

Definitely not, but then I've not written it to be as cheap as an add instruction either. If we have to expand the intrinsic then the cost will be quite high. If we're not expanding the intrinsic then the only sensible thing that the BasicTTIImpl implementation can do is assume it's cheap and it's then up to the target cost model to override this in it's own getIntrinsicIntrCost function.

https://github.com/llvm/llvm-project/pull/90720


More information about the llvm-commits mailing list