[clang] [llvm] [RISCV] Add MIPS extensions (PR #121394)

Jessica Clarke via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 31 09:48:51 PST 2024


================
@@ -0,0 +1,82 @@
+//===-- RISCVInstrInfoXMips.td -----------------------------*- tablegen -*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+//
+// This file describes the vendor extensions defined by MIPS.
+//
+//===----------------------------------------------------------------------===//
+
+//===----------------------------------------------------------------------===//
+
+// MIPS extensions
+//===----------------------------------------------------------------------===//
+
+let Predicates = [HasVendorMIPSCMove], hasSideEffects = 0, mayLoad = 0, mayStore = 0, DecoderNamespace = "Xmipscomve" in {
+def CCMOV : RVInstR4<0b11, 0b011, OPC_CUSTOM_0, (outs GPR:$rd),
+                    (ins GPR:$rs1, GPR:$rs2, GPR:$rs3),
+                    "ccmov", "$rd, $rs2, $rs1, $rs3">,
----------------
jrtc27 wrote:

For upstreaming such a prefix must be registered: https://github.com/riscv-non-isa/riscv-toolchain-conventions/blob/08ae8fe66141c12ba436678c60a05da9ac08c4e6/src/toolchain-conventions.adoc#assembly-mnemonic

https://github.com/llvm/llvm-project/pull/121394


More information about the llvm-commits mailing list