[WebAssembly] Use single-threaded mode when -matomics isn't enabled.
authorDan Gohman <dev@sunfishcode.online>
Fri, 5 Feb 2021 00:12:41 +0000 (16:12 -0800)
committerDan Gohman <dev@sunfishcode.online>
Fri, 5 Feb 2021 02:16:48 +0000 (18:16 -0800)
commit95da64da23ac3a5855a8934a738b0fa10aa1323c
treecbf612ed4a2c7a8c2aed2eaa6978ec3f8a546713
parent698c6b0a099b902722d9e89234e0205ac240c13e
[WebAssembly] Use single-threaded mode when -matomics isn't enabled.

When the -matomics feature is not enabled, disable POSIXThreads
mode and set the thread model to Single, so that we don't predefine
macros like `__STDCPP_THREADS__`.

Differential Revision: https://reviews.llvm.org/D96091
clang/lib/Basic/Targets/WebAssembly.cpp
clang/lib/Basic/Targets/WebAssembly.h
clang/test/Preprocessor/init.c