Skip to content

Commit 783c1a7

Browse files
authored
AMDGPU: skip AMDGPUAttributor pass on R600 some more. (#162418)
This is a follow-up for #162207, where I neglected to skip the second use of AMDGPUAttributor for R600 targets. This use is covered by the test lld/test/ELF/lto/r600.ll.
1 parent d01e1c1 commit 783c1a7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -966,7 +966,7 @@ void AMDGPUTargetMachine::registerPassBuilderCallbacks(PassBuilder &PB) {
966966
PM.addPass(InternalizePass(mustPreserveGV));
967967
PM.addPass(GlobalDCEPass());
968968
}
969-
if (EnableAMDGPUAttributor) {
969+
if (EnableAMDGPUAttributor && getTargetTriple().isAMDGCN()) {
970970
AMDGPUAttributorOptions Opt;
971971
if (HasClosedWorldAssumption)
972972
Opt.IsClosedWorld = true;

0 commit comments

Comments
 (0)