linux-kbuild.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Nick Terrell <terrelln@fb.com>
To: Masahiro Yamada <masahiroy@kernel.org>
Cc: Ben Hutchings <ben@decadent.org.uk>,
	"linux-ia64@vger.kernel.org" <linux-ia64@vger.kernel.org>,
	Linux Kbuild mailing list <linux-kbuild@vger.kernel.org>
Subject: Re: vmlinux link failure on ia64 with zstd
Date: Tue, 15 Sep 2020 06:52:43 +0000	[thread overview]
Message-ID: <7A672D9C-A3A7-456D-BF2E-758566DC2A54@fb.com> (raw)
In-Reply-To: <CAK7LNAToB3n9Y9OPXR55VKbDAkYgm1kUDO8gUu0Ak_+=6AhzCw@mail.gmail.com>



> On Sep 14, 2020, at 11:48 PM, Masahiro Yamada <masahiroy@kernel.org> wrote:
> 
> On Tue, Sep 15, 2020 at 4:12 AM Nick Terrell <terrelln@fb.com> wrote:
>> 
>> 
>> 
>>> On Sep 13, 2020, at 12:51 PM, Ben Hutchings <ben@decadent.org.uk> wrote:
>>> 
>>> Enabling CONFIG_RD_ZSTD (which is enabled by default) resulted in a
>>> link failure on ia64:
>>> 
>>> + ld -r -o vmlinux.o --whole-archive arch/ia64/kernel/head.o init/built-in.a usr/built-in.a arch/ia64/kernel/built-in.a arch/ia64/mm/built-in.a kernel/built-in.a certs/built-in.a mm/built-in.a fs/built-in.a ipc/built-in.a security/built-in.a crypto/built-in.a block/built-in.a lib/built-in.a arch/ia64/lib/built-in.a lib/lib.a arch/ia64/lib/lib.a drivers/built-in.a sound/built-in.a net/built-in.a virt/built-in.a arch/ia64/pci/built-in.a arch/ia64/hp/common/built-in.a --no-whole-archive --start-group --end-group
>>> ld: lib/zstd/entropy_common.o: linking constant-gp files with non-constant-gp files
>>> ld: failed to merge target specific data of file lib/zstd/entropy_common.o
>>> ld: lib/zstd/fse_decompress.o: linking constant-gp files with non-constant-gp files
>>> ld: failed to merge target specific data of file lib/zstd/fse_decompress.o
>>> ld: lib/zstd/zstd_common.o: linking constant-gp files with non-constant-gp files
>>> ld: failed to merge target specific data of file lib/zstd/zstd_common.o
>> 
>> I’ve never seen anything like this error before. I did some searching, and found that it may show up if an object file is empty.
>> 
>> These three files are all included in both the zstd_compress and the zstd_decompress modules. We used to exclude these 3 files from the zstd_decompress module when both modules are built-in. But then commit dc35da16a2e2 [0] removed that, because Kbuild is supposed to handle that case.
>> 
>> If you revert commit dc35da16a2e2 [0] does that fix the issue? I’m attempting to build with IA64, and I’ll let you know if I am able to reproduce the issue and test if this fixes it.
>> 
>> CC: Masahiro Yamada <yamada.masahiro@socionext.com> author of the commit and the linux-kbuild mailing list.
>> 
>> [0] https://github.com/torvalds/linux/commit/dc35da16a2e23db04822f0129cd5b28b7b0e72b4
> 
> 
> dc35da16a2e2 is more than two years old (i.e. v4.17)
> 
> Are we discussing a long-standing issue
> or something that arose recently?

It arose recently because I believe that zstd wasn’t enabled on any IA64 systems before recently.
But, I believe that the cause is that some of the object files contain no symbols, and binutils can’t
handle it on this architecture. I’m not 100% positive, because I haven’t been able to reproduce the
issue, since I haven’t yet been able to build with IA64.

-Nick

>> Best,
>> Nick
>> 
>>> This is seen on Debian unstable, with gcc 10.2 and binutils 2.35.  A
>>> full build log is available at:
>>> https://urldefense.proofpoint.com/v2/url?u=https-3A__buildd.debian.org_status_fetch.php-3Fpkg-3Dlinux-26arch-3Dia64-26ver-3D5.9-7Erc4-2D1-7Eexp1-26stamp-3D1599955166-26raw-3D1&d=DwIFaQ&c=5VD0RTtNlTh3ycd41b3MUw&r=HQM5IQdWOB8WaMoii2dYTw&m=zqqAl5yIf7XQV-QrVXwcu88cjrqLf9QedSMsg216RPo&s=dpKuoQBFAM1Z4q9XD9bSaSpK3o4WSELqyze8nMsxRgI&e= 
>>> 
>>> Ben.
>>> 
>>> --
>>> Ben Hutchings
>>> Humour is the best antidote to reality.
>>> 
>> 
> 
> 
> -- 
> Best Regards
> Masahiro Yamada


  reply	other threads:[~2020-09-15  6:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <f0a93b2d435252b3878ce821142677754f5e434c.camel@decadent.org.uk>
2020-09-14 19:12 ` vmlinux link failure on ia64 with zstd Nick Terrell
2020-09-15  6:48   ` Masahiro Yamada
2020-09-15  6:52     ` Nick Terrell [this message]
2020-11-30 12:27     ` John Paul Adrian Glaubitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7A672D9C-A3A7-456D-BF2E-758566DC2A54@fb.com \
    --to=terrelln@fb.com \
    --cc=ben@decadent.org.uk \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=masahiroy@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).