C++: Add operand labels for more operand tags

I kept forgetting which operand on a Chi instruction was which, so I added dump labels. I added labels for the function target of a `Call`, for positional arguments, and for address operands as well.
This commit is contained in:
Dave Bartolomeo
2019-02-22 16:36:07 -08:00
parent a7f3160684
commit eed0894029
5 changed files with 1387 additions and 1367 deletions

View File

@@ -78,6 +78,10 @@ class AddressOperandTag extends RegisterOperandTag, TAddressOperand {
override final int getSortOrder() {
result = 0
}
override final string getLabel() {
result = "&:"
}
}
AddressOperandTag addressOperand() {
@@ -247,6 +251,10 @@ class CallTargetOperandTag extends RegisterOperandTag, TCallTargetOperand {
override final int getSortOrder() {
result = 10
}
override final string getLabel() {
result = "func:"
}
}
CallTargetOperandTag callTargetOperand() {
@@ -306,6 +314,10 @@ class PositionalArgumentOperandTag extends ArgumentOperandTag,
result = 12 + argIndex
}
override final string getLabel() {
result = argIndex.toString() + ":"
}
final int getArgIndex() {
result = argIndex
}
@@ -323,6 +335,10 @@ class ChiTotalOperandTag extends MemoryOperandTag, TChiTotalOperand {
override final int getSortOrder() {
result = 13
}
override final string getLabel() {
result = "total:"
}
}
ChiTotalOperandTag chiTotalOperand() {
@@ -337,6 +353,10 @@ class ChiPartialOperandTag extends MemoryOperandTag, TChiPartialOperand {
override final int getSortOrder() {
result = 14
}
override final string getLabel() {
result = "partial:"
}
}
ChiPartialOperandTag chiPartialOperand() {