__longjmp.S 602 B

1234567891011121314151617181920212223242526
  1. /* Copyright (C) 2002, David McCullough <davidm@snapgear.com> */
  2. /* This file is released under the LGPL, any version you like */
  3. #include <features.h>
  4. #include <jmpbuf-offsets.h>
  5. .globl __longjmp
  6. .type __longjmp,@function
  7. .align 4
  8. __longjmp:
  9. moveal %sp@(4), %a0
  10. movel %sp@(8), %d0
  11. bne 1f
  12. movel #1, %d0
  13. 1:
  14. moveml %a0@(JB_REGS), %d2-%d7/%a2-%a7
  15. #if defined __mcffpu__ && defined __UCLIBC_HAS_FPU__
  16. fmovem %a0@(JB_FPREGS), %fp2-%fp7
  17. #elif defined __HAVE_68881__ || defined __UCLIBC_HAS_FPU__
  18. fmovemx %a0@(JB_FPREGS), %fp2-%fp7
  19. #endif
  20. movel %a0@(JB_PC), %sp@
  21. rts
  22. libc_hidden_def(__longjmp)