Skip to content

Commit 6c3f5af

Browse files
committed
Revert "[AMDGPU] Identify vector idiom to unlock SROA"
This reverts commit fe45cb1.
1 parent fe45cb1 commit 6c3f5af

File tree

6 files changed

+0
-965
lines changed

6 files changed

+0
-965
lines changed

llvm/lib/Target/AMDGPU/AMDGPUPassRegistry.def

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,6 @@ FUNCTION_PASS("amdgpu-simplifylib", AMDGPUSimplifyLibCallsPass())
6969
FUNCTION_PASS("amdgpu-unify-divergent-exit-nodes",
7070
AMDGPUUnifyDivergentExitNodesPass())
7171
FUNCTION_PASS("amdgpu-usenative", AMDGPUUseNativeCallsPass())
72-
FUNCTION_PASS("amdgpu-vector-idiom",
73-
AMDGPUVectorIdiomCombinePass(/*MaxBytes=*/32))
7472
FUNCTION_PASS("si-annotate-control-flow", SIAnnotateControlFlowPass(*static_cast<const GCNTargetMachine *>(this)))
7573
#undef FUNCTION_PASS
7674

llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
#include "AMDGPUTargetObjectFile.h"
3030
#include "AMDGPUTargetTransformInfo.h"
3131
#include "AMDGPUUnifyDivergentExitNodes.h"
32-
#include "AMDGPUVectorIdiom.h"
3332
#include "AMDGPUWaitSGPRHazards.h"
3433
#include "GCNDPPCombine.h"
3534
#include "GCNIterativeScheduler.h"
@@ -850,12 +849,6 @@ void AMDGPUTargetMachine::registerPassBuilderCallbacks(PassBuilder &PB) {
850849
EnablePromoteKernelArguments)
851850
FPM.addPass(AMDGPUPromoteKernelArgumentsPass());
852851

853-
// Run vector-idiom canonicalization early (after inlining) and before
854-
// infer-AS / SROA to maximize scalarization opportunities.
855-
// Specify 32 bytes since the largest HIP vector types are double4 or
856-
// long4.
857-
FPM.addPass(AMDGPUVectorIdiomCombinePass(/*MaxBytes=*/32));
858-
859852
// Add infer address spaces pass to the opt pipeline after inlining
860853
// but before SROA to increase SROA opportunities.
861854
FPM.addPass(InferAddressSpacesPass());
@@ -918,8 +911,6 @@ void AMDGPUTargetMachine::registerPassBuilderCallbacks(PassBuilder &PB) {
918911
if (EnableLowerModuleLDS)
919912
PM.addPass(AMDGPULowerModuleLDSPass(*this));
920913
if (Level != OptimizationLevel::O0) {
921-
PM.addPass(createModuleToFunctionPassAdaptor(
922-
AMDGPUVectorIdiomCombinePass(/*MaxBytes=*/32)));
923914
// Do we really need internalization in LTO?
924915
if (InternalizeSymbols) {
925916
PM.addPass(InternalizePass(mustPreserveGV));

0 commit comments

Comments
 (0)