Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 538604 - sys-devel/binutils-6.1: ld gives large number of LTO remarks when used to link LLVM bytecode objects (LTO)
Summary: sys-devel/binutils-6.1: ld gives large number of LTO remarks when used to lin...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: lto
  Show dependency tree
 
Reported: 2015-02-03 00:43 UTC by Michael Weiser
Modified: 2024-03-11 22:46 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
add option -verbose_lto_remarks to ld64 to conditionally enable LTO remarks output (binutils-apple-6.1-lto-noremarks.tar.gz,1.73 KB, patch)
2015-02-03 00:44 UTC, Michael Weiser
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Weiser 2015-02-03 00:43:50 UTC
ld64-241.9 gives a huge number of LTO remarks on stderr (!) when link LLVM bytecode objects:

ld: LTO remark: <unknown>:0:0: system_error will not be inlined into main
ld: LTO remark: <unknown>:0:0: system_fatal too costly to inline (cost=5, threshold=1)
ld: LTO remark: <unknown>:0:0: system_fatal will not be inlined into main
ld: LTO remark: <unknown>:0:0: strip_file too costly to inline (cost=230, threshold=225)
ld: LTO remark: <unknown>:0:0: strip_file will not be inlined into main
ld: LTO remark: <unknown>:0:0: strip_file too costly to inline (cost=230, threshold=225)
ld: LTO remark: <unknown>:0:0: strip_file will not be inlined into main
ld: LTO remark: <unknown>:0:0: fatal can be inlined into main with cost=195 (threshold=337)

This can not be deactivated by the user. Example of linking ld64:

"/Users/michael/nobak/gentoo/usr/bin/ld" -demangle -dynamic -arch x86_64 -macosx_version_min 10.10.0 -o ./strip.NEW -L../../ld64-241.9/src -L/Users/michael/nobak/gentoo/usr/lib/gcc/x86_64-apple-darwin14/4.2.1 ./strip.private.o -lprunetrie -lc++ -lSystem /Users/michael/nobak/gentoo/usr/bin/../lib/clang/3.5.1/lib/darwin/libclang_rt.osx.a -verbose_lto_remarks 2>&1 | wc -l
4274


Reproducible: Always
Comment 1 Michael Weiser 2015-02-03 00:44:44 UTC
Created attachment 395430 [details, diff]
add option -verbose_lto_remarks to ld64 to conditionally enable LTO remarks output
Comment 2 Fabian Groffen gentoo-dev 2015-02-04 17:33:35 UTC
Thanks, I applied the patch