Skip to content

Commit 9329900

Browse files
trbauerigcbot
authored andcommitted
G4 asm improvements for stray cases
Fixes some g4 syntax cases
1 parent 2b2a222 commit 9329900

File tree

1 file changed

+17
-4
lines changed

1 file changed

+17
-4
lines changed

visa/G4_SendDescs.cpp

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1464,11 +1464,24 @@ std::string G4_SendDescRaw::getDescription() const {
14641464
if (getBitField(desc.value, 15, 1))
14651465
ss << "t";
14661466
}
1467-
switch (getBitField(desc.value, 7, 2)) {
1468-
case 2: ss << ".a32"; break;
1469-
case 3: ss << ".a64"; break;
1470-
default: ss << "a?"; break;
1467+
bool hasImpliedA32 = false, hasImpliedA64 = false;
1468+
if (hasImpliedA32) {
1469+
ss << ".a32";
1470+
} else if (hasImpliedA64) {
1471+
ss << ".a64";
1472+
} else {
1473+
switch (getBitField(desc.value, 7, 2)) {
1474+
case 2: ss << ".a32"; break;
1475+
case 3: ss << ".a64"; break;
1476+
default: ss << ".a??"; break;
1477+
// certain messages have hardcoded or implied address sizes, and
1478+
// this will report .a?? for those, but good enough for internal debug
1479+
// for now
1480+
}
14711481
}
1482+
auto [l1,l3] = getCaching();
1483+
ss << ToSymbol(l1, l3);
1484+
14721485
switch (getBitField(desc.value, 29, 2)) {
14731486
case 0: ss << " flat[A"; break;
14741487
case 1: ss << " bss[..][A"; break;

0 commit comments

Comments
 (0)