Sandipan Das has uploaded this change for review. (
https://gem5-review.googlesource.com/c/public/gem5/+/40922 )
Change subject: arch-power: Add parity instructions
......................................................................
arch-power: Add parity instructions
This adds the following instructions.
* Parity Word (prtyw)
* Parity Doubleword (prtyd)
Change-Id: Ic102d722f1bc8cea4921ddbf9febfa0e7c0f892e
Signed-off-by: Sandipan Das <[email protected]>
---
M src/arch/power/isa/decoder.isa
1 file changed, 17 insertions(+), 0 deletions(-)
diff --git a/src/arch/power/isa/decoder.isa b/src/arch/power/isa/decoder.isa
index 08b9d10..4482f2a 100644
--- a/src/arch/power/isa/decoder.isa
+++ b/src/arch/power/isa/decoder.isa
@@ -554,6 +554,23 @@
506: popcntd({{ Ra = popCount(Rs); }});
+ 154: prtyw({{
+ uint64_t res = Rs;
+ res = res ^ (res >> 16);
+ res = res ^ (res >> 8);
+ res = res & 0x100000001;
+ Ra = res;
+ }});
+
+ 186: prtyd({{
+ uint64_t res = Rs;
+ res = res ^ (res >> 32);
+ res = res ^ (res >> 16);
+ res = res ^ (res >> 8);
+ res = res & 0x1;
+ Ra = res;
+ }});
+
24: slw({{
if (Rb & 0x20) {
Ra = 0;
--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/40922
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: Ic102d722f1bc8cea4921ddbf9febfa0e7c0f892e
Gerrit-Change-Number: 40922
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