Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(859)

Side by Side Diff: src/untrusted/stubs/crti_x86_32.S

Issue 639113003: Add nacl-clang testing to SCons (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: ncbray comment Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/trusted/validator/nacl.scons ('k') | src/untrusted/stubs/crti_x86_64.S » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2011 The Native Client Authors. All rights reserved. 2 * Copyright (c) 2011 The Native Client Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be 3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file. 4 * found in the LICENSE file.
5 */ 5 */
6 6 #if !defined(__clang__)
7 /* 7 /*
8 * The .init section contains one symbol, _init, which is the entry 8 * The .init section contains one symbol, _init, which is the entry
9 * of a function and hence needs to be aligned in accordance with 9 * of a function and hence needs to be aligned in accordance with
10 * the NativeClient conventions. 10 * the NativeClient conventions.
11 */ 11 */
12 .section .init 12 .section .init
13 .p2align NACLENTRYALIGN 13 .p2align NACLENTRYALIGN
14 .global _init 14 .global _init
15 _init: 15 _init:
16 pushl %ebp 16 pushl %ebp
17 movl %esp, %ebp 17 movl %esp, %ebp
18 18
19 /* 19 /*
20 * The code that follows will be appended by the linker, and will not 20 * The code that follows will be appended by the linker, and will not
21 * be aligned individually, so we need to align it. 21 * be aligned individually, so we need to align it.
22 */ 22 */
23 .p2align NACLENTRYALIGN 23 .p2align NACLENTRYALIGN
24 24
25 /* 25 /*
26 * The .fini section contains one symbol, _fini, which is the entry 26 * The .fini section contains one symbol, _fini, which is the entry
27 * of a function and hence needs to be aligned in accordance with 27 * of a function and hence needs to be aligned in accordance with
28 * the NativeClient conventions. 28 * the NativeClient conventions.
29 */ 29 */
30 .section .fini 30 .section .fini
31 .p2align NACLENTRYALIGN 31 .p2align NACLENTRYALIGN
32 .global _fini 32 .global _fini
33 _fini: 33 _fini:
34 pushl %ebp 34 pushl %ebp
35 movl %esp, %ebp 35 movl %esp, %ebp
36 #else
37 /*
38 * nacl-clang does not use the .init/.fini mechanism at all, but newlib
39 * still calls _init and _fini, so define them as empty functions in the
40 * text section.
41 */
42 .section .text
43 .p2align NACLENTRYALIGN
44 .global _init
45 _init:
46 naclret
36 47
48 .p2align NACLENTRYALIGN
49 .global _fini
50 _fini:
51 naclret
52 #endif
37 /* 53 /*
38 * The code that follows will be appended by the linker, and will not 54 * The code that follows will be appended by the linker, and will not
39 * be aligned individually, so we need to align it. 55 * be aligned individually, so we need to align it.
40 */ 56 */
41 .p2align NACLENTRYALIGN 57 .p2align NACLENTRYALIGN
OLDNEW
« no previous file with comments | « src/trusted/validator/nacl.scons ('k') | src/untrusted/stubs/crti_x86_64.S » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698