summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/radeon/SIInstrInfo.cpp
diff options
context:
space:
mode:
authorTom Stellard <[email protected]>2012-06-02 09:51:04 -0400
committerTom Stellard <[email protected]>2012-06-06 13:46:04 -0400
commitf81e4663a766e71e907886640327abea4a0d78e2 (patch)
tree259c055e49e421d0a9ef792b38d7ba68ed15a080 /src/gallium/drivers/radeon/SIInstrInfo.cpp
parent1777c99bff40f160b09dd3c9708b0963c772610a (diff)
radeon/llvm: Add isMov() to AMDILInstrInfo
This enables the CFGStructurizer to work without the AMDIL::MOV* instructions.
Diffstat (limited to 'src/gallium/drivers/radeon/SIInstrInfo.cpp')
-rw-r--r--src/gallium/drivers/radeon/SIInstrInfo.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeon/SIInstrInfo.cpp b/src/gallium/drivers/radeon/SIInstrInfo.cpp
index 4c7a92075c6..058c772e620 100644
--- a/src/gallium/drivers/radeon/SIInstrInfo.cpp
+++ b/src/gallium/drivers/radeon/SIInstrInfo.cpp
@@ -115,3 +115,18 @@ MachineInstr * SIInstrInfo::getMovImmInstr(MachineFunction *MF, unsigned DstReg,
return MI;
}
+
+bool SIInstrInfo::isMov(unsigned Opcode) const
+{
+ switch(Opcode) {
+ default: return false;
+ case AMDIL::S_MOV_B32:
+ case AMDIL::S_MOV_B64:
+ case AMDIL::V_MOV_B32_e32:
+ case AMDIL::V_MOV_B32_e64:
+ case AMDIL::V_MOV_IMM_F32:
+ case AMDIL::V_MOV_IMM_I32:
+ case AMDIL::S_MOV_IMM_I32:
+ return true;
+ }
+}