Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "[libc][RISCV] Add naked attribute to setjmp/longjmp" #100193

Conversation

ilovepi
Copy link
Contributor

@ilovepi ilovepi commented Jul 23, 2024

Reverts #100036

This caused a failure on bots: https://lab.llvm.org/buildbot/#/builders/183/builds/1799

We likely need to discuss the particulars here a bit more deeply before either relanding or choosing an alternate solution

@llvmbot llvmbot added the libc label Jul 23, 2024
@ilovepi ilovepi merged commit 8bdc3d9 into main Jul 23, 2024
6 of 7 checks passed
@ilovepi ilovepi deleted the revert-100036-users/ilovepi/spr/libcriscv-add-naked-attribute-to-setjmplongjmp branch July 23, 2024 20:17
@llvmbot
Copy link
Member

llvmbot commented Jul 23, 2024

@llvm/pr-subscribers-libc

Author: Paul Kirth (ilovepi)

Changes

Reverts llvm/llvm-project#100036

This caused a failure on bots: https://lab.llvm.org/buildbot/#/builders/183/builds/1799

We likely need to discuss the particulars here a bit more deeply before either relanding or choosing an alternate solution


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

2 Files Affected:

  • (modified) libc/src/setjmp/riscv/longjmp.cpp (-1)
  • (modified) libc/src/setjmp/riscv/setjmp.cpp (-1)
diff --git a/libc/src/setjmp/riscv/longjmp.cpp b/libc/src/setjmp/riscv/longjmp.cpp
index b14f636659ac3..0f9537ccc4151 100644
--- a/libc/src/setjmp/riscv/longjmp.cpp
+++ b/libc/src/setjmp/riscv/longjmp.cpp
@@ -30,7 +30,6 @@
 
 namespace LIBC_NAMESPACE_DECL {
 
-[[gnu::naked]]
 LLVM_LIBC_FUNCTION(void, longjmp, (__jmp_buf * buf, int val)) {
   LOAD(ra, buf->__pc);
   LOAD(s0, buf->__regs[0]);
diff --git a/libc/src/setjmp/riscv/setjmp.cpp b/libc/src/setjmp/riscv/setjmp.cpp
index 92982cc9d74d4..12def578b56f3 100644
--- a/libc/src/setjmp/riscv/setjmp.cpp
+++ b/libc/src/setjmp/riscv/setjmp.cpp
@@ -29,7 +29,6 @@
 
 namespace LIBC_NAMESPACE_DECL {
 
-[[gnu::naked]]
 LLVM_LIBC_FUNCTION(int, setjmp, (__jmp_buf * buf)) {
   STORE(ra, buf->__pc);
   STORE(s0, buf->__regs[0]);

yuxuanchen1997 pushed a commit that referenced this pull request Jul 25, 2024
Summary:
Reverts #100036

This caused a failure on bots:
https://lab.llvm.org/buildbot/#/builders/183/builds/1799

We likely need to discuss the particulars here a bit more deeply before
either relanding or choosing an alternate solution.

Test Plan: 

Reviewers: 

Subscribers: 

Tasks: 

Tags: 


Differential Revision: https://phabricator.intern.facebook.com/D60251135
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants