================
@@ -876,8 +874,8 @@ void
AMDGPUTargetMachine::registerPassBuilderCallbacks(PassBuilder &PB) {
});
PB.registerPipelineEarlySimplificationEPCallback(
----------------
yoonseoch wrote:
I think if AMDGPUAttributor can be added within
[PB.registerCGSCCOptimizerLateEPCallback](https://github.com/llvm/llvm-project/blob/3837db12e76c783f95a82804f74762453d6b4475/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp#L918-L948),
it can go after `function-attrs<skip-non-recursive-function-attrs›`,
`openmp-opt-cgscc` and before `AMDGPULowerKernelAttributes`.
(https://github.com/llvm/llvm-project/blob/3b0880a2c270c3bd493f39b2812afc7984198d8c/llvm/lib/Passes/PassBuilderPipelines.cpp#L1001-L1004).
Currently, AMDGPUAttributor is a module pass. To be added into
`PB.registerCGSCCOptimizerLateEPCallback`, it should become a CGSCC pass?
Did you suggest changing AMDGPUAtributor from a module pass to a CGSCC pass?
In the current code, some attributes, e.g. uniform-work-group-size, are
propagated from a caller (eventually a kernel) to a callee through by callee's
getAAFor invokes caller's getAAFor. (e.g. UniformWorkGroupSizeFunction's
updateImpl:
https://github.com/llvm/llvm-project/blob/9ca02a13a484ae351a4ba6dba725a4d232728dcb/llvm/lib/Target/AMDGPU/AMDGPUAttributor.cpp#L395-L419)
https://github.com/llvm/llvm-project/pull/178028
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits