[llvm] Add the 'initializes' attribute langref and support (PR #84803)

Arthur Eubanks via llvm-commits llvm-commits at lists.llvm.org
Wed May 8 22:15:16 PDT 2024


aeubanks wrote:

> FWIW, what I originally had in mind was to actually not have separate ConstantRange and ConstantRangeList attribute kinds, and only have the latter -- the existing ConstantRange kind would just be a list with a single element.
> 
> The upside of doing that is that we have less attribute kinds to deal with :) The downside is that the representation for the single-attribute case becomes less efficient (because we have to explicitly store the size 1).

The less efficient single-range seems ok if the single range attributes aren't too common and have too many unique ranges. It's hard to predict the future to know if this will be the case. Supporting a separate ConstantRangeList attribute doesn't seem too bad though, so I'm leaning toward keeping them separate.

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


More information about the llvm-commits mailing list