[llvm-bugs] [Bug 42831] New: clang drops the -flto=full when compiling an assembler file
via llvm-bugs
llvm-bugs at lists.llvm.org
Tue Jul 30 12:03:59 PDT 2019
https://bugs.llvm.org/show_bug.cgi?id=42831
Bug ID: 42831
Summary: clang drops the -flto=full when compiling an assembler
file
Product: clang
Version: 8.0
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: -New Bugs
Assignee: unassignedclangbugs at nondot.org
Reporter: belangerj at ainfosec.com
CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org,
neeilans at live.com, richard-llvm at metafoo.co.uk
When I type the following (note: for a .c file and -flto=full specified):
----------------------------
$ clang -flto-full -W<others> -f<others> -c test.c -o test.c.o -v
clang version 8.0.8
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /home/users/me/llvm/bin
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/5.5.0
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/6.0.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.5.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6.0.0
Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.4.0
Candidate multilib: .;@m64
Candidate multilib: 32;@m32
Candidate multilib: x32;@m32
Selected multilib: .;@m64
"/home/users/me/llvm/bin/clang-8" \
-cc1 \
-triple x86_64-unknown-linux-gnu \
-emit-llvm-bc \
-flto=full \ # <<<<< Note: -flto=full
-flto-unit \
-disable-free \
-disable-llvm-verifier \
-discard-value-names \
-main-file-name test.c \
-mrelocation-model pic \
-pic-level 2 \
-mthread-model posix \
-fmerge-all-constants \
-fmath-errno \
-masm-verbose \
-mconstructor-aliases \
-munwind-tables \
-fuse-init-array \
-target-cpu x86-64 \
-dwarf-column-info \
-debugger-tuning=gdb \
-momit-leaf-frame-pointer \
-v \
-coverage-notes-file test.c.gcno \
-nostdsysteminc \
-nobuiltininc \
-resource-dir /home/users/me/llvm/lib/clang/8.0.0 \
<all-my-includes> \
<all-my-supplied-options> \
-o test.c.o \
-x c \
test.c \
-faddrsig
clang -cc1 version 8.0.0 based upon LLVM 8.0.0 default target
x86_64-unknown-linux-gnu
#include "..." search starts here:
#include <...> search starts here:
<list-of-my-include-files>
End of search list.
----------------------------
When I type the following (note for a .S file):
----------------------------
$ clang -flto-full -W<others> -f<others> -c test.S -o test.S.o -v
clang version 8.0.8
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /home/users/me/llvm/bin
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/5.5.0
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/6.0.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.5.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6.0.0
Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.4.0
Candidate multilib: .;@m64
Candidate multilib: 32;@m32
Candidate multilib: x32;@m32
Selected multilib: .;@m64
"/home/users/me/llvm/bin/clang-8" \
-cc1 \
-triple x86_64-unknown-linux-gnu \
-E \ # <<<<< Note: E
# <<<<< Note: no
-emit-llvm-bc
# <<<<< Note: no -flto=full
# <<<<< Note: no -flto-unit
-disable-free \
-disable-llvm-verifier \
-discard-value-names \
-main-file-name test.S \
-mrelocation-model pic \
-pic-level 2 \
-mthread-model posix \
-fmerge-all-constants \
-fmath-errno \
-masm-verbose \
-mconstructor-aliases \
-munwind-tables \
-fuse-init-array \
-target-cpu x86-64 \
-dwarf-column-info \
-debugger-tuning=gdb \
-momit-leaf-frame-pointer \
-v \
-coverage-notes-file test.S.gcno \
-nostdsysteminc \
-nobuiltininc \
-resource-dir /home/users/me/llvm/lib/clang/8.0.0 \
<all-my-includes> \
<all-my-supplied-options> \
-o test.S.o \
-x c \
test.S \
-faddrsig
clang -cc1 version 8.0.0 based upon LLVM 8.0.0 default target
x86_64-unknown-linux-gnu
#include "..." search starts here:
#include <...> search starts here:
<list-of-my-include-files>
End of search list.
----------------------------
--
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/20190730/61213d93/attachment.html>
More information about the llvm-bugs
mailing list