summaryrefslogtreecommitdiff
path: root/assembler
diff options
context:
space:
mode:
authorHomer Hsing <homer.xing@intel.com>2012-09-18 13:25:53 +0800
committerDamien Lespiau <damien.lespiau@intel.com>2013-03-04 15:54:32 +0000
commit74383f4db4c348be1fd3c227653493c8eb5dab67 (patch)
tree5643c2661530ad112cb0d41b8835620e0f9b7496 /assembler
parent375d1fd7b2858accb91c277b8606eaa98837ce75 (diff)
Explain the difference between binaryinstruction and binaryaccinstruction
Developers may add new instructions in wrong place in the future if they don't know the difference between binaryinstruction and binaryaccinstruction.
Diffstat (limited to 'assembler')
-rw-r--r--assembler/src/gram.y4
1 files changed, 4 insertions, 0 deletions
diff --git a/assembler/src/gram.y b/assembler/src/gram.y
index ad53a084..58940cbe 100644
--- a/assembler/src/gram.y
+++ b/assembler/src/gram.y
@@ -367,6 +367,8 @@ instrseq: instrseq pragma
;
/* 1.4.1: Instruction groups */
+// binaryinstruction: Source operands cannot be accumulators
+// binaryaccinstruction: Source operands can be accumulators
instruction: unaryinstruction
| binaryinstruction
| binaryaccinstruction
@@ -417,6 +419,7 @@ unaryop: MOV | FRC | RNDU | RNDD | RNDE | RNDZ | NOT | LZD | BFREV | CBIT
| F16TO32 | F32TO16 | FBH | FBL
;
+// Source operands cannot be accumulators
binaryinstruction:
predicate binaryop conditionalmodifier saturate execsize
dst src srcimm instoptions
@@ -454,6 +457,7 @@ binaryinstruction:
binaryop: MUL | MAC | MACH | LINE | SAD2 | SADA2 | DP4 | DPH | DP3 | DP2 | SUBB
;
+// Source operands can be accumulators
binaryaccinstruction:
predicate binaryaccop conditionalmodifier saturate execsize
dst srcacc srcimm instoptions