[llvm-branch-commits] [clang] release/20.x: [CSKY] Default to unsigned char (PR #126436)

via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Sun Feb 9 12:33:55 PST 2025


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-clang-driver

@llvm/pr-subscribers-clang

Author: None (llvmbot)

<details>
<summary>Changes</summary>

Backport d2047242e6d0f0deb7634ff22ab164354c520c79

Requested by: @<!-- -->arichardson

---
Full diff: https://github.com/llvm/llvm-project/pull/126436.diff


2 Files Affected:

- (modified) clang/lib/Driver/ToolChains/Clang.cpp (+1) 
- (modified) clang/test/Driver/csky-toolchain.c (+1) 


``````````diff
diff --git a/clang/lib/Driver/ToolChains/Clang.cpp b/clang/lib/Driver/ToolChains/Clang.cpp
index 589de953be5be1b..49c6d2b271b3812 100644
--- a/clang/lib/Driver/ToolChains/Clang.cpp
+++ b/clang/lib/Driver/ToolChains/Clang.cpp
@@ -1358,6 +1358,7 @@ static bool isSignedCharDefault(const llvm::Triple &Triple) {
       return true;
     return false;
 
+  case llvm::Triple::csky:
   case llvm::Triple::hexagon:
   case llvm::Triple::msp430:
   case llvm::Triple::ppcle:
diff --git a/clang/test/Driver/csky-toolchain.c b/clang/test/Driver/csky-toolchain.c
index 66485464652ac87..638ce64ec98cde3 100644
--- a/clang/test/Driver/csky-toolchain.c
+++ b/clang/test/Driver/csky-toolchain.c
@@ -3,6 +3,7 @@
 
 // RUN: %clang -### %s --target=csky 2>&1 | FileCheck -check-prefix=CC1 %s
 // CC1: "-cc1" "-triple" "csky"
+// CC1: "-fno-signed-char"
 
 // In the below tests, --rtlib=platform is used so that the driver ignores
 // the configure-time CLANG_DEFAULT_RTLIB option when choosing the runtime lib

``````````

</details>


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


More information about the llvm-branch-commits mailing list