[llvm] [IR] Add TargetExtType::CanBeAlloca property (PR #99016)

Jay Foad via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 17 03:01:31 PDT 2024


jayfoad wrote:

> The use case here is specifically a type that _is_ sized but cannot be used in alloca?

Yes. The use case I am interested in is special global objects that correspond to hardware resources that will be statically allocated by the backend. They can never be dynamically allocated.

> What about use in byval?

We definitely don't want them in byval - thanks!

Perhaps `MustBeGlobal` would be a better name to describe this property?

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


More information about the llvm-commits mailing list