From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ot1-x333.google.com (mail-ot1-x333.google.com [IPv6:2607:f8b0:4864:20::333]) by sourceware.org (Postfix) with ESMTPS id 17AC13858D1E for ; Wed, 10 Aug 2022 13:22:51 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 17AC13858D1E Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=sifive.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=sifive.com Received: by mail-ot1-x333.google.com with SMTP id a14-20020a0568300b8e00b0061c4e3eb52aso10585315otv.3 for ; Wed, 10 Aug 2022 06:22:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sifive.com; s=google; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc; bh=snEGwVP4oo2Sdzy76Zb9QUpobUsvBA5PO3MQxJVrYdw=; b=DZFx0Y7PDz/3nhFT8YAsld3e5QHG0v52INmjwCxyWmh+fPBQWmmJPxRkaTB2oHfMvV rebAx6PtdNcByMR1iNo/KZuBWBe9mngS9WXPR9t0glES8mIObqMi2VKMJ3bz5kGWlKV8 VrNMml7HCUANSTWzwIffIXY0Ee/cpob8k3tp1X3pmgZp6HPqXOvOuoJN1fod1kCCyykQ ktz3bMhnBcVQLwBtpU6rBw2qPQCYhGfM+n5ApiBvpFQBSKARorL2oB71o/EPKs9WgAUd 5egs0xTbcS8hKIqOIglOf7mavU5PWHkYnUsNxfPVOvuFVS5sfoawJja7d1X+DObiPt8X C0/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc; bh=snEGwVP4oo2Sdzy76Zb9QUpobUsvBA5PO3MQxJVrYdw=; b=CKq6y7ymtcbpl7osEXG3p1vVb84lvmv1rMmH4X/6jY4xCK6ONgQg3dsj1Yr2KBUFo3 u1a2vVLdpwgH1H2wI4oqTVhATVcyi+IJF0U54w6FpMgZAHPIbGdis02Ed6AwL4unOZmb 34eNgVTXnh84J+k4oQNDXYUH/W97DT+A737oLQrTGmA8rSAKuENJs8k2qzzrVLl/+R3A /UBTMl7cLrNBxUmfSHWYUqC6S6A56OTZ4uWPOAixHFE6sKTPEIEjWF1kPNOjUUeqfm83 hxcqFTMsb48Qg35m6iG09XCq1IGPIHzcWcQ2TWqeLLipn3GvV7xlTmA/8+b6NTicOtpd s1/g== X-Gm-Message-State: ACgBeo2ItNBcr6Sd+M8U9jlY+hGk3LdPWQ2G9AXhDZi6osjkeXM5O/ui TYXP6ASYQ/+2boYhrChkccoDZOkytQp7k3tmy3eF6g== X-Google-Smtp-Source: AA6agR77W7h+o6XGqwGkjq68fqyudt/DSUcII9KIv76YQgDWsYXcZAdrHRV0YBjRS0j6kKVvkC/UP+wYBpuKb+Vb1EE= X-Received: by 2002:a05:6830:6615:b0:616:d545:fa81 with SMTP id cp21-20020a056830661500b00616d545fa81mr10452508otb.129.1660137770272; Wed, 10 Aug 2022 06:22:50 -0700 (PDT) MIME-Version: 1.0 References: <20220808065523.18152-1-maskray@google.com> <20220808172742.vlbb5hpr7yqh5led@google.com> In-Reply-To: From: Kito Cheng Date: Wed, 10 Aug 2022 21:22:39 +0800 Message-ID: Subject: Re: [PATCH] RISC-V: Remove R_RISCV_GNU_VTINHERIT/R_RISCV_GNU_VTENTRY To: Fangrui Song Cc: Kito Cheng , Andreas Schwab , Fangrui Song via Binutils Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-5.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: binutils@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Aug 2022 13:22:53 -0000 LGTM, although I am not one of RISC-V binutils maintainer :P On Wed, Aug 10, 2022 at 2:33 PM Fangrui Song wrote: > > On Mon, Aug 8, 2022 at 10:27 AM Fangrui Song wrote: > > > > On 2022-08-08, Kito Cheng wrote: > > >Hi Andreas: > > > > > >> FWIW, they are still generically handled by the .vtable_inherit and > > >> .vtable_entry pseudo-ops, but support for -fvtable-gc has been removed > > >> from gcc in 2003. The RISC-V assembler never picked them up. > > > > > >Thanks for the historical data! RISC-V GNU toolchain is upstreamed > > >after that time, so sounds like we could remove that safely for > > >RISC-V. > > > > Second this. > > > > >> $ riscv64-suse-linux-as vtable.s > > >> vtable.s: Assembler messages: > > >> vtable.s:1: Error: cannot represent BFD_RELOC_VTABLE_ENTRY relocation in object file > > >> vtable.s:2: Error: cannot represent BFD_RELOC_VTABLE_INHERIT relocation in object file > > > > > >Maybe we can improve the error message into something like: > > >.vtable_inherit / .vtable_entry is unsupported for RISC-V. > > > > I think the diagnostic is from gas/config/tc-riscv.c:4135 . > > Since gcc -fvtable-gc was gone in 2003 and we essentially cannot find > > .vtable_entry uses, I think sticking with the existing generic diagnostic isn't bad. > > If this patch has no objection, I will push this.