arch-riscv: Implemented zicbom/zicboz extensions for RISC V

Change-Id: I79d0e6059a2dbb5a0057c4f7489b999f9e803684
This commit is contained in:
zmckevitt
2023-06-29 23:23:02 +00:00
committed by Roger Chang
parent 6e39f2097d
commit 14c25a383c
2 changed files with 24 additions and 0 deletions

View File

@@ -677,6 +677,23 @@ decode QUADRANT default Unknown::unknown() {
0x1: fence_i({{
}}, uint64_t, IsNonSpeculative, IsSerializeAfter, No_OpClass);
}
0x2: decode FUNCT12 {
format CBMOp {
0x0: cbo_inval({{
Mem = 0;
}}, mem_flags=[INVALIDATE, DST_POC]);
0x1: cbo_clean({{
Mem = 0;
}}, mem_flags=[CLEAN, DST_POC]);
0x2: cbo_flush({{
Mem = 0;
}}, mem_flags=[CLEAN, INVALIDATE, DST_POC]);
0x4: cbo_zero({{
Mem = 0;
}}, mem_flags=[CACHE_BLOCK_ZERO]);
}
}
}
0x04: decode FUNCT3 {

View File

@@ -243,3 +243,10 @@ def format Store(memacc_code, ea_code={{EA = rvZext(Rs1 + offset);}},
LoadStoreBase(name, Name, offset_code, ea_code, memacc_code, mem_flags,
inst_flags, 'Store', exec_template_base='Store')
}};
def format CBMOp(memacc_code, ea_code={{EA = rvZext(Rs1 + offset);}},
offset_code={{offset = 0;}}, mem_flags=[], inst_flags=[]) {{
(header_output, decoder_output, decode_block, exec_output) = \
LoadStoreBase(name, Name, offset_code, ea_code, memacc_code, mem_flags,
inst_flags, 'Store', exec_template_base='Store')
}};