summaryrefslogtreecommitdiff
path: root/cheri/cheri_prelude_common.sail
diff options
context:
space:
mode:
Diffstat (limited to 'cheri/cheri_prelude_common.sail')
-rw-r--r--cheri/cheri_prelude_common.sail7
1 files changed, 7 insertions, 0 deletions
diff --git a/cheri/cheri_prelude_common.sail b/cheri/cheri_prelude_common.sail
index 0072ded7..09e07f70 100644
--- a/cheri/cheri_prelude_common.sail
+++ b/cheri/cheri_prelude_common.sail
@@ -185,6 +185,13 @@ bitfield CapCauseReg : bits(16) = {
register CapCause : CapCauseReg
+val execute_branch_pcc : CapStruct -> unit effect {wreg}
+function execute_branch_pcc(newPCC) = {
+ delayedPC = to_bits(64, getCapOffset(newPCC));
+ delayedPCC = capStructToCapReg(newPCC);
+ branchPending = 0b1;
+}
+
function SignalException (ex) =
{
if (not (CP0Status.EXL())) then {