Mercurial > hg > CbC > CbC_gcc
comparison gcc/config/arc/linux.h @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children | 1830386684a0 |
comparison
equal
deleted
inserted
replaced
111:04ced10e8804 | 131:84e7813d76e9 |
---|---|
1 /* Target macros for arc*-*-linux targets. | 1 /* Target macros for arc*-*-linux targets. |
2 | 2 |
3 Copyright (C) 2017 Free Software Foundation, Inc. | 3 Copyright (C) 2017-2018 Free Software Foundation, Inc. |
4 | 4 |
5 This file is part of GCC. | 5 This file is part of GCC. |
6 | 6 |
7 GCC is free software; you can redistribute it and/or modify | 7 GCC is free software; you can redistribute it and/or modify |
8 it under the terms of the GNU General Public License as published by | 8 it under the terms of the GNU General Public License as published by |
27 { \ | 27 { \ |
28 GNU_USER_TARGET_OS_CPP_BUILTINS (); \ | 28 GNU_USER_TARGET_OS_CPP_BUILTINS (); \ |
29 } \ | 29 } \ |
30 while (0) | 30 while (0) |
31 | 31 |
32 #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2" | 32 #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-arc.so.2" |
33 #define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" | 33 #define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" |
34 | 34 |
35 /* Note that the default is to link against dynamic libraries, if they are | 35 /* Note that the default is to link against dynamic libraries, if they are |
36 available. Override with -static. */ | 36 available. Override with -static. */ |
37 #undef LINK_SPEC | 37 #undef LINK_SPEC |
59 #define LIB_SPEC \ | 59 #define LIB_SPEC \ |
60 "%{pthread:-lpthread} \ | 60 "%{pthread:-lpthread} \ |
61 %{shared:-lc} \ | 61 %{shared:-lc} \ |
62 %{!shared:%{profile:-lc_p}%{!profile:-lc}}" | 62 %{!shared:%{profile:-lc_p}%{!profile:-lc}}" |
63 | 63 |
64 #undef TARGET_ASM_FILE_END | |
64 #define TARGET_ASM_FILE_END file_end_indicate_exec_stack | 65 #define TARGET_ASM_FILE_END file_end_indicate_exec_stack |
65 | 66 |
66 /* No SDATA default for linux. */ | 67 /* No SDATA default for linux. */ |
67 #undef TARGET_SDATA_DEFAULT | 68 #undef TARGET_SDATA_DEFAULT |
68 #define TARGET_SDATA_DEFAULT 0 | 69 #define TARGET_SDATA_DEFAULT 0 |
89 #define TARGET_INDEXED_LOADS_DEFAULT 0 | 90 #define TARGET_INDEXED_LOADS_DEFAULT 0 |
90 | 91 |
91 /* Pre/post modify with register displacement are default off. */ | 92 /* Pre/post modify with register displacement are default off. */ |
92 #undef TARGET_AUTO_MODIFY_REG_DEFAULT | 93 #undef TARGET_AUTO_MODIFY_REG_DEFAULT |
93 #define TARGET_AUTO_MODIFY_REG_DEFAULT 0 | 94 #define TARGET_AUTO_MODIFY_REG_DEFAULT 0 |
95 | |
96 #if DEFAULT_LIBC == LIBC_GLIBC | |
97 /* Override linux.h LINK_EH_SPEC definition. | |
98 Signalize that because we have fde-glibc, we don't need all C shared libs | |
99 linked against -lgcc_s. */ | |
100 #undef LINK_EH_SPEC | |
101 #define LINK_EH_SPEC "--eh-frame-hdr " | |
102 #endif | |
103 | |
104 #undef SUBTARGET_CPP_SPEC | |
105 #define SUBTARGET_CPP_SPEC "\ | |
106 %{pthread:-D_REENTRANT} \ | |
107 " | |
108 | |
109 /* Build attribute: procedure call standard. */ | |
110 #undef ATTRIBUTE_PCS | |
111 #define ATTRIBUTE_PCS 3 | |
112 | |
113 /* Clear the instruction cache from `beg' to `end'. This makes an | |
114 inline system call to SYS_cacheflush. */ | |
115 #undef CLEAR_INSN_CACHE | |
116 #define CLEAR_INSN_CACHE(beg, end) \ | |
117 { \ | |
118 register unsigned long _beg __asm ("r0") = (unsigned long) (beg); \ | |
119 register unsigned long _end __asm ("r1") = (unsigned long) (end); \ | |
120 register unsigned long _xtr __asm ("r2") = 0; \ | |
121 register unsigned long _scno __asm ("r8") = 244; \ | |
122 __asm __volatile ("trap_s 0 ; sys_cache_sync" \ | |
123 : "=r" (_beg) \ | |
124 : "0" (_beg), "r" (_end), "r" (_xtr), "r" (_scno)); \ | |
125 } |