summaryrefslogtreecommitdiff
path: root/src/display.rs
diff options
context:
space:
mode:
authoriximeow <me@iximeow.net>2025-04-06 19:58:42 -0700
committeriximeow <me@iximeow.net>2025-04-06 19:58:42 -0700
commitddeacaf13a9e18e9cfe9083cd39f72b2ff78e773 (patch)
treedb0c98a1e9c591e427545c7d5f3d43ad0fc5a238 /src/display.rs
parentdc1fb4bde1ea601e8be3a7ce3f4244344d1f8e3c (diff)
more pmpy, ignore shift_{left,right} with amt=0
Diffstat (limited to 'src/display.rs')
-rw-r--r--src/display.rs11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/display.rs b/src/display.rs
index f2b0e51..fc4fd3a 100644
--- a/src/display.rs
+++ b/src/display.rs
@@ -119,6 +119,14 @@ impl fmt::Display for Instruction {
return write!(f, "{} = add({}, mpyi({}, {}))", self.dest.as_ref().unwrap(),
self.sources[0], self.sources[1], self.sources[2]);
},
+ Opcode::MpyiPos => {
+ return write!(f, "{} = +mpyi({}, {})", self.dest.as_ref().unwrap(),
+ self.sources[0], self.sources[1]);
+ },
+ Opcode::MpyiNeg => {
+ return write!(f, "{} = -mpyi({}, {})", self.dest.as_ref().unwrap(),
+ self.sources[0], self.sources[1]);
+ },
Opcode::AddClb => {
return write!(f, "{} = add(clb({}), {})", self.dest.as_ref().unwrap(),
self.sources[0], self.sources[1]);
@@ -636,7 +644,8 @@ impl fmt::Display for Opcode {
Opcode::Vnegh => { f.write_str("vnegh") },
Opcode::Vcnegh => { f.write_str("vcnegh") },
- Opcode:: Pmpyw => { f.write_str("pmpyw") },
+ Opcode::Pmpyw => { f.write_str("pmpyw") },
+ Opcode::Vpmpyh => { f.write_str("vpmpyh") },
Opcode::Lfs => { f.write_str("lfs") },
Opcode:: Vxaddsubh => { f.write_str("vxaddsubh") },