OLD | NEW |
1 /****************************************************************************** | 1 /****************************************************************************** |
2 * Copyright (C) 2009-2014, International Business Machines | 2 * Copyright (C) 2009-2015, International Business Machines |
3 * Corporation and others. All Rights Reserved. | 3 * Corporation and others. All Rights Reserved. |
4 ******************************************************************************* | 4 ******************************************************************************* |
5 */ | 5 */ |
6 #include "unicode/utypes.h" | 6 #include "unicode/utypes.h" |
7 | 7 |
8 #if U_PLATFORM_HAS_WIN32_API | 8 #if U_PLATFORM_HAS_WIN32_API |
9 # define VC_EXTRALEAN | 9 # define VC_EXTRALEAN |
10 # define WIN32_LEAN_AND_MEAN | 10 # define WIN32_LEAN_AND_MEAN |
11 # define NOUSER | 11 # define NOUSER |
12 # define NOSERVICE | 12 # define NOSERVICE |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
113 int8_t hexType; /* HEX_0X or HEX_0h */ | 113 int8_t hexType; /* HEX_0X or HEX_0h */ |
114 } assemblyHeader[] = { | 114 } assemblyHeader[] = { |
115 /* For gcc assemblers, the meaning of .align changes depending on the */ | 115 /* For gcc assemblers, the meaning of .align changes depending on the */ |
116 /* hardware, so we use .balign 16 which always means 16 bytes. */ | 116 /* hardware, so we use .balign 16 which always means 16 bytes. */ |
117 /* https://sourceware.org/binutils/docs/as/Pseudo-Ops.html */ | 117 /* https://sourceware.org/binutils/docs/as/Pseudo-Ops.html */ |
118 {"gcc", | 118 {"gcc", |
119 ".globl %s\n" | 119 ".globl %s\n" |
120 "\t.section .note.GNU-stack,\"\",%%progbits\n" | 120 "\t.section .note.GNU-stack,\"\",%%progbits\n" |
121 "\t.section .rodata\n" | 121 "\t.section .rodata\n" |
122 "\t.balign 16\n" | 122 "\t.balign 16\n" |
123 /* The 3 lines below are added for Chrome. */ | |
124 "#ifdef U_HIDE_DATA_SYMBOL\n" | 123 "#ifdef U_HIDE_DATA_SYMBOL\n" |
125 "\t.hidden %s\n" | 124 "\t.hidden %s\n" |
126 "#endif\n" | 125 "#endif\n" |
127 "\t.type %s,%%object\n" | 126 "\t.type %s,%%object\n" |
128 "%s:\n\n", | 127 "%s:\n\n", |
129 | 128 |
130 ".long ","",HEX_0X | 129 ".long ","",HEX_0X |
131 }, | 130 }, |
132 {"gcc-darwin", | 131 {"gcc-darwin", |
133 /*"\t.section __TEXT,__text,regular,pure_instructions\n" | 132 /*"\t.section __TEXT,__text,regular,pure_instructions\n" |
134 "\t.section __TEXT,__picsymbolstub1,symbol_stubs,pure_instructions,32\n"
*/ | 133 "\t.section __TEXT,__picsymbolstub1,symbol_stubs,pure_instructions,32\n"
*/ |
135 ".globl _%s\n" | 134 ".globl _%s\n" |
136 /* The 3 lines below are added for Chrome. */ | |
137 "#ifdef U_HIDE_DATA_SYMBOL\n" | 135 "#ifdef U_HIDE_DATA_SYMBOL\n" |
138 "\t.private_extern _%s\n" | 136 "\t.private_extern _%s\n" |
139 "#endif\n" | 137 "#endif\n" |
140 "\t.data\n" | 138 "\t.data\n" |
141 "\t.const\n" | 139 "\t.const\n" |
142 "\t.balign 16\n" | 140 "\t.balign 16\n" |
143 "_%s:\n\n", | 141 "_%s:\n\n", |
144 | 142 |
145 ".long ","",HEX_0X | 143 ".long ","",HEX_0X |
146 }, | 144 }, |
(...skipping 1043 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1190 | 1188 |
1191 if(T_FileStream_error(out)) { | 1189 if(T_FileStream_error(out)) { |
1192 fprintf(stderr, "genccode: file write error while generating from file %
s\n", filename); | 1190 fprintf(stderr, "genccode: file write error while generating from file %
s\n", filename); |
1193 exit(U_FILE_ACCESS_ERROR); | 1191 exit(U_FILE_ACCESS_ERROR); |
1194 } | 1192 } |
1195 | 1193 |
1196 T_FileStream_close(out); | 1194 T_FileStream_close(out); |
1197 T_FileStream_close(in); | 1195 T_FileStream_close(in); |
1198 } | 1196 } |
1199 #endif | 1197 #endif |
OLD | NEW |