From d0ad7df94af7ded5e4a90cd17a6dddf27fc707e4 Mon Sep 17 00:00:00 2001 From: LLVM Packaging Team Date: Mon, 23 Sep 2024 13:23:31 +0200 Subject: [PATCH] mips-force-nomadd4 The MIPS port aims to support the Loongson 3 family of CPUs in addition of the other MIPS CPUs. On the Loongson 3 family the MADD4 instructions are fused, while they are not fused on the other MIPS CPUs. In order to support both, we have to disabled those instructions. For that, the patch below basically corresponds to the --with-madd4=no used on the GCC side. Gbp-Pq: Topic mips Gbp-Pq: Name mips-force-nomadd4.patch --- clang/lib/Basic/Targets/Mips.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/clang/lib/Basic/Targets/Mips.h b/clang/lib/Basic/Targets/Mips.h index 23d4e1b598..4095ccada3 100644 --- a/clang/lib/Basic/Targets/Mips.h +++ b/clang/lib/Basic/Targets/Mips.h @@ -336,6 +336,8 @@ public: HasMSA = true; else if (Feature == "+nomadd4") DisableMadd4 = true; + else if (Feature == "-nomadd4") + DisableMadd4 = false; else if (Feature == "+fp64") FPMode = FP64; else if (Feature == "-fp64") -- 2.30.2