target/loongarch/cpu.c | 96 +++++++++--- target/loongarch/csr.c | 129 +++++++++++++++++ target/loongarch/csr.h | 29 ++++ target/loongarch/meson.build | 1 + .../tcg/insn_trans/trans_privileged.c.inc | 161 +++++---------------- target/loongarch/tcg/tcg_loongarch.h | 12 ++ target/loongarch/tcg/translate.c | 5 + 7 files changed, 294 insertions(+), 139 deletions(-) create mode 100644 target/loongarch/csr.c create mode 100644 target/loongarch/csr.h create mode 100644 target/loongarch/tcg/tcg_loongarch.h