setjmp.S 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. /* setjmp for the Blackfin project
  2. *
  3. * Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
  4. * Copyright (C) 2003 Metrowerks
  5. * Based on code from Analog Devices.
  6. *
  7. * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
  8. */
  9. .text
  10. .global ___sigsetjmp;
  11. .type ___sigsetjmp,STT_FUNC;
  12. .align 4;
  13. ___sigsetjmp:
  14. [--SP] = P0; /* Save P0 */
  15. P0 = R0;
  16. R0 = [SP++];
  17. [P0 + 0x00] = R0; /* Save saved P0 */
  18. [P0 + 0x04] = P1;
  19. [P0 + 0x08] = P2;
  20. [P0 + 0x0C] = P3;
  21. [P0 + 0x10] = P4;
  22. [P0 + 0x14] = P5;
  23. [P0 + 0x18] = FP; /* Frame Pointer */
  24. [P0 + 0x1C] = SP; /* Stack Pointer */
  25. [P0 + 0x20] = P0; /* Data Registers */
  26. [P0 + 0x24] = R1;
  27. [P0 + 0x28] = R2;
  28. [P0 + 0x2C] = R3;
  29. [P0 + 0x30] = R4;
  30. [P0 + 0x34] = R5;
  31. [P0 + 0x38] = R6;
  32. [P0 + 0x3C] = R7;
  33. R0 = ASTAT;
  34. [P0 + 0x40] = R0;
  35. R0 = LC0; /* Loop Counters */
  36. [P0 + 0x44] = R0;
  37. R0 = LC1;
  38. [P0 + 0x48] = R0;
  39. R0 = A0.W; /* Accumulators */
  40. [P0 + 0x4C] = R0;
  41. R0 = A0.X;
  42. [P0 + 0x50] = R0;
  43. R0 = A1.W;
  44. [P0 + 0x54] = R0;
  45. R0 = A1.X;
  46. [P0 + 0x58] = R0;
  47. R0 = I0; /* Index Registers */
  48. [P0 + 0x5C] = R0;
  49. R0 = I1;
  50. [P0 + 0x60] = R0;
  51. R0 = I2;
  52. [P0 + 0x64] = R0;
  53. R0 = I3;
  54. [P0 + 0x68] = R0;
  55. R0 = M0; /* Modifier Registers */
  56. [P0 + 0x6C] = R0;
  57. R0 = M1;
  58. [P0 + 0x70] = R0;
  59. R0 = M2;
  60. [P0 + 0x74] = R0;
  61. R0 = M3;
  62. [P0 + 0x78] = R0;
  63. R0 = L0; /* Length Registers */
  64. [P0 + 0x7c] = R0;
  65. R0 = L1;
  66. [P0 + 0x80] = R0;
  67. R0 = L2;
  68. [P0 + 0x84] = R0;
  69. R0 = L3;
  70. [P0 + 0x88] = R0;
  71. R0 = B0; /* Base Registers */
  72. [P0 + 0x8C] = R0;
  73. R0 = B1;
  74. [P0 + 0x90] = R0;
  75. R0 = B2;
  76. [P0 + 0x94] = R0;
  77. R0 = B3;
  78. [P0 + 0x98] = R0;
  79. R0 = RETS;
  80. [P0 + 0x9C] = R0;
  81. R0 = [P0 + 0x20];
  82. JUMP.L ___sigjmp_save;
  83. .size ___sigsetjmp, .-___sigsetjmp
  84. .section .note.GNU-stack,"",%progbits