<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 --- - clang fails to compile magick/attribute.c from ImageMagick using -fopenmp=libiomp5 -Xclang -fopenmp=libiomp5"
href="https://llvm.org/bugs/show_bug.cgi?id=23387">23387</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>clang fails to compile magick/attribute.c from ImageMagick using -fopenmp=libiomp5 -Xclang -fopenmp=libiomp5
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>3.6
</td>
</tr>
<tr>
<th>Hardware</th>
<td>Macintosh
</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>howarth.mailing.lists@gmail.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>Created <span class=""><a href="attachment.cgi?id=14274" name="attach_14274" title="preprocessed source for magick/attribute.c from ImageMagick">attachment 14274</a> <a href="attachment.cgi?id=14274&action=edit" title="preprocessed source for magick/attribute.c from ImageMagick">[details]</a></span>
preprocessed source for magick/attribute.c from ImageMagick
The build of ImageMagick-6.8.2-6 and ImageMagick-6.9.1-2 both fail using
current clang 3.7 svn with the proposed patches from
<a href="http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20150427/128219.html">http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20150427/128219.html</a>
and
<a href="http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20150427/128227.html">http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20150427/128227.html</a>
applied. The compilation of magick/attribute.c fails with the error...
magick/attribute.c:180:60: warning: extra tokens at the end of '#pragma omp
parallel for' are ignored [-Wextra-tokens]
#pragma omp parallel for schedule(static,4) shared(status)
magick_threads(image,image,image->rows,1)
^
magick/attribute.c:329:60: warning: extra tokens at the end of '#pragma omp
parallel for' are ignored [-Wextra-tokens]
#pragma omp parallel for schedule(static,4) shared(status)
magick_threads(image,image,1,1)
^
magick/attribute.c:332:7: error: loop iteration variable in the associated loop
of 'omp parallel for' directive may not be threadprivate or thread local,
predetermined as
private
for (i=0; i < (ssize_t) image->colors; i++)
^
magick/attribute.c:300:5: note: loop iteration variable is predetermined as
linear
i;
^
magick/attribute.c:480:60: warning: extra tokens at the end of '#pragma omp
parallel for' are ignored [-Wextra-tokens]
#pragma omp parallel for schedule(static,4) shared(status)
magick_threads(image,image,image->rows,1)
^
magick/attribute.c:873:60: warning: extra tokens at the end of '#pragma omp
parallel for' are ignored [-Wextra-tokens]
#pragma omp parallel for schedule(static,4) shared(status)
magick_threads(image,image,1,1)
^
magick/attribute.c:876:7: error: loop iteration variable in the associated loop
of 'omp parallel for' directive may not be threadprivate or thread local,
predetermined as
private
for (i=0; i < (ssize_t) image->colors; i++)
^
magick/attribute.c:870:9: note: loop iteration variable is predetermined as
linear
i;
^
magick/attribute.c:966:60: warning: extra tokens at the end of '#pragma omp
parallel for' are ignored [-Wextra-tokens]
#pragma omp parallel for schedule(static,4) shared(status)
magick_threads(image,image,image->rows,1)
^
5 warnings and 2 errors generated.
The error can be reproduced with the attached attributes.i preprocessed source
file and the command...
clang-3.7 -DHAVE_CONFIG_H -DMAGICKCORE_HDRI_ENABLE=1
-DMAGICKCORE_QUANTUM_DEPTH=16 -O3 -g -fopenmp=libiomp5 -Xclang
-fopenmp=libiomp5 -Wall -fexceptions -D_FORTIFY_SOURCE=0 -D_THREAD_SAFE
-DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -c attribute.i</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>