diff options
| author | Robert Norton | 2018-05-18 15:41:36 +0100 |
|---|---|---|
| committer | Robert Norton | 2018-05-18 15:41:40 +0100 |
| commit | 29b96cc942b0032044e2d219afb89a08d2c88ef6 (patch) | |
| tree | 0c091e4ebb19e2743e79bacdd0ceb899ab49ad29 | |
| parent | 7548f9b549bbb2b23598d3eb62eca1c3feeeb5cc (diff) | |
cheri: add support for clc with big immediate (clcbi). This is quite easily done by making it decode to same CLC ast node and extending length of immediate field to 16 bits. cscbi is not supported as the feeling is that it will not be needed.
| -rw-r--r-- | cheri/cheri_insts.sail | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/cheri/cheri_insts.sail b/cheri/cheri_insts.sail index 2f083411..045c8152 100644 --- a/cheri/cheri_insts.sail +++ b/cheri/cheri_insts.sail @@ -183,10 +183,11 @@ function clause decode (0b010010 @ 0b10000 @ rs : regno @ cb : regno @ rd : regn function clause decode (0b010010 @ 0b10000 @ rs : regno @ cb : regno @ rd : regno @ 0b0000 @ 0b11) = Some(CStore(rs, cb, 0b00000, rd, 0b00000000, D, true)) /* CSCD */ function clause decode (0b111110 @ cs : regno @ cb : regno@ rt : regno @ offset : bits(11)) = Some(CSC(cs, cb, rt, 0b00000, offset, false)) -function clause decode (0b010010 @ 0b10000 @ cs : regno @ cb : regno@ rd : regno @ 0b00 @ 0b0111) = Some(CSC(cs, cb, 0b00000, rd, 0b00000000000, true)) +function clause decode (0b010010 @ 0b10000 @ cs : regno @ cb : regno@ rd : regno @ 0b00 @ 0b0111) = Some(CSC(cs, cb, 0b00000, rd, 0b00000000000, true)) /* CSCC */ -function clause decode (0b110110 @ cd : regno @ cb : regno@ rt : regno @ offset : bits(11)) = Some(CLC(cd, cb, rt, offset, false)) -function clause decode (0b010010 @ 0b10000 @ cd : regno @ cb : regno@ 0b0000000 @ 0b1111) = Some(CLC(cd, cb, 0b00000, 0b00000000000, true)) +function clause decode (0b110110 @ cd : regno @ cb : regno @ rt : regno @ offset : bits(11)) = Some(CLC(cd, cb, rt, sign_extend(offset), false)) /* CLC */ +function clause decode (0b010010 @ 0b10000 @ cd : regno @ cb : regno@ 0b0000000 @ 0b1111) = Some(CLC(cd, cb, 0b00000, 0x0000, true)) /* CLLC */ +function clause decode (0b011101 @ cd : regno @ cb : regno @ offset : bits(16)) = Some(CLC(cd, cb, 0b00000, offset, false)) /* CLCBI */ function clause decode (0b010010 @ 0b00100 @ rt : regno @ 0x0006) = Some(C2Dump(rt)) @@ -1298,7 +1299,7 @@ function clause execute (CSC(cs, cb, rt, rd, offset, conditional)) = } } -union clause ast = CLC : (regno, regno, regno, bits(11), bool) +union clause ast = CLC : (regno, regno, regno, bits(16), bool) function clause execute (CLC(cd, cb, rt, offset, linked)) = { checkCP2usable(); |
