[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Add "riscv" as an alias for "riscv32"

From: Richard W.M. Jones
Subject: Re: [PATCH] Add "riscv" as an alias for "riscv32"
Date: Fri, 22 Jun 2018 11:22:57 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

On Thu, Jun 21, 2018 at 05:25:59PM -0700, Palmer Dabbelt wrote:
> On Thu, 21 Jun 2018 16:16:51 PDT (-0700), address@hidden wrote:
> >On Wed, Jun 20, 2018 at 10:24:41AM -0700, Palmer Dabbelt wrote:
> >
> >>2018-06-11  Palmer Dabbelt  <address@hidden>
> >>
> >>    * config.sub: Add "riscv-*" as an alias for "riscv32-*".
> >>    * testsuite/ Add tests for the "riscv-*" alias.
> >
> >In light of the discussion, I think this patch is OK. Do we want to
> >change config.guess to always emit riscv for the native configuration,
> >like so?
> >
> >diff --git a/config.guess b/config.guess
> >index 883a671..c501b8a 100755
> >--- a/config.guess
> >+++ b/config.guess
> >@@ -1025,7 +1025,7 @@ EOF
> >     echo powerpcle-unknown-linux-"$LIBC"
> >     exit ;;
> >     riscv32:Linux:*:* | riscv64:Linux:*:*)
> >-    echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
> >+    echo riscv-unknown-linux-"$LIBC"
> >     exit ;;
> >     s390:Linux:*:* | s390x:Linux:*:*)
> >     echo "$UNAME_MACHINE"-ibm-linux-"$LIBC"
> That sounds reasonable to me.  The only wrinkle I can see here is
> that if "riscv-*" maps to "riscv32-*", you're on a 64-bit system,
> and we assume that compilers running on RISC-V machines default to a
> native target, does that mean that the logical "riscv32-*" is a
> 64-bit compiler?
> It's not a big deal as configure scripts should just be matching
> "riscv*-*" anyway, but maybe it's a problem for native userspace.
> I'm adding some native distro people to see if anyone has any
> opinions, as I'm far from an expert on this sort of stuff.

>From the Fedora point of view we're only ever going to be using
‘riscv64-*’ here, and we're not interested in 32 bit, so I guess it
doesn't really affect us.

I'm interested in why you decided that 32 bit would be the default for
this though.  Wouldn't it make more sense to try to guess the current
bit length and use that (maybe difficult for cross-compilation however...)


Richard Jones, Virtualization Group, Red Hat
Read my programming and virtualization blog:
virt-df lists disk usage of guests without needing to install any
software inside the virtual machine.  Supports Linux and Windows.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]