llvm-6502/test/TableGen/regmatch.td

12 lines
278 B
TableGen
Raw Normal View History

// RUN: tblgen %s | grep {Match1 = 1} | count 1
// RUN: tblgen %s | grep {Match2 = 1} | count 1
class Foo<string v> {
string Value = v;
int Match1 = !regmatch(".*ps$", v);
int Match2 = !regmatch(".*pd$", v);
}
def Bar : Foo<"addps">;
def Baz : Foo<"addpd">;