From: Dmitry Preobrazhensky Date: Tue, 13 Sep 2022 09:41:39 +0000 (+0300) Subject: [AMDGPU][MC][GFX11] Add a helper function for identification of VOPD instructions X-Git-Tag: upstream/17.0.6~33684 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a80116efecef3ad52b30b2917bd33947e8d0981d;p=platform%2Fupstream%2Fllvm.git [AMDGPU][MC][GFX11] Add a helper function for identification of VOPD instructions Differential Revision: https://reviews.llvm.org/D133608 --- diff --git a/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp b/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp index b5fb390..c482eb7 100644 --- a/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp +++ b/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp @@ -427,6 +427,8 @@ unsigned getVOPDOpcode(unsigned Opc) { return Info ? Info->VOPDOp : ~0u; } +bool isVOPD(unsigned Opc) { return getVOPDOpcodeHelper(Opc); } + unsigned mapWMMA2AddrTo3AddrOpcode(unsigned Opc) { const WMMAOpcodeMappingInfo *Info = getWMMAMappingInfoFrom2AddrOpcode(Opc); return Info ? Info->Opcode3Addr : ~0u; diff --git a/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h b/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h index 51cf167..ceb1fcb 100644 --- a/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h +++ b/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h @@ -497,6 +497,9 @@ LLVM_READONLY int getVOPDFull(unsigned OpX, unsigned OpY); LLVM_READONLY +bool isVOPD(unsigned Opc); + +LLVM_READONLY unsigned mapWMMA2AddrTo3AddrOpcode(unsigned Opc); LLVM_READONLY