blob: f9d5e60cdec6797a97d0dd1b61b05d1ee51e00f9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
Index: gcc-6-6.2.1-4.1/src/gcc/config/i386/gnu.h
===================================================================
--- gcc-6-6.2.1-4.1.orig/src/gcc/config/i386/gnu.h
+++ gcc-6-6.2.1-4.1/src/gcc/config/i386/gnu.h
@@ -37,11 +37,14 @@ along with GCC. If not, see <http://www
#ifdef TARGET_LIBC_PROVIDES_SSP
-/* Not supported yet. */
-# undef TARGET_THREAD_SSP_OFFSET
-
-/* Not supported yet. */
-# undef TARGET_CAN_SPLIT_STACK
-# undef TARGET_THREAD_SPLIT_STACK_OFFSET
+/* i386 glibc provides __stack_chk_guard in %gs:0x14. */
+#define TARGET_THREAD_SSP_OFFSET 0x14
+/* We only build the -fsplit-stack support in libgcc if the
+ assembler has full support for the CFI directives. */
+#if HAVE_GAS_CFI_PERSONALITY_DIRECTIVE
+#define TARGET_CAN_SPLIT_STACK
+#endif
+/* We steal the last transactional memory word. */
+#define TARGET_THREAD_SPLIT_STACK_OFFSET 0x30
#endif
|