Re: [PATCH/RFA] Do not set MULTILIB_DEFAULTS for arm*-*-linux-gnueabi* targets

2013-08-20 Thread Ramana Radhakrishnan

On 08/19/13 11:54, Matthew Gretton-Dann wrote:

All,

The attached patch removes the setting of MULTILIB_DEFAULTS for
arm*-*-linux-gnueabi* targets.

The current setting of MULTILIB_DEFAULTS includes mfloat-abi=hard,
which for arm*-*-linux-gnueabi is not true.  This makes generating a
hard-float multilib impossible in this configuration.



For the record, setting that to the default means that any multilib will 
assume a hard-float ABI configuration, little endian configuration by 
default ! My suspicion is this is a legacy that pre-dates 
arm-linux-gnueabi and keeping this definition at odds with the 
documentation, doesn't make sense to me.


Also we no longer use CLEAR_INSN_CACHE in linux-gas.h so the comment in 
t-linux-eabi is obsolete, so that restriction to building thumb 
multilibs is just bogus and indeed we have a number of folks defaulting 
to thumb libraries. This comment in t-linux-gnueabi and the definition 
of CLEAR_INSN_CACHE in linux-gas.h can be removed in a follow up patch 
- please :)


Ok .

regards
Ramana




[PATCH/RFA] Do not set MULTILIB_DEFAULTS for arm*-*-linux-gnueabi* targets

2013-08-19 Thread Matthew Gretton-Dann
All,

The attached patch removes the setting of MULTILIB_DEFAULTS for
arm*-*-linux-gnueabi* targets.

The current setting of MULTILIB_DEFAULTS includes mfloat-abi=hard,
which for arm*-*-linux-gnueabi is not true.  This makes generating a
hard-float multilib impossible in this configuration.

In an off-list conversation with Ramana we decided that
MULTILIB_DEFAULTS should not be set for these targets, as we set
MULTILIB_OPTIONS to an empty string (as per the docs for
MULTILIB_DEFAULTS).

I added comments by the definition of MULTILIB_OPTIONS and
MULTILIB_DEFAULTS to make it clear that the two options are related.

Tested cross arm-none-linux-gnueabi.

OK for trunk?

Thanks,

Matt

gcc/ChangeLog:
2013-08-19  Matthew Gretton-Dann  

* config/arm/linux-elf.h (MULTILIB_DEFAULTS): Remove definition.
* config/arm/t-linux-eabi: (MULTILIB_OPTIONS): Document association
with MULTILIB_DEFAULTS.

-- 
Matthew Gretton-Dann
Linaro Toolchain Working Group
matthew.gretton-d...@linaro.org
diff --git a/gcc/config/arm/linux-elf.h b/gcc/config/arm/linux-elf.h
index 488efa4..475e220 100644
--- a/gcc/config/arm/linux-elf.h
+++ b/gcc/config/arm/linux-elf.h
@@ -44,9 +44,9 @@
 
 #define SUBTARGET_EXTRA_LINK_SPEC " -m " TARGET_LINKER_EMULATION " -p"
 
+/* We do not have any MULTILIB_OPTIONS specified, so there are no
+   MULTILIB_DEFAULTS.  */
 #undef  MULTILIB_DEFAULTS
-#define MULTILIB_DEFAULTS \
-   { "marm", "mlittle-endian", "mfloat-abi=hard", "mno-thumb-interwork" }
 
 /* Now we define the strings used to build the spec file.  */
 #undef  LIB_SPEC
diff --git a/gcc/config/arm/t-linux-eabi b/gcc/config/arm/t-linux-eabi
index 2f2f8ff..07e32b3 100644
--- a/gcc/config/arm/t-linux-eabi
+++ b/gcc/config/arm/t-linux-eabi
@@ -18,6 +18,8 @@
 
 # We do not build a Thumb multilib for Linux because the definition of
 # CLEAR_INSN_CACHE in linux-gas.h does not work in Thumb mode.
+# If you set MULTILIB_OPTIONS to a non-empty value you should also set
+# MULTILIB_DEFAULTS in linux-elf.h.
 MULTILIB_OPTIONS   =
 MULTILIB_DIRNAMES  =