summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp
diff options
context:
space:
mode:
authorColin LeMahieu <colinl@codeaurora.org>2016-10-08 17:18:51 +0000
committerColin LeMahieu <colinl@codeaurora.org>2016-10-08 17:18:51 +0000
commitc69f7ff6c075d24a8c509376f40f70644e159bee (patch)
tree7d67219d6fa7306b5314b85aa9f92d7b096319ae /llvm/lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp
parent897bab9b35dd80e10e8a9c34dcac072c173fcffb (diff)
downloadbcm5719-llvm-c69f7ff6c075d24a8c509376f40f70644e159bee.tar.gz
bcm5719-llvm-c69f7ff6c075d24a8c509376f40f70644e159bee.zip
[Hexagon] Adding change of flow max 1 (cofMax1) TS flag for marking this restriction rather than implying it from TypeJR.
llvm-svn: 283665
Diffstat (limited to 'llvm/lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp')
-rw-r--r--llvm/lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp b/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp
index 5187798f588..88f37d620dc 100644
--- a/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp
+++ b/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp
@@ -171,7 +171,7 @@ bool HexagonShuffler::check() {
unsigned slotJump = slotFirstJump;
unsigned slotLoadStore = slotFirstLoadStore;
// Number of branches, solo branches, indirect branches.
- unsigned jumps = 0, jump1 = 0, jumpr = 0;
+ unsigned jumps = 0, jump1 = 0;
// Number of memory operations, loads, solo loads, stores, solo stores, single
// stores.
unsigned memory = 0, loads = 0, load0 = 0, stores = 0, store0 = 0, store1 = 0;
@@ -207,6 +207,8 @@ bool HexagonShuffler::check() {
++pSlot3Cnt;
slot3ISJ = ISJ;
}
+ if (HexagonMCInstrInfo::isCofMax1(MCII, *ID))
+ ++jump1;
switch (HexagonMCInstrInfo::getType(MCII, *ID)) {
case HexagonII::TypeXTYPE:
@@ -214,8 +216,6 @@ bool HexagonShuffler::check() {
++xtypeFloat;
break;
case HexagonII::TypeJR:
- ++jumpr;
- LLVM_FALLTHROUGH;
case HexagonII::TypeJ:
++jumps;
break;
@@ -304,7 +304,7 @@ bool HexagonShuffler::check() {
if (HexagonMCInstrInfo::getDesc(MCII, *ID).isBranch() ||
HexagonMCInstrInfo::getDesc(MCII, *ID).isCall())
if (jumps > 1) {
- if (jumpr || slotJump < slotLastJump) {
+ if (slotJump < slotLastJump) {
// Error if indirect branch with another branch or
// no more slots available for branches.
Error = SHUFFLE_ERROR_BRANCHES;
OpenPOWER on IntegriCloud