tls.c (840e70929b3bc0bfdbccfd8d8626d6e2f29ddbcf) | tls.c (d422e6f9b5dc816cd43a5d33b04b7f04ba7716d7) |
---|---|
1/*- 2 * Copyright (c) 2004 Doug Rabson 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 51 unchanged lines hidden (view full) --- 60void *_rtld_allocate_tls(void *oldtls, size_t tcbsize, size_t tcbalign); 61void _rtld_free_tls(void *tls, size_t tcbsize, size_t tcbalign); 62void *__libc_allocate_tls(void *oldtls, size_t tcbsize, size_t tcbalign); 63void __libc_free_tls(void *tls, size_t tcbsize, size_t tcbalign); 64 65#if defined(__amd64__) 66#define TLS_TCB_ALIGN 16 67#elif defined(__powerpc__) || defined(__i386__) || defined(__arm__) || \ | 1/*- 2 * Copyright (c) 2004 Doug Rabson 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 51 unchanged lines hidden (view full) --- 60void *_rtld_allocate_tls(void *oldtls, size_t tcbsize, size_t tcbalign); 61void _rtld_free_tls(void *tls, size_t tcbsize, size_t tcbalign); 62void *__libc_allocate_tls(void *oldtls, size_t tcbsize, size_t tcbalign); 63void __libc_free_tls(void *tls, size_t tcbsize, size_t tcbalign); 64 65#if defined(__amd64__) 66#define TLS_TCB_ALIGN 16 67#elif defined(__powerpc__) || defined(__i386__) || defined(__arm__) || \ |
68 defined(__sparc64__) || defined(__mips__) | 68 defined(__sparc64__) || defined(__mips__) || defined(__aarch64__) |
69#define TLS_TCB_ALIGN sizeof(void *) 70#else 71#error TLS_TCB_ALIGN undefined for target architecture 72#endif 73 | 69#define TLS_TCB_ALIGN sizeof(void *) 70#else 71#error TLS_TCB_ALIGN undefined for target architecture 72#endif 73 |
74#if defined(__arm__) || defined(__mips__) || defined(__powerpc__) | 74#if defined(__arm__) || defined(__mips__) || defined(__powerpc__) || \ 75 defined(__aarch64__) |
75#define TLS_VARIANT_I 76#endif 77#if defined(__i386__) || defined(__amd64__) || defined(__sparc64__) 78#define TLS_VARIANT_II 79#endif 80 81#ifndef PIC 82 --- 244 unchanged lines hidden --- | 76#define TLS_VARIANT_I 77#endif 78#if defined(__i386__) || defined(__amd64__) || defined(__sparc64__) 79#define TLS_VARIANT_II 80#endif 81 82#ifndef PIC 83 --- 244 unchanged lines hidden --- |