[Bug 237676] [Minor] LLD Filesize and default option suggestions

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Wed May 1 03:44:54 UTC 2019


            Bug ID: 237676
           Summary: [Minor] LLD Filesize and default option suggestions
           Product: Base System
           Version: 12.0-RELEASE
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: bin
          Assignee: bugs at FreeBSD.org
          Reporter: pprocacci at gmail.com

The .comment section added by lld should be removed and made optional.

The file size using lld is unacceptable (some still use assembly) for embedded
stuff.  The default is 1200% larger by default and should be minimal like gnu

# /usr/local/bin/ld -s -o porcupine porcupine.o
# ld --discard-all -o porcupine.lld -m elf_amd64_fbsd porcupine.o
# strip porcupine.lld
# objcopy --remove-section .comment porcupine.lld
# ls -l porcupine porcupine.lld
-rwxr-xr-x  1 root  wheel   352 Apr 30 23:41 porcupine
-rwxr-xr-x  1 root  wheel  4320 Apr 30 23:41 porcupine.lld

Specifying `-m elf_amd64_fbsd` or similar shouldn't be necessary and should be
the default (depending on platform).

You are receiving this mail because:
You are the assignee for the bug.

More information about the freebsd-bugs mailing list