If a record field was used as a template argument,
it wasn't fully evaluated leaving unfolded !ifs.
Fixes bug 30254 reduced testcase as reported.
Unfortunately, tablegen still errors when I remove
the workaround for this bug in the AMDGPU td files
so this might be incomplete.