[all-commits] [llvm/llvm-project] 16e530: [tblgen] Fix behavior of !isa to prevent premature...

Krzysztof Drewniak via All-commits all-commits at lists.llvm.org
Mon Mar 10 20:06:50 PDT 2025


  Branch: refs/heads/users/krzysz00/tablegen-isa-non-primary
  Home:   https://github.com/llvm/llvm-project
  Commit: 16e530498ac9e2850ba5028bdf3f716510c6b26a
      https://github.com/llvm/llvm-project/commit/16e530498ac9e2850ba5028bdf3f716510c6b26a
  Author: Krzysztof Drewniak <krzysdrewniak at gmail.com>
  Date:   2025-03-10 (Mon, 10 Mar 2025)

  Changed paths:
    M llvm/lib/TableGen/Record.cpp
    A llvm/test/TableGen/isa-non-primary.td

  Log Message:
  -----------
  [tblgen] Fix behavior of !isa to prevent premature folding

The test included with this commit shows a case where, even though a
record's true type was !isa<> some unrelated class, the isa<> operator
wolud use the declared type of the argument it was examining in order
to conclude that the !isa<> expression had to be be false.

The issues is fixed by checking to make sure that the argument to the
!isa operator is fully concrete before declaring its result to be false.



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