https://bugs.llvm.org/show_bug.cgi?id=42445
Bug ID: 42445
Summary: clang -flto -Os/-Oz passes -Os/-Oz to lld (but lld
doesn't know what to do with it)
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: -New Bugs
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected],
[email protected], [email protected]
clang with -flto passes optimization levels to lld unmodified -- even if the
optimization level is one lld doesn't understand, such as -Os or -Oz.
This makes -flto with -Os/-Oz unusable.
$ clang -Os -fuse-ld=lld -flto test.c
ld.lld: error: -plugin-opt=Os: number expected, but got 's'
clang-9: error: linker command failed with exit code 1 (use -v to see
invocation)
$ clang -Oz -fuse-ld=lld -flto test.c
ld.lld: error: -plugin-opt=Oz: number expected, but got 'z'
clang-9: error: linker command failed with exit code 1 (use -v to see
invocation)
--
You are receiving this mail because:
You are on the CC list for the bug._______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs