split_i386_1.s 433 B

12345678910111213141516171819202122232425262728293031323334
  1. # split_i386_1.s: i386 specific test case for -fsplit-stack.
  2. .text
  3. .global fn1
  4. .type fn1,@function
  5. fn1:
  6. cmp %gs:0x30,%esp
  7. jae 1f
  8. call __morestack
  9. ret
  10. 1:
  11. call fn2
  12. ret
  13. .size fn1,. - fn1
  14. .global fn2
  15. .type fn2,@function
  16. fn2:
  17. lea -0x200(%esp),%ecx
  18. cmp %gs:0x30,%ecx
  19. jae 1f
  20. call __morestack
  21. ret
  22. 1:
  23. call fn1
  24. ret
  25. .size fn2,. - fn2
  26. .section .note.GNU-stack,"",@progbits
  27. .section .note.GNU-split-stack,"",@progbits