From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 52463 invoked by alias); 25 Oct 2018 19:19:35 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 52453 invoked by uid 89); 25 Oct 2018 19:19:34 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_SOFTFAIL autolearn=no version=3.3.2 spammy=H*f:sk:CAFyWVa, Hx-languages-length:1073, H*i:sk:CAFyWVa X-HELO: mail.baldwin.cx Received: from bigwig.baldwin.cx (HELO mail.baldwin.cx) (96.47.65.170) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 25 Oct 2018 19:19:33 +0000 Received: from John-Baldwins-MacBook-Pro-2.local (ralph.baldwin.cx [66.234.199.215]) by mail.baldwin.cx (Postfix) with ESMTPSA id AEBD310A87D; Thu, 25 Oct 2018 15:19:30 -0400 (EDT) Subject: Re: [PATCH 4/5] RISC-V: Add native linux support. To: Jim Wilson References: <20180808233908.8149-1-jimw@sifive.com> <20181025110946.GN2929@embecosm.com> Cc: Andrew Burgess , Andreas Schwab , gdb-patches@sourceware.org From: John Baldwin Message-ID: <0cc883c4-e304-c3a9-adba-55ea434ec238@FreeBSD.org> Date: Thu, 25 Oct 2018 19:19:00 -0000 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2018-10/txt/msg00590.txt.bz2 On 10/25/18 11:17 AM, Jim Wilson wrote: > On Thu, Oct 25, 2018 at 10:55 AM John Baldwin wrote: >> Now that the MISA defaults to 0 if not present, would it better to just remove >> this and not set it to 0 explicitly? The FreeBSD native target for RISC-V >> doesn't set MISA to anything at all. > > There is still the issue of FP register size, which comes from MISA, > unless perhaps we can get it from auxvec/hw-cap info. I was going to > look into that latter, and if the auxvec/hw-cap stuff works, then > remove the remaining MISA support in the riscv-linux-nat.c file. Ok. I do agree that auxvec is probably the right way to handle this, as what really matters is what format the kernel exports. You can find existing uses of auxvec for this on 32-bit arm support where AT_HWCAP flags are tested for both Linux and FreeBSD in the respective tdep.c files to determine which floating point registers are available. You are free to use the same code in a nat.c file as well of course. -- John Baldwin