From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 342593858D39 for ; Mon, 27 Mar 2023 13:44:41 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 342593858D39 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1679924680; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=gM2X1avw0AxLtuDurKT5wJmz8/c6/bOc6v5wnV+9pqk=; b=L9+WyaQNTlToT8x8HrdBqtUU+1G0Ew6Zbs/4rub7NS4WZaLc3VQGzrBuoLlGiRz5A/Btyh l+k2ccfhGivQiMfinT5kgDCKOfw8sV2mpughOcdCwQDJxo4K8tBmws0+WuOlFr3dK74cFm 2qah/RAtOhdo7BrYQ8AMIcbR3eh+ueo= Received: from mail-yb1-f198.google.com (mail-yb1-f198.google.com [209.85.219.198]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-214-1JlvD1spNyCudtzCIJMoQA-1; Mon, 27 Mar 2023 09:44:39 -0400 X-MC-Unique: 1JlvD1spNyCudtzCIJMoQA-1 Received: by mail-yb1-f198.google.com with SMTP id w5-20020a253005000000b00aedd4305ff2so8779303ybw.13 for ; Mon, 27 Mar 2023 06:44:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679924679; h=content-transfer-encoding:in-reply-to:organization:from:references :cc:to:content-language:subject:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=gM2X1avw0AxLtuDurKT5wJmz8/c6/bOc6v5wnV+9pqk=; b=abQVS4WeoHEnfCqEhkRlcVR7dhyBubZ/CJzzAJgi0Hw3gqgadnnIgEZ2qnYJCt5V7B mjx7phTkG1Zi0pIS1yS8ly9N9vhhbN8FDO/FCNWR4I/jlfI7S58A0TwROAKX6+7Jg5/W qAFw4CSzVuf63h2ahHgfNLw5HIP0aPOZ7BEtkxfmgAVvszJFHYERmcF8Z74C4y5JKCE9 BdUQ6RgUhZBEU4gR77kutX2OQ7lSCpzlW6iK+D/2jKOr8iq1iZokVCeeq+ZpFIY3TKor mYvP/ard5Wl1F9n4jhJ/SS0mmafP7hZeU6XR3p+zHWiTH20fq8ysk8wZa/paH3l6lrwq IbZQ== X-Gm-Message-State: AAQBX9cNqD//IlXIx9SApqV0Gf6urWGMpqarX7uXDPnF60eFfO5o54S7 zYddwHAAMjXP8/NWhop6KeVNPMvuLyxe8MW13h+Gs/J+oVmWftC6bBkWUHIkxP4Cyfx3azX0fCD BFx/CYT+jveRv9YfMLLTENkt/LlaD X-Received: by 2002:a81:5214:0:b0:541:63b7:a2f with SMTP id g20-20020a815214000000b0054163b70a2fmr12339347ywb.4.1679924678952; Mon, 27 Mar 2023 06:44:38 -0700 (PDT) X-Google-Smtp-Source: AKy350aTkxT2fTAZws3EjMf94+/cFZWwoHb/3Seve8SInltn5nwERd4XSYGQU2bOJJd+5N3LiRpcDA== X-Received: by 2002:a81:5214:0:b0:541:63b7:a2f with SMTP id g20-20020a815214000000b0054163b70a2fmr12339329ywb.4.1679924678699; Mon, 27 Mar 2023 06:44:38 -0700 (PDT) Received: from [192.168.0.241] ([198.48.244.52]) by smtp.gmail.com with ESMTPSA id e188-20020a81a7c5000000b005460412e2fcsm65886ywh.70.2023.03.27.06.44.37 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 27 Mar 2023 06:44:37 -0700 (PDT) Message-ID: Date: Mon, 27 Mar 2023 09:44:36 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.9.0 Subject: Re: [PATCH] LoongArch: ldconfig: Ignore EF_LARCH_OBJABI_V1 in shared objects To: Xi Ruoyao , libc-alpha@sourceware.org Cc: caiyinyu , Wang Xuerui , Adhemerval Zanella Netto References: <20230326111334.9920-1-xry111@xry111.site> From: Carlos O'Donell Organization: Red Hat In-Reply-To: <20230326111334.9920-1-xry111@xry111.site> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-12.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 3/26/23 07:13, Xi Ruoyao via Libc-alpha wrote: > Binutils 2.40 sets EF_LARCH_OBJABI_V1 for shared objects: > > $ ld --version | head -n1 > GNU ld (GNU Binutils) 2.40 > $ echo 'int dummy;' > dummy.c > $ cc dummy.c -shared > $ readelf -h a.out | grep Flags > Flags: 0x43, DOUBLE-FLOAT, OBJ-v1 > > We need to ignore it in ldconfig or ldconfig will consider all shared > objects linked by Binutils 2.40 "unsupported". Maybe we should stop > setting EF_LARCH_OBJABI_V1 for shared objects, but Binutils 2.40 is > already released and we cannot change it. > --- > sysdeps/unix/sysv/linux/loongarch/readelflib.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/sysdeps/unix/sysv/linux/loongarch/readelflib.c b/sysdeps/unix/sysv/linux/loongarch/readelflib.c > index bcaff86b36..ceba355959 100644 > --- a/sysdeps/unix/sysv/linux/loongarch/readelflib.c > +++ b/sysdeps/unix/sysv/linux/loongarch/readelflib.c > @@ -40,7 +40,7 @@ process_elf_file (const char *file_name, const char *lib, int *flag, > > ret = process_elf64_file (file_name, lib, flag, isa_level, soname, > file_contents, file_length); > - flags = elf64_header->e_flags; > + flags = elf64_header->e_flags & ~EF_LARCH_OBJABI_V1; Are such objects ABI compatible? Why isn't this handled below via SUPPORTED_ELF_FLAGS? > > /* LoongArch linkers encode the floating point ABI as part of the ELF headers. */ > switch (flags & SUPPORTED_ELF_FLAGS) -- Cheers, Carlos.