[PATCH] D22748: AMDGPU: override shouldNormalizeToSelectSequence

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 25 13:15:45 PDT 2016


arsenm added a comment.

I think you should try https://reviews.llvm.org/D9419 instead (which will have the same result). HasMultipleConditionRegisters also impacts CodeGenPrepare unlike this. I never had time to look at the regression Tom found.

The problem is Whether or not this is really profitable depends on whether the select will be a scalar or vector select. CodeGenPrepare currently does something like this depending on HasMultipleConditionRegisters. I want to split out this code (which I also think is redundant with FlattenCFG) into a utility, and then have AMDGPUCodeGenPrepare decide to do this based on DivergenceAnalysis. The problem now is we don't ever use scalar selects, so that codegen problem should probably be fixed first.


https://reviews.llvm.org/D22748





More information about the llvm-commits mailing list