Skip to content

Commit f6f9337

Browse files
committed
Fix a few missed spots
1 parent 9e3d9f2 commit f6f9337

File tree

4 files changed

+8
-4
lines changed

4 files changed

+8
-4
lines changed

llvm/lib/IR/Function.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1232,6 +1232,7 @@ bool llvm::CallingConv::supportsNonVoidReturnType(CallingConv::ID CC) {
12321232
case CallingConv::AArch64_SVE_VectorCall:
12331233
case CallingConv::WASM_EmscriptenInvoke:
12341234
case CallingConv::AMDGPU_Gfx:
1235+
case CallingConv::AMDGPU_Gfx_WholeWave:
12351236
case CallingConv::M68k_INTR:
12361237
case CallingConv::AArch64_SME_ABI_Support_Routines_PreserveMost_From_X0:
12371238
case CallingConv::AArch64_SME_ABI_Support_Routines_PreserveMost_From_X2:

llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3206,7 +3206,7 @@ bool GCNHazardRecognizer::fixRequiredExportPriority(MachineInstr *MI) {
32063206
// Check entry priority at each export (as there will only be a few).
32073207
// Note: amdgpu_gfx can only be a callee, so defer to caller setprio.
32083208
bool Changed = false;
3209-
if (CC != CallingConv::AMDGPU_Gfx)
3209+
if (CC != CallingConv::AMDGPU_Gfx && CC != CallingConv::AMDGPU_Gfx_WholeWave)
32103210
Changed = ensureEntrySetPrio(MF, NormalPriority, TII);
32113211

32123212
auto NextMI = std::next(It);

llvm/lib/Target/AMDGPU/SIISelLowering.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2258,7 +2258,8 @@ SDValue SITargetLowering::getPreloadedValue(
22582258
const ArgDescriptor WorkGroupIDZ =
22592259
ArgDescriptor::createRegister(AMDGPU::TTMP7, 0xFFFF0000u);
22602260
if (Subtarget->hasArchitectedSGPRs() &&
2261-
(AMDGPU::isCompute(CC) || CC == CallingConv::AMDGPU_Gfx)) {
2261+
(AMDGPU::isCompute(CC) || CC == CallingConv::AMDGPU_Gfx ||
2262+
CC == CallingConv::AMDGPU_Gfx_WholeWave)) {
22622263
switch (PVID) {
22632264
case AMDGPUFunctionArgInfo::WORKGROUP_ID_X:
22642265
Reg = &WorkGroupIDX;
@@ -2940,7 +2941,8 @@ SDValue SITargetLowering::LowerFormalArguments(
29402941
if (!Subtarget->enableFlatScratch())
29412942
assert(!UserSGPRInfo.hasFlatScratchInit());
29422943
if ((CallConv != CallingConv::AMDGPU_CS &&
2943-
CallConv != CallingConv::AMDGPU_Gfx) ||
2944+
CallConv != CallingConv::AMDGPU_Gfx &&
2945+
CallConv != CallingConv::AMDGPU_Gfx_WholeWave) ||
29442946
!Subtarget->hasArchitectedSGPRs())
29452947
assert(!Info->hasWorkGroupIDX() && !Info->hasWorkGroupIDY() &&
29462948
!Info->hasWorkGroupIDZ());

llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1423,7 +1423,8 @@ constexpr bool isShader(CallingConv::ID CC) {
14231423

14241424
LLVM_READNONE
14251425
constexpr bool isGraphics(CallingConv::ID CC) {
1426-
return isShader(CC) || CC == CallingConv::AMDGPU_Gfx;
1426+
return isShader(CC) || CC == CallingConv::AMDGPU_Gfx ||
1427+
CC == CallingConv::AMDGPU_Gfx_WholeWave;
14271428
}
14281429

14291430
LLVM_READNONE

0 commit comments

Comments
 (0)