[PATCH] D81183: AMDGPU: Fix overriding global FP atomic feature predicates

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 4 12:09:38 PDT 2020


arsenm created this revision.
arsenm added a reviewer: rampitec.
Herald added subscribers: kerbowa, jfb, hiraditya, t-tye, tpr, dstuttard, yaxunl, nhaehnle, wdng, jvesely, kzhuravl.
Herald added a project: LLVM.

Global TableGen let override blocks are pretty dangerous and override
any local special cases. In this case, the broader HasFlatGlobalInsts
was overriding the more specific predicate for
FeatureAtomicFaddInsts. Make sure HasFlatGlobalInsts is implied by
FeatureAtomicFaddInsts, and make sure the right predicate is used.

      

One issue with independently setting the subtarget features on
incompatible targets is all of the encoding families do not define all
opcodes. This will hit an assert on gfx10 for example, since we set
the encoding independently based on the generation and not based on a
 feature.


https://reviews.llvm.org/D81183

Files:
  llvm/lib/Target/AMDGPU/AMDGPU.td
  llvm/lib/Target/AMDGPU/FLATInstructions.td
  llvm/test/CodeGen/AMDGPU/global-atomics-fp.ll
  llvm/test/CodeGen/AMDGPU/llvm.amdgcn.atomic.fadd.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D81183.268551.patch
Type: text/x-patch
Size: 4834 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200604/23e098fb/attachment.bin>


More information about the llvm-commits mailing list