ano*_*non 13 multithreading gcc g++ pthreads clang
我正在从g ++切换到clang
但是,在g ++中,我有-pthread标志,clang似乎无法识别.
clang中的等价物是什么?
编辑:我的clang build正在从2010年3月5日的svn开始.
vy3*_*y32 32
clang -pthread在编译时需要,但在链接时不需要.这很烦人,但观察到的行为:
$ clang -c x.cpp
$ clang -pthread -c x.cpp
$ clang -o x x.o
$ clang -pthread -o x x.o
clang: warning: argument unused during compilation: '-pthread'
$
$ clang --version
Apple LLVM version 5.0 (clang-500.2.76) (based on LLVM 3.3svn)
Target: x86_64-apple-darwin13.0.0
Thread model: posix
$
Run Code Online (Sandbox Code Playgroud)