[llvm-bugs] [Bug 36676] New: clang-cl asm output does not work with cc1as
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri Mar 9 09:43:53 PST 2018
https://bugs.llvm.org/show_bug.cgi?id=36676
Bug ID: 36676
Summary: clang-cl asm output does not work with cc1as
Product: clang
Version: unspecified
Hardware: PC
OS: Windows NT
Status: NEW
Severity: enhancement
Priority: P
Component: Frontend
Assignee: unassignedclangbugs at nondot.org
Reporter: nicolasweber at gmx.de
CC: llvm-bugs at lists.llvm.org
thakis at thakis:~/src/chrome/src$ cat test.cc
int printf(const char*, ...);
void f() {
char buffer[20];
printf(buffer);
}
thakis at thakis:~/src/chrome/src$
third_party/llvm-build/Release+Asserts/bin/clang-cl /TP /c test.cc /FA -m32
test.asm:29:7: error: unknown token in expression
call @__security_check_cookie at 4
^
/FA causes clang to not use the integrated assembler but instead to run a cc1as
pass on the generated .asm file -- and cc1as apparently doesn't like clang's
output.
I made /FA use intel assembly in r322652, which might be related.
clang-cl as far as I know doesn't have a flag like -S that means "only generate
assembly", it can only generate assembly as a side effect of compiling.
My motivation is to try and get whodis working with chrome/win translation
units in a cross build. whodis needs intel asm output. I'm trying to just tack
on '/FA /Z7 /Fafilename' to the compile command I get from the comp db, but hat
doesn't roundtrip. __security_check_cookie is one issue, another is `push
offset`:
/usr/local/google/home/thakis/src/chrome/src/out/gnwin/whodis.temp.asm:28933:14:
error: cannot use more than one symbol in memory operand
push offset "??_C at _02GFKOMOKH@?5?$CI?$AA@"
^
I think these are the only two types of errors. So I suppose the fix is to
teach the assembly parser about these two constructs?
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180309/ee7a0672/attachment.html>
More information about the llvm-bugs
mailing list