arch-power: Added dcbz instruction
authorKajoljain379 <kajoljain797@gmail.com>
Wed, 10 Apr 2019 05:40:49 +0000 (05:40 +0000)
committerKajol Jain <kajoljain797@gmail.com>
Wed, 12 Jun 2019 08:36:05 +0000 (14:06 +0530)
* Added dcbz cache instruction which used by kernel to clear multiple
  words at a time.

Change-Id: I7cfd7c93cac2d4419db987e7cf8fef8b4c71f805
Signed-off-by: Kajoljain379 <kajoljain797@gmail.com>
src/arch/power/isa/decoder.isa

index e72aae7fbaa02d80bd777e58bdb83a2adf00e197..667a732238517a74989f77ebdd0c32691c21b504 100644 (file)
@@ -966,6 +966,21 @@ decode PO default Unknown::unknown() {
         format MiscOp {
             278: dcbt({{ }});
             246: dcbtst({{ }});
+
+            1014: dcbz({{
+                  Request::Flags flags = Request::PHYSICAL;
+                  Addr EA;
+                  if(RA == 0)
+                    EA = Rb & -128ULL;
+                  else
+                    EA = (Ra + Rb) & -128ULL;
+                  Mem = 0;
+                  for (int i = 0; i < 16; ++i) {
+                    writeMemAtomic(xc, traceData, Mem,EA + i*8,
+                                            flags, NULL);
+                }
+            }});
+
             86: dcbf({{ }});
             598: sync({{ }}, [ IsMemBarrier ]);
             854: eieio({{ }}, [ IsMemBarrier ]);