Skip to content

Commit 6dfabf6

Browse files
[AMDGPU] It's not profitable to narrow to i1
1 parent 5ab861f commit 6dfabf6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1040,6 +1040,8 @@ bool AMDGPUTargetLowering::isNarrowingProfitable(SDNode *N, EVT SrcVT,
10401040
case ISD::MUL:
10411041
case ISD::SETCC:
10421042
case ISD::SELECT:
1043+
if (DestVT.getScalarSizeInBits() == 1)
1044+
return false;
10431045
if (Subtarget->has16BitInsts() &&
10441046
(!DestVT.isVector() || !Subtarget->hasVOP3PInsts())) {
10451047
// Don't narrow back down to i16 if promoted to i32 already.

0 commit comments

Comments
 (0)