From c471ecf98c48fab31128d0a59e6a447b5bb72e6e Mon Sep 17 00:00:00 2001 From: doko Date: Mon, 16 Jun 2014 07:41:12 +0000 Subject: * Update to SVN 20140616 (r211693) from the gcc-4_8-branch. git-svn-id: svn://svn.debian.org/svn/gcccvs/branches/sid/gcc-4.8@7456 6ca36cf4-e1d1-0310-8c6f-e303bb2178ca --- debian/changelog | 8 +- debian/patches/svn-updates.diff | 785 +++++++++++++++++++++++++++++++++++++++- 2 files changed, 782 insertions(+), 11 deletions(-) diff --git a/debian/changelog b/debian/changelog index e1cb0c7..a3f8939 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,9 +1,11 @@ -gcc-4.8 (4.8.3-3) UNRELEASED; urgency=medium +gcc-4.8 (4.8.3-4) UNRELEASED; urgency=medium + + * Update to SVN 20140616 (r211693) from the gcc-4_8-branch. [ Aurelien Jarno ] * Fix PR c++/61336, taken from the trunk. - - -- Matthias Klose Sat, 07 Jun 2014 02:28:40 +0200 + + -- Matthias Klose Mon, 16 Jun 2014 09:28:11 +0200 gcc-4.8 (4.8.3-3) unstable; urgency=medium diff --git a/debian/patches/svn-updates.diff b/debian/patches/svn-updates.diff index 8ba748f..0743df0 100644 --- a/debian/patches/svn-updates.diff +++ b/debian/patches/svn-updates.diff @@ -1,10 +1,10 @@ -# DP: updates from the 4.8 branch upto 20140606 (r211339). +# DP: updates from the 4.8 branch upto 20140616 (r211693). last_updated() { cat > ${dir}LAST_UPDATED < ++ ++ Backport from mainline ++ ++ 2014-06-13 Peter Bergner ++ PR target/61415 ++ * config/rs6000/rs6000-builtin.def (BU_MISC_1): Delete. ++ (BU_MISC_2): Rename to ... ++ (BU_LDBL128_2): ... this. ++ * config/rs6000/rs6000.h (RS6000_BTM_LDBL128): New define. ++ (RS6000_BTM_COMMON): Add RS6000_BTM_LDBL128. ++ * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Handle ++ RS6000_BTM_LDBL128. ++ (rs6000_invalid_builtin): Add long double 128-bit builtin support. ++ (rs6000_builtin_mask_names): Add RS6000_BTM_LDBL128. ++ * config/rs6000/rs6000.md (unpacktf_0): Remove define)expand. ++ (unpacktf_1): Likewise. ++ * doc/extend.texi (__builtin_longdouble_dw0): Remove documentation. ++ (__builtin_longdouble_dw1): Likewise. ++ * doc/sourcebuild.texi (longdouble128): Document. ++ ++2014-06-13 Jason Merrill ++ ++ PR c++/60731 ++ * common.opt (-fno-gnu-unique): Add. ++ * config/elfos.h (USE_GNU_UNIQUE_OBJECT): Check it. ++ ++2014-06-12 Georg-Johann Lay ++ ++ Backport from 2014-05-09 trunk r210272 ++ ++ * config/avr/avr-fixed.md (round3): Use -1U instead of -1 in ++ unsigned int initializers for regno_in, regno_out. ++ ++ Backport from 2014-05-14 trunk r210418 ++ * config/avr/avr.h (REG_CLASS_CONTENTS): Use unsigned suffix for ++ shifted values to avoid build warning. ++ ++ Backport from 2014-06-12 trunk r211491 ++ ++ PR target/61443 ++ * config/avr/avr.md (push1): Avoid (subreg(mem)) when ++ loading from address spaces. ++ ++2014-06-12 Alan Modra ++ ++ PR target/61300 ++ * doc/tm.texi.in (INCOMING_REG_PARM_STACK_SPACE): Document. ++ * doc/tm.texi: Regenerate. ++ * function.c (INCOMING_REG_PARM_STACK_SPACE): Provide default. ++ Use throughout in place of REG_PARM_STACK_SPACE. ++ * config/rs6000/rs6000.c (rs6000_reg_parm_stack_space): Add ++ "incoming" param. Pass to rs6000_function_parms_need_stack. ++ (rs6000_function_parms_need_stack): Add "incoming" param, ignore ++ prototype_p when incoming. Use function decl when incoming ++ to handle K&R style functions. ++ * config/rs6000/rs6000.h (REG_PARM_STACK_SPACE): Adjust. ++ (INCOMING_REG_PARM_STACK_SPACE): Define. ++ +2014-06-06 Michael Meissner + + Back port from trunk @@ -408,6 +467,30 @@ Index: gcc/ChangeLog 2014-05-22 Release Manager * GCC 4.8.3 released. +Index: gcc/testsuite/gcc.target/powerpc/tfmode_off.c +=================================================================== +--- a/src/gcc/testsuite/gcc.target/powerpc/tfmode_off.c (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/testsuite/gcc.target/powerpc/tfmode_off.c (.../branches/gcc-4_8-branch) +@@ -1,6 +1,7 @@ + /* { dg-do assemble } */ + /* { dg-skip-if "" { powerpc-ibm-aix* } { "*" } { "" } } */ + /* { dg-skip-if "no TFmode" { powerpc-*-eabi* } { "*" } { "" } } */ ++/* { dg-require-effective-target longdouble128 } */ + /* { dg-options "-O2 -fno-align-functions -mtraceback=no -save-temps" } */ + + typedef float TFmode __attribute__ ((mode (TF))); +Index: gcc/testsuite/gcc.target/powerpc/pack02.c +=================================================================== +--- a/src/gcc/testsuite/gcc.target/powerpc/pack02.c (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/testsuite/gcc.target/powerpc/pack02.c (.../branches/gcc-4_8-branch) +@@ -2,6 +2,7 @@ + /* { dg-skip-if "" { powerpc*-*-darwin* } { "*" } { "" } } */ + /* { dg-skip-if "" { powerpc*-*-*spe* } { "*" } { "" } } */ + /* { dg-require-effective-target powerpc_fprs } */ ++/* { dg-require-effective-target longdouble128 } */ + /* { dg-options "-O2 -mhard-float" } */ + + #include Index: gcc/testsuite/gcc.target/powerpc/htm-ttest.c =================================================================== --- a/src/gcc/testsuite/gcc.target/powerpc/htm-ttest.c (.../tags/gcc_4_8_3_release) @@ -427,6 +510,145 @@ Index: gcc/testsuite/gcc.target/powerpc/htm-ttest.c +{ + return _HTM_STATE(__builtin_ttest()); +} +Index: gcc/testsuite/gcc.target/avr/torture/pr61443.c +=================================================================== +--- a/src/gcc/testsuite/gcc.target/avr/torture/pr61443.c (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/testsuite/gcc.target/avr/torture/pr61443.c (.../branches/gcc-4_8-branch) +@@ -0,0 +1,134 @@ ++/* { dg-do run } */ ++/* { dg-options "-std=gnu99" } */ ++ ++#include ++#include ++ ++#define NC __attribute__((noinline,noclone)) ++ ++void NC vfun (char n, ...) ++{ ++ va_list ap; ++ ++ va_start (ap, n); ++ ++ switch (n) ++ { ++ default: ++ abort(); ++ case 1: ++ if (11 != va_arg (ap, int)) ++ abort(); ++ break; ++ case 2: ++ if (2222 != va_arg (ap, int)) ++ abort(); ++ break; ++ case 3: ++ if (333333 != va_arg (ap, __int24)) ++ abort(); ++ break; ++ case 4: ++ if (44444444 != va_arg (ap, long)) ++ abort(); ++ break; ++ case 8: ++ if (8888888888888888 != va_arg (ap, long long)) ++ abort(); ++ break; ++ } ++ ++ va_end (ap); ++} ++ ++ ++void NC boo_qi (const __flash char *p) ++{ ++ vfun (1, *p); ++} ++ ++void NC boox_qi (const __memx char *p) ++{ ++ vfun (1, *p); ++} ++ ++void NC boo_hi (const __flash int *p) ++{ ++ vfun (2, *p); ++} ++ ++void NC boox_hi (const __memx int *p) ++{ ++ vfun (2, *p); ++} ++ ++void NC boo_psi (const __flash __int24 *p) ++{ ++ vfun (3, *p); ++} ++ ++void NC boox_psi (const __memx __int24 *p) ++{ ++ vfun (3, *p); ++} ++ ++void NC boo_si (const __flash long *p) ++{ ++ vfun (4, *p); ++} ++ ++void NC boox_si (const __memx long *p) ++{ ++ vfun (4, *p); ++} ++ ++void NC boo_di (const __flash long long *p) ++{ ++ vfun (8, *p); ++} ++ ++void NC boox_di (const __memx long long *p) ++{ ++ vfun (8, *p); ++} ++ ++const __flash char f_qi = 11; ++const __flash int f_hi = 2222; ++const __flash __int24 f_psi = 333333; ++const __flash long f_si = 44444444; ++const __flash long long f_di = 8888888888888888; ++ ++const __memx char x_qi = 11; ++const __memx int x_hi = 2222; ++const __memx __int24 x_psi = 333333; ++const __memx long x_si = 44444444; ++const __memx long long x_di = 8888888888888888; ++ ++char r_qi = 11; ++int r_hi = 2222; ++__int24 r_psi = 333333; ++long r_si = 44444444; ++long long r_di = 8888888888888888; ++ ++int main (void) ++{ ++ boo_qi (&f_qi); ++ boo_hi (&f_hi); ++ boo_psi (&f_psi); ++ boo_si (&f_si); ++ boo_di (&f_di); ++ ++ boox_qi (&x_qi); ++ boox_hi (&x_hi); ++ boox_psi (&x_psi); ++ boox_si (&x_si); ++ boox_di (&x_di); ++ ++ boox_qi (&r_qi); ++ boox_hi (&r_hi); ++ boox_psi (&r_psi); ++ boox_si (&r_si); ++ boox_di (&r_di); ++ ++ exit (0); ++} Index: gcc/testsuite/gcc.target/i386/pr60901.c =================================================================== --- a/src/gcc/testsuite/gcc.target/i386/pr60901.c (.../tags/gcc_4_8_3_release) @@ -449,6 +671,49 @@ Index: gcc/testsuite/gcc.target/i386/pr60901.c + baz (0); + } +} +Index: gcc/testsuite/lib/target-supports.exp +=================================================================== +--- a/src/gcc/testsuite/lib/target-supports.exp (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/testsuite/lib/target-supports.exp (.../branches/gcc-4_8-branch) +@@ -1790,6 +1790,15 @@ + }] + } + ++# Return 1 if the target supports long double of 128 bits, ++# 0 otherwise. ++ ++proc check_effective_target_longdouble128 { } { ++ return [check_no_compiler_messages longdouble128 object { ++ int dummy[sizeof(long double) == 16 ? 1 : -1]; ++ }] ++} ++ + # Return 1 if the target supports double of 64 bits, + # 0 otherwise. + +Index: gcc/testsuite/gfortran.dg/cray_pointers_10.f90 +=================================================================== +--- a/src/gcc/testsuite/gfortran.dg/cray_pointers_10.f90 (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/testsuite/gfortran.dg/cray_pointers_10.f90 (.../branches/gcc-4_8-branch) +@@ -0,0 +1,18 @@ ++! { dg-do run } ++! { dg-options "-fcray-pointer" } ++! ++! PR fortran/45187 ++! ++module foo ++ implicit none ++ real :: a ++ pointer(c_a, a) ++end module foo ++ ++program test ++ use foo ++ real :: z ++ c_a = loc(z) ++ a = 42 ++ if (z /= 42) call abort ++end program test Index: gcc/testsuite/gnat.dg/overflow_fixed.adb =================================================================== --- a/src/gcc/testsuite/gnat.dg/overflow_fixed.adb (.../tags/gcc_4_8_3_release) @@ -551,7 +816,30 @@ Index: gcc/testsuite/ChangeLog =================================================================== --- a/src/gcc/testsuite/ChangeLog (.../tags/gcc_4_8_3_release) +++ b/src/gcc/testsuite/ChangeLog (.../branches/gcc-4_8-branch) -@@ -1,3 +1,42 @@ +@@ -1,3 +1,65 @@ ++2014-06-15 Francois-Xavier Coudert ++ ++ Backport from trunk. ++ PR fortran/45187 ++ * gfortran.dg/cray_pointers_10.f90: New file. ++ ++2014-06-13 Peter Bergner ++ ++ Backport from mainline ++ ++ 2014-06-13 Peter Bergner ++ PR target/61415 ++ * lib/target-supports.exp (check_effective_target_longdouble128): New. ++ * gcc.target/powerpc/pack02.c: Use it. ++ * gcc.target/powerpc/tfmode_off.c: Likewise. ++ ++2014-06-12 Georg-Johann Lay ++ ++ Backport from 2014-06-12 trunk r211491 ++ ++ PR target/61443 ++ * gcc.target/avr/torture/pr61443.c: New test. ++ +2014-06-04 Richard Biener + + PR tree-optimization/61383 @@ -594,6 +882,61 @@ Index: gcc/testsuite/ChangeLog 2014-05-22 Release Manager * GCC 4.8.3 released. +Index: gcc/testsuite/g++.dg/cpp0x/variadic158.C +=================================================================== +--- a/src/gcc/testsuite/g++.dg/cpp0x/variadic158.C (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/testsuite/g++.dg/cpp0x/variadic158.C (.../branches/gcc-4_8-branch) +@@ -0,0 +1,24 @@ ++// PR c++/61134 ++// { dg-do compile { target c++11 } } ++ ++struct Base { }; ++ ++template ++struct Fixed { ++ typedef const char* name; ++}; ++ ++template ++void New(const char* name, ++ typename Fixed::name... field_names); ++ ++template ++void CreateMetric(const char* name, ++ typename Fixed::name... field_names, ++ const Base&) { } ++ ++ ++void Fn() ++{ ++ CreateMetric("abcd", "def", Base()); ++} +Index: gcc/cp/ChangeLog +=================================================================== +--- a/src/gcc/cp/ChangeLog (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/cp/ChangeLog (.../branches/gcc-4_8-branch) +@@ -1,3 +1,8 @@ ++2014-06-02 Jason Merrill ++ ++ PR c++/61134 ++ * pt.c (pack_deducible_p): Handle canonicalization. ++ + 2014-05-22 Release Manager + + * GCC 4.8.3 released. +Index: gcc/cp/pt.c +=================================================================== +--- a/src/gcc/cp/pt.c (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/cp/pt.c (.../branches/gcc-4_8-branch) +@@ -14934,7 +14934,7 @@ + continue; + for (packs = PACK_EXPANSION_PARAMETER_PACKS (type); + packs; packs = TREE_CHAIN (packs)) +- if (TREE_VALUE (packs) == parm) ++ if (template_args_equal (TREE_VALUE (packs), parm)) + { + /* The template parameter pack is used in a function parameter + pack. If this is the end of the parameter list, the Index: gcc/double-int.c =================================================================== --- a/src/gcc/double-int.c (.../tags/gcc_4_8_3_release) @@ -784,7 +1127,14 @@ Index: gcc/fortran/ChangeLog =================================================================== --- a/src/gcc/fortran/ChangeLog (.../tags/gcc_4_8_3_release) +++ b/src/gcc/fortran/ChangeLog (.../branches/gcc-4_8-branch) -@@ -1,3 +1,10 @@ +@@ -1,3 +1,17 @@ ++2014-06-15 Francois-Xavier Coudert ++ ++ Backport from trunk. ++ PR fortran/45187 ++ * trans-decl.c (gfc_create_module_variable): Don't create ++ Cray-pointee decls twice. ++ +2014-05-26 Janne Blomqvist + + Backport from mainline @@ -795,6 +1145,95 @@ Index: gcc/fortran/ChangeLog 2014-05-22 Release Manager * GCC 4.8.3 released. +Index: gcc/fortran/trans-decl.c +=================================================================== +--- a/src/gcc/fortran/trans-decl.c (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/fortran/trans-decl.c (.../branches/gcc-4_8-branch) +@@ -4084,8 +4084,8 @@ + } + + /* Don't generate variables from other modules. Variables from +- COMMONs will already have been generated. */ +- if (sym->attr.use_assoc || sym->attr.in_common) ++ COMMONs and Cray pointees will already have been generated. */ ++ if (sym->attr.use_assoc || sym->attr.in_common || sym->attr.cray_pointee) + return; + + /* Equivalenced variables arrive here after creation. */ +Index: gcc/function.c +=================================================================== +--- a/src/gcc/function.c (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/function.c (.../branches/gcc-4_8-branch) +@@ -1354,9 +1354,13 @@ + #define STACK_POINTER_OFFSET 0 + #endif + ++#if defined (REG_PARM_STACK_SPACE) && !defined (INCOMING_REG_PARM_STACK_SPACE) ++#define INCOMING_REG_PARM_STACK_SPACE REG_PARM_STACK_SPACE ++#endif ++ + /* If not defined, pick an appropriate default for the offset of dynamically + allocated memory depending on the value of ACCUMULATE_OUTGOING_ARGS, +- REG_PARM_STACK_SPACE, and OUTGOING_REG_PARM_STACK_SPACE. */ ++ INCOMING_REG_PARM_STACK_SPACE, and OUTGOING_REG_PARM_STACK_SPACE. */ + + #ifndef STACK_DYNAMIC_OFFSET + +@@ -1368,12 +1372,12 @@ + `crtl->outgoing_args_size'. Nevertheless, we must allow + for it when allocating stack dynamic objects. */ + +-#if defined(REG_PARM_STACK_SPACE) ++#ifdef INCOMING_REG_PARM_STACK_SPACE + #define STACK_DYNAMIC_OFFSET(FNDECL) \ + ((ACCUMULATE_OUTGOING_ARGS \ + ? (crtl->outgoing_args_size \ + + (OUTGOING_REG_PARM_STACK_SPACE ((!(FNDECL) ? NULL_TREE : TREE_TYPE (FNDECL))) ? 0 \ +- : REG_PARM_STACK_SPACE (FNDECL))) \ ++ : INCOMING_REG_PARM_STACK_SPACE (FNDECL))) \ + : 0) + (STACK_POINTER_OFFSET)) + #else + #define STACK_DYNAMIC_OFFSET(FNDECL) \ +@@ -2211,8 +2215,9 @@ + #endif + all->args_so_far = pack_cumulative_args (&all->args_so_far_v); + +-#ifdef REG_PARM_STACK_SPACE +- all->reg_parm_stack_space = REG_PARM_STACK_SPACE (current_function_decl); ++#ifdef INCOMING_REG_PARM_STACK_SPACE ++ all->reg_parm_stack_space ++ = INCOMING_REG_PARM_STACK_SPACE (current_function_decl); + #endif + } + +Index: gcc/common.opt +=================================================================== +--- a/src/gcc/common.opt (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/common.opt (.../branches/gcc-4_8-branch) +@@ -1226,6 +1226,10 @@ + Common Report Var(flag_tm) + Enable support for GNU transactional memory + ++fgnu-unique ++Common Report Var(flag_gnu_unique) Init(1) ++Use STB_GNU_UNIQUE if supported by the assembler ++ + floop-flatten + Common Ignore + Does nothing. Preserved for backward compatibility. +Index: gcc/config/elfos.h +=================================================================== +--- a/src/gcc/config/elfos.h (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/config/elfos.h (.../branches/gcc-4_8-branch) +@@ -287,7 +287,7 @@ + /* Write the extra assembler code needed to declare an object properly. */ + + #ifdef HAVE_GAS_GNU_UNIQUE_OBJECT +-#define USE_GNU_UNIQUE_OBJECT 1 ++#define USE_GNU_UNIQUE_OBJECT flag_gnu_unique + #else + #define USE_GNU_UNIQUE_OBJECT 0 + #endif Index: gcc/config/i386/i386.c =================================================================== --- a/src/gcc/config/i386/i386.c (.../tags/gcc_4_8_3_release) @@ -830,6 +1269,71 @@ Index: gcc/config/i386/i386.c add_dependee_for_func_arg (first_arg, e->src); } } +Index: gcc/config/avr/avr-fixed.md +=================================================================== +--- a/src/gcc/config/avr/avr-fixed.md (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/config/avr/avr-fixed.md (.../branches/gcc-4_8-branch) +@@ -430,8 +430,8 @@ + } + + // Input and output of the libgcc function +- const unsigned int regno_in[] = { -1, 22, 22, -1, 18 }; +- const unsigned int regno_out[] = { -1, 24, 24, -1, 22 }; ++ const unsigned int regno_in[] = { -1U, 22, 22, -1U, 18 }; ++ const unsigned int regno_out[] = { -1U, 24, 24, -1U, 22 }; + + operands[3] = gen_rtx_REG (mode, regno_out[(size_t) GET_MODE_SIZE (mode)]); + operands[4] = gen_rtx_REG (mode, regno_in[(size_t) GET_MODE_SIZE (mode)]); +Index: gcc/config/avr/avr.md +=================================================================== +--- a/src/gcc/config/avr/avr.md (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/config/avr/avr.md (.../branches/gcc-4_8-branch) +@@ -367,6 +367,15 @@ + "" + { + int i; ++ ++ // Avoid (subreg (mem)) for non-generic address spaces below. Because ++ // of the poor addressing capabilities of these spaces it's better to ++ // load them in one chunk. And it avoids PR61443. ++ ++ if (MEM_P (operands[0]) ++ && !ADDR_SPACE_GENERIC_P (MEM_ADDR_SPACE (operands[0]))) ++ operands[0] = copy_to_mode_reg (mode, operands[0]); ++ + for (i = GET_MODE_SIZE (mode) - 1; i >= 0; --i) + { + rtx part = simplify_gen_subreg (QImode, operands[0], mode, i); +Index: gcc/config/avr/avr.h +=================================================================== +--- a/src/gcc/config/avr/avr.h (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/config/avr/avr.h (.../branches/gcc-4_8-branch) +@@ -250,18 +250,18 @@ + #define REG_CLASS_CONTENTS { \ + {0x00000000,0x00000000}, /* NO_REGS */ \ + {0x00000001,0x00000000}, /* R0_REG */ \ +- {3 << REG_X,0x00000000}, /* POINTER_X_REGS, r26 - r27 */ \ +- {3 << REG_Y,0x00000000}, /* POINTER_Y_REGS, r28 - r29 */ \ +- {3 << REG_Z,0x00000000}, /* POINTER_Z_REGS, r30 - r31 */ \ ++ {3u << REG_X,0x00000000}, /* POINTER_X_REGS, r26 - r27 */ \ ++ {3u << REG_Y,0x00000000}, /* POINTER_Y_REGS, r28 - r29 */ \ ++ {3u << REG_Z,0x00000000}, /* POINTER_Z_REGS, r30 - r31 */ \ + {0x00000000,0x00000003}, /* STACK_REG, STACK */ \ +- {(3 << REG_Y) | (3 << REG_Z), \ ++ {(3u << REG_Y) | (3u << REG_Z), \ + 0x00000000}, /* BASE_POINTER_REGS, r28 - r31 */ \ +- {(3 << REG_X) | (3 << REG_Y) | (3 << REG_Z), \ ++ {(3u << REG_X) | (3u << REG_Y) | (3u << REG_Z), \ + 0x00000000}, /* POINTER_REGS, r26 - r31 */ \ +- {(3 << REG_X) | (3 << REG_Y) | (3 << REG_Z) | (3 << REG_W), \ ++ {(3u << REG_X) | (3u << REG_Y) | (3u << REG_Z) | (3u << REG_W), \ + 0x00000000}, /* ADDW_REGS, r24 - r31 */ \ + {0x00ff0000,0x00000000}, /* SIMPLE_LD_REGS r16 - r23 */ \ +- {(3 << REG_X)|(3 << REG_Y)|(3 << REG_Z)|(3 << REG_W)|(0xff << 16), \ ++ {(3u << REG_X)|(3u << REG_Y)|(3u << REG_Z)|(3u << REG_W)|(0xffu << 16),\ + 0x00000000}, /* LD_REGS, r16 - r31 */ \ + {0x0000ffff,0x00000000}, /* NO_LD_REGS r0 - r15 */ \ + {0xffffffff,0x00000000}, /* GENERAL_REGS, r0 - r31 */ \ Index: gcc/config/aarch64/arm_neon.h =================================================================== --- a/src/gcc/config/aarch64/arm_neon.h (.../tags/gcc_4_8_3_release) @@ -865,11 +1369,76 @@ Index: gcc/config/rs6000/htm.md (parallel [(set (match_operand:SI 0 "int_reg_operand" "") (and:SI (match_dup 3) (const_int 15))) (clobber (scratch:CC))])] +Index: gcc/config/rs6000/rs6000-protos.h +=================================================================== +--- a/src/gcc/config/rs6000/rs6000-protos.h (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/config/rs6000/rs6000-protos.h (.../branches/gcc-4_8-branch) +@@ -161,7 +161,7 @@ + extern rtx rs6000_libcall_value (enum machine_mode); + extern rtx rs6000_va_arg (tree, tree); + extern int function_ok_for_sibcall (tree); +-extern int rs6000_reg_parm_stack_space (tree); ++extern int rs6000_reg_parm_stack_space (tree, bool); + extern void rs6000_elf_declare_function_name (FILE *, const char *, tree); + extern bool rs6000_elf_in_small_data_p (const_tree); + #ifdef ARGS_SIZE_RTX +Index: gcc/config/rs6000/rs6000-builtin.def +=================================================================== +--- a/src/gcc/config/rs6000/rs6000-builtin.def (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/config/rs6000/rs6000-builtin.def (.../branches/gcc-4_8-branch) +@@ -622,20 +622,13 @@ + | RS6000_BTC_TERNARY), \ + CODE_FOR_ ## ICODE) /* ICODE */ + +-/* Miscellaneous builtins. */ +-#define BU_MISC_1(ENUM, NAME, ATTR, ICODE) \ ++/* 128-bit long double floating point builtins. */ ++#define BU_LDBL128_2(ENUM, NAME, ATTR, ICODE) \ + RS6000_BUILTIN_2 (MISC_BUILTIN_ ## ENUM, /* ENUM */ \ + "__builtin_" NAME, /* NAME */ \ +- RS6000_BTM_HARD_FLOAT, /* MASK */ \ ++ (RS6000_BTM_HARD_FLOAT /* MASK */ \ ++ | RS6000_BTM_LDBL128), \ + (RS6000_BTC_ ## ATTR /* ATTR */ \ +- | RS6000_BTC_UNARY), \ +- CODE_FOR_ ## ICODE) /* ICODE */ +- +-#define BU_MISC_2(ENUM, NAME, ATTR, ICODE) \ +- RS6000_BUILTIN_2 (MISC_BUILTIN_ ## ENUM, /* ENUM */ \ +- "__builtin_" NAME, /* NAME */ \ +- RS6000_BTM_HARD_FLOAT, /* MASK */ \ +- (RS6000_BTC_ ## ATTR /* ATTR */ \ + | RS6000_BTC_BINARY), \ + CODE_FOR_ ## ICODE) /* ICODE */ + +@@ -1593,10 +1586,8 @@ + BU_DFP_MISC_2 (PACK_TD, "pack_dec128", CONST, packtd) + BU_DFP_MISC_2 (UNPACK_TD, "unpack_dec128", CONST, unpacktd) + +-BU_MISC_2 (PACK_TF, "pack_longdouble", CONST, packtf) +-BU_MISC_2 (UNPACK_TF, "unpack_longdouble", CONST, unpacktf) +-BU_MISC_1 (UNPACK_TF_0, "longdouble_dw0", CONST, unpacktf_0) +-BU_MISC_1 (UNPACK_TF_1, "longdouble_dw1", CONST, unpacktf_1) ++BU_LDBL128_2 (PACK_TF, "pack_longdouble", CONST, packtf) ++BU_LDBL128_2 (UNPACK_TF, "unpack_longdouble", CONST, unpacktf) + + BU_P7_MISC_2 (PACK_V1TI, "pack_vector_int128", CONST, packv1ti) + BU_P7_MISC_2 (UNPACK_V1TI, "unpack_vector_int128", CONST, unpackv1ti) Index: gcc/config/rs6000/rs6000.c =================================================================== --- a/src/gcc/config/rs6000/rs6000.c (.../tags/gcc_4_8_3_release) +++ b/src/gcc/config/rs6000/rs6000.c (.../branches/gcc-4_8-branch) -@@ -6109,7 +6109,8 @@ +@@ -3014,7 +3014,8 @@ + | ((TARGET_CRYPTO) ? RS6000_BTM_CRYPTO : 0) + | ((TARGET_HTM) ? RS6000_BTM_HTM : 0) + | ((TARGET_DFP) ? RS6000_BTM_DFP : 0) +- | ((TARGET_HARD_FLOAT) ? RS6000_BTM_HARD_FLOAT : 0)); ++ | ((TARGET_HARD_FLOAT) ? RS6000_BTM_HARD_FLOAT : 0) ++ | ((TARGET_LONG_DOUBLE_128) ? RS6000_BTM_LDBL128 : 0)); + } + + /* Override command line options. Mostly we process the processor type and +@@ -6109,7 +6110,8 @@ return false; extra = GET_MODE_SIZE (mode) - UNITS_PER_WORD; @@ -879,6 +1448,129 @@ Index: gcc/config/rs6000/rs6000.c if (GET_CODE (addr) == LO_SUM) /* For lo_sum addresses, we must allow any offset except one that +@@ -10497,10 +10499,9 @@ + list, or passes any parameter in memory. */ + + static bool +-rs6000_function_parms_need_stack (tree fun) ++rs6000_function_parms_need_stack (tree fun, bool incoming) + { +- function_args_iterator args_iter; +- tree arg_type; ++ tree fntype, result; + CUMULATIVE_ARGS args_so_far_v; + cumulative_args_t args_so_far; + +@@ -10507,26 +10508,57 @@ + if (!fun) + /* Must be a libcall, all of which only use reg parms. */ + return false; ++ ++ fntype = fun; + if (!TYPE_P (fun)) +- fun = TREE_TYPE (fun); ++ fntype = TREE_TYPE (fun); + + /* Varargs functions need the parameter save area. */ +- if (!prototype_p (fun) || stdarg_p (fun)) ++ if ((!incoming && !prototype_p (fntype)) || stdarg_p (fntype)) + return true; + +- INIT_CUMULATIVE_INCOMING_ARGS (args_so_far_v, fun, NULL_RTX); ++ INIT_CUMULATIVE_INCOMING_ARGS (args_so_far_v, fntype, NULL_RTX); + args_so_far = pack_cumulative_args (&args_so_far_v); + +- if (aggregate_value_p (TREE_TYPE (fun), fun)) ++ /* When incoming, we will have been passed the function decl. ++ It is necessary to use the decl to handle K&R style functions, ++ where TYPE_ARG_TYPES may not be available. */ ++ if (incoming) + { +- tree type = build_pointer_type (TREE_TYPE (fun)); +- rs6000_parm_needs_stack (args_so_far, type); ++ gcc_assert (DECL_P (fun)); ++ result = DECL_RESULT (fun); + } ++ else ++ result = TREE_TYPE (fntype); + +- FOREACH_FUNCTION_ARGS (fun, arg_type, args_iter) +- if (rs6000_parm_needs_stack (args_so_far, arg_type)) +- return true; ++ if (result && aggregate_value_p (result, fntype)) ++ { ++ if (!TYPE_P (result)) ++ result = TREE_TYPE (result); ++ result = build_pointer_type (result); ++ rs6000_parm_needs_stack (args_so_far, result); ++ } + ++ if (incoming) ++ { ++ tree parm; ++ ++ for (parm = DECL_ARGUMENTS (fun); ++ parm && parm != void_list_node; ++ parm = TREE_CHAIN (parm)) ++ if (rs6000_parm_needs_stack (args_so_far, TREE_TYPE (parm))) ++ return true; ++ } ++ else ++ { ++ function_args_iterator args_iter; ++ tree arg_type; ++ ++ FOREACH_FUNCTION_ARGS (fntype, arg_type, args_iter) ++ if (rs6000_parm_needs_stack (args_so_far, arg_type)) ++ return true; ++ } ++ + return false; + } + +@@ -10537,7 +10569,7 @@ + all parameters in registers. */ + + int +-rs6000_reg_parm_stack_space (tree fun) ++rs6000_reg_parm_stack_space (tree fun, bool incoming) + { + int reg_parm_stack_space; + +@@ -10555,7 +10587,7 @@ + case ABI_ELFv2: + /* ??? Recomputing this every time is a bit expensive. Is there + a place to cache this information? */ +- if (rs6000_function_parms_need_stack (fun)) ++ if (rs6000_function_parms_need_stack (fun, incoming)) + reg_parm_stack_space = TARGET_64BIT ? 64 : 32; + else + reg_parm_stack_space = 0; +@@ -13544,11 +13576,15 @@ + else if ((fnmask & (RS6000_BTM_DFP | RS6000_BTM_P8_VECTOR)) + == (RS6000_BTM_DFP | RS6000_BTM_P8_VECTOR)) + error ("Builtin function %s requires the -mhard-dfp and" +- "-mpower8-vector options", name); ++ " -mpower8-vector options", name); + else if ((fnmask & RS6000_BTM_DFP) != 0) + error ("Builtin function %s requires the -mhard-dfp option", name); + else if ((fnmask & RS6000_BTM_P8_VECTOR) != 0) + error ("Builtin function %s requires the -mpower8-vector option", name); ++ else if ((fnmask & (RS6000_BTM_HARD_FLOAT | RS6000_BTM_LDBL128)) ++ == (RS6000_BTM_HARD_FLOAT | RS6000_BTM_LDBL128)) ++ error ("Builtin function %s requires the -mhard-float and" ++ " -mlong-double-128 options", name); + else if ((fnmask & RS6000_BTM_HARD_FLOAT) != 0) + error ("Builtin function %s requires the -mhard-float option", name); + else +@@ -31413,6 +31449,7 @@ + { "htm", RS6000_BTM_HTM, false, false }, + { "hard-dfp", RS6000_BTM_DFP, false, false }, + { "hard-float", RS6000_BTM_HARD_FLOAT, false, false }, ++ { "long-double-128", RS6000_BTM_LDBL128, false, false }, + }; + + /* Option variables that we want to support inside attribute((target)) and Index: gcc/config/rs6000/vsx.md =================================================================== --- a/src/gcc/config/rs6000/vsx.md (.../tags/gcc_4_8_3_release) @@ -980,6 +1672,56 @@ Index: gcc/config/rs6000/vsx.md (parallel [(const_int 1) (const_int 0)])))] "!BYTES_BIG_ENDIAN && VECTOR_MEM_VSX_P (mode)" "stxvd2x %x1,%y0" +Index: gcc/config/rs6000/rs6000.h +=================================================================== +--- a/src/gcc/config/rs6000/rs6000.h (.../tags/gcc_4_8_3_release) ++++ b/src/gcc/config/rs6000/rs6000.h (.../branches/gcc-4_8-branch) +@@ -1593,8 +1593,15 @@ + /* Define this if stack space is still allocated for a parameter passed + in a register. The value is the number of bytes allocated to this + area. */ +-#define REG_PARM_STACK_SPACE(FNDECL) rs6000_reg_parm_stack_space((FNDECL)) ++#define REG_PARM_STACK_SPACE(FNDECL) \ ++ rs6000_reg_parm_stack_space ((FNDECL), false) + ++/* Define this macro if space guaranteed when compiling a function body ++ is different to space required when making a call, a situation that ++ can arise with K&R style function definitions. */ ++#define INCOMING_REG_PARM_STACK_SPACE(FNDECL) \ ++ rs6000_reg_parm_stack_space ((FNDECL), true) ++ + /* Define this if the above stack space is to be considered part of the + space allocated by the caller. */ + #define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 +@@ -2483,8 +2490,8 @@ + #define RS6000_BTC_SAT RS6000_BTC_MISC /* saturate sets VSCR. */ + + /* Builtin targets. For now, we reuse the masks for those options that are in +- target flags, and pick two random bits for SPE and paired which aren't in +- target_flags. */ ++ target flags, and pick three random bits for SPE, paired and ldbl128 which ++ aren't in target_flags. */ + #define RS6000_BTM_ALWAYS 0 /* Always enabled. */ + #define RS6000_BTM_ALTIVEC MASK_ALTIVEC /* VMX/altivec vectors. */ + #define RS6000_BTM_VSX MASK_VSX /* VSX (vector/scalar). */ +@@ -2501,6 +2508,7 @@ + #define RS6000_BTM_CELL MASK_FPRND /* Target is cell powerpc. */ + #define RS6000_BTM_DFP MASK_DFP /* Decimal floating point. */ + #define RS6000_BTM_HARD_FLOAT MASK_SOFT_FLOAT /* Hardware floating point. */ ++#define RS6000_BTM_LDBL128 MASK_MULTIPLE /* 128-bit long double. */ + + #define RS6000_BTM_COMMON (RS6000_BTM_ALTIVEC \ + | RS6000_BTM_VSX \ +@@ -2514,7 +2522,8 @@ + | RS6000_BTM_POPCNTD \ + | RS6000_BTM_CELL \ + | RS6000_BTM_DFP \ +- | RS6000_BTM_HARD_FLOAT) ++ | RS6000_BTM_HARD_FLOAT \ ++ | RS6000_BTM_LDBL128) + + /* Define builtin enum index. */ + Index: gcc/config/rs6000/rs6000.md =================================================================== --- a/src/gcc/config/rs6000/rs6000.md (.../tags/gcc_4_8_3_release) @@ -1002,6 +1744,33 @@ Index: gcc/config/rs6000/rs6000.md "TARGET_POWERPC64 && rs6000_gen_cell_microcode && !TARGET_LFIWAX" "@ lwa%U1%X1 %0,%1 +@@ -15847,26 +15847,6 @@ + "" + "") + +-;; The Advance Toolchain 7.0-3 added private builtins: __builtin_longdouble_dw0 +-;; and __builtin_longdouble_dw1 to optimize glibc. Add support for these +-;; builtins here. +- +-(define_expand "unpacktf_0" +- [(set (match_operand:DF 0 "nonimmediate_operand" "") +- (unspec:DF [(match_operand:TF 1 "register_operand" "") +- (const_int 0)] +- UNSPEC_UNPACK_128BIT))] +- "" +- "") +- +-(define_expand "unpacktf_1" +- [(set (match_operand:DF 0 "nonimmediate_operand" "") +- (unspec:DF [(match_operand:TF 1 "register_operand" "") +- (const_int 1)] +- UNSPEC_UNPACK_128BIT))] +- "" +- "") +- + (define_insn_and_split "unpack_dm" + [(set (match_operand: 0 "nonimmediate_operand" "=d,m,d,r,m") + (unspec: Index: gcc/config/arm/arm.md =================================================================== --- a/src/gcc/config/arm/arm.md (.../tags/gcc_4_8_3_release) -- cgit v1.2.3