[PATCH] D98136: [RFC] Initially support the K-extension instructions on the LLVM MC layer

Xinlong Wu via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Mar 6 22:05:07 PST 2021


VincentWu created this revision.
VincentWu added reviewers: kito-cheng, MaskRay, craig.topper, HsiangKai, asb, jrtc27.
Herald added subscribers: frasercrmck, luismarques, apazos, sameer.abuasal, s.egerton, Jim, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, niosHD, sabuasal, simoncook, johnrusso, rbar, hiraditya.
VincentWu requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

This commit is currently implementing supports for scalar cryptography extension for LLVM according to version 0.9.0 (Pre-release) and version 0.8.1 of K Ext specification <https://github.com/riscv/riscv-crypto/releases>. Currently, we are implementing the MC (Machine Code) layer of his extension and the majority of work is done under `llvm/lib/Target/RISCV` directory. There are also some test files in `llvm/test/MC/RISCV/rvk` directory.

Add two new CSR, `MNOISE` and `MENTROPY`.
Add two new Immediate numbers, `uimm2` and `rcon`.

//**Recognising that it might be better to add the definition of the immediate number `uimm2` into file `RISCVInstrInfo.td`, we will update diff soon**//

**Co-author:**@ksyx & @VincentWu


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D98136

Files:
  llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
  llvm/lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.h
  llvm/lib/Target/RISCV/RISCV.td
  llvm/lib/Target/RISCV/RISCVInstrInfo.td
  llvm/lib/Target/RISCV/RISCVInstrInfoK.td
  llvm/lib/Target/RISCV/RISCVSubtarget.h
  llvm/lib/Target/RISCV/RISCVSystemOperands.td
  llvm/test/MC/RISCV/rvk/rv32k.s
  llvm/test/MC/RISCV/rvk/rv64k.s
  llvm/test/MC/RISCV/rvk/rvk-invalid.s

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D98136.328835.patch
Type: text/x-patch
Size: 23378 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210307/7595ffcf/attachment.bin>


More information about the llvm-commits mailing list