Sandipan Das has uploaded this change for review. (
https://gem5-review.googlesource.com/c/public/gem5/+/40923 )
Change subject: arch-power: Add bit permute instructions
......................................................................
arch-power: Add bit permute instructions
This adds the following instructions.
* Bit Permute Doubleword (bpermd)
Change-Id: Iab3cc6729b9d59c95e29b4f1d3e2c0eb48fde917
Signed-off-by: Sandipan Das <[email protected]>
---
M src/arch/power/isa/decoder.isa
1 file changed, 13 insertions(+), 0 deletions(-)
diff --git a/src/arch/power/isa/decoder.isa b/src/arch/power/isa/decoder.isa
index 4482f2a..908ba3c 100644
--- a/src/arch/power/isa/decoder.isa
+++ b/src/arch/power/isa/decoder.isa
@@ -571,6 +571,19 @@
Ra = res;
}});
+ 252: bpermd({{
+ uint64_t res = 0;
+ for (int i = 0; i < 8; ++i) {
+ int index = (Rs >> (i * 8)) & 0xff;
+ if (index < 64) {
+ if (Rb & (1ULL << (63 - index))) {
+ res |= 1 << i;
+ }
+ }
+ }
+ Ra = res;
+ }});
+
24: slw({{
if (Rb & 0x20) {
Ra = 0;
--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/40923
To unsubscribe, or for help writing mail filters, visit
https://gem5-review.googlesource.com/settings
Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: Iab3cc6729b9d59c95e29b4f1d3e2c0eb48fde917
Gerrit-Change-Number: 40923
Gerrit-PatchSet: 1
Gerrit-Owner: Sandipan Das <[email protected]>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s