[all-commits] [llvm/llvm-project] 367d14: [TableGen] Emit constexpr versions of some directi...

Krzysztof Parzyszek via All-commits all-commits at lists.llvm.org
Tue Apr 28 06:50:57 PDT 2026


  Branch: refs/heads/users/kparzysz/tablegen-constexpr
  Home:   https://github.com/llvm/llvm-project
  Commit: 367d140414858c9a6c6296c32f42d9e632157593
      https://github.com/llvm/llvm-project/commit/367d140414858c9a6c6296c32f42d9e632157593
  Author: Krzysztof Parzyszek <Krzysztof.Parzyszek at amd.com>
  Date:   2026-04-28 (Tue, 28 Apr 2026)

  Changed paths:
    M llvm/test/TableGen/directive1.td
    M llvm/test/TableGen/directive2.td
    M llvm/utils/TableGen/Basic/DirectiveEmitter.cpp

  Log Message:
  -----------
  [TableGen] Emit constexpr versions of some directive/clause functions

A variant of https://github.com/llvm/llvm-project/pull/176253 with a
change to reduce compile-time impact.

Since "llvm_unreachable" is actually allowed in constexpr functions,
simply emit the bodies of the selected functions in the header file.

In the previous PR the `isAllowedClauseForDirective` function was made
constexpr, but since it was very long it had a significant impact on
compilation time. In this PR that function is no longer constexpr.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list