diff options
author | Schrodinger ZHU Yifan <yifanzhu@rochester.edu> | 2024-07-31 09:26:49 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-07-31 09:26:49 -0700 |
commit | 3715035797a8b07ddaf2e2eff08fedc535891e15 (patch) | |
tree | e23d3bcf229cb15357367760742ef70d5c82bb7b | |
parent | d36c9f828d795d77127ea0fada6be4b7b5e19dbb (diff) | |
download | llvm-3715035797a8b07ddaf2e2eff08fedc535891e15.zip llvm-3715035797a8b07ddaf2e2eff08fedc535891e15.tar.gz llvm-3715035797a8b07ddaf2e2eff08fedc535891e15.tar.bz2 |
[libc] quick fix for aarch64 jmpbuf build (#101357)
-rw-r--r-- | libc/src/setjmp/aarch64/longjmp.cpp | 4 | ||||
-rw-r--r-- | libc/src/setjmp/aarch64/setjmp.cpp | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/libc/src/setjmp/aarch64/longjmp.cpp b/libc/src/setjmp/aarch64/longjmp.cpp index 3207cf4..fbb8652 100644 --- a/libc/src/setjmp/aarch64/longjmp.cpp +++ b/libc/src/setjmp/aarch64/longjmp.cpp @@ -22,7 +22,9 @@ namespace LIBC_NAMESPACE_DECL { // supports the MTE instructions, not whether the compiler is configured to use // them.) -[[gnu::naked]] LLVM_LIBC_FUNCTION(void, longjmp, (__jmp_buf * buf, int val)) { +[[gnu::naked]] LLVM_LIBC_FUNCTION(void, longjmp, + ([[maybe_unused]] __jmp_buf * buf, + [[maybe_unused]] int val)) { // If BTI branch protection is in use, the compiler will automatically insert // a BTI here, so we don't need to make any extra effort to do so. diff --git a/libc/src/setjmp/aarch64/setjmp.cpp b/libc/src/setjmp/aarch64/setjmp.cpp index ba4dd64..90e49be 100644 --- a/libc/src/setjmp/aarch64/setjmp.cpp +++ b/libc/src/setjmp/aarch64/setjmp.cpp @@ -12,7 +12,8 @@ namespace LIBC_NAMESPACE_DECL { -[[gnu::naked]] LLVM_LIBC_FUNCTION(int, setjmp, (__jmp_buf * buf)) { +[[gnu::naked]] LLVM_LIBC_FUNCTION(int, setjmp, + ([[maybe_unused]] __jmp_buf * buf)) { // If BTI branch protection is in use, the compiler will automatically insert // a BTI here, so we don't need to make any extra effort to do so. |