<html>
<head>
<base href="https://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - -fopenmp does not define _OPENMP macro"
href="https://llvm.org/bugs/show_bug.cgi?id=23492">23492</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>-fopenmp does not define _OPENMP macro
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>-New Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>zhouyan@me.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Following recent news of Clang is OpenMP 3.1 complete, which is wonderful, I
tried to use clang with OpenMP support. Before I can run any more test, it
seems that the _OPENMP macro is not properly defined at all.
The following is a minimal example
#ifndef _OPENMP
#error NO OPENMP defined
#endif
int main () {}
And on compile line clang++ -fopenmp -o test test.cpp (or clang)
The following is more details of the build of clang
OS : CentOS 7 (updated daily)
LLVM subprojects in the build tree: LLVM, clang, compiler-rt, polly,
clang-extra-tools, libcxx, libcxxabi
CMake options:
args="$args -DCMAKE_BUILD_TYPE=Release"
args="$args -DCMAKE_INSTALL_PREFIX=/opt/LLVM/$prefix"
args="$args -DBUILD_SHARED_LIBS=ON"
args="$args -DLLVM_ENABLE_BACKTRACES=OFF"
args="$args -DLLVM_ENABLE_CRASH_OVERRIDES=OFF"
args="$args -DLLVM_ENABLE_PEDANTIC=OFF"
args="$args -DLLVM_ENABLE_WARNINGS=OFF"
args="$args -DLLVM_INCLUDE_DOCS=OFF"
args="$args -DLLVM_INCLUDE_EXAMPLES=OFF"
args="$args -DLLVM_INCLUDE_TESTS=OFF"
args="$args -DLLVM_TARGETS_TO_BUILD=host"</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>