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

Krzysztof Drewniak via All-commits all-commits at lists.llvm.org
Sat Mar 8 14:44:24 PST 2025


  Branch: refs/heads/users/krzysz00/tablegen-isa-non-primary
  Home:   https://github.com/llvm/llvm-project
  Commit: 1b2a73eccd879349475dff61ee7966805dc40edf
      https://github.com/llvm/llvm-project/commit/1b2a73eccd879349475dff61ee7966805dc40edf
  Author: Krzysztof Drewniak <krzysdrewniak at gmail.com>
  Date:   2025-03-08 (Sat, 08 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