[llvm] [clang] [NVPTX] Add 'activemask' builtin and intrinsic support (PR #79768)

Artem Belevich via cfe-commits cfe-commits at lists.llvm.org
Mon Jan 29 11:01:06 PST 2024


Artem-B wrote:

'activemask' is a rather peculiar instruction which may not be a good candidate for exposing it to LLVM.

The problem is that it can 'observe' the past branch decisions and reflects the state of not-yet-reconverged conditional branches. LLVM does not take it into account. Opaque inline assembly is the sledgehammer which stops LLVM from doing anything fancy with it. The intrinsic will need to have appropriately conservative attributes, at the very least.

I think we've had a bug about that and, if I recall correctly, we could not come up with a good way to handle activemask. Let me try finding the details.

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


More information about the cfe-commits mailing list