diff options
Diffstat (limited to 'compiler-rt/lib')
| -rw-r--r-- | compiler-rt/lib/asan/asan_rtl_x86_64.S | 1 | ||||
| -rw-r--r-- | compiler-rt/lib/builtins/assembly.h | 5 | ||||
| -rw-r--r-- | compiler-rt/lib/hwasan/hwasan_setjmp_x86_64.S | 1 | ||||
| -rw-r--r-- | compiler-rt/lib/orc/elfnix_tls.x86-64.S | 1 | ||||
| -rw-r--r-- | compiler-rt/lib/orc/sysv_reenter.x86-64.S | 1 | ||||
| -rw-r--r-- | compiler-rt/lib/profile/CMakeLists.txt | 6 | ||||
| -rw-r--r-- | compiler-rt/lib/profile/GCDAProfiling.c | 5 | ||||
| -rw-r--r-- | compiler-rt/lib/profile/InstrProfilingFile.c | 5 | ||||
| -rw-r--r-- | compiler-rt/lib/profile/InstrProfilingUtil.c | 5 | ||||
| -rw-r--r-- | compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_i386.inc.S | 2 | ||||
| -rw-r--r-- | compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_x86_64.inc.S | 2 | ||||
| -rw-r--r-- | compiler-rt/lib/tsan/rtl/tsan_rtl_amd64.S | 2 |
12 files changed, 32 insertions, 4 deletions
diff --git a/compiler-rt/lib/asan/asan_rtl_x86_64.S b/compiler-rt/lib/asan/asan_rtl_x86_64.S index 9c5289856d8a..5ee830d3afc5 100644 --- a/compiler-rt/lib/asan/asan_rtl_x86_64.S +++ b/compiler-rt/lib/asan/asan_rtl_x86_64.S @@ -5,6 +5,7 @@ #include "sanitizer_common/sanitizer_platform.h" .file "asan_rtl_x86_64.S" +.att_syntax #define NAME(n, reg, op, s, i) n##_##op##_##i##_##s##_##reg diff --git a/compiler-rt/lib/builtins/assembly.h b/compiler-rt/lib/builtins/assembly.h index d1e532813aa2..ac119af521a3 100644 --- a/compiler-rt/lib/builtins/assembly.h +++ b/compiler-rt/lib/builtins/assembly.h @@ -337,4 +337,9 @@ #endif #endif +#if defined(__ASSEMBLER__) && (defined(__i386__) || defined(__amd64__)) && \ + !defined(__arm64ec__) +.att_syntax +#endif + #endif // COMPILERRT_ASSEMBLY_H diff --git a/compiler-rt/lib/hwasan/hwasan_setjmp_x86_64.S b/compiler-rt/lib/hwasan/hwasan_setjmp_x86_64.S index 9804e8d7ceca..a5379d39c6e7 100644 --- a/compiler-rt/lib/hwasan/hwasan_setjmp_x86_64.S +++ b/compiler-rt/lib/hwasan/hwasan_setjmp_x86_64.S @@ -30,6 +30,7 @@ .section .text .file "hwasan_setjmp_x86_64.S" +.att_syntax .global ASM_WRAPPER_NAME(setjmp) ASM_TYPE_FUNCTION(ASM_WRAPPER_NAME(setjmp)) diff --git a/compiler-rt/lib/orc/elfnix_tls.x86-64.S b/compiler-rt/lib/orc/elfnix_tls.x86-64.S index b3e0bef00867..da202127bdbf 100644 --- a/compiler-rt/lib/orc/elfnix_tls.x86-64.S +++ b/compiler-rt/lib/orc/elfnix_tls.x86-64.S @@ -13,6 +13,7 @@ // The content of this file is x86_64-only #if defined(__x86_64__) +.att_syntax #define REGISTER_SAVE_SPACE_SIZE 512 diff --git a/compiler-rt/lib/orc/sysv_reenter.x86-64.S b/compiler-rt/lib/orc/sysv_reenter.x86-64.S index 0a36280f1d1f..99615c0468b9 100644 --- a/compiler-rt/lib/orc/sysv_reenter.x86-64.S +++ b/compiler-rt/lib/orc/sysv_reenter.x86-64.S @@ -12,6 +12,7 @@ // The content of this file is x86_64-only #if defined(__x86_64__) +.att_syntax // Save all GRPS except %rsp. // This value is also subtracted from %rsp below, despite the fact that %rbp diff --git a/compiler-rt/lib/profile/CMakeLists.txt b/compiler-rt/lib/profile/CMakeLists.txt index ac1451c8ceed..a6402f80b890 100644 --- a/compiler-rt/lib/profile/CMakeLists.txt +++ b/compiler-rt/lib/profile/CMakeLists.txt @@ -162,8 +162,7 @@ if(APPLE) CFLAGS ${EXTRA_FLAGS} SOURCES ${PROFILE_SOURCES} ADDITIONAL_HEADERS ${PROFILE_HEADERS} - PARENT_TARGET profile - EXTENSIONS ON) + PARENT_TARGET profile) else() add_compiler_rt_runtime(clang_rt.profile STATIC @@ -171,6 +170,5 @@ else() CFLAGS ${EXTRA_FLAGS} SOURCES ${PROFILE_SOURCES} ADDITIONAL_HEADERS ${PROFILE_HEADERS} - PARENT_TARGET profile - EXTENSIONS ON) + PARENT_TARGET profile) endif() diff --git a/compiler-rt/lib/profile/GCDAProfiling.c b/compiler-rt/lib/profile/GCDAProfiling.c index ac01805e70ad..523ade5eafc1 100644 --- a/compiler-rt/lib/profile/GCDAProfiling.c +++ b/compiler-rt/lib/profile/GCDAProfiling.c @@ -21,6 +21,11 @@ #if !defined(__Fuchsia__) +#if defined(__linux__) +// For fdopen() +#define _DEFAULT_SOURCE +#endif + #include <errno.h> #include <fcntl.h> #include <stdint.h> diff --git a/compiler-rt/lib/profile/InstrProfilingFile.c b/compiler-rt/lib/profile/InstrProfilingFile.c index 354f21b78615..71127b05aafb 100644 --- a/compiler-rt/lib/profile/InstrProfilingFile.c +++ b/compiler-rt/lib/profile/InstrProfilingFile.c @@ -8,6 +8,11 @@ #if !defined(__Fuchsia__) +#if defined(__linux__) +// For fileno(), ftruncate(), getpagesize(), setenv() +#define _DEFAULT_SOURCE +#endif + #include <assert.h> #include <errno.h> #include <stdio.h> diff --git a/compiler-rt/lib/profile/InstrProfilingUtil.c b/compiler-rt/lib/profile/InstrProfilingUtil.c index 0fae91cfb895..a9d9df813764 100644 --- a/compiler-rt/lib/profile/InstrProfilingUtil.c +++ b/compiler-rt/lib/profile/InstrProfilingUtil.c @@ -12,6 +12,11 @@ #include <windows.h> #include "WindowsMMap.h" #else +#if defined(__linux__) +// For fdopen(), fileno(), getpagesize(), madvise() +#define _DEFAULT_SOURCE +#endif + #include <errno.h> #include <fcntl.h> #include <sys/file.h> diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_i386.inc.S b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_i386.inc.S index c633014e2daa..5ef090c003dc 100644 --- a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_i386.inc.S +++ b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_i386.inc.S @@ -2,6 +2,8 @@ #include "sanitizer_common/sanitizer_asm.h" +.att_syntax + .comm _ZN14__interception10real_vforkE,4,4 .globl ASM_WRAPPER_NAME(vfork) ASM_TYPE_FUNCTION(ASM_WRAPPER_NAME(vfork)) diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_x86_64.inc.S b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_x86_64.inc.S index 5500f817aec5..9c85407fe022 100644 --- a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_x86_64.inc.S +++ b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_vfork_x86_64.inc.S @@ -2,6 +2,8 @@ #include "sanitizer_common/sanitizer_asm.h" +.att_syntax + .comm _ZN14__interception10real_vforkE,8,8 .globl ASM_WRAPPER_NAME(vfork) ASM_TYPE_FUNCTION(ASM_WRAPPER_NAME(vfork)) diff --git a/compiler-rt/lib/tsan/rtl/tsan_rtl_amd64.S b/compiler-rt/lib/tsan/rtl/tsan_rtl_amd64.S index f848be9dd46c..8b9b706a822d 100644 --- a/compiler-rt/lib/tsan/rtl/tsan_rtl_amd64.S +++ b/compiler-rt/lib/tsan/rtl/tsan_rtl_amd64.S @@ -3,6 +3,8 @@ #include "sanitizer_common/sanitizer_asm.h" +.att_syntax + #if !defined(__APPLE__) .section .text #else |
