crti.S 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. # Start .init and .fini sections.
  2. # Copyright (C) 2003-2022 Free Software Foundation, Inc.
  3. #
  4. # This file is free software; you can redistribute it and/or modify it
  5. # under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 3, or (at your option)
  7. # any later version.
  8. #
  9. # GCC is distributed in the hope that it will be useful, but WITHOUT ANY
  10. # WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11. # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
  12. # for more details.
  13. #
  14. # Under Section 7 of GPL version 3, you are granted additional
  15. # permissions described in the GCC Runtime Library Exception, version
  16. # 3.1, as published by the Free Software Foundation.
  17. #
  18. # You should have received a copy of the GNU General Public License and
  19. # a copy of the GCC Runtime Library Exception along with this program;
  20. # see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
  21. # <http://www.gnu.org/licenses/>.
  22. # This file just makes a stack frame for the contents of the .fini and
  23. # .init sections. Users may put any desired instructions in those
  24. # sections.
  25. #include "xtensa-config.h"
  26. .section .init
  27. .globl _init
  28. .type _init,@function
  29. .align 4
  30. _init:
  31. #if XCHAL_HAVE_WINDOWED && !__XTENSA_CALL0_ABI__
  32. entry sp, 64
  33. #else
  34. addi sp, sp, -32
  35. s32i a0, sp, 0
  36. #endif
  37. .section .fini
  38. .globl _fini
  39. .type _fini,@function
  40. .align 4
  41. _fini:
  42. #if XCHAL_HAVE_WINDOWED && !__XTENSA_CALL0_ABI__
  43. entry sp, 64
  44. #else
  45. addi sp, sp, -32
  46. s32i a0, sp, 0
  47. #endif