<html>
<head>
<base href="https://bugs.llvm.org/">
</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 - LLVM ERROR: Error parsing inline asm"
href="https://bugs.llvm.org/show_bug.cgi?id=33386">33386</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>LLVM ERROR: Error parsing inline asm
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>Macintosh
</td>
</tr>
<tr>
<th>OS</th>
<td>MacOS X
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>release blocker
</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>jonas@trust1team.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>Hi
I was trying to compile openssl-1.0.2g on my macOS (Sierra 10.12.5).
During the linking however I got an error:
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [link_app.] Error 1
make[1]: *** [dsatest] Error 2
make[1]: *** Waiting for unfinished jobs....
<inline asm>:1:12: error: invalid operand for instruction
divq $-8446744073709551616
^~~~~~~~~~~~~~~~~~~~~
LLVM ERROR: Error parsing inline asm
My clang version:
Apple LLVM version 8.1.0 (clang-802.0.42)
Target: x86_64-apple-darwin16.6.0
Thread model: posix
InstalledDir:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
Steps to Reproduce:
Download openssl 1.0.2g from <a href="https://www.openssl.org/source/old/1.0.2/">https://www.openssl.org/source/old/1.0.2/</a>.
Untar the openssl-1.0.2g.tar.gz
Open a terminal and go the the untarred openssl folder
Execute the following commands
export CC=clang
export CXX=clang++
export CFLAGS="-flto -mmacosx-version-min=10.9"
export LFLAGS="-flto -mmacosx-version-min=10.9"
./Configure darwin64-x86_64-cc -flto -mmacosx-version-min=10.9
make depend
make -j8
Expected Results:
Successful compilation of openssl
Observed Results:
Crash in the LLVM linker
making all in test...
( :; LIBDEPS="${LIBDEPS:--Wl,-search_paths_first -L.. -lssl -L.. -lcrypto }";
LDCMD="${LDCMD:-clang}"; LDFLAGS="${LDFLAGS:--DOPENSSL_THREADS -D_REENTRANT
-DDSO_DLFCN -DHAVE_DLFCN_H -flto -mmacosx-version-min=10.9 -arch x86_64 -O3
-DL_ENDIAN -Wall -DOPENSSL_IA32_SSE2 -DOPENSSL_BN_ASM_MONT
-DOPENSSL_BN_ASM_MONT5 -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM
-DSHA512_ASM -DMD5_ASM -DAES_ASM -DVPAES_ASM -DBSAES_ASM -DWHIRLPOOL_ASM
-DGHASH_ASM -DECP_NISTZ256_ASM}"; LIBPATH=`for x in $LIBDEPS; do echo $x; done
| sed -e 's/^ *-L//;t' -e d | uniq`; LIBPATH=`echo $LIBPATH | sed -e 's/
/:/g'`; LD_LIBRARY_PATH=$LIBPATH:$LD_LIBRARY_PATH ${LDCMD} ${LDFLAGS} -o
${APPNAME:=dsatest} dsatest.o ${LIBDEPS} )
<inline asm>:1:12: error: invalid operand for instruction
divq $-8446744073709551616
^~~~~~~~~~~~~~~~~~~~~
LLVM ERROR: Error parsing inline asm
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [link_app.] Error 1
make[1]: *** [dsatest] Error 2
make: *** [build_tests] Error 1
Version:
macOS Sierra 10.12.5
Notes:
I noticed that this error occurred from the Xcode 8.3 update (Apple LLVM
version 8.1.0). The version before this update worked just fine.</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>