Debugging: Add code to print backtrace for guest on SIGSEGV
[nativeclient.git] / tools / stubs / crti.S
blob4eba9699e0c22465a5f6a4852d991aad1fe3e9b8
1         /*
2          * The .init section contains one symbol, _init, which is the entry
3          * of a function and hence needs to be aligned in accordance with
4          * the NativeClient conventions.
5          */
6         .section .init
7         .p2align NACLENTRYALIGN
8         .global _init
9 _init:
10         pushl  %ebp
11         movl   %esp, %ebp
12         /*
13          * The code that follows will be appended by the linker, and will not
14          * be aligned individually, so we need to align it.
15          */
16         .p2align NACLENTRYALIGN
18         /*
19          * The .fini section contains one symbol, _fini, which is the entry
20          * of a function and hence needs to be aligned in accordance with
21          * the NativeClient conventions.
22          */
23         .section .fini
24         .p2align NACLENTRYALIGN
25         .global _fini
26 _fini:
27         push   %ebp
28         movl   %esp, %ebp
29         /*
30          * The code that follows will be appended by the linker, and will not
31          * be aligned individually, so we need to align it.
32          */
33         .p2align NACLENTRYALIGN
35         /*
36          * This section contains the simple rpc method descriptors.
37          */
38         .section .nacl_rpc_methods, "aw", @progbits
39         .p2align 3
40         .global __kNaClSrpcHandlers
41 __kNaClSrpcHandlers: