]> granicus.if.org Git - clang/commit
[Atomic][X8664] set max atomic inline width according to the target
authorWei Mi <wmi@google.com>
Fri, 22 Sep 2017 16:30:00 +0000 (16:30 +0000)
committerWei Mi <wmi@google.com>
Fri, 22 Sep 2017 16:30:00 +0000 (16:30 +0000)
commit5c5aea8028aa58b347eaf3b552bc158a2a85ee18
tree59f3d84c43b86a2155750ad356c2183a68bd67d3
parent9687f1d501bfff51838e70d124cd9a7463e1a727
[Atomic][X8664] set max atomic inline width according to the target

This is to fix PR31620. MaxAtomicInlineWidth is set to 128 for x86_64. However
for target without cx16 support, 128 atomic operation will generate __sync_*
libcalls. The patch set MaxAtomicInlineWidth to 64 if the target doesn't support
cx16.

Differential Revision: https://reviews.llvm.org/D38046

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@313992 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Basic/TargetInfo.h
lib/Basic/Targets.cpp
lib/Basic/Targets/X86.h
test/CodeGenCXX/atomic-inline.cpp [new file with mode: 0644]
test/OpenMP/atomic_capture_codegen.cpp
test/OpenMP/atomic_read_codegen.c
test/OpenMP/atomic_update_codegen.cpp
test/OpenMP/atomic_write_codegen.c