llvm-project
473f6ade - [IR] Make optnone imply noinline (#228169)

Commit
3 hours ago
[IR] Make optnone imply noinline (#228169) Previously the verifier required every `optnone` function to also carry `noinline`. Instead, make `optnone` imply `noinline` so the pairing is no longer necessary. To avoid each user having to remember to check both attributes, add `Function::isNoInline()` (true for `noinline` or `optnone`) and make `CallBase::isNoInline()` defer to it for the callee. Existing direct queries of `Attribute::NoInline` on functions are migrated to the helper. The verifier now explicitly rejects `alwaysinline` + `optnone`, which was previously only enforced transitively via the `noinline` requirement. ForceFunctionAttrs and llvm-reduce no longer need to keep the two attributes paired. Assisted-By: Claude
Author
Parents
Loading