[this is -not- a SSSE3 discussion thread nor should it turn into one]
We were having some discussions around in some bugs that things should
in general follow OBS project optflags/CFLAGS/CXXFLAGS. For MeeGo.com
builds this is naturally optimized for Atom.
I noticed the following default patch (see further down) in MeeGo gcc,
which seems to make the optflags a bit of a null-op as it overrides
them for x86 anyway.
Would it be saner to remove/disable this patch and solely rely on
CFLAGS/CXXFLAGS/optflags for MeeGo builds? This would be more
ecosystem-friendly and allow for proper flexibility of compilation
flags for any given target.
The sideeffect of this would be that gcc without any optimization
parameters would default to whatever default gcc has with this patch
removed*
(* There is a bit of discussion about compliance having to maintain
same packaging. Does this still apply to patches that enforce certain
hardware models, like the below one?)
diff -Naurp gcc-4.5.0-orig/gcc/config/i386/i386.c
gcc-4.5.0/gcc/config/i386/i386.c
--- gcc-4.5.0-orig/gcc/config/i386/i386.c 2010-04-23
04:43:24.000000000 -0400
+++ gcc-4.5.0/gcc/config/i386/i386.c 2010-04-23 04:45:30.000000000 -0400
@@ -1783,7 +1783,7 @@ enum asm_dialect ix86_asm_dialect = ASM_
enum tls_dialect ix86_tls_dialect = TLS_DIALECT_GNU;
/* Which unit we are generating floating point math for. */
-enum fpmath_unit ix86_fpmath;
+enum fpmath_unit ix86_fpmath = FPMATH_SSE;
/* Which cpu are we scheduling for. */
enum attr_cpu ix86_schedule;
@@ -1923,15 +1923,9 @@ static enum calling_abi ix86_function_ab
#endif
/* Whether -mtune= or -march= were specified */
-static int ix86_tune_defaulted;
+static int ix86_tune_defaulted = 1;
static int ix86_arch_specified;
-/* Bit flags that specify the ISA we are compiling for. */
-int ix86_isa_flags = TARGET_64BIT_DEFAULT | TARGET_SUBTARGET_ISA_DEFAULT;
-
-/* A mask of ix86_isa_flags that includes bit X if X
- was set or cleared on the command line. */
-static int ix86_isa_flags_explicit;
/* Define a set of ISAs which are available when a given ISA is
enabled. MMX and SSE ISAs are handled separately. */
@@ -2034,6 +2028,14 @@ static int ix86_isa_flags_explicit;
#define OPTION_MASK_ISA_MOVBE_UNSET OPTION_MASK_ISA_MOVBE
#define OPTION_MASK_ISA_CRC32_UNSET OPTION_MASK_ISA_CRC32
+/* Bit flags that specify the ISA we are compiling for. */
+int ix86_isa_flags = TARGET_64BIT_DEFAULT |
TARGET_SUBTARGET_ISA_DEFAULT | OPTION_MASK_ISA_SSSE3_SET;
+
+/* A mask of ix86_isa_flags that includes bit X if X
+ was set or cleared on the command line. */
+static int ix86_isa_flags_explicit = OPTION_MASK_ISA_SSSE3_SET;
+
+
/* Vectorization library interface and handlers. */
tree (*ix86_veclib_handler)(enum built_in_function, tree, tree) = NULL;
static tree ix86_veclibabi_svml (enum built_in_function, tree, tree);
@@ -2807,6 +2809,8 @@ override_options (bool main_args_p)
flag_pcc_struct_return = DEFAULT_PCC_STRUCT_RETURN;
}
+
+ ix86_tune_string = "atom";
/* Need to check -mtune=generic first. */
if (ix86_tune_string)
{
@@ -2882,6 +2886,7 @@ override_options (bool main_args_p)
ix86_stringop_string, prefix, suffix, sw);
}
+ ix86_arch_string = "core2";
if (!ix86_arch_string)
ix86_arch_string = TARGET_64BIT ? "x86-64" : SUBTARGET32_DEFAULT_CPU;
else
@@ -3311,7 +3316,7 @@ override_options (bool main_args_p)
&& ! TARGET_SSE)
error ("%ssseregparm%s used without SSE enabled", prefix, suffix);
- ix86_fpmath = TARGET_FPMATH_DEFAULT;
+ ix86_fpmath = FPMATH_SSE;
if (ix86_fpmath_string != 0)
{
if (! strcmp (ix86_fpmath_string, "387"))
Best regards,
Carsten Munk
_______________________________________________
MeeGo-dev mailing list
[email protected]
http://lists.meego.com/listinfo/meego-dev