source: patches/gcc-4.4.1-branch_update-4.patch@ 761b731

clfs-1.2 clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 761b731 was 0cbb4b7, checked in by jim <jim@…>, 15 years ago

Updated GCC Patches

  • Property mode set to 100644
File size: 240.3 KB
  • contrib/compare-debug

    Submitted By: Jim Gifford (jim at cross-lfs dot org)
    Date: 09-12-2009
    Initial Package Version: 4.4.1
    Origin: Upstream
    Upstream Status: Applied
    Description: This is a branch update for gcc-4.4.1, and should be
                 rechecked periodically.
    
    This patch was made from Revision # 151655.
    
    diff -Naur gcc-4.4.1.orig/contrib/compare-debug gcc-4.4.1/contrib/compare-debug
    old new  
    22
    33# Compare stripped copies of two given object files.
    44
    5 # Copyright (C) 2007 Free Software Foundation
     5# Copyright (C) 2007, 2008, 2009 Free Software Foundation
    66# Originally by Alexandre Oliva <aoliva@redhat.com>
    77
    88# This file is part of GCC.
     
    6767  status=0
    6868else
    6969  status=1
     70
     71  # Assembler-generated CFI will add an .eh_frame section for -g not
     72  # present in -g0.  Try to cope with it by checking that an .eh_frame
     73  # section is present in either object file, and then stripping it
     74  # off before re-comparing.
     75
     76  cmd=
     77  cmp1=
     78  cmp2=
     79
     80  for t in objdump readelf eu-readelf; do
     81    if ($t --help) 2>&1 | grep -e '--\[*section-\]*headers' > /dev/null; then
     82      cmd=$t
     83
     84      $cmd --section-headers "$1.$suf1" | grep '\.eh_frame' > /dev/null
     85      cmp1=$?
     86
     87      $cmd --section-headers "$2.$suf2" | grep '\.eh_frame' > /dev/null
     88      cmp2=$?
     89
     90      break
     91    fi
     92  done
     93
     94  # If we found .eh_frame in one but not the other, or if we could not
     95  # find a command to tell, try to strip off the .eh_frame section
     96  # from both.
     97  if test "x$cmp1" != "x$cmp2" || test "x$cmd" = "x"; then
     98    suf3=$suf1.
     99    while test -f "$1.$suf3"; do
     100      suf3=$suf3.
     101    done
     102
     103    suf4=$suf2.
     104    while test -f "$2.$suf4"; do
     105      suf4=$suf4.
     106    done
     107
     108    trap 'rm -f "$1.$suf1" "$2.$suf2" "$1.$suf3" "$2.$suf4"' 0 1 2 15
     109
     110    echo stripping off .eh_frame, then retrying >&2
     111
     112    if (objcopy -v) 2>&1 | grep -e "--remove-section" > /dev/null; then
     113      objcopy --remove-section .eh_frame --remove-section .rel.eh_frame --remove-section .rela.eh_frame "$1.$suf1" "$1.$suf3"
     114      mv "$1.$suf3" "$1.$suf1"
     115
     116      objcopy --remove-section .eh_frame --remove-section .rel.eh_frame --remove-section .rela.eh_frame "$2.$suf2" "$2.$suf4"
     117      mv "$2.$suf4" "$2.$suf2"
     118    elif (strip --help) 2>&1 | grep -e --remove-section > /dev/null; then
     119      cp "$1.$suf1" "$1.$suf3"
     120      strip --remove-section .eh_frame --remove-section .rel.eh_frame --remove-section .rela.eh_frame "$1.$suf3"
     121      mv "$1.$suf3" "$1.$suf1"
     122
     123      cp "$2.$suf2" "$2.$suf4"
     124      strip --remove-section .eh_frame --remove-section .rel.eh_frame --remove-section .rela.eh_frame "$2.$suf4"
     125      mv "$2.$suf4" "$2.$suf2"
     126    else
     127      echo failed to strip off .eh_frame >&2
     128    fi
     129
     130    trap 'rm -f "$1.$suf1" "$2.$suf2"' 0 1 2 15
     131
     132    if cmp "$1.$suf1" "$2.$suf2"; then
     133      status=0
     134    else
     135      status=1
     136    fi
     137  fi
    70138fi
    71139
    72140$rm "$1.$suf1" "$2.$suf2"
  • gcc/alias.c

    diff -Naur gcc-4.4.1.orig/gcc/alias.c gcc-4.4.1/gcc/alias.c
    old new  
    19321932{
    19331933  const_tree fieldx, fieldy, typex, typey, orig_y;
    19341934
     1935  if (!flag_strict_aliasing)
     1936    return false;
     1937
    19351938  do
    19361939    {
    19371940      /* The comparison has to be done at a common type, since we don't
  • gcc/builtins.c

    diff -Naur gcc-4.4.1.orig/gcc/builtins.c gcc-4.4.1/gcc/builtins.c
    old new  
    86348634            }
    86358635        }
    86368636
    8637       /* Optimize pow(pow(x,y),z) = pow(x,y*z).  */
     8637      /* Optimize pow(pow(x,y),z) = pow(x,y*z) iff x is nonnegative.  */
    86388638      if (fcode == BUILT_IN_POW
    86398639          || fcode == BUILT_IN_POWF
    86408640          || fcode == BUILT_IN_POWL)
    86418641        {
    86428642          tree arg00 = CALL_EXPR_ARG (arg0, 0);
    8643           tree arg01 = CALL_EXPR_ARG (arg0, 1);
    8644           tree narg1 = fold_build2 (MULT_EXPR, type, arg01, arg1);
    8645           return build_call_expr (fndecl, 2, arg00, narg1);
     8643          if (tree_expr_nonnegative_p (arg00))
     8644            {
     8645              tree arg01 = CALL_EXPR_ARG (arg0, 1);
     8646              tree narg1 = fold_build2 (MULT_EXPR, type, arg01, arg1);
     8647              return build_call_expr (fndecl, 2, arg00, narg1);
     8648            }
    86468649        }
    86478650    }
    86488651
  • gcc/config/alpha/alpha.c

    diff -Naur gcc-4.4.1.orig/gcc/config/alpha/alpha.c gcc-4.4.1/gcc/config/alpha/alpha.c
    old new  
    20522052
    20532053  switch (GET_CODE (x))
    20542054    {
    2055     case CONST:
    20562055    case LABEL_REF:
    20572056    case HIGH:
    20582057      return true;
    20592058
     2059    case CONST:
     2060      if (GET_CODE (XEXP (x, 0)) == PLUS
     2061          && GET_CODE (XEXP (XEXP (x, 0), 1)) == CONST_INT)
     2062        x = XEXP (XEXP (x, 0), 0);
     2063      else
     2064        return true;
     2065
     2066      if (GET_CODE (x) != SYMBOL_REF)
     2067        return true;
     2068
     2069      /* FALLTHRU */
     2070
    20602071    case SYMBOL_REF:
    20612072      /* TLS symbols are never valid.  */
    20622073      return SYMBOL_REF_TLS_MODEL (x) == 0;
     
    35423553              emit_insn (gen_insll_le (insl, gen_lowpart (SImode, src), addr));
    35433554              break;
    35443555            case 8:
    3545               emit_insn (gen_insql_le (insl, src, addr));
     3556              emit_insn (gen_insql_le (insl, gen_lowpart (DImode, src), addr));
    35463557              break;
    35473558            }
    35483559        }
     
    82798290  insn = get_last_insn ();
    82808291  if (!INSN_P (insn))
    82818292    insn = prev_active_insn (insn);
    8282   if (GET_CODE (insn) == CALL_INSN)
     8293  if (insn && GET_CODE (insn) == CALL_INSN)
    82838294    output_asm_insn (get_insn_template (CODE_FOR_nop, NULL), NULL);
    82848295
    82858296#if TARGET_ABI_OSF
  • gcc/config/alpha/alpha.md

    diff -Naur gcc-4.4.1.orig/gcc/config/alpha/alpha.md gcc-4.4.1/gcc/config/alpha/alpha.md
    old new  
    256256        (sign_extend:DI (match_dup 1)))]
    257257  "")
    258258
    259 ;; Don't say we have addsi3 if optimizing.  This generates better code.  We
    260 ;; have the anonymous addsi3 pattern below in case combine wants to make it.
    261 (define_expand "addsi3"
    262   [(set (match_operand:SI 0 "register_operand" "")
    263         (plus:SI (match_operand:SI 1 "reg_or_0_operand" "")
    264                  (match_operand:SI 2 "add_operand" "")))]
    265   "! optimize"
    266   "")
    267 
    268 (define_insn "*addsi_internal"
     259(define_insn "addsi3"
    269260  [(set (match_operand:SI 0 "register_operand" "=r,r,r,r")
    270261        (plus:SI (match_operand:SI 1 "reg_or_0_operand" "%rJ,rJ,rJ,rJ")
    271262                 (match_operand:SI 2 "add_operand" "rI,O,K,L")))]
     
    619610  ""
    620611  "subqv $31,%1,%0")
    621612
    622 (define_expand "subsi3"
    623   [(set (match_operand:SI 0 "register_operand" "")
    624         (minus:SI (match_operand:SI 1 "reg_or_0_operand" "")
    625                   (match_operand:SI 2 "reg_or_8bit_operand" "")))]
    626   "! optimize"
    627   "")
    628 
    629 (define_insn "*subsi_internal"
     613(define_insn "subsi3"
    630614  [(set (match_operand:SI 0 "register_operand" "=r")
    631615        (minus:SI (match_operand:SI 1 "reg_or_0_operand" "rJ")
    632616                  (match_operand:SI 2 "reg_or_8bit_operand" "rI")))]
     
    37163700        (match_operator:DF 1 "alpha_fp_comparison_operator"
    37173701                           [(match_operand:DF 2 "reg_or_0_operand" "fG")
    37183702                            (match_operand:DF 3 "reg_or_0_operand" "fG")]))]
    3719   "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
    3720   "cmp%-%C1%/ %R2,%R3,%0"
    3721   [(set_attr "type" "fadd")
    3722    (set_attr "trap" "yes")
    3723    (set_attr "trap_suffix" "su")])
    3724 
    3725 (define_insn "*cmpdf_ieee_ext1"
    3726   [(set (match_operand:DF 0 "register_operand" "=&f")
    3727         (match_operator:DF 1 "alpha_fp_comparison_operator"
    3728                            [(float_extend:DF
    3729                              (match_operand:SF 2 "reg_or_0_operand" "fG"))
    3730                             (match_operand:DF 3 "reg_or_0_operand" "fG")]))]
    3731   "TARGET_FP && alpha_fptm >= ALPHA_FPTM_SU"
     3703  "TARGET_FP"
    37323704  "cmp%-%C1%/ %R2,%R3,%0"
    37333705  [(set_attr "type" "fadd")
    37343706   (set_attr "trap" "yes")
     
    37463718   (set_attr "trap" "yes")
    37473719   (set_attr "trap_suffix" "su")])
    37483720
    3749 (define_insn "*cmpdf_ieee_ext2"
    3750   [(set (match_operand:DF 0 "register_operand" "=&f")
    3751         (match_operator:DF 1 "alpha_fp_comparison_operator"
    3752                            [(match_operand:DF 2 "reg_or_0_operand" "fG")
    3753                             (float_extend:DF
    3754                              (match_operand:SF 3 "reg_or_0_operand" "fG"))]))]
    3755   "TARGET_FP && alpha_fptm >= ALPHA_FPTM_SU"
    3756   "cmp%-%C1%/ %R2,%R3,%0"
    3757   [(set_attr "type" "fadd")
    3758    (set_attr "trap" "yes")
    3759    (set_attr "trap_suffix" "su")])
    3760 
    37613721(define_insn "*cmpdf_ext2"
    37623722  [(set (match_operand:DF 0 "register_operand" "=f")
    37633723        (match_operator:DF 1 "alpha_fp_comparison_operator"
     
    37703730   (set_attr "trap" "yes")
    37713731   (set_attr "trap_suffix" "su")])
    37723732
    3773 (define_insn "*cmpdf_ieee_ext3"
    3774   [(set (match_operand:DF 0 "register_operand" "=&f")
    3775         (match_operator:DF 1 "alpha_fp_comparison_operator"
    3776                            [(float_extend:DF
    3777                              (match_operand:SF 2 "reg_or_0_operand" "fG"))
    3778                             (float_extend:DF
    3779                              (match_operand:SF 3 "reg_or_0_operand" "fG"))]))]
    3780   "TARGET_FP && alpha_fptm >= ALPHA_FPTM_SU"
    3781   "cmp%-%C1%/ %R2,%R3,%0"
    3782   [(set_attr "type" "fadd")
    3783    (set_attr "trap" "yes")
    3784    (set_attr "trap_suffix" "su")])
    3785 
    37863733(define_insn "*cmpdf_ext3"
    37873734  [(set (match_operand:DF 0 "register_operand" "=f")
    37883735        (match_operator:DF 1 "alpha_fp_comparison_operator"
     
    38323779                          (match_operand:DF 2 "const0_operand" "G,G")])
    38333780         (float_extend:DF (match_operand:SF 1 "reg_or_0_operand" "fG,0"))
    38343781         (match_operand:DF 5 "reg_or_0_operand" "0,fG")))]
    3835   "TARGET_FP"
     3782  "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
    38363783  "@
    38373784   fcmov%C3 %R4,%R1,%0
    38383785   fcmov%D3 %R4,%R5,%0"
     
    38473794                          (match_operand:DF 2 "const0_operand" "G,G")])
    38483795         (match_operand:DF 1 "reg_or_0_operand" "fG,0")
    38493796         (match_operand:DF 5 "reg_or_0_operand" "0,fG")))]
    3850   "TARGET_FP"
     3797  "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
    38513798  "@
    38523799   fcmov%C3 %R4,%R1,%0
    38533800   fcmov%D3 %R4,%R5,%0"
     
    38623809                          (match_operand:DF 2 "const0_operand" "G,G")])
    38633810         (match_operand:SF 1 "reg_or_0_operand" "fG,0")
    38643811         (match_operand:SF 5 "reg_or_0_operand" "0,fG")))]
    3865   "TARGET_FP"
     3812  "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
    38663813  "@
    38673814   fcmov%C3 %R4,%R1,%0
    38683815   fcmov%D3 %R4,%R5,%0"
     
    38773824                          (match_operand:DF 2 "const0_operand" "G,G")])
    38783825         (float_extend:DF (match_operand:SF 1 "reg_or_0_operand" "fG,0"))
    38793826         (match_operand:DF 5 "reg_or_0_operand" "0,fG")))]
    3880   "TARGET_FP"
     3827  "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
    38813828  "@
    38823829   fcmov%C3 %R4,%R1,%0
    38833830   fcmov%D3 %R4,%R5,%0"
  • gcc/config/alpha/sync.md

    diff -Naur gcc-4.4.1.orig/gcc/config/alpha/sync.md gcc-4.4.1/gcc/config/alpha/sync.md
    old new  
    6262  [(set_attr "type" "st_c")])
    6363
    6464;; The Alpha Architecture Handbook says that it is UNPREDICTABLE whether
    65 ;; the lock is cleared by a TAKEN branch.  If we were to honor that, it
    66 ;; would mean that we could not expand a ll/sc sequence until after the
    67 ;; final basic-block reordering pass.  Fortunately, it appears that no
    68 ;; Alpha implementation ever built actually clears the lock on branches,
    69 ;; taken or not.
     65;; the lock is cleared by a TAKEN branch.  This means that we can not
     66;; expand a ll/sc sequence until after the final basic-block reordering pass.
    7067
    7168(define_insn_and_split "sync_<fetchop_name><mode>"
    7269  [(set (match_operand:I48MODE 0 "memory_operand" "+m")
     
    7774   (clobber (match_scratch:I48MODE 2 "=&r"))]
    7875  ""
    7976  "#"
    80   "reload_completed"
     77  "epilogue_completed"
    8178  [(const_int 0)]
    8279{
    8380  alpha_split_atomic_op (<CODE>, operands[0], operands[1],
     
    9693   (clobber (match_scratch:I48MODE 2 "=&r"))]
    9794  ""
    9895  "#"
    99   "reload_completed"
     96  "epilogue_completed"
    10097  [(const_int 0)]
    10198{
    10299  alpha_split_atomic_op (NOT, operands[0], operands[1],
     
    116113   (clobber (match_scratch:I48MODE 3 "=&r"))]
    117114  ""
    118115  "#"
    119   "reload_completed"
     116  "epilogue_completed"
    120117  [(const_int 0)]
    121118{
    122119  alpha_split_atomic_op (<CODE>, operands[1], operands[2],
     
    137134   (clobber (match_scratch:I48MODE 3 "=&r"))]
    138135  ""
    139136  "#"
    140   "reload_completed"
     137  "epilogue_completed"
    141138  [(const_int 0)]
    142139{
    143140  alpha_split_atomic_op (NOT, operands[1], operands[2],
     
    158155   (clobber (match_scratch:I48MODE 3 "=&r"))]
    159156  ""
    160157  "#"
    161   "reload_completed"
     158  "epilogue_completed"
    162159  [(const_int 0)]
    163160{
    164161  alpha_split_atomic_op (<CODE>, operands[1], operands[2],
     
    179176   (clobber (match_scratch:I48MODE 3 "=&r"))]
    180177  ""
    181178  "#"
    182   "reload_completed"
     179  "epilogue_completed"
    183180  [(const_int 0)]
    184181{
    185182  alpha_split_atomic_op (NOT, operands[1], operands[2],
     
    214211   (clobber (match_scratch:DI 6 "=X,&r"))]
    215212  ""
    216213  "#"
    217   "reload_completed"
     214  "epilogue_completed"
    218215  [(const_int 0)]
    219216{
    220217  alpha_split_compare_and_swap_12 (<MODE>mode, operands[0], operands[1],
     
    251248   (clobber (match_scratch:I48MODE 4 "=&r"))]
    252249  ""
    253250  "#"
    254   "reload_completed"
     251  "epilogue_completed"
    255252  [(const_int 0)]
    256253{
    257254  alpha_split_compare_and_swap (operands[0], operands[1], operands[2],
     
    282279   (clobber (match_scratch:DI 4 "=&r"))]
    283280  ""
    284281  "#"
    285   "reload_completed"
     282  "epilogue_completed"
    286283  [(const_int 0)]
    287284{
    288285  alpha_split_lock_test_and_set_12 (<MODE>mode, operands[0], operands[1],
     
    301298   (clobber (match_scratch:I48MODE 3 "=&r"))]
    302299  ""
    303300  "#"
    304   "reload_completed"
     301  "epilogue_completed"
    305302  [(const_int 0)]
    306303{
    307304  alpha_split_lock_test_and_set (operands[0], operands[1],
  • gcc/config/arm/arm.md

    diff -Naur gcc-4.4.1.orig/gcc/config/arm/arm.md gcc-4.4.1/gcc/config/arm/arm.md
    old new  
    472472  if (TARGET_THUMB1)
    473473    {
    474474      if (GET_CODE (operands[1]) != REG)
    475         operands[1] = force_reg (SImode, operands[1]);
     475        operands[1] = force_reg (DImode, operands[1]);
    476476      if (GET_CODE (operands[2]) != REG)
    477         operands[2] = force_reg (SImode, operands[2]);
     477        operands[2] = force_reg (DImode, operands[2]);
    478478     }
    479479  "
    480480)
  • gcc/config/avr/avr.c

    diff -Naur gcc-4.4.1.orig/gcc/config/avr/avr.c gcc-4.4.1/gcc/config/avr/avr.c
    old new  
    996996              start_sequence ();
    997997
    998998              emit_move_insn (myfp,
    999                               gen_rtx_PLUS (HImode, myfp,
     999                              gen_rtx_PLUS (GET_MODE (myfp), myfp,
    10001000                                            gen_int_mode (size,
    10011001                                                          GET_MODE(myfp))));
    10021002
  • gcc/config/i386/i386.c

    diff -Naur gcc-4.4.1.orig/gcc/config/i386/i386.c gcc-4.4.1/gcc/config/i386/i386.c
    old new  
    73407340    return 0;
    73417341
    73427342  ix86_compute_frame_layout (&frame);
    7343   return frame.to_allocate == 0 && (frame.nregs + frame.nsseregs) == 0;
     7343  return frame.to_allocate == 0 && frame.padding0 == 0
     7344         && (frame.nregs + frame.nsseregs) == 0;
    73447345}
    73457346
    73467347
  • gcc/config/i386/i386.md

     /* Value should be nonzero if functions must have frame pointers.
    @@ -8328,7 +8329,7 @@
              && (! TARGET_STACK_PROBE || allocate < CHECK_STACK_LIMIT)))
         {
           if (!frame_pointer_needed
    -	  || !frame.to_allocate
    +	  || !(frame.to_allocate + frame.padding0)
     	  || crtl->stack_realign_needed)
             ix86_emit_save_regs_using_mov (stack_pointer_rtx,
     				       frame.to_allocate
    @@ -8338,7 +8339,7 @@
     				       -frame.nregs * UNITS_PER_WORD);
         }
       if (!frame_pointer_needed
    -      || !frame.to_allocate
    +      || !(frame.to_allocate + frame.padding0)
           || crtl->stack_realign_needed)
         ix86_emit_save_sse_regs_using_mov (stack_pointer_rtx,
     				       frame.to_allocate);
    @@ -8524,8 +8525,10 @@
       if ((!sp_valid && (frame.nregs + frame.nsseregs) <= 1)
           || (TARGET_EPILOGUE_USING_MOVE
     	  && cfun->machine->use_fast_prologue_epilogue
    -	  && ((frame.nregs + frame.nsseregs) > 1 || frame.to_allocate))
    -      || (frame_pointer_needed && !(frame.nregs + frame.nsseregs) && frame.to_allocate)
    +	  && ((frame.nregs + frame.nsseregs) > 1
    +	      || (frame.to_allocate + frame.padding0) != 0))
    +      || (frame_pointer_needed && !(frame.nregs + frame.nsseregs)
    +          && (frame.to_allocate + frame.padding0) != 0)
           || (frame_pointer_needed && TARGET_USE_LEAVE
     	  && cfun->machine->use_fast_prologue_epilogue
     	  && (frame.nregs + frame.nsseregs) == 1)
    @@ -8535,13 +8538,13 @@
     	 locations.  If both are available, default to ebp, since offsets
     	 are known to be small.  Only exception is esp pointing directly
     	 to the end of block of saved registers, where we may simplify
    -	 addressing mode.  
    +	 addressing mode.
     
     	 If we are realigning stack with bp and sp, regs restore can't
     	 be addressed by bp. sp must be used instead.  */
     
           if (!frame_pointer_needed
    -	  || (sp_valid && !frame.to_allocate) 
    +	  || (sp_valid && !(frame.to_allocate + frame.padding0))
     	  || stack_realign_fp)
     	{
     	  ix86_emit_restore_sse_regs_using_mov (stack_pointer_rtx,
    @@ -8630,9 +8633,10 @@
               ix86_emit_restore_sse_regs_using_mov (stack_pointer_rtx,
     					        frame.to_allocate, style == 2);
     	  pro_epilogue_adjust_stack (stack_pointer_rtx, stack_pointer_rtx,
    -				     GEN_INT (frame.nsseregs * 16), style);
    +				     GEN_INT (frame.nsseregs * 16 +
    +				       frame.padding0), style);
     	}
    -      else if (frame.to_allocate || frame.nsseregs)
    +      else if (frame.to_allocate || frame.padding0 || frame.nsseregs)
     	{
               ix86_emit_restore_sse_regs_using_mov (stack_pointer_rtx,
     					        frame.to_allocate,
    @@ -12090,16 +12094,18 @@
     output_387_ffreep (rtx *operands ATTRIBUTE_UNUSED, int opno)
     {
       if (TARGET_USE_FFREEP)
    -#if HAVE_AS_IX86_FFREEP
    +#ifdef HAVE_AS_IX86_FFREEP
         return opno ? "ffreep\t%y1" : "ffreep\t%y0";
     #else
         {
    -      static char retval[] = ".word\t0xc_df";
    +      static char retval[32];
           int regno = REGNO (operands[opno]);
     
           gcc_assert (FP_REGNO_P (regno));
     
    -      retval[9] = '0' + (regno - FIRST_STACK_REG);
    +      regno -= FIRST_STACK_REG;
    +
    +      snprintf (retval, sizeof (retval), ASM_SHORT "0xc%ddf", regno);
           return retval;
         }
     #endif
    @@ -16307,10 +16313,20 @@
       /* When emitting push, take care for source operands on the stack.  */
       if (push && MEM_P (operands[1])
           && reg_overlap_mentioned_p (stack_pointer_rtx, operands[1]))
    -    for (i = 0; i < nparts - 1; i++)
    -      part[1][i] = change_address (part[1][i],
    -				   GET_MODE (part[1][i]),
    -				   XEXP (part[1][i + 1], 0));
    +    {
    +      rtx src_base = XEXP (part[1][nparts - 1], 0);
    +
    +      /* Compensate for the stack decrement by 4.  */
    +      if (!TARGET_64BIT && nparts == 3
    +	  && mode == XFmode && TARGET_128BIT_LONG_DOUBLE)
    +	src_base = plus_constant (src_base, 4);
    +
    +      /* src_base refers to the stack pointer and is
    +	 automatically decreased by emitted push.  */
    +      for (i = 0; i < nparts; i++)
    +	part[1][i] = change_address (part[1][i],
    +				     GET_MODE (part[1][i]), src_base);
    +    }
     
       /* We need to do copy in the right order in case an address register
          of the source overlaps the destination.  */
    @@ -16380,7 +16396,8 @@
     	  if (nparts == 3)
     	    {
     	      if (TARGET_128BIT_LONG_DOUBLE && mode == XFmode)
    -                emit_insn (gen_addsi3 (stack_pointer_rtx, stack_pointer_rtx, GEN_INT (-4)));
    +                emit_insn (gen_addsi3 (stack_pointer_rtx,
    +				       stack_pointer_rtx, GEN_INT (-4)));
     	      emit_move_insn (part[0][2], part[1][2]);
     	    }
     	  else if (nparts == 4)
    @@ -25306,7 +25323,7 @@
     static tree
     ix86_vectorize_builtin_conversion (unsigned int code, tree type)
     {
    -  if (TREE_CODE (type) != VECTOR_TYPE
    +  if (!TARGET_SSE2 || TREE_CODE (type) != VECTOR_TYPE
           /* There are only conversions from/to signed integers.  */
           || TYPE_UNSIGNED (TREE_TYPE (type)))
         return NULL_TREE;
    diff -Naur gcc-4.4.1.orig/gcc/config/i386/i386.md gcc-4.4.1/gcc/config/i386/i386.md
    old new  
    1497314973         (match_operand:SI 1 "" ""))
    1497414974   (set (reg:SI SP_REG) (plus:SI (reg:SI SP_REG)
    1497514975                            (match_operand:SI 2 "immediate_operand" "i")))]
    14976   "!TARGET_64BIT"
     14976  "!SIBLING_CALL_P (insn) && !TARGET_64BIT"
    1497714977{
    1497814978  if (constant_call_address_operand (operands[0], Pmode))
    14979     {
    14980       if (SIBLING_CALL_P (insn))
    14981         return "jmp\t%P0";
    14982       else
    14983         return "call\t%P0";
    14984     }
    14985   if (SIBLING_CALL_P (insn))
    14986     return "jmp\t%A0";
    14987   else
    14988     return "call\t%A0";
     14979    return "call\t%P0";
     14980  return "call\t%A0";
    1498914981}
    1499014982  [(set_attr "type" "call")])
    1499114983
     14984(define_insn "*sibcall_pop_1"
     14985  [(call (mem:QI (match_operand:SI 0 "sibcall_insn_operand" "s,U"))
     14986         (match_operand:SI 1 "" ""))
     14987   (set (reg:SI SP_REG) (plus:SI (reg:SI SP_REG)
     14988                            (match_operand:SI 2 "immediate_operand" "i,i")))]
     14989  "SIBLING_CALL_P (insn) && !TARGET_64BIT"
     14990  "@
     14991   jmp\t%P0
     14992   jmp\t%A0"
     14993  [(set_attr "type" "call")])
     14994
    1499214995(define_expand "call"
    1499314996  [(call (match_operand:QI 0 "" "")
    1499414997         (match_operand 1 "" ""))
     
    1592015923   (unspec:DI [(match_operand:DI 1 "tls_symbolic_operand" "")]
    1592115924              UNSPEC_TLS_GD)]
    1592215925  "TARGET_64BIT"
    15923   ".byte\t0x66\;lea{q}\t{%a1@TLSGD(%%rip), %%rdi|rdi, %a1@TLSGD[rip]}\;.word\t0x6666\;rex64\;call\t%P2"
     15926  { return ".byte\t0x66\n\tlea{q}\t{%a1@TLSGD(%%rip), %%rdi|rdi, %a1@TLSGD[rip]}\n" ASM_SHORT "0x6666\n\trex64\n\tcall\t%P2"; }
    1592415927  [(set_attr "type" "multi")
    1592515928   (set_attr "length" "16")])
    1592615929
     
    2146921472              (match_operand:SI 2 "" "")))
    2147021473   (set (reg:SI SP_REG) (plus:SI (reg:SI SP_REG)
    2147121474                            (match_operand:SI 3 "immediate_operand" "i")))]
    21472   "!TARGET_64BIT"
     21475  "!SIBLING_CALL_P (insn) && !TARGET_64BIT"
    2147321476{
    2147421477  if (constant_call_address_operand (operands[1], Pmode))
    21475     {
    21476       if (SIBLING_CALL_P (insn))
    21477         return "jmp\t%P1";
    21478       else
    21479         return "call\t%P1";
    21480     }
    21481   if (SIBLING_CALL_P (insn))
    21482     return "jmp\t%A1";
    21483   else
    21484     return "call\t%A1";
     21478    return "call\t%P1";
     21479  return "call\t%A1";
    2148521480}
    2148621481  [(set_attr "type" "callv")])
    2148721482
     21483(define_insn "*sibcall_value_pop_1"
     21484  [(set (match_operand 0 "" "")
     21485        (call (mem:QI (match_operand:SI 1 "sibcall_insn_operand" "s,U"))
     21486              (match_operand:SI 2 "" "")))
     21487   (set (reg:SI SP_REG) (plus:SI (reg:SI SP_REG)
     21488                            (match_operand:SI 3 "immediate_operand" "i,i")))]
     21489  "SIBLING_CALL_P (insn) && !TARGET_64BIT"
     21490  "@
     21491   jmp\t%P1
     21492   jmp\t%A1"
     21493  [(set_attr "type" "callv")])
     21494
    2148821495(define_insn "*call_value_0"
    2148921496  [(set (match_operand 0 "" "")
    2149021497        (call (mem:QI (match_operand:SI 1 "constant_call_address_operand" ""))
  • gcc/config/i386/netware.c

    diff -Naur gcc-4.4.1.orig/gcc/config/i386/netware.c gcc-4.4.1/gcc/config/i386/netware.c
    old new  
    3030#include "flags.h"
    3131#include "tm_p.h"
    3232#include "toplev.h"
     33#include "langhooks.h"
    3334#include "ggc.h"
    3435
    3536/* Return string which is the function name, identified by ID, modified
     
    179180{
    180181  default_encode_section_info (decl, rtl, first);
    181182
    182   if (first
    183       && TREE_CODE (decl) == FUNCTION_DECL
     183  if (TREE_CODE (decl) == FUNCTION_DECL
    184184      /* Do not change the identifier if a verbatim asmspec
    185185         or if stdcall suffix already added.  */
    186186      && *IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl)) != '*'
    187       && !strchr (IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl)), '@'))
     187      && !strchr (IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl)), '@')
     188      /* FIXME:  Imported stdcall names are not modified by the Ada frontend.
     189         Check and decorate the RTL name now.  */
     190      && strcmp (lang_hooks.name, "GNU Ada") == 0)
    188191    {
    189       /* FIXME: In Ada, and perhaps other language frontends,
    190          imported stdcall names may not yet have been modified.
    191          Check and do it know.  */
    192192      rtx symbol = XEXP (rtl, 0);
    193193      tree new_id;
    194194      tree old_id = DECL_ASSEMBLER_NAME (decl);
     
    196196      gcc_assert (GET_CODE (symbol) == SYMBOL_REF);
    197197
    198198      if ((new_id = i386_nlm_maybe_mangle_decl_assembler_name (decl, old_id)))
    199         {
    200           /* These attributes must be present on first declaration,
    201              change_decl_assembler_name will warn if they are added
    202              later and the decl has been referenced, but duplicate_decls
    203              should catch the mismatch first.  */
    204           change_decl_assembler_name (decl, new_id);
    205           XSTR (symbol, 0) = IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl));
    206         }
     199        XSTR (symbol, 0) = IDENTIFIER_POINTER (new_id);
    207200    }
    208201}
    209202
     
    233226    }
    234227  return name;
    235228}
    236 
    237 /* Sometimes certain combinations of command options do not make
    238    sense on a particular target machine.  You can define a macro
    239    `OVERRIDE_OPTIONS' to take account of this.  This macro, if
    240    defined, is executed once just after all the command options have
    241    been parsed.
    242 
    243    Don't use this macro to turn on various extra optimizations for
    244    `-O'.  That is what `OPTIMIZATION_OPTIONS' is for.  */
    245 
    246 void
    247 netware_override_options (void)
    248 {
    249   override_options ();
    250 
    251   if (flag_pic)
    252     {
    253       error ("-fPIC and -fpic are not supported for this target");
    254       flag_pic = 0;
    255     }
    256 }
  • gcc/config/i386/netware.h

    diff -Naur gcc-4.4.1.orig/gcc/config/i386/netware.h gcc-4.4.1/gcc/config/i386/netware.h
    old new  
    7272#define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP | \
    7373        MASK_FLOAT_RETURNS | MASK_ALIGN_DOUBLE | MASK_MS_BITFIELD_LAYOUT)
    7474
    75 /* Sometimes certain combinations of command options do not make
    76    sense on a particular target machine.  You can define a macro
    77    `OVERRIDE_OPTIONS' to take account of this.  This macro, if
    78    defined, is executed once just after all the command options have
    79    been parsed.
    80 
    81    Don't use this macro to turn on various extra optimizations for
    82    `-O'.  That is what `OPTIMIZATION_OPTIONS' is for.  */
    83 #undef  OVERRIDE_OPTIONS
    84 extern void netware_override_options (void);
    85 #define OVERRIDE_OPTIONS netware_override_options ()
     75/* Don't allow flag_pic to propagate since invalid relocations will
     76   result otherwise.  */
     77#define SUBTARGET_OVERRIDE_OPTIONS                                      \
     78do {                                                                    \
     79  if (flag_pic)                                                         \
     80    {                                                                   \
     81      error ("-fPIC and -fpic are not supported for this target");      \
     82      flag_pic = 0;                                                     \
     83    }                                                                   \
     84} while (0)
    8685
    8786#undef MATH_LIBRARY
    8887#define MATH_LIBRARY ""
     
    9998#undef KEEP_AGGREGATE_RETURN_POINTER
    10099#define KEEP_AGGREGATE_RETURN_POINTER 1
    101100
     101#undef ASM_COMMENT_START
     102#define ASM_COMMENT_START "#"
     103
    102104#undef DBX_REGISTER_NUMBER
    103105#define DBX_REGISTER_NUMBER(n) (svr4_dbx_register_map[n])
    104106
  • gcc/config/i386/nwld.h

    diff -Naur gcc-4.4.1.orig/gcc/config/i386/nwld.h gcc-4.4.1/gcc/config/i386/nwld.h
    old new  
    5555#define TARGET_ASM_CONSTRUCTOR nwld_named_section_asm_out_constructor
    5656#define TARGET_ASM_DESTRUCTOR  nwld_named_section_asm_out_destructor
    5757
     58#define SUBSUBTARGET_OVERRIDE_OPTIONS                                   \
     59do {                                                                    \
     60  /* XXX This can be enabled once gas output meets nwld's needs. */     \
     61  /* if (!flag_unwind_tables && !flag_exceptions) */                    \
     62    flag_dwarf2_cfi_asm = 0;                                            \
     63} while (0)
     64
    5865#undef  EH_FRAME_SECTION_NAME
    5966#define EH_FRAME_SECTION_NAME ".eh_frame"TARGET_SUB_SECTION_SEPARATOR
    6067
  • gcc/config/i386/sse.md

    diff -Naur gcc-4.4.1.orig/gcc/config/i386/sse.md gcc-4.4.1/gcc/config/i386/sse.md
    old new  
    6464(define_mode_iterator SSEMODE4S [V4SF V4SI])
    6565(define_mode_iterator SSEMODE2D [V2DF V2DI])
    6666
     67;; Modes handled by integer vcond pattern
     68(define_mode_iterator SSEMODE124C8 [V16QI V8HI V4SI
     69                                    (V2DI "TARGET_SSE4_2 || TARGET_SSE5")])
     70
    6771;; Mapping from float mode to required SSE level
    6872(define_mode_attr sse [(SF "sse") (DF "sse2") (V4SF "sse") (V2DF "sse2")])
    6973
     
    14931497          (match_operand:SSEMODEF2P 2 "general_operand" "")))]
    14941498  "SSE_VEC_FLOAT_MODE_P (<MODE>mode)"
    14951499{
    1496   if (ix86_expand_fp_vcond (operands))
    1497     DONE;
    1498   else
    1499     FAIL;
     1500  bool ok = ix86_expand_fp_vcond (operands);
     1501  gcc_assert (ok);
     1502  DONE;
    15001503})
    15011504
    15021505;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
     
    58375840   (set_attr "mode" "TI")])
    58385841
    58395842(define_expand "vcond<mode>"
    5840   [(set (match_operand:SSEMODEI 0 "register_operand" "")
    5841         (if_then_else:SSEMODEI
     5843  [(set (match_operand:SSEMODE124C8 0 "register_operand" "")
     5844        (if_then_else:SSEMODE124C8
    58425845          (match_operator 3 ""
    5843             [(match_operand:SSEMODEI 4 "nonimmediate_operand" "")
    5844              (match_operand:SSEMODEI 5 "nonimmediate_operand" "")])
    5845           (match_operand:SSEMODEI 1 "general_operand" "")
    5846           (match_operand:SSEMODEI 2 "general_operand" "")))]
     5846            [(match_operand:SSEMODE124C8 4 "nonimmediate_operand" "")
     5847             (match_operand:SSEMODE124C8 5 "nonimmediate_operand" "")])
     5848          (match_operand:SSEMODE124C8 1 "general_operand" "")
     5849          (match_operand:SSEMODE124C8 2 "general_operand" "")))]
    58475850  "TARGET_SSE2"
    58485851{
    5849   if (ix86_expand_int_vcond (operands))
    5850     DONE;
    5851   else
    5852     FAIL;
     5852  bool ok = ix86_expand_int_vcond (operands);
     5853  gcc_assert (ok);
     5854  DONE;
    58535855})
    58545856
    58555857(define_expand "vcondu<mode>"
    5856   [(set (match_operand:SSEMODEI 0 "register_operand" "")
    5857         (if_then_else:SSEMODEI
     5858  [(set (match_operand:SSEMODE124C8 0 "register_operand" "")
     5859        (if_then_else:SSEMODE124C8
    58585860          (match_operator 3 ""
    5859             [(match_operand:SSEMODEI 4 "nonimmediate_operand" "")
    5860              (match_operand:SSEMODEI 5 "nonimmediate_operand" "")])
    5861           (match_operand:SSEMODEI 1 "general_operand" "")
    5862           (match_operand:SSEMODEI 2 "general_operand" "")))]
     5861            [(match_operand:SSEMODE124C8 4 "nonimmediate_operand" "")
     5862             (match_operand:SSEMODE124C8 5 "nonimmediate_operand" "")])
     5863          (match_operand:SSEMODE124C8 1 "general_operand" "")
     5864          (match_operand:SSEMODE124C8 2 "general_operand" "")))]
    58635865  "TARGET_SSE2"
    58645866{
    5865   if (ix86_expand_int_vcond (operands))
    5866     DONE;
    5867   else
    5868     FAIL;
     5867  bool ok = ix86_expand_int_vcond (operands);
     5868  gcc_assert (ok);
     5869  DONE;
    58695870})
    58705871
    58715872;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  • gcc/config/pa/pa.c

    diff -Naur gcc-4.4.1.orig/gcc/config/pa/pa.c gcc-4.4.1/gcc/config/pa/pa.c
    old new  
    22172217  else
    22182218    {
    22192219      /* Find the width of the bitstring in IMM.  */
    2220       for (len = 5; len < 32; len++)
     2220      for (len = 5; len < 32 - lsb; len++)
    22212221        {
    2222           if ((imm & (1 << len)) == 0)
     2222          if ((imm & ((unsigned HOST_WIDE_INT) 1 << len)) == 0)
    22232223            break;
    22242224        }
    22252225
     
    22382238void
    22392239compute_zdepdi_operands (unsigned HOST_WIDE_INT imm, unsigned *op)
    22402240{
    2241   HOST_WIDE_INT lsb, len;
     2241  int lsb, len, maxlen;
     2242
     2243  maxlen = MIN (HOST_BITS_PER_WIDE_INT, 64);
    22422244
    22432245  /* Find the least significant set bit in IMM.  */
    2244   for (lsb = 0; lsb < HOST_BITS_PER_WIDE_INT; lsb++)
     2246  for (lsb = 0; lsb < maxlen; lsb++)
    22452247    {
    22462248      if ((imm & 1) != 0)
    22472249        break;
     
    22502252
    22512253  /* Choose variants based on *sign* of the 5-bit field.  */
    22522254  if ((imm & 0x10) == 0)
    2253     len = ((lsb <= HOST_BITS_PER_WIDE_INT - 4)
    2254            ? 4 : HOST_BITS_PER_WIDE_INT - lsb);
     2255    len = (lsb <= maxlen - 4) ? 4 : maxlen - lsb;
    22552256  else
    22562257    {
    22572258      /* Find the width of the bitstring in IMM.  */
    2258       for (len = 5; len < HOST_BITS_PER_WIDE_INT; len++)
     2259      for (len = 5; len < maxlen - lsb; len++)
    22592260        {
    22602261          if ((imm & ((unsigned HOST_WIDE_INT) 1 << len)) == 0)
    22612262            break;
    22622263        }
    22632264
     2265      /* Extend length if host is narrow and IMM is negative.  */
     2266      if (HOST_BITS_PER_WIDE_INT == 32 && len == maxlen - lsb)
     2267        len += 32;
     2268
    22642269      /* Sign extend IMM as a 5-bit value.  */
    22652270      imm = (imm & 0xf) - 0x10;
    22662271    }
  • gcc/config/rs6000/freebsd.h

    diff -Naur gcc-4.4.1.orig/gcc/config/rs6000/freebsd.h gcc-4.4.1/gcc/config/rs6000/freebsd.h
    old new  
    11/* Definitions for PowerPC running FreeBSD using the ELF format
    2    Copyright (C) 2001, 2003, 2007 Free Software Foundation, Inc.
     2   Copyright (C) 2001, 2003, 2007, 2009 Free Software Foundation, Inc.
    33   Contributed by David E. O'Brien <obrien@FreeBSD.org> and BSDi.
    44
    55   This file is part of GCC.
     
    6969/* Override rs6000.h definition.  */
    7070#undef  ASM_APP_OFF
    7171#define ASM_APP_OFF "#NO_APP\n"
     72/* Define SVR4_ASM_SPEC, we use GAS by default. See svr4.h for details.  */
     73#define SVR4_ASM_SPEC \
     74  "%{v:-V} %{Wa,*:%*}"
  • gcc/config/rs6000/rs6000.c

    diff -Naur gcc-4.4.1.orig/gcc/config/rs6000/rs6000.c gcc-4.4.1/gcc/config/rs6000/rs6000.c
    old new  
    38083808rs6000_legitimize_address (rtx x, rtx oldx ATTRIBUTE_UNUSED,
    38093809                           enum machine_mode mode)
    38103810{
     3811  unsigned int extra = 0;
     3812
    38113813  if (GET_CODE (x) == SYMBOL_REF)
    38123814    {
    38133815      enum tls_model model = SYMBOL_REF_TLS_MODEL (x);
     
    38153817        return rs6000_legitimize_tls_address (x, model);
    38163818    }
    38173819
     3820  switch (mode)
     3821    {
     3822    case DFmode:
     3823    case DDmode:
     3824      extra = 4;
     3825      break;
     3826    case DImode:
     3827      if (!TARGET_POWERPC64)
     3828        extra = 4;
     3829      break;
     3830    case TFmode:
     3831    case TDmode:
     3832      extra = 12;
     3833      break;
     3834    case TImode:
     3835      extra = TARGET_POWERPC64 ? 8 : 12;
     3836      break;
     3837    default:
     3838      break;
     3839    }
     3840
    38183841  if (GET_CODE (x) == PLUS
    38193842      && GET_CODE (XEXP (x, 0)) == REG
    38203843      && GET_CODE (XEXP (x, 1)) == CONST_INT
    3821       && (unsigned HOST_WIDE_INT) (INTVAL (XEXP (x, 1)) + 0x8000) >= 0x10000
     3844      && ((unsigned HOST_WIDE_INT) (INTVAL (XEXP (x, 1)) + 0x8000)
     3845          >= 0x10000 - extra)
    38223846      && !((TARGET_POWERPC64
    38233847            && (mode == DImode || mode == TImode)
    38243848            && (INTVAL (XEXP (x, 1)) & 3) != 0)
     
    38313855      HOST_WIDE_INT high_int, low_int;
    38323856      rtx sum;
    38333857      low_int = ((INTVAL (XEXP (x, 1)) & 0xffff) ^ 0x8000) - 0x8000;
     3858      if (low_int >= 0x8000 - extra)
     3859        low_int = 0;
    38343860      high_int = INTVAL (XEXP (x, 1)) - low_int;
    38353861      sum = force_operand (gen_rtx_PLUS (Pmode, XEXP (x, 0),
    38363862                                         GEN_INT (high_int)), 0);
    3837       return gen_rtx_PLUS (Pmode, sum, GEN_INT (low_int));
     3863      return plus_constant (sum, low_int);
    38383864    }
    38393865  else if (GET_CODE (x) == PLUS
    38403866           && GET_CODE (XEXP (x, 0)) == REG
  • gcc/config/s390/2084.md

    diff -Naur gcc-4.4.1.orig/gcc/config/s390/2084.md gcc-4.4.1/gcc/config/s390/2084.md
    old new  
    163163
    164164(define_insn_reservation "x_fsimptf" 7
    165165  (and (eq_attr "cpu" "z990,z9_109")
    166        (eq_attr "type" "fsimptf"))
     166       (eq_attr "type" "fsimptf,fhex"))
    167167  "x_e1_t*2,x-wr-fp")
    168168
    169169(define_insn_reservation "x_fsimpdf" 6
    170170  (and (eq_attr "cpu" "z990,z9_109")
    171        (eq_attr "type" "fsimpdf,fmuldf"))
     171       (eq_attr "type" "fsimpdf,fmuldf,fhex"))
    172172  "x_e1_t,x-wr-fp")
    173173
    174174(define_insn_reservation "x_fsimpsf" 6
    175175  (and (eq_attr "cpu" "z990,z9_109")
    176        (eq_attr "type" "fsimpsf,fmulsf"))
     176       (eq_attr "type" "fsimpsf,fmulsf,fhex"))
    177177  "x_e1_t,x-wr-fp")
    178178
    179179
  • gcc/config/s390/2097.md

    diff -Naur gcc-4.4.1.orig/gcc/config/s390/2097.md gcc-4.4.1/gcc/config/s390/2097.md
    old new  
    463463
    464464; BFP multiplication and general instructions
    465465
    466 (define_insn_reservation "z10_fsimpdf" 12
     466(define_insn_reservation "z10_fsimpdf" 6
    467467  (and (eq_attr "cpu" "z10")
    468468       (eq_attr "type" "fsimpdf,fmuldf"))
    469469  "z10_e1_BOTH, z10_Gate_FP")
    470 ; Wg "z10_e1_T, z10_Gate_FP")
    471470
    472 (define_insn_reservation "z10_fsimpsf" 12
     471; LOAD ZERO produces a hex value but we need bin. Using the stage 7
     472; bypass causes an exception for format conversion which is very
     473; expensive. So, make sure subsequent instructions only get the zero
     474; in the normal way.
     475(define_insn_reservation "z10_fhex" 12
     476  (and (eq_attr "cpu" "z10")
     477       (eq_attr "type" "fhex"))
     478  "z10_e1_BOTH, z10_Gate_FP")
     479
     480(define_insn_reservation "z10_fsimpsf" 6
    473481  (and (eq_attr "cpu" "z10")
    474482       (eq_attr "type" "fsimpsf,fmulsf"))
    475483  "z10_e1_BOTH, z10_Gate_FP")
    476 ; Wg "z10_e1_T, z10_Gate_FP")
    477484
    478485(define_insn_reservation "z10_fmultf" 52
    479486  (and (eq_attr "cpu" "z10")
    480487       (eq_attr "type" "fmultf"))
    481488  "z10_e1_BOTH*4, z10_Gate_FP")
    482 ; Wg  "z10_e1_T*4, z10_Gate_FP")
    483489
    484490(define_insn_reservation "z10_fsimptf" 14
    485491  (and (eq_attr "cpu" "z10")
    486492       (eq_attr "type" "fsimptf"))
    487493  "z10_e1_BOTH*2, z10_Gate_FP")
    488 ; Wg  "z10_e1_T*2, z10_Gate_FP")
    489494
    490495
    491496; BFP division
     
    531536       (eq_attr "type" "floadtf"))
    532537  "z10_e1_T, z10_Gate_FP")
    533538
    534 (define_insn_reservation "z10_floaddf" 12
     539(define_insn_reservation "z10_floaddf" 1
    535540  (and (eq_attr "cpu" "z10")
    536541       (eq_attr "type" "floaddf"))
    537542  "z10_e1_T, z10_Gate_FP")
    538543
    539 (define_insn_reservation "z10_floadsf" 12
     544(define_insn_reservation "z10_floadsf" 1
    540545  (and (eq_attr "cpu" "z10")
    541546       (eq_attr "type" "floadsf"))
    542547  "z10_e1_T, z10_Gate_FP")
     
    553558
    554559
    555560; BFP truncate
    556 (define_insn_reservation "z10_ftrunctf" 12
     561(define_insn_reservation "z10_ftrunctf" 16
    557562  (and (eq_attr "cpu" "z10")
    558563       (eq_attr "type" "ftrunctf"))
    559564  "z10_e1_T, z10_Gate_FP")
    560565
    561 (define_insn_reservation "z10_ftruncdf" 16
     566(define_insn_reservation "z10_ftruncdf" 12
    562567  (and (eq_attr "cpu" "z10")
    563568       (eq_attr "type" "ftruncdf"))
    564569  "z10_e1_T, z10_Gate_FP")
     
    585590; BFP-related bypasses.  There is no bypass for extended mode.
    586591(define_bypass 1 "z10_fsimpdf" "z10_fstoredf")
    587592(define_bypass 1 "z10_fsimpsf" "z10_fstoresf")
    588 (define_bypass 1 "z10_floaddf" "z10_fsimpdf, z10_fstoredf, z10_floaddf")
    589 (define_bypass 1 "z10_floadsf" "z10_fsimpsf, z10_fstoresf, z10_floadsf")
     593(define_bypass 1 "z10_floaddf" "z10_fsimpdf, z10_fstoredf")
     594(define_bypass 1 "z10_floadsf" "z10_fsimpsf, z10_fstoresf")
    590595
    591596
    592597;
  • gcc/config/s390/constraints.md

    diff -Naur gcc-4.4.1.orig/gcc/config/s390/constraints.md gcc-4.4.1/gcc/config/s390/constraints.md
    old new  
    6666;;    B -- Multiple letter constraint followed by Q, R, S, or T:
    6767;;         Memory reference of the type specified by second letter that
    6868;;         does *not* refer to a literal pool entry.
    69 ;;    U -- Pointer with short displacement.
    70 ;;    W -- Pointer with long displacement.
     69;;    U -- Pointer with short displacement. (deprecated - use ZQZR)
     70;;    W -- Pointer with long displacement. (deprecated - use ZSZT)
    7171;;    Y -- Shift count operand.
     72;;    ZQ -- Pointer without index register and with short displacement.
     73;;    ZR -- Pointer with index register and short displacement.
     74;;    ZS -- Pointer without index register but with long displacement.
     75;;    ZT -- Pointer with index register and long displacement.
     76;;
    7277;;
    7378
    7479
     
    462467
    463468
    464469(define_address_constraint "U"
    465   "Pointer with short displacement"
     470  "Pointer with short displacement. (deprecated - use ZQZR)"
    466471  (match_test "s390_mem_constraint (\"U\", op)"))
    467472
    468 
    469 
    470473(define_address_constraint "W"
    471   "Pointer with long displacement"
     474  "Pointer with long displacement. (deprecated - use ZSZT)"
    472475  (match_test "s390_mem_constraint (\"W\", op)"))
     476
     477
     478(define_address_constraint "ZQ"
     479  "Pointer without index register and with short displacement."
     480  (match_test "s390_mem_constraint (\"ZQ\", op)"))
     481
     482(define_address_constraint "ZR"
     483  "Pointer with index register and short displacement."
     484  (match_test "s390_mem_constraint (\"ZR\", op)"))
     485
     486(define_address_constraint "ZS"
     487  "Pointer without index register but with long displacement."
     488  (match_test "s390_mem_constraint (\"ZS\", op)"))
     489
     490(define_address_constraint "ZT"
     491  "Pointer with index register and long displacement."
     492  (match_test "s390_mem_constraint (\"ZT\", op)"))
  • gcc/config/s390/s390.c

    diff -Naur gcc-4.4.1.orig/gcc/config/s390/s390.c gcc-4.4.1/gcc/config/s390/s390.c
    old new  
    5252#include "optabs.h"
    5353#include "gimple.h"
    5454#include "df.h"
     55#include "params.h"
    5556
    5657
    5758/* Define the specific costs for a given cpu.  */
     
    204205  COSTS_N_INSNS (10),    /* MSGFR */
    205206  COSTS_N_INSNS (10),    /* MSGR  */
    206207  COSTS_N_INSNS (10),    /* MSR   */
    207   COSTS_N_INSNS (10),    /* multiplication in DFmode */
     208  COSTS_N_INSNS (1) ,    /* multiplication in DFmode */
    208209  COSTS_N_INSNS (50),    /* MXBR */
    209210  COSTS_N_INSNS (120),   /* SQXBR */
    210211  COSTS_N_INSNS (52),    /* SQDBR */
    211212  COSTS_N_INSNS (38),    /* SQEBR */
    212   COSTS_N_INSNS (10),    /* MADBR */
    213   COSTS_N_INSNS (10),    /* MAEBR */
     213  COSTS_N_INSNS (1),     /* MADBR */
     214  COSTS_N_INSNS (1),     /* MAEBR */
    214215  COSTS_N_INSNS (111),   /* DXBR */
    215216  COSTS_N_INSNS (39),    /* DDBR */
    216217  COSTS_N_INSNS (32),    /* DEBR */
     
    352353#define REGNO_PAIR_OK(REGNO, MODE)                               \
    353354  (HARD_REGNO_NREGS ((REGNO), (MODE)) == 1 || !((REGNO) & 1))
    354355
     356/* That's the read ahead of the dynamic branch prediction unit in
     357   bytes on a z10 CPU.  */
     358#define Z10_PREDICT_DISTANCE 384
     359
    355360static enum machine_mode
    356361s390_libgcc_cmp_return_mode (void)
    357362{
     
    16411646  if (!(target_flags_explicit & MASK_LONG_DOUBLE_128))
    16421647    target_flags |= MASK_LONG_DOUBLE_128;
    16431648#endif
     1649
     1650  if (s390_tune == PROCESSOR_2097_Z10
     1651      && !PARAM_SET_P (PARAM_MAX_UNROLLED_INSNS))
     1652    set_param_value ("max-unrolled-insns", 100);
    16441653}
    16451654
    16461655/* Map for smallest class containing reg regno.  */
     
    16781687  if (!disp)
    16791688    return true;
    16801689
     1690  /* Without the long displacement facility we don't need to
     1691     distingiush between long and short displacement.  */
     1692  if (!TARGET_LONG_DISPLACEMENT)
     1693    return true;
     1694
    16811695  /* Integer displacement in range.  */
    16821696  if (GET_CODE (disp) == CONST_INT)
    16831697    return INTVAL (disp) >= 0 && INTVAL (disp) < 4096;
     
    20462060}
    20472061
    20482062
    2049 /* Evaluates constraint strings described by the regular expression
    2050    ([A|B](Q|R|S|T))|U|W and returns 1 if OP is a valid operand for the
    2051    constraint given in STR, or 0 else.  */
     2063/* Return true if ADDR is of kind symbol_ref or symbol_ref + const_int
     2064   and return these parts in SYMREF and ADDEND.  You can pass NULL in
     2065   SYMREF and/or ADDEND if you are not interested in these values.  */
    20522066
    2053 int
    2054 s390_mem_constraint (const char *str, rtx op)
     2067static bool
     2068s390_symref_operand_p (rtx addr, rtx *symref, HOST_WIDE_INT *addend)
    20552069{
    2056   struct s390_address addr;
    2057   char c = str[0];
     2070  HOST_WIDE_INT tmpaddend = 0;
    20582071
    2059   /* Check for offsettable variants of memory constraints.  */
    2060   if (c == 'A')
     2072  if (GET_CODE (addr) == CONST)
     2073    addr = XEXP (addr, 0);
     2074
     2075  if (GET_CODE (addr) == PLUS)
    20612076    {
    2062       /* Only accept non-volatile MEMs.  */
    2063       if (!MEM_P (op) || MEM_VOLATILE_P (op))
    2064         return 0;
     2077      if (GET_CODE (XEXP (addr, 0)) == SYMBOL_REF
     2078          && CONST_INT_P (XEXP (addr, 1)))
     2079        {
     2080          tmpaddend = INTVAL (XEXP (addr, 1));
     2081          addr = XEXP (addr, 0);
     2082        }
     2083      else
     2084        return false;
     2085    }
     2086  else
     2087    if (GET_CODE (addr) != SYMBOL_REF)
     2088        return false;
    20652089
    2066       if ((reload_completed || reload_in_progress)
    2067           ? !offsettable_memref_p (op) : !offsettable_nonstrict_memref_p (op))
    2068         return 0;
     2090  if (symref)
     2091    *symref = addr;
     2092  if (addend)
     2093    *addend = tmpaddend;
     2094
     2095  return true;
     2096}
    20692097
    2070       c = str[1];
    2071     }
    20722098
    2073   /* Check for non-literal-pool variants of memory constraints.  */
    2074   else if (c == 'B')
     2099/* Return true if the address in OP is valid for constraint letter C
     2100   if wrapped in a MEM rtx.  Set LIT_POOL_OK to true if it literal
     2101   pool MEMs should be accepted.  Only the Q, R, S, T constraint
     2102   letters are allowed for C.  */
     2103
     2104static int
     2105s390_check_qrst_address (char c, rtx op, bool lit_pool_ok)
     2106{
     2107  struct s390_address addr;
     2108  bool decomposed = false;
     2109
     2110  /* This check makes sure that no symbolic address (except literal
     2111     pool references) are accepted by the R or T constraints.  */
     2112  if (s390_symref_operand_p (op, NULL, NULL))
    20752113    {
    2076       if (GET_CODE (op) != MEM)
     2114      if (!lit_pool_ok)
    20772115        return 0;
    2078       if (!s390_decompose_address (XEXP (op, 0), &addr))
     2116      if (!s390_decompose_address (op, &addr))
    20792117        return 0;
    2080       if (addr.literal_pool)
     2118      if (!addr.literal_pool)
    20812119        return 0;
    2082 
    2083       c = str[1];
     2120      decomposed = true;
    20842121    }
    20852122
    20862123  switch (c)
    20872124    {
    2088     case 'Q':
    2089       if (GET_CODE (op) != MEM)
    2090         return 0;
    2091       if (!s390_decompose_address (XEXP (op, 0), &addr))
     2125    case 'Q': /* no index short displacement */
     2126      if (!decomposed && !s390_decompose_address (op, &addr))
    20922127        return 0;
    20932128      if (addr.indx)
    20942129        return 0;
    2095 
    2096       if (TARGET_LONG_DISPLACEMENT)
    2097         {
    2098           if (!s390_short_displacement (addr.disp))
    2099             return 0;
    2100         }
    2101       break;
    2102 
    2103     case 'R':
    2104       if (GET_CODE (op) != MEM)
     2130      if (!s390_short_displacement (addr.disp))
    21052131        return 0;
     2132      break;
    21062133
     2134    case 'R': /* with index short displacement */
    21072135      if (TARGET_LONG_DISPLACEMENT)
    21082136        {
    2109           if (!s390_decompose_address (XEXP (op, 0), &addr))
     2137          if (!decomposed && !s390_decompose_address (op, &addr))
    21102138            return 0;
    21112139          if (!s390_short_displacement (addr.disp))
    21122140            return 0;
    21132141        }
     2142      /* Any invalid address here will be fixed up by reload,
     2143         so accept it for the most generic constraint.  */
    21142144      break;
    21152145
    2116     case 'S':
     2146    case 'S': /* no index long displacement */
    21172147      if (!TARGET_LONG_DISPLACEMENT)
    21182148        return 0;
    2119       if (GET_CODE (op) != MEM)
    2120         return 0;
    2121       if (!s390_decompose_address (XEXP (op, 0), &addr))
     2149      if (!decomposed && !s390_decompose_address (op, &addr))
    21222150        return 0;
    21232151      if (addr.indx)
    21242152        return 0;
     
    21262154        return 0;
    21272155      break;
    21282156
    2129     case 'T':
     2157    case 'T': /* with index long displacement */
    21302158      if (!TARGET_LONG_DISPLACEMENT)
    21312159        return 0;
    2132       if (GET_CODE (op) != MEM)
    2133         return 0;
    2134       if (!s390_decompose_address (XEXP (op, 0), &addr))
    2135         return 0;
    2136       if (s390_short_displacement (addr.disp))
     2160      /* Any invalid address here will be fixed up by reload,
     2161         so accept it for the most generic constraint.  */
     2162      if ((decomposed || s390_decompose_address (op, &addr))
     2163          && s390_short_displacement (addr.disp))
    21372164        return 0;
    21382165      break;
     2166    default:
     2167      return 0;
     2168    }
     2169  return 1;
     2170}
    21392171
    2140     case 'U':
    2141       if (TARGET_LONG_DISPLACEMENT)
    2142         {
    2143           if (!s390_decompose_address (op, &addr))
    2144             return 0;
    2145           if (!s390_short_displacement (addr.disp))
    2146             return 0;
    2147         }
    2148       break;
    21492172
    2150     case 'W':
    2151       if (!TARGET_LONG_DISPLACEMENT)
     2173/* Evaluates constraint strings described by the regular expression
     2174   ([A|B|Z](Q|R|S|T))|U|W|Y and returns 1 if OP is a valid operand for
     2175   the constraint given in STR, or 0 else.  */
     2176
     2177int
     2178s390_mem_constraint (const char *str, rtx op)
     2179{
     2180  char c = str[0];
     2181
     2182  switch (c)
     2183    {
     2184    case 'A':
     2185      /* Check for offsettable variants of memory constraints.  */
     2186      if (!MEM_P (op) || MEM_VOLATILE_P (op))
    21522187        return 0;
    2153       if (!s390_decompose_address (op, &addr))
     2188      if ((reload_completed || reload_in_progress)
     2189          ? !offsettable_memref_p (op) : !offsettable_nonstrict_memref_p (op))
    21542190        return 0;
    2155       if (s390_short_displacement (addr.disp))
     2191      return s390_check_qrst_address (str[1], XEXP (op, 0), true);
     2192    case 'B':
     2193      /* Check for non-literal-pool variants of memory constraints.  */
     2194      if (!MEM_P (op))
    21562195        return 0;
    2157       break;
    2158 
     2196      return s390_check_qrst_address (str[1], XEXP (op, 0), false);
     2197    case 'Q':
     2198    case 'R':
     2199    case 'S':
     2200    case 'T':
     2201      if (GET_CODE (op) != MEM)
     2202        return 0;
     2203      return s390_check_qrst_address (c, XEXP (op, 0), true);
     2204    case 'U':
     2205      return (s390_check_qrst_address ('Q', op, true)
     2206              || s390_check_qrst_address ('R', op, true));
     2207    case 'W':
     2208      return (s390_check_qrst_address ('S', op, true)
     2209              || s390_check_qrst_address ('T', op, true));
    21592210    case 'Y':
    21602211      /* Simply check for the basic form of a shift count.  Reload will
    21612212         take care of making sure we have a proper base register.  */
    21622213      if (!s390_decompose_shift_count (op, NULL, NULL))
    21632214        return 0;
    21642215      break;
    2165 
     2216    case 'Z':
     2217      return s390_check_qrst_address (str[1], op, true);
    21662218    default:
    21672219      return 0;
    21682220    }
    2169 
    21702221  return 1;
    21712222}
    21722223
    21732224
    2174 
    21752225/* Evaluates constraint strings starting with letter O.  Input
    21762226   parameter C is the second letter following the "O" in the constraint
    21772227   string. Returns 1 if VALUE meets the respective constraint and 0
     
    27892839  return rclass;
    27902840}
    27912841
    2792 /* Return true if ADDR is of kind symbol_ref or symbol_ref + const_int
    2793    and return these parts in SYMREF and ADDEND.  You can pass NULL in
    2794    SYMREF and/or ADDEND if you are not interested in these values.  */
    2795 
    2796 static bool
    2797 s390_symref_operand_p (rtx addr, rtx *symref, HOST_WIDE_INT *addend)
    2798 {
    2799   HOST_WIDE_INT tmpaddend = 0;
    2800 
    2801   if (GET_CODE (addr) == CONST)
    2802     addr = XEXP (addr, 0);
    2803 
    2804   if (GET_CODE (addr) == PLUS)
    2805     {
    2806       if (GET_CODE (XEXP (addr, 0)) == SYMBOL_REF
    2807           && CONST_INT_P (XEXP (addr, 1)))
    2808         {
    2809           tmpaddend = INTVAL (XEXP (addr, 1));
    2810           addr = XEXP (addr, 0);
    2811         }
    2812       else
    2813         return false;
    2814     }
    2815   else
    2816     if (GET_CODE (addr) != SYMBOL_REF)
    2817         return false;
    2818 
    2819   if (symref)
    2820     *symref = addr;
    2821   if (addend)
    2822     *addend = tmpaddend;
    2823 
    2824   return true;
    2825 }
    2826 
    28272842/* Return true if ADDR is SYMBOL_REF + addend with addend being a
    28282843   multiple of ALIGNMENT and the SYMBOL_REF being naturally
    28292844   aligned.  */
     
    52765291   A STD instruction should be scheduled earlier,
    52775292   in order to use the bypass.  */
    52785293
     5294
    52795295static int
    52805296s390_adjust_priority (rtx insn ATTRIBUTE_UNUSED, int priority)
    52815297{
     
    52835299    return priority;
    52845300
    52855301  if (s390_tune != PROCESSOR_2084_Z990
    5286       && s390_tune != PROCESSOR_2094_Z9_109)
     5302      && s390_tune != PROCESSOR_2094_Z9_109
     5303      && s390_tune != PROCESSOR_2097_Z10)
    52875304    return priority;
    52885305
    52895306  switch (s390_safe_attr_type (insn))
     
    53025319  return priority;
    53035320}
    53045321
     5322
    53055323/* The number of instructions that can be issued per cycle.  */
    53065324
    53075325static int
     
    95899607    }
    95909608}
    95919609
     9610/* On z10 the dynamic branch prediction must see the backward jump in
     9611   a window of 384 bytes. If not it falls back to the static
     9612   prediction.  This function rearranges the loop backward branch in a
     9613   way which makes the static prediction always correct.  The function
     9614   returns true if it added an instruction.  */
     9615static bool
     9616s390_z10_fix_long_loop_prediction (rtx insn)
     9617{
     9618  rtx set = single_set (insn);
     9619  rtx code_label, label_ref, new_label;
     9620  rtx uncond_jump;
     9621  rtx cur_insn;
     9622  rtx tmp;
     9623  int distance;
     9624
     9625  /* This will exclude branch on count and branch on index patterns
     9626     since these are correctly statically predicted.  */
     9627  if (!set
     9628      || SET_DEST (set) != pc_rtx
     9629      || GET_CODE (SET_SRC(set)) != IF_THEN_ELSE)
     9630    return false;
     9631
     9632  label_ref = (GET_CODE (XEXP (SET_SRC (set), 1)) == LABEL_REF ?
     9633               XEXP (SET_SRC (set), 1) : XEXP (SET_SRC (set), 2));
     9634
     9635  gcc_assert (GET_CODE (label_ref) == LABEL_REF);
     9636
     9637  code_label = XEXP (label_ref, 0);
     9638
     9639  if (INSN_ADDRESSES (INSN_UID (code_label)) == -1
     9640      || INSN_ADDRESSES (INSN_UID (insn)) == -1
     9641      || (INSN_ADDRESSES (INSN_UID (insn))
     9642          - INSN_ADDRESSES (INSN_UID (code_label)) < Z10_PREDICT_DISTANCE))
     9643    return false;
     9644
     9645  for (distance = 0, cur_insn = PREV_INSN (insn);
     9646       distance < Z10_PREDICT_DISTANCE - 6;
     9647       distance += get_attr_length (cur_insn), cur_insn = PREV_INSN (cur_insn))
     9648    if (!cur_insn || JUMP_P (cur_insn) || LABEL_P (cur_insn))
     9649      return false;
     9650
     9651  new_label = gen_label_rtx ();
     9652  uncond_jump = emit_jump_insn_after (
     9653                  gen_rtx_SET (VOIDmode, pc_rtx,
     9654                               gen_rtx_LABEL_REF (VOIDmode, code_label)),
     9655                  insn);
     9656  emit_label_after (new_label, uncond_jump);
     9657
     9658  tmp = XEXP (SET_SRC (set), 1);
     9659  XEXP (SET_SRC (set), 1) = XEXP (SET_SRC (set), 2);
     9660  XEXP (SET_SRC (set), 2) = tmp;
     9661  INSN_CODE (insn) = -1;
     9662
     9663  XEXP (label_ref, 0) = new_label;
     9664  JUMP_LABEL (insn) = new_label;
     9665  JUMP_LABEL (uncond_jump) = code_label;
     9666
     9667  return true;
     9668}
     9669
    95929670/* Returns 1 if INSN reads the value of REG for purposes not related
    95939671   to addressing of memory, and 0 otherwise.  */
    95949672static int
     
    96719749   if that register's value is delivered via a bypass, then the
    96729750   pipeline recycles, thereby causing significant performance decline.
    96739751   This function locates such situations and exchanges the two
    9674    operands of the compare.  */
    9675 static void
    9676 s390_z10_optimize_cmp (void)
     9752   operands of the compare.  The function return true whenever it
     9753   added an insn.  */
     9754static bool
     9755s390_z10_optimize_cmp (rtx insn)
    96779756{
    9678   rtx insn, prev_insn, next_insn;
    9679   int added_NOPs = 0;
     9757  rtx prev_insn, next_insn;
     9758  bool insn_added_p = false;
     9759  rtx cond, *op0, *op1;
    96809760
    9681   for (insn = get_insns (); insn; insn = NEXT_INSN (insn))
     9761  if (GET_CODE (PATTERN (insn)) == PARALLEL)
    96829762    {
    9683       rtx cond, *op0, *op1;
    9684 
    9685       if (!INSN_P (insn) || INSN_CODE (insn) <= 0)
    9686         continue;
    9687 
    9688       if (GET_CODE (PATTERN (insn)) == PARALLEL)
    9689         {
    9690           /* Handle compare and branch and branch on count
    9691              instructions.  */
    9692           rtx pattern = single_set (insn);
    9693 
    9694           if (!pattern
    9695               || SET_DEST (pattern) != pc_rtx
    9696               || GET_CODE (SET_SRC (pattern)) != IF_THEN_ELSE)
    9697             continue;
     9763      /* Handle compare and branch and branch on count
     9764         instructions.  */
     9765      rtx pattern = single_set (insn);
     9766
     9767      if (!pattern
     9768          || SET_DEST (pattern) != pc_rtx
     9769          || GET_CODE (SET_SRC (pattern)) != IF_THEN_ELSE)
     9770        return false;
    96989771
    9699           cond = XEXP (SET_SRC (pattern), 0);
    9700           op0 = &XEXP (cond, 0);
    9701           op1 = &XEXP (cond, 1);
    9702         }
    9703       else if (GET_CODE (PATTERN (insn)) == SET)
    9704         {
    9705           rtx src, dest;
     9772      cond = XEXP (SET_SRC (pattern), 0);
     9773      op0 = &XEXP (cond, 0);
     9774      op1 = &XEXP (cond, 1);
     9775    }
     9776  else if (GET_CODE (PATTERN (insn)) == SET)
     9777    {
     9778      rtx src, dest;
    97069779
    9707           /* Handle normal compare instructions.  */
    9708           src = SET_SRC (PATTERN (insn));
    9709           dest = SET_DEST (PATTERN (insn));
     9780      /* Handle normal compare instructions.  */
     9781      src = SET_SRC (PATTERN (insn));
     9782      dest = SET_DEST (PATTERN (insn));
    97109783
    9711           if (!REG_P (dest)
    9712               || !CC_REGNO_P (REGNO (dest))
    9713               || GET_CODE (src) != COMPARE)
    9714             continue;
     9784      if (!REG_P (dest)
     9785          || !CC_REGNO_P (REGNO (dest))
     9786          || GET_CODE (src) != COMPARE)
     9787        return false;
    97159788
    9716           /* s390_swap_cmp will try to find the conditional
    9717              jump when passing NULL_RTX as condition.  */
    9718           cond = NULL_RTX;
    9719           op0 = &XEXP (src, 0);
    9720           op1 = &XEXP (src, 1);
    9721         }
    9722       else
    9723         continue;
     9789      /* s390_swap_cmp will try to find the conditional
     9790         jump when passing NULL_RTX as condition.  */
     9791      cond = NULL_RTX;
     9792      op0 = &XEXP (src, 0);
     9793      op1 = &XEXP (src, 1);
     9794    }
     9795  else
     9796    return false;
    97249797
    9725       if (!REG_P (*op0) || !REG_P (*op1))
    9726         continue;
     9798  if (!REG_P (*op0) || !REG_P (*op1))
     9799    return false;
    97279800
    9728       /* Swap the COMPARE arguments and its mask if there is a
    9729          conflicting access in the previous insn.  */
    9730       prev_insn = PREV_INSN (insn);
     9801  /* Swap the COMPARE arguments and its mask if there is a
     9802     conflicting access in the previous insn.  */
     9803  prev_insn = PREV_INSN (insn);
     9804  if (prev_insn != NULL_RTX && INSN_P (prev_insn)
     9805      && reg_referenced_p (*op1, PATTERN (prev_insn)))
     9806    s390_swap_cmp (cond, op0, op1, insn);
     9807
     9808  /* Check if there is a conflict with the next insn. If there
     9809     was no conflict with the previous insn, then swap the
     9810     COMPARE arguments and its mask.  If we already swapped
     9811     the operands, or if swapping them would cause a conflict
     9812     with the previous insn, issue a NOP after the COMPARE in
     9813     order to separate the two instuctions.  */
     9814  next_insn = NEXT_INSN (insn);
     9815  if (next_insn != NULL_RTX && INSN_P (next_insn)
     9816      && s390_non_addr_reg_read_p (*op1, next_insn))
     9817    {
    97319818      if (prev_insn != NULL_RTX && INSN_P (prev_insn)
    9732           && reg_referenced_p (*op1, PATTERN (prev_insn)))
    9733         s390_swap_cmp (cond, op0, op1, insn);
    9734 
    9735       /* Check if there is a conflict with the next insn. If there
    9736          was no conflict with the previous insn, then swap the
    9737          COMPARE arguments and its mask.  If we already swapped
    9738          the operands, or if swapping them would cause a conflict
    9739          with the previous insn, issue a NOP after the COMPARE in
    9740          order to separate the two instuctions.  */
    9741       next_insn = NEXT_INSN (insn);
    9742       if (next_insn != NULL_RTX && INSN_P (next_insn)
    9743           && s390_non_addr_reg_read_p (*op1, next_insn))
     9819          && s390_non_addr_reg_read_p (*op0, prev_insn))
    97449820        {
    9745           if (prev_insn != NULL_RTX && INSN_P (prev_insn)
    9746               && s390_non_addr_reg_read_p (*op0, prev_insn))
    9747             {
    9748               if (REGNO (*op1) == 0)
    9749                 emit_insn_after (gen_nop1 (), insn);
    9750               else
    9751                 emit_insn_after (gen_nop (), insn);
    9752               added_NOPs = 1;
    9753             }
     9821          if (REGNO (*op1) == 0)
     9822            emit_insn_after (gen_nop1 (), insn);
    97549823          else
    9755             s390_swap_cmp (cond, op0, op1, insn);
     9824            emit_insn_after (gen_nop (), insn);
     9825          insn_added_p = true;
    97569826        }
     9827      else
     9828        s390_swap_cmp (cond, op0, op1, insn);
    97579829    }
    9758 
    9759   /* Adjust branches if we added new instructions.  */
    9760   if (added_NOPs)
    9761     shorten_branches (get_insns ());
     9830  return insn_added_p;
    97629831}
    97639832
    9764 
    97659833/* Perform machine-dependent processing.  */
    97669834
    97679835static void
     
    98729940  /* Try to optimize prologue and epilogue further.  */
    98739941  s390_optimize_prologue ();
    98749942
    9875   /* Eliminate z10-specific pipeline recycles related to some compare
    9876      instructions.  */
     9943  /* Walk over the insns and do some z10 specific changes.  */
    98779944  if (s390_tune == PROCESSOR_2097_Z10)
    9878     s390_z10_optimize_cmp ();
     9945    {
     9946      rtx insn;
     9947      bool insn_added_p = false;
     9948
     9949      /* The insn lengths and addresses have to be up to date for the
     9950         following manipulations.  */
     9951      shorten_branches (get_insns ());
     9952
     9953      for (insn = get_insns (); insn; insn = NEXT_INSN (insn))
     9954        {
     9955          if (!INSN_P (insn) || INSN_CODE (insn) <= 0)
     9956            continue;
     9957
     9958          if (JUMP_P (insn))
     9959            insn_added_p |= s390_z10_fix_long_loop_prediction (insn);
     9960
     9961          if (GET_CODE (PATTERN (insn)) == PARALLEL
     9962              || GET_CODE (PATTERN (insn)) == SET)
     9963            insn_added_p |= s390_z10_optimize_cmp (insn);
     9964        }
     9965
     9966      /* Adjust branches if we added new instructions.  */
     9967      if (insn_added_p)
     9968        shorten_branches (get_insns ());
     9969    }
    98799970}
    98809971
    98819972
  • gcc/config/s390/s390.md

    diff -Naur gcc-4.4.1.orig/gcc/config/s390/s390.md gcc-4.4.1/gcc/config/s390/s390.md
    old new  
    202202(define_attr "type" "none,integer,load,lr,la,larl,lm,stm,
    203203                     cs,vs,store,sem,idiv,
    204204                     imulhi,imulsi,imuldi,
    205                      branch,jsr,fsimptf,fsimpdf,fsimpsf,
     205                     branch,jsr,fsimptf,fsimpdf,fsimpsf,fhex,
    206206                     floadtf,floaddf,floadsf,fstoredf,fstoresf,
    207207                     fmultf,fmuldf,fmulsf,fdivtf,fdivdf,fdivsf,
    208208                     ftoi,fsqrttf,fsqrtdf,fsqrtsf,
     
    10761076                      (const_int 6) (const_int 12)))]) ; 8 byte for clr/jg
    10771077                                                       ; 10 byte for clgr/jg
    10781078
     1079; And now the same two patterns as above but with a negated CC mask.
     1080
     1081; cij, cgij, crj, cgrj, cfi, cgfi, cr, cgr
     1082; The following instructions do a complementary access of their second
     1083; operand (z01 only): crj_c, cgrjc, cr, cgr
     1084(define_insn "*icmp_and_br_signed_<mode>"
     1085  [(set (pc)
     1086        (if_then_else (match_operator 0 "s390_signed_integer_comparison"
     1087                        [(match_operand:GPR 1 "register_operand"  "d,d")
     1088                         (match_operand:GPR 2 "nonmemory_operand" "d,C")])
     1089                      (pc)
     1090                      (label_ref (match_operand 3 "" ""))))
     1091   (clobber (reg:CC CC_REGNUM))]
     1092  "TARGET_Z10"
     1093{
     1094  if (get_attr_length (insn) == 6)
     1095    return which_alternative ?
     1096      "c<g>ij%D0\t%1,%c2,%l3" : "c<g>rj%D0\t%1,%2,%l3";
     1097  else
     1098    return which_alternative ?
     1099      "c<g>fi\t%1,%c2\;jg%D0\t%l3" : "c<g>r\t%1,%2\;jg%D0\t%l3";
     1100}
     1101  [(set_attr "op_type" "RIE")
     1102   (set_attr "type"    "branch")
     1103   (set_attr "z10prop" "z10_super_c,z10_super")
     1104   (set (attr "length")
     1105        (if_then_else (lt (abs (minus (pc) (match_dup 3))) (const_int 60000))
     1106                      (const_int 6) (const_int 12)))]) ; 8 byte for cr/jg
     1107                                                       ; 10 byte for cgr/jg
     1108
     1109; clij, clgij, clrj, clgrj, clfi, clgfi, clr, clgr
     1110; The following instructions do a complementary access of their second
     1111; operand (z10 only): clrj, clgrj, clr, clgr
     1112(define_insn "*icmp_and_br_unsigned_<mode>"
     1113  [(set (pc)
     1114        (if_then_else (match_operator 0 "s390_unsigned_integer_comparison"
     1115                        [(match_operand:GPR 1 "register_operand"  "d,d")
     1116                         (match_operand:GPR 2 "nonmemory_operand" "d,I")])
     1117                      (pc)
     1118                      (label_ref (match_operand 3 "" ""))))
     1119   (clobber (reg:CC CC_REGNUM))]
     1120  "TARGET_Z10"
     1121{
     1122  if (get_attr_length (insn) == 6)
     1123    return which_alternative ?
     1124      "cl<g>ij%D0\t%1,%b2,%l3" : "cl<g>rj%D0\t%1,%2,%l3";
     1125  else
     1126    return which_alternative ?
     1127      "cl<g>fi\t%1,%b2\;jg%D0\t%l3" : "cl<g>r\t%1,%2\;jg%D0\t%l3";
     1128}
     1129  [(set_attr "op_type" "RIE")
     1130   (set_attr "type"    "branch")
     1131   (set_attr "z10prop" "z10_super_c,z10_super")
     1132   (set (attr "length")
     1133        (if_then_else (lt (abs (minus (pc) (match_dup 3))) (const_int 60000))
     1134                      (const_int 6) (const_int 12)))]) ; 8 byte for clr/jg
     1135                                                       ; 10 byte for clgr/jg
     1136
    10791137;;
    10801138;;- Move instructions.
    10811139;;
     
    14701528
    14711529(define_insn "*la_64"
    14721530  [(set (match_operand:DI 0 "register_operand" "=d,d")
    1473         (match_operand:QI 1 "address_operand" "U,W"))]
     1531        (match_operand:QI 1 "address_operand" "ZQZR,ZSZT"))]
    14741532  "TARGET_64BIT"
    14751533  "@
    14761534   la\t%0,%a1
     
    16531711
    16541712(define_insn "*la_31"
    16551713  [(set (match_operand:SI 0 "register_operand" "=d,d")
    1656         (match_operand:QI 1 "address_operand" "U,W"))]
     1714        (match_operand:QI 1 "address_operand" "ZQZR,ZSZT"))]
    16571715  "!TARGET_64BIT && legitimate_la_operand_p (operands[1])"
    16581716  "@
    16591717   la\t%0,%a1
     
    16881746
    16891747(define_insn "*la_31_and"
    16901748  [(set (match_operand:SI 0 "register_operand" "=d,d")
    1691         (and:SI (match_operand:QI 1 "address_operand" "U,W")
     1749        (and:SI (match_operand:QI 1 "address_operand" "ZQZR,ZSZT")
    16921750                (const_int 2147483647)))]
    16931751  "!TARGET_64BIT"
    16941752  "@
     
    17141772
    17151773(define_insn "force_la_31"
    17161774  [(set (match_operand:SI 0 "register_operand" "=d,d")
    1717         (match_operand:QI 1 "address_operand" "U,W"))
     1775        (match_operand:QI 1 "address_operand" "ZQZR,ZSZT"))
    17181776   (use (const_int 0))]
    17191777  "!TARGET_64BIT"
    17201778  "@
     
    19091967   #
    19101968   #"
    19111969  [(set_attr "op_type" "RRE,RRE,*,*,RSY,RSY,*,*")
    1912    (set_attr "type"    "fsimptf,fsimptf,*,*,lm,stm,*,*")])
     1970   (set_attr "type"    "fhex,fsimptf,*,*,lm,stm,*,*")])
    19131971
    19141972(define_insn "*mov<mode>_31"
    19151973  [(set (match_operand:TD_TF 0 "nonimmediate_operand" "=f,f,f,o")
     
    19211979   #
    19221980   #"
    19231981  [(set_attr "op_type" "RRE,RRE,*,*")
    1924    (set_attr "type"    "fsimptf,fsimptf,*,*")])
     1982   (set_attr "type"    "fhex,fsimptf,*,*")])
    19251983
    19261984; TFmode in GPRs splitters
    19271985
     
    20292087   lg\t%0,%1
    20302088   stg\t%1,%0"
    20312089  [(set_attr "op_type" "RRE,RR,RRE,RRE,RX,RXY,RX,RXY,RRE,RXY,RXY")
    2032    (set_attr "type" "fsimpdf,floaddf,floaddf,floaddf,floaddf,floaddf,
     2090   (set_attr "type" "fhex,floaddf,floaddf,floaddf,floaddf,floaddf,
    20332091                     fstoredf,fstoredf,lr,load,store")
    20342092   (set_attr "z10prop" "*,
    20352093                        *,
     
    20592117   lg\t%0,%1
    20602118   stg\t%1,%0"
    20612119  [(set_attr "op_type" "RRE,RR,RX,RXY,RX,RXY,RRE,RXY,RXY")
    2062    (set_attr "type" "fsimp<mode>,fload<mode>,fload<mode>,fload<mode>,
     2120   (set_attr "type" "fhex,fload<mode>,fload<mode>,fload<mode>,
    20632121                     fstore<mode>,fstore<mode>,lr,load,store")
    20642122   (set_attr "z10prop" "*,
    20652123                        *,
     
    20912149   #
    20922150   #"
    20932151  [(set_attr "op_type" "RRE,RR,RX,RXY,RX,RXY,RS,RSY,RS,RSY,*,*")
    2094    (set_attr "type" "fsimp<mode>,fload<mode>,fload<mode>,fload<mode>,
     2152   (set_attr "type" "fhex,fload<mode>,fload<mode>,fload<mode>,
    20952153                     fstore<mode>,fstore<mode>,lm,lm,stm,stm,*,*")])
    20962154
    20972155(define_split
     
    21582216   st\t%1,%0
    21592217   sty\t%1,%0"
    21602218  [(set_attr "op_type" "RRE,RR,RX,RXY,RX,RXY,RR,RX,RXY,RX,RXY")
    2161    (set_attr "type" "fsimp<mode>,fload<mode>,fload<mode>,fload<mode>,
     2219   (set_attr "type" "fhex,fload<mode>,fload<mode>,fload<mode>,
    21622220                     fstore<mode>,fstore<mode>,lr,load,load,store,store")
    21632221   (set_attr "z10prop" "*,
    21642222                        *,
     
    74077465  [(set (pc)
    74087466        (if_then_else
    74097467          (match_operator 1 "s390_comparison" [(reg CC_REGNUM) (const_int 0)])
    7410           (match_operand 0 "address_operand" "U")
     7468          (match_operand 0 "address_operand" "ZQZR")
    74117469          (pc)))]
    74127470  ""
    74137471{
     
    74717529        (if_then_else
    74727530          (match_operator 1 "s390_comparison" [(reg CC_REGNUM) (const_int 0)])
    74737531          (pc)
    7474           (match_operand 0 "address_operand" "U")))]
     7532          (match_operand 0 "address_operand" "ZQZR")))]
    74757533  ""
    74767534{
    74777535  if (get_attr_op_type (insn) == OP_TYPE_RR)
     
    76607718        (if_then_else
    76617719          (ne (match_operand:SI 1 "register_operand" "d")
    76627720              (const_int 1))
    7663           (match_operand 0 "address_operand" "U")
     7721          (match_operand 0 "address_operand" "ZQZR")
    76647722          (pc)))
    76657723   (set (match_operand:SI 2 "register_operand" "=1")
    76667724        (plus:SI (match_dup 1) (const_int -1)))
     
    77717829;
    77727830
    77737831(define_insn "indirect_jump"
    7774  [(set (pc) (match_operand 0 "address_operand" "U"))]
     7832 [(set (pc) (match_operand 0 "address_operand" "ZQZR"))]
    77757833  ""
    77767834{
    77777835  if (get_attr_op_type (insn) == OP_TYPE_RR)
     
    77907848;
    77917849
    77927850(define_insn "casesi_jump"
    7793  [(set (pc) (match_operand 0 "address_operand" "U"))
     7851 [(set (pc) (match_operand 0 "address_operand" "ZQZR"))
    77947852   (use (label_ref (match_operand 1 "" "")))]
    77957853  ""
    77967854{
     
    80128070   (set_attr "type"    "jsr")])
    80138071
    80148072(define_insn "*basr"
    8015   [(call (mem:QI (match_operand 0 "address_operand" "U"))
     8073  [(call (mem:QI (match_operand 0 "address_operand" "ZQZR"))
    80168074         (match_operand 1 "const_int_operand" "n"))
    80178075   (clobber (match_operand 2 "register_operand" "=r"))]
    80188076  "!SIBLING_CALL_P (insn) && GET_MODE (operands[2]) == Pmode"
     
    80708128
    80718129(define_insn "*basr_r"
    80728130  [(set (match_operand 0 "" "")
    8073         (call (mem:QI (match_operand 1 "address_operand" "U"))
     8131        (call (mem:QI (match_operand 1 "address_operand" "ZQZR"))
    80748132              (match_operand 2 "const_int_operand" "n")))
    80758133   (clobber (match_operand 3 "register_operand" "=r"))]
    80768134  "!SIBLING_CALL_P (insn) && GET_MODE (operands[3]) == Pmode"
     
    81708228
    81718229(define_insn "*basr_tls"
    81728230  [(set (match_operand 0 "" "")
    8173         (call (mem:QI (match_operand 1 "address_operand" "U"))
     8231        (call (mem:QI (match_operand 1 "address_operand" "ZQZR"))
    81748232              (match_operand 2 "const_int_operand" "n")))
    81758233   (clobber (match_operand 3 "register_operand" "=r"))
    81768234   (use (match_operand 4 "" ""))]
     
    87208778;
    87218779
    87228780(define_insn "prefetch"
    8723   [(prefetch (match_operand 0 "address_operand" "UW,X")
    8724              (match_operand:SI 1 "const_int_operand" "n,n")
    8725              (match_operand:SI 2 "const_int_operand" "n,n"))]
    8726   "TARGET_Z10"
     8781  [(prefetch (match_operand 0    "address_operand"   "ZQZS,ZRZT,X")
     8782             (match_operand:SI 1 "const_int_operand" "   n,   n,n")
     8783             (match_operand:SI 2 "const_int_operand" "   n,   n,n"))]
     8784  "TARGET_ZARCH && s390_tune == PROCESSOR_2097_Z10"
    87278785{
    8728   if (larl_operand (operands[0], Pmode))
    8729     return INTVAL (operands[1]) == 1 ? "pfdrl\t2,%a0" : "pfdrl\t1,%a0";
     8786  switch (which_alternative)
     8787    {
     8788      case 0:
     8789        return INTVAL (operands[1]) == 1 ? "stcmh\t2,0,%a0" : "stcmh\t1,0,%a0";
     8790      case 1:
     8791        return INTVAL (operands[1]) == 1 ? "pfd\t2,%a0" : "pfd\t1,%a0";
     8792      case 2:
     8793        if (larl_operand (operands[0], Pmode))
     8794          return INTVAL (operands[1]) == 1 ? "pfdrl\t2,%a0" : "pfdrl\t1,%a0";
     8795      default:
    87308796
    8731   if (s390_mem_constraint ("W", operands[0])
    8732       || s390_mem_constraint ("U", operands[0]))
    8733     return INTVAL (operands[1]) == 1 ? "pfd\t2,%a0" : "pfd\t1,%a0";
    8734 
    8735   /* This point might be reached if op0 is a larl operand with an
    8736      uneven addend.  In this case we simply omit issuing a prefetch
    8737      instruction.  */
     8797        /* This might be reached for symbolic operands with an odd
     8798           addend.  We simply omit the prefetch for such rare cases.  */
    87388799
    8739   return "";
     8800        return "";
     8801     }
    87408802}
    8741   [(set_attr "type" "load,larl")
    8742    (set_attr "op_type" "RXY,RIL")
    8743    (set_attr "z10prop" "z10_super")])
     8803  [(set_attr "type" "store,load,larl")
     8804   (set_attr "op_type" "RSY,RXY,RIL")
     8805   (set_attr "z10prop" "z10_super")
     8806   (set_attr "cpu_facility" "*,z10,z10")])
    87448807
    87458808
    87468809;
  • gcc/cp/call.c

    diff -Naur gcc-4.4.1.orig/gcc/cp/call.c gcc-4.4.1/gcc/cp/call.c
    old new  
    12111211      lvalue_p = clk_ordinary;
    12121212      from = TREE_TYPE (from);
    12131213    }
    1214   else if (expr)
     1214
     1215  if (expr && BRACE_ENCLOSED_INITIALIZER_P (expr))
     1216    {
     1217      maybe_warn_cpp0x ("extended initializer lists");
     1218      conv = implicit_conversion (to, from, expr, c_cast_p,
     1219                                  flags);
     1220      if (!CLASS_TYPE_P (to)
     1221          && CONSTRUCTOR_NELTS (expr) == 1)
     1222        {
     1223          expr = CONSTRUCTOR_ELT (expr, 0)->value;
     1224          from = TREE_TYPE (expr);
     1225        }
     1226    }
     1227
     1228  if (lvalue_p == clk_none && expr)
    12151229    lvalue_p = real_lvalue_p (expr);
    12161230
    12171231  tfrom = from;
     
    13471361     conversion operator).  */
    13481362  flags |= LOOKUP_NO_TEMP_BIND;
    13491363
    1350   conv = implicit_conversion (to, from, expr, c_cast_p,
    1351                               flags);
     1364  if (!conv)
     1365    conv = implicit_conversion (to, from, expr, c_cast_p,
     1366                                flags);
    13521367  if (!conv)
    13531368    return NULL;
    13541369
     
    62426257  ref_conv1 = maybe_handle_ref_bind (&ics1);
    62436258  ref_conv2 = maybe_handle_ref_bind (&ics2);
    62446259
     6260  /* List-initialization sequence L1 is a better conversion sequence than
     6261     list-initialization sequence L2 if L1 converts to
     6262     std::initializer_list<X> for some X and L2 does not.  */
     6263  if (ics1->kind == ck_list && ics2->kind != ck_list)
     6264    return 1;
     6265  if (ics2->kind == ck_list && ics1->kind != ck_list)
     6266    return -1;
     6267
    62456268  /* [over.ics.rank]
    62466269
    62476270     When  comparing  the  basic forms of implicit conversion sequences (as
     
    62926315      conversion *t1;
    62936316      conversion *t2;
    62946317
    6295       for (t1 = ics1; t1->kind != ck_user && t1->kind != ck_list; t1 = t1->u.next)
     6318      for (t1 = ics1; t1->kind != ck_user; t1 = t1->u.next)
    62966319        if (t1->kind == ck_ambig || t1->kind == ck_aggr)
    62976320          return 0;
    6298       for (t2 = ics2; t2->kind != ck_user && t2->kind != ck_list; t2 = t2->u.next)
     6321      for (t2 = ics2; t2->kind != ck_user; t2 = t2->u.next)
    62996322        if (t2->kind == ck_ambig || t2->kind == ck_aggr)
    63006323          return 0;
    63016324
    6302       /* Conversion to std::initializer_list is better than other
    6303          user-defined conversions.  */
    6304       if (t1->kind == ck_list
    6305           || t2->kind == ck_list)
    6306         {
    6307           if (t2->kind != ck_list)
    6308             return 1;
    6309           else if (t1->kind != ck_list)
    6310             return -1;
    6311           else
    6312             return 0;
    6313         }
    6314 
    63156325      if (t1->cand->fn != t2->cand->fn)
    63166326        return 0;
    63176327
     
    72887298  if (!conv || conv->bad_p)
    72897299    {
    72907300      if (!(TYPE_QUALS (TREE_TYPE (type)) & TYPE_QUAL_CONST)
     7301          && !TYPE_REF_IS_RVALUE (type)
    72917302          && !real_lvalue_p (expr))
    72927303        error ("invalid initialization of non-const reference of "
    72937304               "type %qT from a temporary of type %qT",
  • gcc/cp/decl.c

    diff -Naur gcc-4.4.1.orig/gcc/cp/decl.c gcc-4.4.1/gcc/cp/decl.c
    old new  
    43454345      return NULL_TREE;
    43464346    }
    43474347
    4348   if (TREE_CODE (init) == CONSTRUCTOR)
    4349     {
    4350       error ("ISO C++ forbids use of initializer list to "
    4351              "initialize reference %qD", decl);
    4352       return NULL_TREE;
    4353     }
    4354 
    43554348  if (TREE_CODE (init) == TREE_LIST)
    43564349    init = build_x_compound_expr_from_list (init, "initializer");
    43574350
     
    76187611  bool unsigned_p, signed_p, short_p, long_p, thread_p;
    76197612  bool type_was_error_mark_node = false;
    76207613  bool parameter_pack_p = declarator? declarator->parameter_pack_p : false;
    7621   bool set_no_warning = false;
    76227614  bool template_type_arg = false;
    76237615
    76247616  signed_p = declspecs->specs[(int)ds_signed];
     
    82978289                /* We now know that the TYPE_QUALS don't apply to the
    82988290                   decl, but to its return type.  */
    82998291                type_quals = TYPE_UNQUALIFIED;
    8300                 set_no_warning = true;
    83018292              }
    83028293
    83038294            /* Error about some types functions can't return.  */
     
    94999490    if (!processing_template_decl)
    95009491      cp_apply_type_quals_to_decl (type_quals, decl);
    95019492
    9502     if (set_no_warning)
    9503         TREE_NO_WARNING (decl) = 1;
    9504 
    95059493    return decl;
    95069494  }
    95079495}
  • gcc/cp/error.c

    diff -Naur gcc-4.4.1.orig/gcc/cp/error.c gcc-4.4.1/gcc/cp/error.c
    old new  
    21812181    return decl_as_string (decl, TFF_DECL_SPECIFIERS);
    21822182
    21832183  reinit_cxx_pp ();
    2184   if (v == 1 && DECL_CLASS_SCOPE_P (decl))
     2184  if (v == 1
     2185      && (DECL_CLASS_SCOPE_P (decl)
     2186          || (DECL_NAMESPACE_SCOPE_P (decl)
     2187              && CP_DECL_CONTEXT (decl) != global_namespace)))
    21852188    {
    21862189      dump_type (CP_DECL_CONTEXT (decl), TFF_PLAIN_IDENTIFIER);
    21872190      pp_cxx_colon_colon (cxx_pp);
  • gcc/cp/init.c

    diff -Naur gcc-4.4.1.orig/gcc/cp/init.c gcc-4.4.1/gcc/cp/init.c
    old new  
    26952695    gcc_assert (!init);
    26962696
    26972697  inner_elt_type = strip_array_types (type);
     2698
     2699  /* Look through the TARGET_EXPR around a compound literal.  */
     2700  if (init && TREE_CODE (init) == TARGET_EXPR
     2701      && TREE_CODE (TARGET_EXPR_INITIAL (init)) == CONSTRUCTOR
     2702      && from_array != 2)
     2703    init = TARGET_EXPR_INITIAL (init);
     2704
    26982705  if (init
    26992706      && TREE_CODE (atype) == ARRAY_TYPE
    27002707      && (from_array == 2
     
    27632770  base = get_temp_regvar (ptype, rval);
    27642771  iterator = get_temp_regvar (ptrdiff_type_node, maxindex);
    27652772
     2773  /* If initializing one array from another, initialize element by
     2774     element.  We rely upon the below calls to do the argument
     2775     checking.  Evaluate the initializer before entering the try block.  */
     2776  if (from_array && init && TREE_CODE (init) != CONSTRUCTOR)
     2777    {
     2778      base2 = decay_conversion (init);
     2779      itype = TREE_TYPE (base2);
     2780      base2 = get_temp_regvar (itype, base2);
     2781      itype = TREE_TYPE (itype);
     2782    }
     2783
    27662784  /* Protect the entire array initialization so that we can destroy
    27672785     the partially constructed array if an exception is thrown.
    27682786     But don't do this if we're assigning.  */
     
    28052823    }
    28062824  else if (from_array)
    28072825    {
    2808       /* If initializing one array from another, initialize element by
    2809          element.  We rely upon the below calls the do argument
    2810          checking.  */
    28112826      if (init)
    2812         {
    2813           base2 = decay_conversion (init);
    2814           itype = TREE_TYPE (base2);
    2815           base2 = get_temp_regvar (itype, base2);
    2816           itype = TREE_TYPE (itype);
    2817         }
     2827        /* OK, we set base2 above.  */;
    28182828      else if (TYPE_LANG_SPECIFIC (type)
    28192829               && TYPE_NEEDS_CONSTRUCTING (type)
    28202830               && ! TYPE_HAS_DEFAULT_CONSTRUCTOR (type))
  • gcc/cp/Make-lang.in

    diff -Naur gcc-4.4.1.orig/gcc/cp/Make-lang.in gcc-4.4.1/gcc/cp/Make-lang.in
    old new  
    7272# Shared with C front end:
    7373CXX_C_OBJS = attribs.o c-common.o c-format.o c-pragma.o c-semantics.o c-lex.o \
    7474        c-dump.o $(CXX_TARGET_OBJS) c-pretty-print.o c-opts.o c-pch.o \
    75         incpath.o cppdefault.o c-ppoutput.o c-cppbuiltin.o prefix.o \
    76         c-gimplify.o c-omp.o tree-inline.o
     75        incpath.o c-ppoutput.o c-cppbuiltin.o prefix.o \
     76        c-gimplify.o c-omp.o
    7777
    7878# Language-specific object files for C++ and Objective C++.
    7979CXX_AND_OBJCXX_OBJS = cp/call.o cp/decl.o cp/expr.o cp/pt.o cp/typeck2.o \
  • gcc/cp/parser.c

    diff -Naur gcc-4.4.1.orig/gcc/cp/parser.c gcc-4.4.1/gcc/cp/parser.c
    old new  
    1187111871  else
    1187211872    identifier = make_anon_name ();
    1187311873
    11874   /* Check for the `:' that denotes a specified underlying type in C++0x.  */
     11874  /* Check for the `:' that denotes a specified underlying type in C++0x.
     11875     Note that a ':' could also indicate a bitfield width, however.  */
    1187511876  if (cp_lexer_next_token_is (parser->lexer, CPP_COLON))
    1187611877    {
    1187711878      cp_decl_specifier_seq type_specifiers;
    1187811879
     11880      /* Consume the `:'.  */
     11881      cp_lexer_consume_token (parser->lexer);
     11882
     11883      /* Parse the type-specifier-seq.  */
     11884      cp_parser_type_specifier_seq (parser, /*is_condition=*/false,
     11885                                    &type_specifiers);
     11886
    1187911887      /* At this point this is surely not elaborated type specifier.  */
    1188011888      if (!cp_parser_parse_definitely (parser))
    1188111889        return NULL_TREE;
     
    1188311891      if (cxx_dialect == cxx98)
    1188411892        maybe_warn_cpp0x ("scoped enums");
    1188511893
    11886       /* Consume the `:'.  */
    11887       cp_lexer_consume_token (parser->lexer);
    11888 
    1188911894      has_underlying_type = true;
    1189011895
    11891       /* Parse the type-specifier-seq.  */
    11892       cp_parser_type_specifier_seq (parser, /*is_condition=*/false,
    11893                                     &type_specifiers);
    11894 
    1189511896      /* If that didn't work, stop.  */
    1189611897      if (type_specifiers.type != error_mark_node)
    1189711898        {
  • gcc/cp/pt.c

    diff -Naur gcc-4.4.1.orig/gcc/cp/pt.c gcc-4.4.1/gcc/cp/pt.c
    old new  
    80078007      cp_function_chain->x_current_class_ref = saved_class_ref;
    80088008    }
    80098009
    8010   pop_access_scope (fn);
    8011 
    80128010  /* Make sure the default argument is reasonable.  */
    80138011  arg = check_default_argument (type, arg);
    80148012
     8013  pop_access_scope (fn);
     8014
    80158015  return arg;
    80168016}
    80178017
  • gcc/cp/tree.c

    diff -Naur gcc-4.4.1.orig/gcc/cp/tree.c gcc-4.4.1/gcc/cp/tree.c
    old new  
    132132      return clk_ordinary;
    133133
    134134    case CONST_DECL:
     135      /* CONST_DECL without TREE_STATIC are enumeration values and
     136         thus not lvalues.  With TREE_STATIC they are used by ObjC++
     137         in objc_build_string_object and need to be considered as
     138         lvalues.  */
     139      if (! TREE_STATIC (ref))
     140        return clk_none;
    135141    case VAR_DECL:
    136142      if (TREE_READONLY (ref) && ! TREE_STATIC (ref)
    137143          && DECL_LANG_SPECIFIC (ref)
  • gcc/DATESTAMP

    diff -Naur gcc-4.4.1.orig/gcc/DATESTAMP gcc-4.4.1/gcc/DATESTAMP
    old new  
    1 20090722
     120090912
  • gcc/doc/install.texi

    diff -Naur gcc-4.4.1.orig/gcc/doc/install.texi gcc-4.4.1/gcc/doc/install.texi
    old new  
    24632463@samp{make pdf} in place of @samp{make dvi}, you can create documentation
    24642464in the form of @file{.pdf} files; this requires @command{texi2pdf}, which
    24652465is included with Texinfo version 4.8 and later.  You can also
    2466 @uref{http://www.gnu.org/order/order.html,,buy printed manuals from the
     2466@uref{http://shop.fsf.org/,,buy printed manuals from the
    24672467Free Software Foundation}, though such manuals may not be for the most
    24682468recent version of GCC@.
    24692469
  • gcc/doc/invoke.texi

    diff -Naur gcc-4.4.1.orig/gcc/doc/invoke.texi gcc-4.4.1/gcc/doc/invoke.texi
    old new  
    456456-mfix-cortex-m3-ldrd}
    457457
    458458@emph{AVR Options}
    459 @gccoptlist{-mmcu=@var{mcu}  -msize  -minit-stack=@var{n}  -mno-interrupts @gol
     459@gccoptlist{-mmcu=@var{mcu}  -msize  -mno-interrupts @gol
    460460-mcall-prologues  -mno-tablejump  -mtiny-stack  -mint8}
    461461
    462462@emph{Blackfin Options}
     
    65136513
    65146514@item -fstrict-aliasing
    65156515@opindex fstrict-aliasing
    6516 Allows the compiler to assume the strictest aliasing rules applicable to
     6516Allow the compiler to assume the strictest aliasing rules applicable to
    65176517the language being compiled.  For C (and C++), this activates
    65186518optimizations based on the type of expressions.  In particular, an
    65196519object of one type is assumed never to reside at the same address as an
     
    65306530@};
    65316531
    65326532int f() @{
    6533   a_union t;
     6533  union a_union t;
    65346534  t.d = 3.0;
    65356535  return t.i;
    65366536@}
     
    65436543implementation}.  However, this code might not:
    65446544@smallexample
    65456545int f() @{
    6546   a_union t;
     6546  union a_union t;
    65476547  int* ip;
    65486548  t.d = 3.0;
    65496549  ip = &t.i;
     
    92779277@opindex msize
    92789278Output instruction sizes to the asm file.
    92799279
    9280 @item -minit-stack=@var{N}
    9281 @opindex minit-stack
    9282 Specify the initial stack address, which may be a symbol or numeric value,
    9283 @samp{__stack} is the default.
    9284 
    92859280@item -mno-interrupts
    92869281@opindex mno-interrupts
    92879282Generated code is not compatible with hardware interrupts.
  • gcc/doc/service.texi

    diff -Naur gcc-4.4.1.orig/gcc/doc/service.texi gcc-4.4.1/gcc/doc/service.texi
    old new  
    2121@item
    2222Look in the service directory for someone who might help you for a fee.
    2323The service directory is found at
    24 @uref{http://www.gnu.org/prep/service.html}.
     24@uref{http://www.fsf.org/resources/service}.
    2525@end itemize
    2626
    2727For further information, see
  • gcc/dse.c

    diff -Naur gcc-4.4.1.orig/gcc/dse.c gcc-4.4.1/gcc/dse.c
    old new  
    10701070{
    10711071  rtx mem_address = XEXP (mem, 0);
    10721072  rtx expanded_address, address;
     1073  int expanded;
     1074
    10731075  /* Make sure that cselib is has initialized all of the operands of
    10741076     the address before asking it to do the subst.  */
    10751077
     
    11141116      fprintf (dump_file, "\n");
    11151117    }
    11161118
    1117   /* Use cselib to replace all of the reg references with the full
    1118      expression.  This will take care of the case where we have
     1119  /* First see if just canon_rtx (mem_address) is const or frame,
     1120     if not, try cselib_expand_value_rtx and call canon_rtx on that.  */
     1121  address = NULL_RTX;
     1122  for (expanded = 0; expanded < 2; expanded++)
     1123    {
     1124      if (expanded)
     1125        {
     1126          /* Use cselib to replace all of the reg references with the full
     1127             expression.  This will take care of the case where we have
    11191128
    1120      r_x = base + offset;
    1121      val = *r_x;
     1129             r_x = base + offset;
     1130             val = *r_x;
    11221131   
    1123      by making it into
    1124 
    1125      val = *(base + offset); 
    1126   */
    1127 
    1128   expanded_address = cselib_expand_value_rtx (mem_address, scratch, 5);
     1132             by making it into
    11291133
    1130   /* If this fails, just go with the mem_address.  */
    1131   if (!expanded_address)
    1132     expanded_address = mem_address;
     1134             val = *(base + offset);  */
    11331135
    1134   /* Split the address into canonical BASE + OFFSET terms.  */
    1135   address = canon_rtx (expanded_address);
     1136          expanded_address = cselib_expand_value_rtx (mem_address,
     1137                                                      scratch, 5);
    11361138
    1137   *offset = 0;
     1139          /* If this fails, just go with the address from first
     1140             iteration.  */
     1141          if (!expanded_address)
     1142            break;
     1143        }
     1144      else
     1145        expanded_address = mem_address;
    11381146
    1139   if (dump_file)
    1140     {
    1141       fprintf (dump_file, "\n   after cselib_expand address: ");
    1142       print_inline_rtx (dump_file, expanded_address, 0);
    1143       fprintf (dump_file, "\n");
     1147      /* Split the address into canonical BASE + OFFSET terms.  */
     1148      address = canon_rtx (expanded_address);
    11441149
    1145       fprintf (dump_file, "\n   after canon_rtx address: ");
    1146       print_inline_rtx (dump_file, address, 0);
    1147       fprintf (dump_file, "\n");
    1148     }
     1150      *offset = 0;
    11491151
    1150   if (GET_CODE (address) == CONST)
    1151     address = XEXP (address, 0);
     1152      if (dump_file)
     1153        {
     1154          if (expanded)
     1155            {
     1156              fprintf (dump_file, "\n   after cselib_expand address: ");
     1157              print_inline_rtx (dump_file, expanded_address, 0);
     1158              fprintf (dump_file, "\n");
     1159            }
    11521160
    1153   if (GET_CODE (address) == PLUS && GET_CODE (XEXP (address, 1)) == CONST_INT)
    1154     {
    1155       *offset = INTVAL (XEXP (address, 1));
    1156       address = XEXP (address, 0);
    1157     }
     1161          fprintf (dump_file, "\n   after canon_rtx address: ");
     1162          print_inline_rtx (dump_file, address, 0);
     1163          fprintf (dump_file, "\n");
     1164        }
    11581165
    1159   if (const_or_frame_p (address))
    1160     {
    1161       group_info_t group = get_group_info (address);
     1166      if (GET_CODE (address) == CONST)
     1167        address = XEXP (address, 0);
    11621168
    1163       if (dump_file)
    1164         fprintf (dump_file, "  gid=%d offset=%d \n", group->id, (int)*offset);
    1165       *base = NULL;
    1166       *group_id = group->id;
    1167     }
    1168   else
    1169     {
    1170       *base = cselib_lookup (address, Pmode, true);
    1171       *group_id = -1;
     1169      if (GET_CODE (address) == PLUS
     1170          && GET_CODE (XEXP (address, 1)) == CONST_INT)
     1171        {
     1172          *offset = INTVAL (XEXP (address, 1));
     1173          address = XEXP (address, 0);
     1174        }
    11721175
    1173       if (*base == NULL)
     1176      if (const_or_frame_p (address))
    11741177        {
     1178          group_info_t group = get_group_info (address);
     1179
    11751180          if (dump_file)
    1176             fprintf (dump_file, " no cselib val - should be a wild read.\n");
    1177           return false;
     1181            fprintf (dump_file, "  gid=%d offset=%d \n",
     1182                     group->id, (int)*offset);
     1183          *base = NULL;
     1184          *group_id = group->id;
     1185          return true;
    11781186        }
     1187    }
     1188
     1189  *base = cselib_lookup (address, Pmode, true);
     1190  *group_id = -1;
     1191
     1192  if (*base == NULL)
     1193    {
    11791194      if (dump_file)
    1180         fprintf (dump_file, "  varying cselib base=%d offset = %d\n",
    1181                  (*base)->value, (int)*offset);
     1195        fprintf (dump_file, " no cselib val - should be a wild read.\n");
     1196      return false;
    11821197    }
     1198  if (dump_file)
     1199    fprintf (dump_file, "  varying cselib base=%d offset = %d\n",
     1200             (*base)->value, (int)*offset);
    11831201  return true;
    11841202}
    11851203
  • gcc/dwarf2out.c

    diff -Naur gcc-4.4.1.orig/gcc/dwarf2out.c gcc-4.4.1/gcc/dwarf2out.c
    old new  
    1426014260static void
    1426114261gen_inlined_subroutine_die (tree stmt, dw_die_ref context_die, int depth)
    1426214262{
    14263   tree decl = block_ultimate_origin (stmt);
     14263  tree decl;
     14264
     14265  /* The instance of function that is effectively being inlined shall not
     14266     be abstract.  */
     14267  gcc_assert (! BLOCK_ABSTRACT (stmt));
     14268
     14269  decl = block_ultimate_origin (stmt);
    1426414270
    1426514271  /* Emit info for the abstract instance first, if we haven't yet.  We
    1426614272     must emit this even if the block is abstract, otherwise when we
     
    1428114287      decls_for_scope (stmt, subr_die, depth);
    1428214288      current_function_has_inlines = 1;
    1428314289    }
    14284   else
    14285     /* We may get here if we're the outer block of function A that was
    14286        inlined into function B that was inlined into function C.  When
    14287        generating debugging info for C, dwarf2out_abstract_function(B)
    14288        would mark all inlined blocks as abstract, including this one.
    14289        So, we wouldn't (and shouldn't) expect labels to be generated
    14290        for this one.  Instead, just emit debugging info for
    14291        declarations within the block.  This is particularly important
    14292        in the case of initializers of arguments passed from B to us:
    14293        if they're statement expressions containing declarations, we
    14294        wouldn't generate dies for their abstract variables, and then,
    14295        when generating dies for the real variables, we'd die (pun
    14296        intended :-)  */
    14297     gen_lexical_block_die (stmt, context_die, depth);
    1429814290}
    1429914291
    1430014292/* Generate a DIE for a field in a record, or structure.  */
     
    1492114913  if (must_output_die)
    1492214914    {
    1492314915      if (inlined_func)
    14924         gen_inlined_subroutine_die (stmt, context_die, depth);
     14916        {
     14917          /* If STMT block is abstract, that means we have been called
     14918             indirectly from dwarf2out_abstract_function.
     14919             That function rightfully marks the descendent blocks (of
     14920             the abstract function it is dealing with) as being abstract,
     14921             precisely to prevent us from emitting any
     14922             DW_TAG_inlined_subroutine DIE as a descendent
     14923             of an abstract function instance. So in that case, we should
     14924             not call gen_inlined_subroutine_die.
     14925
     14926             Later though, when cgraph asks dwarf2out to emit info
     14927             for the concrete instance of the function decl into which
     14928             the concrete instance of STMT got inlined, the later will lead
     14929             to the generation of a DW_TAG_inlined_subroutine DIE.  */
     14930          if (! BLOCK_ABSTRACT (stmt))
     14931            gen_inlined_subroutine_die (stmt, context_die, depth);
     14932        }
    1492514933      else
    1492614934        gen_lexical_block_die (stmt, context_die, depth);
    1492714935    }
  • gcc/expr.c

    diff -Naur gcc-4.4.1.orig/gcc/expr.c gcc-4.4.1/gcc/expr.c
    old new  
    78067806                          || mode1 == BLKmode
    78077807                          || bitpos + bitsize > GET_MODE_BITSIZE (mode2));
    78087808
     7809        /* Handle CONCAT first.  */
     7810        if (GET_CODE (op0) == CONCAT && !must_force_mem)
     7811          {
     7812            if (bitpos == 0
     7813                && bitsize == GET_MODE_BITSIZE (GET_MODE (op0)))
     7814              return op0;
     7815            if (bitpos == 0
     7816                && bitsize == GET_MODE_BITSIZE (GET_MODE (XEXP (op0, 0)))
     7817                && bitsize)
     7818              {
     7819                op0 = XEXP (op0, 0);
     7820                mode2 = GET_MODE (op0);
     7821              }
     7822            else if (bitpos == GET_MODE_BITSIZE (GET_MODE (XEXP (op0, 0)))
     7823                     && bitsize == GET_MODE_BITSIZE (GET_MODE (XEXP (op0, 1)))
     7824                     && bitpos
     7825                     && bitsize)
     7826              {
     7827                op0 = XEXP (op0, 1);
     7828                bitpos = 0;
     7829                mode2 = GET_MODE (op0);
     7830              }
     7831            else
     7832              /* Otherwise force into memory.  */
     7833              must_force_mem = 1;
     7834          }
     7835
    78097836        /* If this is a constant, put it in a register if it is a legitimate
    78107837           constant and we don't need a memory reference.  */
    78117838        if (CONSTANT_P (op0)
     
    78797906            MEM_VOLATILE_P (op0) = 1;
    78807907          }
    78817908
    7882         /* The following code doesn't handle CONCAT.
    7883            Assume only bitpos == 0 can be used for CONCAT, due to
    7884            one element arrays having the same mode as its element.  */
    7885         if (GET_CODE (op0) == CONCAT)
    7886           {
    7887             gcc_assert (bitpos == 0
    7888                         && bitsize == GET_MODE_BITSIZE (GET_MODE (op0)));
    7889             return op0;
    7890           }
    7891 
    78927909        /* In cases where an aligned union has an unaligned object
    78937910           as a field, we might be extracting a BLKmode value from
    78947911           an integer-mode (e.g., SImode) object.  Handle this case
  • gcc/fortran/check.c

    diff -Naur gcc-4.4.1.orig/gcc/fortran/check.c gcc-4.4.1/gcc/fortran/check.c
    old new  
    813813                     gfc_current_intrinsic, &y->where);
    814814          return FAILURE;
    815815        }
     816
     817      if (y->ts.type == BT_COMPLEX)
     818        {
     819          gfc_error ("'%s' argument of '%s' intrinsic at %L must have a type "
     820                     "of either REAL or INTEGER", gfc_current_intrinsic_arg[1],
     821                     gfc_current_intrinsic, &y->where);
     822          return FAILURE;
     823        }
     824
    816825    }
    817826
    818827  if (kind_check (kind, 2, BT_COMPLEX) == FAILURE)
     
    937946                     gfc_current_intrinsic, &y->where);
    938947          return FAILURE;
    939948        }
     949
     950      if (y->ts.type == BT_COMPLEX)
     951        {
     952          gfc_error ("'%s' argument of '%s' intrinsic at %L must have a type "
     953                     "of either REAL or INTEGER", gfc_current_intrinsic_arg[1],
     954                     gfc_current_intrinsic, &y->where);
     955          return FAILURE;
     956        }
    940957    }
    941958
    942959  return SUCCESS;
  • gcc/fortran/intrinsic.c

    diff -Naur gcc-4.4.1.orig/gcc/fortran/intrinsic.c gcc-4.4.1/gcc/fortran/intrinsic.c
    old new  
    836836  /* See if this intrinsic is allowed in the current standard.  */
    837837  if (gfc_check_intrinsic_standard (isym, &symstd, false, loc) == FAILURE)
    838838    {
    839       if (gfc_option.warn_intrinsics_std)
    840         gfc_warning_now ("The intrinsic '%s' at %L is not included in the"
    841                          " selected standard but %s and '%s' will be treated as"
    842                          " if declared EXTERNAL.  Use an appropriate -std=*"
    843                          " option or define -fall-intrinsics to allow this"
    844                          " intrinsic.", sym->name, &loc, symstd, sym->name);
    845       sym->attr.external = 1;
     839      if (sym->attr.proc == PROC_UNKNOWN)
     840        {
     841          if (gfc_option.warn_intrinsics_std)
     842            gfc_warning_now ("The intrinsic '%s' at %L is not included in the"
     843                             " selected standard but %s and '%s' will be"
     844                             " treated as if declared EXTERNAL.  Use an"
     845                             " appropriate -std=* option or define"
     846                             " -fall-intrinsics to allow this intrinsic.",
     847                             sym->name, &loc, symstd, sym->name);
     848          gfc_add_external (&sym->attr, &loc);
     849        }
    846850
    847851      return false;
    848852    }
  • gcc/fortran/iresolve.c

    diff -Naur gcc-4.4.1.orig/gcc/fortran/iresolve.c gcc-4.4.1/gcc/fortran/iresolve.c
    old new  
    23462346  /* TODO: Make this do something meaningful.  */
    23472347  static char transfer0[] = "__transfer0", transfer1[] = "__transfer1";
    23482348
    2349   if (mold->ts.type == BT_CHARACTER && !mold->ts.cl->length
    2350         && !(mold->expr_type == EXPR_VARIABLE && mold->symtree->n.sym->attr.dummy))
    2351     mold->ts.cl->length = gfc_int_expr (mold->value.character.length);
     2349  if (mold->ts.type == BT_CHARACTER
     2350        && !mold->ts.cl->length
     2351        && gfc_is_constant_expr (mold))
     2352    {
     2353      int len;
     2354      if (mold->expr_type == EXPR_CONSTANT)
     2355        mold->ts.cl->length = gfc_int_expr (mold->value.character.length);
     2356      else
     2357        {
     2358          len = mold->value.constructor->expr->value.character.length;
     2359          mold->ts.cl->length = gfc_int_expr (len);
     2360        }
     2361    }
    23522362
    23532363  f->ts = mold->ts;
    23542364
  • gcc/fortran/openmp.c

    diff -Naur gcc-4.4.1.orig/gcc/fortran/openmp.c gcc-4.4.1/gcc/fortran/openmp.c
    old new  
    396396              const char *p = gfc_extract_int (cexpr, &collapse);
    397397              if (p)
    398398                {
    399                   gfc_error (p);
     399                  gfc_error_now (p);
    400400                  collapse = 1;
    401401                }
    402402              else if (collapse <= 0)
    403403                {
    404                   gfc_error ("COLLAPSE clause argument not constant positive integer at %C");
     404                  gfc_error_now ("COLLAPSE clause argument not"
     405                                 " constant positive integer at %C");
    405406                  collapse = 1;
    406407                }
    407408              c->collapse = collapse;
  • gcc/fortran/primary.c

    diff -Naur gcc-4.4.1.orig/gcc/fortran/primary.c gcc-4.4.1/gcc/fortran/primary.c
    old new  
    17731773      if (m != MATCH_YES)
    17741774        return MATCH_ERROR;
    17751775
    1776       tbp = gfc_find_typebound_proc (sym, &t, name, false);
     1776      if (sym->f2k_derived)
     1777        tbp = gfc_find_typebound_proc (sym, &t, name, false);
     1778      else
     1779        tbp = NULL;
     1780
    17771781      if (tbp)
    17781782        {
    17791783          gfc_symbol* tbp_sym;
  • gcc/fortran/resolve.c

    diff -Naur gcc-4.4.1.orig/gcc/fortran/resolve.c gcc-4.4.1/gcc/fortran/resolve.c
    old new  
    94149414      if ((!a->save && !a->dummy && !a->pointer
    94159415           && !a->in_common && !a->use_assoc
    94169416           && !(a->function && sym != sym->result))
    9417           || (a->dummy && a->intent == INTENT_OUT))
     9417          || (a->dummy && a->intent == INTENT_OUT && !a->pointer))
    94189418        apply_default_init (sym);
    94199419    }
    94209420
  • gcc/fortran/trans-decl.c

    diff -Naur gcc-4.4.1.orig/gcc/fortran/trans-decl.c gcc-4.4.1/gcc/fortran/trans-decl.c
    old new  
    28262826  gfc_init_block (&fnblock);
    28272827  for (f = proc_sym->formal; f; f = f->next)
    28282828    if (f->sym && f->sym->attr.intent == INTENT_OUT
    2829           && f->sym->ts.type == BT_DERIVED)
     2829        && !f->sym->attr.pointer
     2830        && f->sym->ts.type == BT_DERIVED)
    28302831      {
    28312832        if (f->sym->ts.derived->attr.alloc_comp)
    28322833          {
     
    32533254              st = gfc_find_symtree (ns->sym_root,
    32543255                                     rent->local_name[0]
    32553256                                     ? rent->local_name : rent->use_name);
    3256               gcc_assert (st && st->n.sym->attr.use_assoc);
     3257              gcc_assert (st);
     3258
     3259              /* Fixing-up doubly contained symbols, sometimes results in
     3260                 ambiguity, which is caught here.  */
     3261              if (!st->n.sym->attr.use_assoc)
     3262                continue;
     3263
    32573264              if (st->n.sym->backend_decl
    32583265                  && DECL_P (st->n.sym->backend_decl)
    32593266                  && st->n.sym->module
     
    35733580         automatic lengths.  */
    35743581      if (sym->attr.dummy && !sym->attr.referenced
    35753582            && sym->ts.type == BT_DERIVED
     3583            && !sym->attr.pointer
    35763584            && sym->ts.derived->attr.alloc_comp
    35773585            && sym->attr.intent == INTENT_OUT)
    35783586        {
  • gcc/java/lang.c

    diff -Naur gcc-4.4.1.orig/gcc/java/lang.c gcc-4.4.1/gcc/java/lang.c
    old new  
    5353
    5454static int java_handle_option (size_t scode, const char *arg, int value);
    5555static void put_decl_string (const char *, int);
    56 static void put_decl_node (tree);
     56static void put_decl_node (tree, int);
    5757static void java_print_error_function (diagnostic_context *, const char *,
    5858                                       diagnostic_info *);
    5959static int merge_init_test_initialization (void * *, void *);
     
    355355  decl_bufpos += len;
    356356}
    357357
    358 /* Append to decl_buf a printable name for NODE. */
     358/* Append to decl_buf a printable name for NODE.
     359   Depending on VERBOSITY, more information about NODE
     360   is printed. Read the comments of decl_printable_name in
     361   langhooks.h for more.  */
    359362
    360363static void
    361 put_decl_node (tree node)
     364put_decl_node (tree node, int verbosity)
    362365{
    363366  int was_pointer = 0;
    364367  if (TREE_CODE (node) == POINTER_TYPE)
     
    370373    {
    371374      if (TREE_CODE (node) == FUNCTION_DECL)
    372375        {
     376          if (verbosity == 0 && DECL_NAME (node))
     377          /* We have been instructed to just print the bare name
     378             of the function.  */
     379            {
     380              put_decl_node (DECL_NAME (node), 0);
     381              return;
     382            }
     383
    373384          /* We want to print the type the DECL belongs to. We don't do
    374385             that when we handle constructors. */
    375386          if (! DECL_CONSTRUCTOR_P (node)
    376               && ! DECL_ARTIFICIAL (node) && DECL_CONTEXT (node))
     387              && ! DECL_ARTIFICIAL (node) && DECL_CONTEXT (node)
     388              /* We want to print qualified DECL names only
     389                 if verbosity is higher than 1.  */
     390              && verbosity >= 1)
    377391            {
    378               put_decl_node (TYPE_NAME (DECL_CONTEXT (node)));
     392              put_decl_node (TYPE_NAME (DECL_CONTEXT (node)),
     393                               verbosity);
    379394              put_decl_string (".", 1);
    380395            }
    381396          if (! DECL_CONSTRUCTOR_P (node))
    382             put_decl_node (DECL_NAME (node));
    383           if (TREE_TYPE (node) != NULL_TREE)
     397            put_decl_node (DECL_NAME (node), verbosity);
     398          if (TREE_TYPE (node) != NULL_TREE
     399              /* We want to print function parameters only if verbosity
     400                 is higher than 2.  */
     401              && verbosity >= 2)
    384402            {
    385403              int i = 0;
    386404              tree args = TYPE_ARG_TYPES (TREE_TYPE (node));
     
    391409                {
    392410                  if (i > 0)
    393411                    put_decl_string (",", 1);
    394                   put_decl_node (TREE_VALUE (args));
     412                  put_decl_node (TREE_VALUE (args), verbosity);
    395413                }
    396414              put_decl_string (")", 1);
    397415            }
    398416        }
    399417      else
    400         put_decl_node (DECL_NAME (node));
     418        put_decl_node (DECL_NAME (node), verbosity);
    401419    }
    402420  else if (TYPE_P (node) && TYPE_NAME (node) != NULL_TREE)
    403421    {
    404       if (TREE_CODE (node) == RECORD_TYPE && TYPE_ARRAY_P (node))
     422      if (TREE_CODE (node) == RECORD_TYPE && TYPE_ARRAY_P (node)
     423          /* Print detailed array information only if verbosity is higher
     424            than 2.  */
     425          && verbosity >= 2)
    405426        {
    406           put_decl_node (TYPE_ARRAY_ELEMENT (node));
     427          put_decl_node (TYPE_ARRAY_ELEMENT (node), verbosity);
    407428          put_decl_string("[]", 2);
    408429        }
    409430      else if (node == promoted_byte_type_node)
     
    417438      else if (node == void_type_node && was_pointer)
    418439        put_decl_string ("null", 4);
    419440      else
    420         put_decl_node (TYPE_NAME (node));
     441        put_decl_node (TYPE_NAME (node), verbosity);
    421442    }
    422443  else if (TREE_CODE (node) == IDENTIFIER_NODE)
    423444    put_decl_string (IDENTIFIER_POINTER (node), IDENTIFIER_LENGTH (node));
     
    434455lang_printable_name (tree decl, int v)
    435456{
    436457  decl_bufpos = 0;
    437   if (v == 0 && TREE_CODE (decl) == FUNCTION_DECL)
    438     put_decl_node (DECL_NAME (decl));
    439   else
    440     put_decl_node (decl);
     458  put_decl_node (decl, v);
    441459  put_decl_string ("", 1);
    442460  return decl_buf;
    443461}
  • gcc/longlong.h

    diff -Naur gcc-4.4.1.orig/gcc/longlong.h gcc-4.4.1/gcc/longlong.h
    old new  
    982982"       or r1,%0"                                                       \
    983983        : "=r" (q), "=&z" (r)                                           \
    984984        : "1" (n1), "r" (n0), "rm" (d), "r" (&__udiv_qrnnd_16)          \
    985         : "r1", "r2", "r4", "r5", "r6", "pr");                          \
     985        : "r1", "r2", "r4", "r5", "r6", "pr", "t");                     \
    986986  } while (0)
    987987
    988988#define UDIV_TIME 80
     
    990990#define sub_ddmmss(sh, sl, ah, al, bh, bl)                              \
    991991  __asm__ ("clrt;subc %5,%1; subc %4,%0"                                \
    992992           : "=r" (sh), "=r" (sl)                                       \
    993            : "0" (ah), "1" (al), "r" (bh), "r" (bl))
     993           : "0" (ah), "1" (al), "r" (bh), "r" (bl) : "t")
    994994
    995995#endif /* __sh__ */
    996996
  • gcc/Makefile.in

    diff -Naur gcc-4.4.1.orig/gcc/Makefile.in gcc-4.4.1/gcc/Makefile.in
    old new  
    39753975# These next rules exist because the output name is not the same as
    39763976# the input name, so our implicit %.pod rule will not work.
    39773977
    3978 gcc.pod: invoke.texi cppenv.texi cppopts.texi
     3978gcc.pod: invoke.texi cppenv.texi cppopts.texi gcc-vers.texi
    39793979        $(STAMP) $@
    39803980        -$(TEXI2POD) $< > $@
    39813981gfdl.pod: fdl.texi
  • gcc/resource.c

    diff -Naur gcc-4.4.1.orig/gcc/resource.c gcc-4.4.1/gcc/resource.c
    old new  
    945945
    946946  /* If we found a basic block, get the live registers from it and update
    947947     them with anything set or killed between its start and the insn before
    948      TARGET.  Otherwise, we must assume everything is live.  */
     948     TARGET; this custom life analysis is really about registers so we need
     949     to use the LR problem.  Otherwise, we must assume everything is live.  */
    949950  if (b != -1)
    950951    {
    951       regset regs_live = df_get_live_in (BASIC_BLOCK (b));
     952      regset regs_live = DF_LR_IN (BASIC_BLOCK (b));
    952953      rtx start_insn, stop_insn;
    953954
    954955      /* Compute hard regs live at start of block.  */
     
    10521053                {
    10531054                  HARD_REG_SET extra_live;
    10541055
    1055                   REG_SET_TO_HARD_REG_SET (extra_live, df_get_live_in (bb));
     1056                  REG_SET_TO_HARD_REG_SET (extra_live, DF_LR_IN (bb));
    10561057                  IOR_HARD_REG_SET (current_live_regs, extra_live);
    10571058                }
    10581059            }
  • gcc/simplify-rtx.c

    diff -Naur gcc-4.4.1.orig/gcc/simplify-rtx.c gcc-4.4.1/gcc/simplify-rtx.c
    old new  
    20092009      /* x*2 is x+x and x*(-1) is -x */
    20102010      if (GET_CODE (trueop1) == CONST_DOUBLE
    20112011          && SCALAR_FLOAT_MODE_P (GET_MODE (trueop1))
     2012          && !DECIMAL_FLOAT_MODE_P (GET_MODE (trueop1))
    20122013          && GET_MODE (op0) == mode)
    20132014        {
    20142015          REAL_VALUE_TYPE d;
     
    52435244      && GET_MODE_BITSIZE (innermode) >= (2 * GET_MODE_BITSIZE (outermode))
    52445245      && GET_CODE (XEXP (op, 1)) == CONST_INT
    52455246      && (INTVAL (XEXP (op, 1)) & (GET_MODE_BITSIZE (outermode) - 1)) == 0
     5247      && INTVAL (XEXP (op, 1)) >= 0
    52465248      && INTVAL (XEXP (op, 1)) < GET_MODE_BITSIZE (innermode)     
    52475249      && byte == subreg_lowpart_offset (outermode, innermode))
    52485250    {
  • gcc/testsuite/ada/acats/support/impdef.a

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/support/impdef.a gcc-4.4.1/gcc/testsuite/ada/acats/support/impdef.a
    old new  
    105105   Minimum_Task_Switch : constant Duration := 0.001;
    106106   --                                         ^^^ --- MODIFY HERE AS NEEDED
    107107
     108   Long_Minimum_Task_Switch : constant Duration := 0.1;
     109
    108110--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
    109111
    110112   -- This is the time required to activate another task and allow it
     
    117119   Switch_To_New_Task : constant Duration := 0.001;
    118120   --                                        ^^^ -- MODIFY HERE AS NEEDED
    119121
     122   Long_Switch_To_New_Task : constant Duration := 0.1;
     123
    120124--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
    121125
    122126   -- This is the time which will clear the queues of other tasks
    123127   -- waiting to run.  It is expected that this will be about five
    124128   -- times greater than Switch_To_New_Task.
    125129
    126    Clear_Ready_Queue : constant Duration := 1.1;
     130   Clear_Ready_Queue : constant Duration := 0.1;
    127131   --                                       ^^^ --- MODIFY HERE AS NEEDED
    128132
    129133--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
  • gcc/testsuite/ada/acats/tests/c9/c940005.a

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c940005.a gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c940005.a
    old new  
    8585      -- In reality one would expect a time of 5 to 10 seconds.  In
    8686      -- the interests of speeding up the test suite a shorter time
    8787      -- is used
    88       Pulse_Time_Delta : constant duration := ImpDef.Switch_To_New_Task;
     88      Pulse_Time_Delta : constant duration := ImpDef.Long_Switch_To_New_Task;
    8989
    9090      -- control over stopping tasks
    9191      protected Control is
  • gcc/testsuite/ada/acats/tests/c9/c940007.a

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c940007.a gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c940007.a
    old new  
    9090      -- In reality one would expect a time of 5 to 10 seconds.  In
    9191      -- the interests of speeding up the test suite a shorter time
    9292      -- is used
    93       Pulse_Time_Delta : constant duration := ImpDef.Switch_To_New_Task;
     93      Pulse_Time_Delta : constant duration := ImpDef.Long_Switch_To_New_Task;
    9494
    9595
    9696      -- control over stopping tasks
  • gcc/testsuite/ada/acats/tests/c9/c94001c.ada

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c94001c.ada gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c94001c.ada
    old new  
    209209
    210210     BEGIN -- (E)
    211211          WHILE NOT(OUT_TSK'TERMINATED) AND DELAY_COUNT < 60 LOOP
    212                DELAY 1.0 * Impdef.One_Second;
     212               DELAY 1.0 * Impdef.One_Long_Second;
    213213               DELAY_COUNT := DELAY_COUNT + 1;
    214214          END LOOP;
    215215          IF DELAY_COUNT = 60 THEN
     
    252252
    253253     BEGIN
    254254          WHILE NOT(OUT_TSK'TERMINATED) AND DELAY_COUNT < 60 LOOP
    255                DELAY 1.0 * Impdef.One_Second;
     255               DELAY 1.0 * Impdef.One_Long_Second;
    256256               DELAY_COUNT := DELAY_COUNT + 1;
    257257          END LOOP;
    258258          IF DELAY_COUNT = 60 THEN
  • gcc/testsuite/ada/acats/tests/c9/c94006a.ada

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c94006a.ada gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c94006a.ada
    old new  
    4242          SELECT
    4343               ACCEPT E;
    4444          OR
    45                DELAY 30.0 * Impdef.One_Second;
     45               DELAY 30.0 * Impdef.One_Long_Second;
    4646          END SELECT;
    4747     END TT;
    4848
  • gcc/testsuite/ada/acats/tests/c9/c94008c.ada

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c94008c.ada gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c94008c.ada
    old new  
    202202                    DELAY 10.0 * Impdef.One_Second;
    203203
    204204                    IF TERMINATE_COUNT.GET /= 1 THEN
    205                          DELAY 20.0 * Impdef.One_Second;
     205                         DELAY 20.0 * Impdef.One_Long_Second;
    206206                    END IF;
    207207
    208208                    IF TERMINATE_COUNT.GET /= 1 THEN
     
    243243          DELAY 10.0 * Impdef.One_Second; -- WAIT FOR T1, T2, AND T3 TO GET TO SELECT STMTS.
    244244
    245245           IF TERMINATE_COUNT.GET /= 3 THEN
    246                 DELAY 20.0 * Impdef.One_Second;
     246                DELAY 20.0 * Impdef.One_Long_Second;
    247247           END IF;
    248248
    249249           IF TERMINATE_COUNT.GET /= 3 THEN
  • gcc/testsuite/ada/acats/tests/c9/c951002.a

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c951002.a gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c951002.a
    old new  
    278278      -- Wait until the message is queued on the entry before starting
    279279      -- the Credit_Task
    280280      while not Hold.TC_Message_is_Queued loop
    281          delay ImpDef.Minimum_Task_Switch;   
     281         delay ImpDef.Long_Minimum_Task_Switch;   
    282282      end loop;
    283283      --
    284284      Credit_Task.TC_Start;
    285285
    286286      -- Ensure the first part of the test is complete before continuing
    287287      while not (Credit_Message'terminated and Credit_Task'terminated) loop
    288          delay ImpDef.Minimum_Task_Switch;   
     288         delay ImpDef.Long_Minimum_Task_Switch;   
    289289      end loop;
    290290
    291291      --======================================================
     
    298298      -- for it to reach the accept statement and call Hold.Set_DB_Overload
    299299      -- before starting Debit_Message
    300300      --
    301       delay ImpDef.Switch_To_New_Task;
     301      delay ImpDef.Long_Switch_To_New_Task;
    302302
    303303      Debit_Message.TC_Start;
    304304
    305305      while not Debit_Task'terminated loop
    306          delay ImpDef.Minimum_Task_Switch;   
     306         delay ImpDef.Long_Minimum_Task_Switch;   
    307307      end loop;   
    308308 
    309309      Hold.Clear_DB_Overload;  -- Allow completion
  • gcc/testsuite/ada/acats/tests/c9/c954a01.a

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c954a01.a gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c954a01.a
    old new  
    148148         end select;
    149149
    150150         -- Allow other tasks to get control
    151          delay ImpDef.Minimum_Task_Switch;
     151         delay ImpDef.Long_Minimum_Task_Switch;
    152152
    153153      end loop;
    154154
     
    175175
    176176procedure C954A01 is
    177177
    178    Long_Enough : constant Duration := ImpDef.Switch_To_New_Task;
     178   Long_Enough : constant Duration := ImpDef.Long_Switch_To_New_Task;
    179179
    180180               --==============================================--
    181181
  • gcc/testsuite/ada/acats/tests/c9/c96001a.ada

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c96001a.ada gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c96001a.ada
    old new  
    5151     ---------------------------------------------
    5252
    5353     DECLARE   -- (A)
    54           X : DURATION := 5.0;
     54          X : DURATION := 5.0 * Impdef.One_Second;
    5555          OLD_TIME : TIME;
    5656          LAPSE : DURATION;
    5757     BEGIN     -- (A)
  • gcc/testsuite/ada/acats/tests/c9/c97307a.ada

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c97307a.ada gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c97307a.ada
    old new  
    160160                         EXPIRED.READ (EXPIRED_CALLS);
    161161                    EXIT WHEN E'COUNT >= DESIRED_QUEUE_LENGTH -
    162162                                         EXPIRED_CALLS;
    163                          DELAY 2.0 * Impdef.One_Second;
     163                         DELAY 2.0 * Impdef.One_Long_Second;
    164164                    END LOOP;
    165165               EXIT WHEN DESIRED_QUEUE_LENGTH = 5;
    166166                    DISPATCH.READY;
     
    171171               -- LET THE TIMED ENTRY CALLS ISSUED BY CALLER1,
    172172               -- CALLER3, AND CALLER5 EXPIRE:
    173173
    174                DELAY DELAY_TIME + 10.0 * Impdef.One_Second;
     174               DELAY DELAY_TIME + 10.0 * Impdef.One_Long_Second;
    175175
    176176               -- AT THIS POINT, ALL THE TIMED ENTRY CALLS MUST HAVE
    177177               -- EXPIRED AND BEEN REMOVED FROM THE ENTRY QUEUE FOR E,
  • gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c
    old new  
    11/* { dg-skip-if "too complex for avr and picochip" { picochip-*-* avr-*-* } { "*" } { "" } } */
     2/* { dg-timeout-factor 4.0 } */
    23#define LIM1(x) x##0, x##1, x##2, x##3, x##4, x##5, x##6, x##7, x##8, x##9,
    34#define LIM2(x) LIM1(x##0) LIM1(x##1) LIM1(x##2) LIM1(x##3) LIM1(x##4) \
    45                LIM1(x##5) LIM1(x##6) LIM1(x##7) LIM1(x##8) LIM1(x##9)
  • gcc/testsuite/gcc.c-torture/compile/pr40321.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40321.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40321.c
    old new  
     1struct X { int flag; int pos; };
     2int foo(struct X *a, struct X *b)
     3{
     4  while (1)
     5    {
     6      if (a->flag)
     7        break;
     8      ({ struct X *tmp = a; a = b; b = tmp; });
     9    }
     10
     11  return a->pos + b->pos;
     12}
  • gcc/testsuite/gcc.c-torture/compile/pr40570.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40570.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40570.c
    old new  
     1extern void anything(int);
     2
     3static int foo(int i);
     4
     5static int bar(int i) { foo(i); }
     6
     7extern int j;
     8
     9static int foo(int i)
     10{
     11  if (j)
     12    anything(j);
     13  return bar(i);
     14}
     15
     16int baz()
     17{
     18  foo(0);
     19  if (baz())
     20    return 1;
     21  return 0;
     22}
  • gcc/testsuite/gcc.c-torture/compile/pr40676.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40676.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40676.c
    old new  
     1extern int f1();
     2extern int f2(void*);
     3extern void* f3(int);
     4int xmsih;
     5typedef unsigned short XWCHAR;
     6
     7inline unsigned int xstrlenW( const XWCHAR *str )
     8{
     9    const XWCHAR *s = str;
     10    while (*s) s++;
     11    return s - str;
     12}
     13
     14
     15static int msi_dialog_register_class( void )
     16{
     17    int cls;
     18
     19    if( !f2( &cls ) )
     20        return 0;
     21    if( !f2( &cls ) )
     22        return 0;
     23    xmsih = f1();
     24    if( !xmsih )
     25        return 0;
     26    return 1;
     27}
     28
     29void *xmsi_dialog_create(const XWCHAR* szDialogName)
     30{
     31    msi_dialog_register_class();
     32    return f3(xstrlenW(szDialogName));
     33}
  • gcc/testsuite/gcc.c-torture/compile/pr40692.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40692.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40692.c
    old new  
     1/* PR middle-end/40692 */
     2
     3#define M1(x) (((x) & 0x00000002) ? 0x2 : ((x) & 0x1))
     4#define M2(x) (((x) & 0x0000000c) ? M1 ((x) >> 2) << 2 : M1 (x))
     5#define M3(x) (((x) & 0x000000f0) ? M2 ((x) >> 4) << 4 : M2 (x))
     6#define M4(x) (((x) & 0x0000ff00) ? M3 ((x) >> 8) << 8 : M3 (x))
     7#define M5(x) (((x) & 0xffff0000) ? M4 ((x) >> 16) << 16 : M4 (x))
     8
     9struct A { char e; char f; };
     10
     11long
     12foo (void)
     13{
     14  return M5 (4096UL - (long) &((struct A *) 0)->f);
     15}
  • gcc/testsuite/gcc.c-torture/compile/pr40753.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40753.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40753.c
    old new  
     1typedef struct {
     2    unsigned nargs;
     3} ffi_cif;
     4typedef struct {
     5    char tramp[24];
     6    ffi_cif *cif;
     7} ffi_closure;
     8extern void *memcpy (void *, const void *, __SIZE_TYPE__);
     9extern void ffi_closure_LINUX64 (void);
     10
     11int
     12ffi_prep_closure_loc (ffi_closure *closure, ffi_cif *cif)
     13{
     14  void **tramp = (void **) &closure->tramp[0];
     15
     16  memcpy (tramp, (char *) ffi_closure_LINUX64, 16);
     17  closure->cif = cif;
     18
     19  return 0;
     20}
  • gcc/testsuite/gcc.c-torture/compile/pr40964.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40964.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40964.c
    old new  
     1struct alloc2 {
     2    int bla;
     3    char * __restrict data;
     4    char * __restrict data2;
     5};
     6struct alloc2 b;
     7void * f (void)
     8{
     9  return b.data;
     10}
  • gcc/testsuite/gcc.c-torture/compile/pr41006-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41006-1.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41006-1.c
    old new  
     1typedef int (*FARPROC)();
     2
     3typedef int (*LPFN_ACCEPTEX)(void*);
     4static LPFN_ACCEPTEX acceptex_fn;
     5
     6int xWSAIoctl(void*);
     7static void get_fn(FARPROC* fn)
     8{
     9    FARPROC func;
     10    if (!xWSAIoctl( &func))
     11        *fn = func;
     12}
     13
     14void get_fn_pointers()
     15{
     16    get_fn((FARPROC*)&acceptex_fn);
     17}
  • gcc/testsuite/gcc.c-torture/compile/pr41006-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41006-2.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41006-2.c
    old new  
     1typedef int *FARPROC;
     2static int * __restrict__ acceptex_fn;
     3
     4int xWSAIoctl(void*);
     5static void get_fn(FARPROC* fn)
     6{
     7  FARPROC func;
     8  if (!xWSAIoctl( &func))
     9    *fn = func;
     10}
     11
     12void get_fn_pointers()
     13{
     14  get_fn((FARPROC*)&acceptex_fn);
     15}
  • gcc/testsuite/gcc.c-torture/compile/pr41016.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41016.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41016.c
    old new  
     1typedef struct _IO_FILE FILE;
     2void
     3CompareRNAStructures (FILE * ofp, int start, int L, char *ss_true, char *ss)
     4{
     5  int i;
     6  float agree = 0.;
     7  float pairs = 0.;
     8  float pairs_true = 0.;
     9  for (i = 0; i < L; i++)
     10    {
     11      pairs_true += 1.;
     12      agree += 1.;
     13    }
     14  if (((int) pairs % 2 != 0) || ((int) pairs_true % 2 != 0)
     15      || ((int) agree % 2 != 0))
     16    Die ("Error in CompareRNAStrutures(); odd number of paired nucleotides\n");
     17}
  • gcc/testsuite/gcc.c-torture/compile/pr41163.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41163.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41163.c
    old new  
     1struct option {
     2    void *value;
     3};
     4void parse_options (struct option *);
     5void cmd_grep(void)
     6{
     7  struct option options[] = { { &options } };
     8  parse_options(options);
     9}
     10
  • gcc/testsuite/gcc.c-torture/compile/pr41181.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41181.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41181.c
    old new  
     1char paths[1024];
     2static void x264_slicetype_path(char (*best_paths)[250], int n, int length)
     3{
     4    __builtin_memcpy (best_paths[n], paths, length);
     5}
     6void x264_slicetype_analyse(int n, int length)
     7{
     8    char best_paths[250][250];
     9    x264_slicetype_path (best_paths, n, length);
     10}
  • gcc/testsuite/gcc.c-torture/compile/pr41282.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41282.c gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41282.c
    old new  
     1struct S
     2{
     3  unsigned int iu;
     4};
     5
     6union U
     7{
     8  struct S s;
     9  signed int is;
     10};
     11
     12extern signed int bar ();
     13
     14struct S foo (void)
     15{
     16  union U u;
     17
     18  u.is = bar ();
     19  return u.s;
     20}
  • gcc/testsuite/gcc.dg/20010912-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20010912-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20010912-1.c
    old new  
    11/* { dg-do run { target fpic } } */
    22/* { dg-options "-O2 -fpic" } */
    3 /* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
    43
    54extern void abort (void);
    65extern void exit (int);
  • gcc/testsuite/gcc.dg/20021018-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20021018-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20021018-1.c
    old new  
    11/* { dg-do run { target fpic } } */
    22/* { dg-options "-O2 -fpic" } */
    3 /* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
    43
    54extern void abort (void);
    65extern void exit (int);
  • gcc/testsuite/gcc.dg/20030213-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20030213-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20030213-1.c
    old new  
    11/* Testcase for http://gcc.gnu.org/ml/gcc-patches/2003-02/msg01017.html */
    22/* { dg-do link { target fpic } } */
    33/* { dg-options "-O -fpic" } */
    4 /* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
    54
    65int *g;
    76
  • gcc/testsuite/gcc.dg/20030225-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20030225-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20030225-1.c
    old new  
    55   and Benjamin Herrenschmidt <benh@kernel.crashing.org>.  */
    66/* { dg-do run { target fpic } } */
    77/* { dg-options "-O2 -fPIC" } */
    8 /* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
    98
    109extern void exit (int);
    1110
  • gcc/testsuite/gcc.dg/20030708-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20030708-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20030708-1.c
    old new  
    11/* PR c/11420 */
    22/* { dg-do link { target fpic } } */
    33/* { dg-options "-O2 -fpic" } */
    4 /* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
    54
    65void (* volatile fn) (void);
    76static void foo (void)
  • gcc/testsuite/gcc.dg/20050321-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20050321-2.c gcc-4.4.1/gcc/testsuite/gcc.dg/20050321-2.c
    old new  
    55   figure out branch to lab is too far.  */
    66/* { dg-do link { target fpic } } */
    77/* { dg-options "-g1 -fpic" } */
    8 /* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
    98/* { dg-require-effective-target int32plus } */
    109
    1110#define A(n) \
  • gcc/testsuite/gcc.dg/20090902-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20090902-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20090902-1.c
    old new  
     1/* { dg-do compile } */
     2#define STRING(x) #x
     3char buf[] = STRING(L'\x123');
  • gcc/testsuite/gcc.dg/bitfld-15.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-15.c gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-15.c
    old new  
    11/* { dg-do compile } */
    22/* Remove pedantic.  Allow the GCC extension to use char for bitfields.  */
    33/* { dg-options "" } */
     4/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
    45
    56struct t
    67{
  • gcc/testsuite/gcc.dg/bitfld-16.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-16.c gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-16.c
    old new  
    11/* { dg-do compile } */
    22/* { dg-options "-Wno-packed-bitfield-compat" } */
     3/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
    34
    45struct t
    56{
  • gcc/testsuite/gcc.dg/bitfld-17.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-17.c gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-17.c
    old new  
    11/* { dg-do compile } */
    22/* { dg-options "" } */
     3/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
    34
    45struct t
    56{
  • gcc/testsuite/gcc.dg/bitfld-18.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-18.c gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-18.c
    old new  
    11/* { dg-do compile } */
    22/* { dg-options "-Wno-packed-bitfield-compat" } */
     3/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
    34
    45struct t
    56{
  • gcc/testsuite/gcc.dg/builtins-10.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/builtins-10.c gcc-4.4.1/gcc/testsuite/gcc.dg/builtins-10.c
    old new  
    2525    link_error ();
    2626
    2727  if (pow(pow(x,4.0),0.25) != x)
    28     link_error ();
     28    /* XFAIL.  PR41098.  */;
    2929}
    3030
    3131void test2(double x, double y, double z)
     
    4242  if (pow(sqrt(x),y) != pow(x,y*0.5))
    4343    link_error ();
    4444
    45   if (pow(pow(x,y),z) != pow(x,y*z))
     45  if (pow(pow(fabs(x),y),z) != pow(fabs(x),y*z))
    4646    link_error ();
    4747}
    4848
  • gcc/testsuite/gcc.dg/builtins-config.h

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/builtins-config.h gcc-4.4.1/gcc/testsuite/gcc.dg/builtins-config.h
    old new  
    1 /* Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation.
     1/* Copyright (C) 2003, 2004, 2005, 2006, 2009 Free Software Foundation.
    22
    33   Define macros useful in tests for bulitin functions.  */
    44
     
    1515/* Irix6 doesn't have the entire C99 runtime.  */
    1616#elif defined(__AVR__)
    1717/* AVR doesn't have the entire C99 runtime.  */
    18 #elif defined(__FreeBSD__) && (__FreeBSD__ < 5)
    19 /* FreeBSD before version 5 doesn't have the entire C99 runtime. */
     18#elif defined(__FreeBSD__)
     19/* FreeBSD up to at least version 8 lacks support for cexp and friends. */
    2020#elif defined(__netware__)
    2121/* NetWare doesn't have the entire C99 runtime.  */
    2222#elif defined(__vxworks)
  • gcc/testsuite/gcc.dg/c90-const-expr-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/c90-const-expr-2.c gcc-4.4.1/gcc/testsuite/gcc.dg/c90-const-expr-2.c
    old new  
    1414int b;
    1515long *c;
    1616
    17 #if defined(_LP64) || defined(_WIN64)
     17#if defined(_LP64)
    1818#define ZERO 0L
     19#elif defined(_WIN64)
     20#define ZERO 0LL
    1921#else
    2022#define ZERO 0
    2123#endif
  • gcc/testsuite/gcc.dg/c99-const-expr-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/c99-const-expr-2.c gcc-4.4.1/gcc/testsuite/gcc.dg/c99-const-expr-2.c
    old new  
    1414int b;
    1515long *c;
    1616
    17 #if defined(_LP64) || defined(_WIN64)
     17#if defined(_LP64)
    1818#define ZERO 0L
     19#elif defined(_WIN64)
     20#define ZERO 0LL
    1921#else
    2022#define ZERO 0
    2123#endif
  • gcc/testsuite/gcc.dg/cdce1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/cdce1.c gcc-4.4.1/gcc/testsuite/gcc.dg/cdce1.c
    old new  
    11/* { dg-do  run  } */
    22/* { dg-skip-if "doubles are floats" { "avr-*-*" "m32c-*-*" } { "*" } { "" } } */
    33/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details  -lm" } */
    4 /* { dg-final { scan-tree-dump  "cdce1.c:16: note: function call is shrink-wrapped into error conditions\."  "cdce" } } */
     4/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details" { target *-*-netware* } } */
     5/* { dg-final { scan-tree-dump  "cdce1.c:17: note: function call is shrink-wrapped into error conditions\."  "cdce" } } */
    56/* { dg-final { cleanup-tree-dump "cdce" } } */
    67
    78#include <stdlib.h>
  • gcc/testsuite/gcc.dg/cdce2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/cdce2.c gcc-4.4.1/gcc/testsuite/gcc.dg/cdce2.c
    old new  
    11/* { dg-do  run  } */
    22/* { dg-skip-if "doubles are floats" { "avr-*-*" } { "*" } { "" } } */
    33/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details  -lm" } */
    4 /* { dg-final { scan-tree-dump  "cdce2.c:16: note: function call is shrink-wrapped into error conditions\." "cdce" } }*/
     4/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details" { target *-*-netware* } } */
     5/* { dg-final { scan-tree-dump  "cdce2.c:17: note: function call is shrink-wrapped into error conditions\." "cdce" } }*/
    56/* { dg-final { cleanup-tree-dump "cdce" } } */
    67 
    78#include <stdlib.h>
  • gcc/testsuite/gcc.dg/debug/20020224-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/debug/20020224-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/debug/20020224-1.c
    old new  
     1/* { dg-options "-g3 -O" } */
    12/* { dg-do compile } */
    23
    3 /* Here's the deal: f3 is not inlined because it's too big, but f2 and
    4    f1 are inlined into it.  We used to fail to emit debugging info for
    5    t1, because it was moved inside the (inlined) block of f1, marked
    6    as abstract, then we'd crash.  */
     4/* Here's the deal: f4 is inlined into main, f3 is inlined into f4, f2 is
     5   inlined into f1. The DIE of main should contain DW_TAG_inlined_subroutines
     6   children for f4, f3, f2 and f1. Also, there should be a DIE representing
     7   and out of line instance of f4, aside the DIE representing its abstract
     8   instance.
     9   We used to fail to emit debugging info for t1, because it was moved
     10   inside the (inlined) block of f1, marked as abstract, then we'd crash.  */
    711
    812#define UNUSED __attribute__((unused))
    913#define EXT __extension__
     
    5862
    5963  return;
    6064}
     65
     66int
     67main ()
     68{
     69    int foo = 1;
     70    f4 ();
     71}
  • gcc/testsuite/gcc.dg/debug/dwarf2/inline2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/debug/dwarf2/inline2.c gcc-4.4.1/gcc/testsuite/gcc.dg/debug/dwarf2/inline2.c
    old new  
     1/* Contributed by Dodji Seketeli <dodji@redhat.com>
     2   Origin: PR debug/37801
     3
     4  Abstract instances (DW_TAG_subroutines having the DW_AT_inline attribute)
     5  of second and first were having a DW_TAG_lexical_block DIE wrongly
     6  representing the inlined calls to third (in second) and to
     7  second (in first). At the same time, main didn't have children
     8  DW_TAG_inlined_subroutine DIEs representing the inlined calls to
     9  first, second and third.
     10
     11  The ideal goal here is to test that we have no superfluous
     12  DW_TAG_lexical_block DIE anymore, that abstract instances DIEs have
     13  no descendant DIE with a DW_AT_abstract_origin attribute, and that main has
     14  properly nested DW_TAG_inlined_subroutine DIEs for third, second and first.
     15*/
     16
     17/* { dg-options "-O -g3 -dA" } */
     18/* { dg-do compile } */
     19
     20/* There are 6 inlined subroutines:
     21   - One for each subroutine inlined into main, that's 3.
     22   - One for earch subroutine inline into the out of line instances
     23     of third, second and first.  */
     24/* { dg-final { scan-assembler-times "\\(DIE \\(.*?\\) DW_TAG_inlined_subroutine" 6 } } */
     25
     26/* Likewise we should have 6 DW_TAG_lexical_block DIEs:
     27   - One for each subroutine inlined into main, so that's 3.
     28   - One for each subroutine inlined in the out of line instances
     29     of third, second and first, that's 3.
     30*/
     31/* { dg-final { scan-assembler-times "\\(DIE \\(.*?\\) DW_TAG_lexical_block" 6 } } */
     32
     33
     34/* There are 3 DW_AT_inline attributes: one per abstract inline instance.
     35   The value of the attribute must be 0x3, meaning the function was
     36   actually inlined.  */
     37/* { dg-final { scan-assembler-times "byte.*?0x3.*? DW_AT_inline" 3 } } */
     38
     39
     40inline void
     41third (int arg3)
     42{
     43  int var3 = arg3;
     44  int* a = 0;
     45  a[0] = var3;
     46}
     47
     48inline void
     49second (int arg2)
     50{
     51  int var2 = arg2;
     52  third (var2+1);
     53}
     54
     55inline void
     56first (int arg1)
     57{
     58  int var1 = arg1;
     59  second (var1+1);
     60}
     61
     62int
     63main ()
     64{
     65  int some_int = 1;
     66  first (some_int);
     67  return 0;
     68}
     69
     70
  • gcc/testsuite/gcc.dg/dfp/pr39902.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/dfp/pr39902.c gcc-4.4.1/gcc/testsuite/gcc.dg/dfp/pr39902.c
    old new  
    189189  if (COMPARE128 (a128, p128_2_0))
    190190    FAILURE
    191191
    192   a128.d = p128_2_0.d * 1.0DD;
     192  a128.d = p128_2_0.d * 1.0DL;
    193193  if (COMPARE128 (a128, p128_2_0))
    194194    FAILURE
    195195
     
    197197  if (COMPARE128 (a128, m128_2_0))
    198198    FAILURE
    199199
    200   a128.d = p128_2_0.d * -1.0DD;
     200  a128.d = p128_2_0.d * -1.0DL;
    201201  if (COMPARE128 (a128, m128_2_0))
    202202    FAILURE
    203203
     
    208208  if (! (COMPARE128 (a128, p128_2_0)))
    209209    FAILURE
    210210
    211   a128.d = p128_2_0.d * 1.DD;
     211  a128.d = p128_2_0.d * 1.DL;
    212212  if (! (COMPARE128 (a128, p128_2_0)))
    213213    FAILURE
    214214
     
    216216  if (! (COMPARE128 (a128, m128_2_0)))
    217217    FAILURE
    218218
    219   a128.d = p128_2_0.d * -1.DD;
     219  a128.d = p128_2_0.d * -1.DL;
    220220  if (! (COMPARE128 (a128, m128_2_0)))
    221221    FAILURE
    222222}
  • gcc/testsuite/gcc.dg/large-size-array-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/large-size-array-2.c gcc-4.4.1/gcc/testsuite/gcc.dg/large-size-array-2.c
    old new  
    44static char * name[] = {
    55    [0x80000000]  = "bar"
    66  };
    7 /* { dg-error "too large" "" { target { { ! lp64 } || x86_64-*-mingw* } }  6 } */
     7/* { dg-error "too large" "" { target { { ! lp64 } && { ! llp64 } } }  6 } */
  • gcc/testsuite/gcc.dg/large-size-array-4.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/large-size-array-4.c gcc-4.4.1/gcc/testsuite/gcc.dg/large-size-array-4.c
    old new  
    44static char * name[] = {
    55    [0x80000000]  = "bar"
    66  };
    7 /* { dg-error "too large" "" { target { { ! lp64 } || x86_64-*-mingw* } }  6 } */
     7/* { dg-error "too large" "" { target { { ! lp64 } && { ! llp64 } } }  6 } */
  • gcc/testsuite/gcc.dg/pr40861.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr40861.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr40861.c
    old new  
     1/* { dg-do compile } */
     2/* { dg-options "-O" } */
     3
     4int foo(int i)
     5{
     6  return (1LL >> 128 * i) && i;
     7}
  • gcc/testsuite/gcc.dg/pr40971.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr40971.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr40971.c
    old new  
     1/* PR target/40971 */
     2/* { dg-do compile } */
     3/* { dg-options "-O -fstack-protector -fno-strict-aliasing" } */
     4/* { dg-require-effective-target fstack_protector } */
     5
     6extern void bar (char *);
     7
     8void
     9foo (int f, long a)
     10{
     11  {
     12    char d[32768];
     13    bar (d);
     14  }
     15  double b = f;
     16  while (a)
     17    {
     18      char c[sizeof (double)];
     19      __builtin_memcpy (c, &b, sizeof (c));
     20      if (*(double *) c != 2.0)
     21        break;
     22    }
     23}
  • gcc/testsuite/gcc.dg/pr41033.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr41033.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr41033.c
    old new  
     1/* { dg-options "-O1 -fno-strict-aliasing" } */
     2/* PR rtl-optimization/41033 */
     3
     4struct X {
     5  int i;
     6  int j;
     7};
     8
     9int foo(struct X *p, struct X *q)
     10{
     11  p->j = 1;
     12  q->i = 0;
     13  return p->j;
     14}
     15
     16extern void abort (void);
     17
     18int main()
     19{
     20  struct X x;
     21  if (foo (&x, (struct X *)&x.j) != 0)
     22    abort ();
     23  return 0;
     24}
  • gcc/testsuite/gcc.dg/pr41123.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr41123.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr41123.c
    old new  
     1/* PR middle-end/41123 */
     2/* { dg-do compile } */
     3/* { dg-options "-O2 -fno-strict-aliasing" } */
     4
     5struct S { char a, b, c, d, e, f, g, h; };
     6struct T { int a, b; };
     7
     8struct S
     9f1 (float _Complex x)
     10{
     11  return *(struct S *) & x;
     12}
     13
     14int
     15f2 (float _Complex x)
     16{
     17  struct S f = f1 (x);
     18  return f.b;
     19}
     20
     21struct T
     22f3 (float _Complex x)
     23{
     24  return *(struct T *) & x;
     25}
     26
     27int
     28f4 (float _Complex x)
     29{
     30  struct T f = f3 (x);
     31  return f.a;
     32}
     33
     34int
     35f5 (float _Complex x)
     36{
     37  struct T f = f3 (x);
     38  return f.b;
     39}
     40
     41struct T
     42f6 (float _Complex x)
     43{
     44  struct T f = f3 (x);
     45  return f;
     46}
  • gcc/testsuite/gcc.dg/pr41232.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr41232.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr41232.c
    old new  
     1/* { dg-do compile } */
     2/* { dg-options "-O1 -g" } */
     3extern int atoi (const char *);
     4extern int sprintf (char *, const char *, ...);
     5void malloc_init() {
     6  char *cptr;
     7  char buf[1];
     8  int tmbd = atoi(cptr);
     9  if (tmbd > 0)
     10    tmbd = (tmbd <= 124) ? tmbd : 124;
     11   else
     12    tmbd = 0;
     13   sprintf(buf, "%d\n", tmbd);
     14}
  • gcc/testsuite/gcc.dg/special/gcsec-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/special/gcsec-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/special/gcsec-1.c
    old new  
    33/* { dg-do run { xfail rs6000-*-aix* powerpc*-*-aix* } } */
    44/* { dg-require-gc-sections "" } */
    55
    6 /* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections -static" } */
    7 /* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections -static" { target native } } */
    8 /* Solaris 10 does not support static linking; there is no libc.a.  */
    9 /* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections" { target *-*-netware* i?86-*-solaris2.1[0-9] } } */
     6/* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections" } */
     7/* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections -static" { target static } } */
    108
    119#include <stdlib.h>
    1210
  • gcc/testsuite/gcc.dg/ssp-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/ssp-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/ssp-1.c
    old new  
    44
    55#include <stdlib.h>
    66
    7 static void
     7void
    88__stack_chk_fail (void)
    99{
    1010  exit (0); /* pass */
  • gcc/testsuite/gcc.dg/torture/builtin-power-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/builtin-power-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/torture/builtin-power-1.c
    old new  
    7777  /* Test pow(pow(x,y),z) -> pow(x,y*z).  */
    7878#define POW_POW \
    7979 extern void link_failure_pow_pow(void); \
    80  if (pow(pow(d1, d2), d3) != pow(d1,d2*d3) \
    81      || powf(powf(f1,f2),f3) != powf(f1,f2*f3) \
    82      || powl(powl(ld1,ld2),ld3) != powl(ld1,ld2*ld3)) \
     80 if (pow(pow(fabs(d1), d2), d3) != pow(fabs(d1),d2*d3) \
     81     || powf(powf(fabs(f1),f2),f3) != powf(fabs(f1),f2*f3) \
     82     || powl(powl(fabs(ld1),ld2),ld3) != powl(fabs(ld1),ld2*ld3)) \
    8383    link_failure_pow_pow()
    8484
    8585  POW_POW;
  • gcc/testsuite/gcc.dg/torture/pr39074.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/pr39074.c gcc-4.4.1/gcc/testsuite/gcc.dg/torture/pr39074.c
    old new  
    22/* { dg-options "-fdump-tree-alias" } */
    33/* { dg-skip-if "" { *-*-* } { "-O0" } { "" } } */
    44
     5typedef __PTRDIFF_TYPE__ intptr_t;
     6
    57int i;
    68void __attribute__((noinline))
    7 foo(long b, long q)
     9foo(long b, intptr_t q)
    810{
    911  int *y;
    1012  int **a = &y, **x;
  • gcc/testsuite/gcc.dg/torture/pr41094.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/pr41094.c gcc-4.4.1/gcc/testsuite/gcc.dg/torture/pr41094.c
    old new  
     1/* { dg-do run } */
     2/* { dg-options "-ffast-math" } */
     3
     4#include <math.h>
     5
     6extern void abort (void);
     7
     8double foo(void)
     9{
     10  double x = -4.0;
     11  return pow (x * x, 0.25);
     12}
     13
     14int main()
     15{
     16  if (foo() != 2.0)
     17    abort ();
     18  return 0;
     19}
  • gcc/testsuite/gcc.dg/torture/pr41261.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/pr41261.c gcc-4.4.1/gcc/testsuite/gcc.dg/torture/pr41261.c
    old new  
     1/* { dg-do compile } */
     2/* { dg-options "-fprofile-arcs" } */
     3
     4extern void relocate_kernel();
     5void machine_kexec(void *control_page)
     6{
     7  __builtin_memcpy(control_page, relocate_kernel, 2048);
     8}
  • gcc/testsuite/gcc.dg/tree-ssa/pr33920.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/tree-ssa/pr33920.c gcc-4.4.1/gcc/testsuite/gcc.dg/tree-ssa/pr33920.c
    old new  
    22/* { dg-do compile } */
    33/* { dg-options "-O3" } */
    44
     5typedef __PTRDIFF_TYPE__ intptr_t;
    56typedef union lispunion *object;
    67struct character
    78{
     
    2223  object V659;
    2324  object _x, _y;
    2425  object V643;
    25   long V648;
     26  intptr_t V648;
    2627  unsigned char V653;
    2728  object V651;
    2829  object V654;
    2930  object V658;
    3031
    3132T1240:
    32 if (V648 >= (long)V651) /* { dg-warning "cast from pointer to integer of different size" "" { target { ! int32plus } } } */
     33if (V648 >= (intptr_t)V651) /* { dg-warning "cast from pointer to integer of different size" "" { target { ! int32plus } } } */
    3334    goto T1243;
    3435  V653 = ((char *) V654->v.v_self)[V648];
    3536  V659 = (object) V654 + V653;
     
    4142    goto T1249;
    4243  goto T1224;
    4344T1249:
    44  V648 = (long) V648 + 1;
     45  V648 = (intptr_t) V648 + 1;
    4546  goto T1240;
    4647T1243:
    4748  V643 = (object) & Cnil_body;
  • gcc/testsuite/gcc.dg/tree-ssa/ssa-ccp-27.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/tree-ssa/ssa-ccp-27.c gcc-4.4.1/gcc/testsuite/gcc.dg/tree-ssa/ssa-ccp-27.c
    old new  
     1/* { dg-do compile } */
     2/* { dg-options "-O2 -fdump-tree-ccp1" } */
     3
     4#include <string.h>
     5
     6char c[10];
     7
     8void
     9f1 ()
     10{
     11  const char *p = "123456";
     12  memcpy (c, p, 6);
     13}
     14
     15void
     16f2 ()
     17{
     18  const char *p = "12345678";
     19  p += 2;
     20  memcpy (c, p, 6);
     21}
     22
     23/* { dg-final { scan-tree-dump-times "memcpy\[^\n\]*123456" 2 "ccp1" } } */
     24/* { dg-final { cleanup-tree-dump "ccp1" } } */
  • gcc/testsuite/gcc.dg/uninit-6.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/uninit-6.c gcc-4.4.1/gcc/testsuite/gcc.dg/uninit-6.c
    old new  
    3939    rv = malloc (sizeof (struct tree));
    4040    rv->car = 0;
    4141
    42     APPEND(rv, field, INTEGER_T, a);  /* { dg-bogus "field" "uninitialized variable warning" } */
     42    APPEND(rv, field, INTEGER_T, a);  /* { dg-bogus "field" "uninitialized variable warning" { xfail *-*-* } } */
    4343    APPEND(rv, field, PTR_T, b);
    4444    APPEND(rv, field, INTEGER_T, c);
    4545
  • gcc/testsuite/gcc.dg/uninit-6-O0.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/uninit-6-O0.c gcc-4.4.1/gcc/testsuite/gcc.dg/uninit-6-O0.c
    old new  
    3939    rv = malloc (sizeof (struct tree));
    4040    rv->car = 0;
    4141
    42     APPEND(rv, field, INTEGER_T, a);  /* { dg-bogus "field" "uninitialized variable warning" } */
     42    APPEND(rv, field, INTEGER_T, a);  /* { dg-bogus "field" "uninitialized variable warning" { xfail *-*-* } } */
    4343    APPEND(rv, field, PTR_T, b);
    4444    APPEND(rv, field, INTEGER_T, c);
    4545
  • gcc/testsuite/gcc.dg/uninit-pr40943.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/uninit-pr40943.c gcc-4.4.1/gcc/testsuite/gcc.dg/uninit-pr40943.c
    old new  
     1/* PR middle-end/40943 */
     2/* { dg-do compile } */
     3/* { dg-options "-O2 -Wuninitialized" } */
     4
     5void
     6foo (void)
     7{
     8  int *p;
     9  *p = 3;       /* { dg-warning "is used uninitialized" } */
     10}
  • gcc/testsuite/gcc.dg/vect/no-scevccp-noreassoc-outer-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/no-scevccp-noreassoc-outer-2.c gcc-4.4.1/gcc/testsuite/gcc.dg/vect/no-scevccp-noreassoc-outer-2.c
    old new  
    44#include "tree-vect.h"
    55
    66#define N 40
    7 int a[200*N];
     7int a[200*N+N];
    88
    99__attribute__ ((noinline)) void
    1010foo (){
  • gcc/testsuite/gcc.dg/vect/O1-pr33854.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/O1-pr33854.c gcc-4.4.1/gcc/testsuite/gcc.dg/vect/O1-pr33854.c
    old new  
    11/* Testcase by Martin Michlmayr <tbm@cyrius.com> */
    22/* { dg-do compile } */
    33
    4 extern void *malloc (long unsigned int __size);
     4extern void *malloc (__SIZE_TYPE__ __size);
    55typedef struct VMatrix_ VMatrix;
    66struct VMatrix_
    77{
  • gcc/testsuite/gcc.dg/vect/O1-pr41008.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/O1-pr41008.c gcc-4.4.1/gcc/testsuite/gcc.dg/vect/O1-pr41008.c
    old new  
     1/* { dg-do compile } */
     2
     3double heating[2][2];
     4
     5void foo (int, int);
     6
     7void map_do()
     8{
     9  int jsav, ksav, k, j;
     10
     11  for(k = 0; k < 2; k++)
     12    for(j = 0; j < 2; j++)
     13      if (heating[k][j] > 0.)
     14        {
     15          jsav = j;
     16          ksav = k;
     17        }
     18
     19  foo (jsav, ksav);
     20}
     21
     22/* { dg-final { cleanup-tree-dump "vect" } } */
     23
  • gcc/testsuite/gcc.dg/vect/pr33833.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/pr33833.c gcc-4.4.1/gcc/testsuite/gcc.dg/vect/pr33833.c
    old new  
    11/* Testcase by Martin Michlmayr <tbm@cyrius.com> */
    22/* { dg-do compile } */
    33
     4#define signed
     5typedef unsigned __PTRDIFF_TYPE__ uintptr_t;
     6#undef signed
     7
    48struct list_head
    59{
    610  struct list_head *prev;
     
    1418  struct prio_array *active, arrays[2];
    1519} per_cpu__runqueues;
    1620
    17 void sched_init (unsigned long __ptr)
     21void sched_init (uintptr_t __ptr)
    1822{
    1923  int j, k;
    2024  struct prio_array *array;
  • gcc/testsuite/gcc.dg/vect/pr33846.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/pr33846.c gcc-4.4.1/gcc/testsuite/gcc.dg/vect/pr33846.c
    old new  
    77  return ~i >> 31;
    88}
    99
    10 void _mix_some_samples (long buf, int *mix_buffer, int mix_size)
     10typedef __PTRDIFF_TYPE__ intptr_t;
     11
     12void _mix_some_samples (intptr_t buf, int *mix_buffer, int mix_size)
    1113{
    1214  int i;
    1315  signed int *p = mix_buffer;
  • gcc/testsuite/gcc.target/i386/avx-vtestpd-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-1.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-1.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestpd-256-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-1.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-1.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestpd-256-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-2.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-2.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestpd-256-3.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-3.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-3.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestpd-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-2.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-2.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestpd-3.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-3.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-3.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestps-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-1.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-1.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestps-256-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-256-1.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-256-1.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestps-256-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-256-2.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-256-2.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestps-256-3.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-256-3.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-256-3.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestps-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-2.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-2.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/avx-vtestps-3.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-3.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-3.c
    old new  
    11/* { dg-do run } */
    22/* { dg-require-effective-target avx } */
    3 /* { dg-options "-O2 -mavx" } */
     3/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
     4/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
     5/* { dg-message " from " "include chain" { target default_packed } 0 } */
    46
    57#include "avx-check.h"
    68
  • gcc/testsuite/gcc.target/i386/m128-check.h

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/m128-check.h gcc-4.4.1/gcc/testsuite/gcc.target/i386/m128-check.h
    old new  
    138138CHECK_FP_ARRAY (d, double, ESP_DOUBLE, "%f")
    139139CHECK_FP_ARRAY (f, float, ESP_FLOAT, "%f")
    140140
     141#ifdef NEED_IEEE754_FLOAT
    141142union ieee754_float
    142143{
    143144   float d;
     
    148149      unsigned sign : 1;
    149150   } bits __attribute__((packed));
    150151};
     152#endif
    151153
     154#ifdef NEED_IEEE754_DOUBLE
    152155union ieee754_double
    153156{
    154157   double d;
     
    160163      unsigned sign : 1;
    161164   } bits __attribute__((packed));
    162165};
     166#endif
  • gcc/testsuite/gcc.target/i386/pr37248-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr37248-2.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr37248-2.c
    old new  
    11/* PR middle-end/37248 */
    2 /* { dg-do compile } */
     2/* { dg-do compile { target { ! default_packed } } } */
    33/* { dg-options "-O2 -fdump-tree-optimized" } */
    44
    55struct S
  • gcc/testsuite/gcc.target/i386/pr37248-3.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr37248-3.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr37248-3.c
    old new  
    11/* PR middle-end/37248 */
    2 /* { dg-do compile } */
    3 /* { dg-options "-O2 -fdump-tree-optimized" } */
     2/* { dg-do compile { target { ! default_packed } } } */
     3/* { dg-options "-O2 -fdump-tree-optimized -mno-ms-bitfields" } */
    44
    55struct S
    66{
  • gcc/testsuite/gcc.target/i386/pr40718.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40718.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40718.c
    old new  
     1/* { dg-do run } */
     2/* { dg-require-effective-target ilp32 } */
     3/* { dg-options "-O1 -foptimize-sibling-calls" } */
     4
     5void abort (void);
     6
     7struct S
     8{
     9  void (__attribute__((__stdcall__)) *f) (struct S *);
     10  int i;
     11};
     12
     13void __attribute__((__stdcall__))
     14foo (struct S *s)
     15{
     16  s->i++;
     17}
     18
     19void __attribute__((__stdcall__))
     20bar (struct S *s)
     21{
     22  foo(s);
     23  s->f(s);
     24}
     25
     26int main (void)
     27{
     28  struct S s = { foo, 0 };
     29
     30  bar (&s);
     31  if (s.i != 2)
     32    abort ();
     33
     34  return 0;
     35}
     36
  • gcc/testsuite/gcc.target/i386/pr40906-1.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40906-1.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40906-1.c
    old new  
     1/* { dg-do run } */
     2/* { dg-require-effective-target ilp32 } */
     3/* { dg-options "-O2 -fomit-frame-pointer -mpush-args -mno-accumulate-outgoing-args" } */
     4
     5void abort (void);
     6
     7void __attribute__((noinline))
     8f (long double a)
     9{
     10  if (a != 1.23L)
     11    abort ();
     12}
     13
     14int __attribute__((noinline))
     15g (long double b)
     16{
     17  f (b);
     18  return 0;
     19}
     20
     21int
     22main (void)
     23{
     24  g (1.23L);
     25  return 0;
     26}
  • gcc/testsuite/gcc.target/i386/pr40906-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40906-2.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40906-2.c
    old new  
     1/* { dg-do run } */
     2/* { dg-require-effective-target ilp32 } */
     3/* { dg-options "-O2 -fomit-frame-pointer -mpush-args -mno-accumulate-outgoing-args -m128bit-long-double" } */
     4
     5void abort (void);
     6
     7void __attribute__((noinline))
     8f (long double a)
     9{
     10  if (a != 1.23L)
     11    abort ();
     12}
     13
     14int __attribute__((noinline))
     15g (long double b)
     16{
     17  f (b);
     18  return 0;
     19}
     20
     21int
     22main (void)
     23{
     24  g (1.23L);
     25  return 0;
     26}
  • gcc/testsuite/gcc.target/i386/pr40906-3.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40906-3.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40906-3.c
    old new  
     1/* { dg-do run { target *-*-linux* } } */
     2/* { dg-require-effective-target ilp32 } */
     3/* { dg-options "-O2 -fomit-frame-pointer -msse2 -mpush-args -mno-accumulate-outgoing-args" } */
     4
     5#include "sse2-check.h"
     6
     7void __attribute__((noinline))
     8f (__float128 a)
     9{
     10  if (a != 1.23Q)
     11    abort ();
     12}
     13
     14int __attribute__((noinline))
     15g (__float128 b)
     16{
     17  f (b);
     18  return 0;
     19}
     20
     21static void
     22sse2_test (void)
     23{
     24  g (1.23Q);
     25}
  • gcc/testsuite/gcc.target/i386/pr40934.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40934.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40934.c
    old new  
     1/* { dg-do compile } */
     2/* { dg-require-effective-target ilp32 } */
     3/* { dg-options "-O2 -march=i586 -ffast-math" } */
     4
     5extern double host_frametime;
     6extern float pitchvel;
     7V_DriftPitch (float delta, float move)
     8{
     9  if (!delta)
     10    move = host_frametime;
     11  if (delta > 0)
     12    ;
     13  else if (delta < 0 && move > -delta)
     14    pitchvel = 0;
     15}
  • gcc/testsuite/gcc.target/i386/pr40957.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40957.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40957.c
    old new  
     1/* { dg-do compile } */
     2/* { dg-require-effective-target avx } */
     3/* { dg-options "-O2 -mavx" } */
     4
     5typedef int __v8si __attribute__((__vector_size__(32)));
     6typedef long long __m256i __attribute__((__vector_size__(32), __may_alias__));
     7
     8static __m256i
     9_mm256_set1_epi32 (int __A)
     10{
     11  return __extension__ (__m256i)(__v8si){ __A, __A, __A, __A,
     12                                          __A, __A, __A, __A };
     13}
     14__m256i
     15foo ()
     16{
     17  return _mm256_set1_epi32 (-1);
     18}
  • gcc/testsuite/gcc.target/i386/pr41019.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr41019.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr41019.c
    old new  
     1/* { dg-do run } */
     2/* { dg-options "-O2 -msse2 -ftree-vectorize" } */
     3
     4#include "sse2-check.h"
     5
     6long long int a[64];
     7
     8void
     9sse2_test (void)
     10{
     11  int k;
     12
     13  for (k = 0; k < 64; k++)
     14    a[k] = a[k] != 5 ? 12 : 10;
     15
     16  for (k = 0; k < 64; k++)
     17    if (a[k] != 12)
     18      abort ();
     19}
  • gcc/testsuite/gcc.target/powerpc/pr39902-2.c

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/powerpc/pr39902-2.c gcc-4.4.1/gcc/testsuite/gcc.target/powerpc/pr39902-2.c
    old new  
     1/* Check that simplification "x*(-1)" -> "-x" is not performed for decimal
     2   float types.  */
     3
     4/* { dg-do compile { target { powerpc*-*-linux* && powerpc_fprs } } } */
     5/* { dg-options "-std=gnu99 -O -mcpu=power6" } */
     6/* { dg-final { scan-assembler-not "fneg" } } */
     7
     8extern _Decimal32 a32, b32;
     9extern _Decimal64 a64, b64;
     10extern _Decimal128 a128, b128;
     11
     12void
     13foo32 (void)
     14{
     15  b32 = a32 * -1.0DF;
     16}
     17
     18void
     19foo64 (void)
     20{
     21  b64 = a64 * -1.0DD;
     22}
     23
     24void
     25foo128 (void)
     26{
     27  b128 = a128 * -1.0DL;
     28}
  • gcc/testsuite/g++.dg/cdce3.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/cdce3.C gcc-4.4.1/gcc/testsuite/g++.dg/cdce3.C
    old new  
    22/* { dg-require-effective-target c99_runtime } */
    33/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details  -DGNU_EXTENSION -DLARGE_LONG_DOUBLE -lm" { target { pow10 && large_long_double } } } */
    44/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -DLARGE_LONG_DOUBLE -lm" { target { {! pow10 } && large_long_double } } } */
    5 /* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -DGNU_EXTENSION -lm" { target {pow10 && {! large_long_double } } } } */
     5/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -DGNU_EXTENSION -lm" { target { pow10 && {! large_long_double } } } } */
    66/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -lm" { target { {! pow10 } && {! large_long_double } } } } */
    7 /* { dg-final { scan-tree-dump  "cdce3.C:91: note: function call is shrink-wrapped into error conditions\." "cdce" { target { pow10 } } } } */
    8 /* { dg-final { scan-tree-dump  "cdce3.C:92: note: function call is shrink-wrapped into error conditions\." "cdce" { target { pow10 } } } } */
    9 /* { dg-final { scan-tree-dump  "cdce3.C:94: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
    10 /* { dg-final { scan-tree-dump  "cdce3.C:95: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
    11 /* { dg-final { scan-tree-dump  "cdce3.C:96: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
    12 /* { dg-final { scan-tree-dump  "cdce3.C:97: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
     7/* { dg-options "-mieee -O2 -fmath-errno -fdump-tree-cdce-details  -DGNU_EXTENSION -DLARGE_LONG_DOUBLE -lm" { target { alpha*-*-* && { pow10 && large_long_double } } } } */
     8/* { dg-options "-mieee -O2 -fmath-errno -fdump-tree-cdce-details -DLARGE_LONG_DOUBLE -lm" { target { alpha*-*-* && { {! pow10 } && large_long_double } } } } */
     9/* { dg-options "-mieee -O2 -fmath-errno -fdump-tree-cdce-details -DGNU_EXTENSION -lm" { target { alpha*-*-* && { pow10 && {! large_long_double } } } } } */
     10/* { dg-options "-mieee -O2 -fmath-errno -fdump-tree-cdce-details -lm" { target { alpha*-*-* && { {! pow10 } && {! large_long_double } } } } } */
     11/* { dg-final { scan-tree-dump  "cdce3.C:95: note: function call is shrink-wrapped into error conditions\." "cdce" { target { pow10 } } } } */
     12/* { dg-final { scan-tree-dump  "cdce3.C:96: note: function call is shrink-wrapped into error conditions\." "cdce" { target { pow10 } } } } */
    1313/* { dg-final { scan-tree-dump  "cdce3.C:98: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
    1414/* { dg-final { scan-tree-dump  "cdce3.C:99: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
    1515/* { dg-final { scan-tree-dump  "cdce3.C:100: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
     
    2020/* { dg-final { scan-tree-dump  "cdce3.C:105: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
    2121/* { dg-final { scan-tree-dump  "cdce3.C:106: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
    2222/* { dg-final { scan-tree-dump  "cdce3.C:107: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
     23/* { dg-final { scan-tree-dump  "cdce3.C:108: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
     24/* { dg-final { scan-tree-dump  "cdce3.C:109: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
     25/* { dg-final { scan-tree-dump  "cdce3.C:110: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
     26/* { dg-final { scan-tree-dump  "cdce3.C:111: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
    2327/* { dg-final { cleanup-tree-dump "cdce" } } */
    2428#include <stdlib.h>
    2529#include <math.h>
  • gcc/testsuite/g++.dg/cpp0x/enum1.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/cpp0x/enum1.C gcc-4.4.1/gcc/testsuite/g++.dg/cpp0x/enum1.C
    old new  
    22// { dg-do compile }
    33// { dg-options "-std=gnu++0x" }
    44
    5 enum : { };     // { dg-error "expected type-specifier" }
     5enum : { };     // { dg-error "expected" }
    66enum : 3 { };   // { dg-error "expected" }
  • gcc/testsuite/g++.dg/cpp0x/initlist22.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/cpp0x/initlist22.C gcc-4.4.1/gcc/testsuite/g++.dg/cpp0x/initlist22.C
    old new  
     1// Core issue 934
     2// { dg-options "-std=c++0x" }
     3
     4int i;
     5
     6int& r1{ i };                   // OK, direct binding
     7int&& r2{ i };                  // OK, direct binding
     8
     9int& r3{ };                     // { dg-error "" } reference to temporary
     10int&& r4{ };                    // OK, reference to temporary
     11
     12struct A { int i; } a;
     13
     14A& r5 { i };                    // { dg-error "" } reference to temporary
     15A&& r6 { i };                   // OK, aggregate initialization of temporary
     16A& r7 { a };                    // { dg-error "" } invalid aggregate initializer for A
     17A&& r8 { a };                   // { dg-error "" } invalid aggregate initializer for A
     18
     19struct B { B(int); int i; } b(0);
     20
     21B& r9 { i };                    // { dg-error "" } reference to temporary
     22B&& r10 { i };                  // OK, make temporary with B(int) constructor
     23B& r11 { b };                   // { dg-error "" } reference to temporary
     24B&& r12 { b };                  // OK, make temporary with copy constructor
  • gcc/testsuite/g++.dg/cpp0x/initlist23.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/cpp0x/initlist23.C gcc-4.4.1/gcc/testsuite/g++.dg/cpp0x/initlist23.C
    old new  
     1// { dg-options "-std=c++0x" }
     2
     3#include <initializer_list>
     4
     5struct A
     6{
     7  A& operator=(int i);
     8  A& operator=(std::initializer_list<int> l) { return *this; }
     9};
     10
     11int main()
     12{
     13  A a;
     14  a = { };
     15}
  • gcc/testsuite/g++.dg/debug/dwarf2/pubnames-1.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/debug/dwarf2/pubnames-1.C gcc-4.4.1/gcc/testsuite/g++.dg/debug/dwarf2/pubnames-1.C
    old new  
     1// Contributed by Dodji Seketeli <dodji@redhat.com>
     2// Origin PR debug/39706
     3// { dg-options "-g -dA" }
     4// { dg-do compile }
     5// { dg-final { scan-assembler-times ".debug_pubnames" 1 } }
     6// { dg-final { scan-assembler-times "\"main\".*external name" 1 } }
     7// { dg-final { scan-assembler-times "\"ns::ns_x.*external name" 1 } }
     8// { dg-final { scan-assembler-times "\"y::y_x.*external name" 1 } }
     9
     10namespace ns { int ns_x; }
     11class y { public: static int y_x; };
     12int y::y_x;
     13int main() { return ns::ns_x; }
     14
  • gcc/testsuite/g++.dg/debug/dwarf2/typedef1.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/debug/dwarf2/typedef1.C gcc-4.4.1/gcc/testsuite/g++.dg/debug/dwarf2/typedef1.C
    old new  
     1// Contributed by Dodji Seketeli <dodji@redhat.com>
     2// Origin: PR c++/40705
     3// { dg-options "-g -dA" }
     4// { dg-do compile }
     5// { dg-final { scan-assembler-times "DW_TAG_structure_type" 2 } }
     6// { dg-final { scan-assembler-times "DW_AT_name: \"foo<1u>\"" 1 } }
     7// { dg-final { scan-assembler-times "DW_TAG_enumeration_type" 2 } }
     8// { dg-final { scan-assembler-times "DW_AT_name: \"typedef foo<1u>::type type\"" 1 } }
     9// { dg-final { scan-assembler-times "DIE (.*) DW_TAG_enumeration_type" 2 } }
     10// { dg-final { scan-assembler-times "\"e0..\".*DW_AT_name" 1 } }
     11// { dg-final { scan-assembler-times "\"e1..\".*DW_AT_name" 1 } }
     12
     13template <unsigned int n>
     14struct foo
     15{
     16public:
     17    typedef
     18 unsigned char type;
     19};
     20
     21template<>
     22struct foo<1>
     23{
     24    typedef enum { e0, e1 } type;
     25};
     26
     27int
     28main()
     29{
     30    foo<1> f;
     31    foo<1>::type t = foo<1>::e1;
     32    return t;
     33}
  • gcc/testsuite/g++.dg/expr/stmt-expr-1.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/expr/stmt-expr-1.C gcc-4.4.1/gcc/testsuite/g++.dg/expr/stmt-expr-1.C
    old new  
     1// Contributed by Dodji Seketeli <dodji@redhat.com>
     2// Origin PR c++/40866
     3// { dg-options "-std=gnu++98" }
     4// { dg-do "compile" }
     5
     6template <typename T> class QForeachContainer {
     7public:
     8    QForeachContainer();
     9    int brk;
     10    typename T::const_iterator i;
     11};
     12
     13template <typename T> class QList {
     14public:
     15    class const_iterator {
     16    public:
     17        const_iterator(const const_iterator &o);
     18        const_iterator &operator++();
     19    };
     20};
     21
     22class QAction;
     23class QWidget {
     24public:
     25    QList<QAction*> actions() const;
     26};
     27class myDialog : public QWidget {
     28    myDialog();
     29};
     30
     31myDialog::myDialog()
     32{
     33    QForeachContainer<__typeof__(actions())> _container_;
     34    ({++_container_.brk; ++_container_.i;});
     35}
     36
  • gcc/testsuite/g++.dg/expr/unary3.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/expr/unary3.C gcc-4.4.1/gcc/testsuite/g++.dg/expr/unary3.C
    old new  
     1// PR c++/41131
     2// { dg-do compile }
     3
     4struct X { enum E { a = 100 }; };
     5
     6int
     7main ()
     8{
     9  X x;
     10  (void) &x.a;    // { dg-error "lvalue required" }
     11}
  • gcc/testsuite/g++.dg/ext/bitfield2.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield2.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield2.C
    old new  
    11/* { dg-do compile } */
    22/* Remove pedantic.  Allow the GCC extension to use char for bitfields.  */
    33/* { dg-options "" } */
     4/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
    45
    56struct t
    67{ /* { dg-message "note: Offset of packed bit-field 't::b' has changed in GCC 4.4" "" { target pcc_bitfield_type_matters } } */
  • gcc/testsuite/g++.dg/ext/bitfield3.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield3.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield3.C
    old new  
    11/* { dg-do compile } */
    22/* { dg-options "-Wno-packed-bitfield-compat" } */
     3/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
    34
    45struct t
    56{
  • gcc/testsuite/g++.dg/ext/bitfield4.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield4.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield4.C
    old new  
    11/* { dg-do compile } */
    22/* { dg-options "" } */
     3/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
    34
    45struct t
    56{ /* { dg-message "note: Offset of packed bit-field 't::b' has changed in GCC 4.4" "" { target pcc_bitfield_type_matters } } */
  • gcc/testsuite/g++.dg/ext/bitfield5.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield5.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield5.C
    old new  
    11/* { dg-do compile } */
    22/* { dg-options "-Wno-packed-bitfield-compat" } */
     3/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
    34
    45struct t
    56{
  • gcc/testsuite/g++.dg/ext/complit12.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/complit12.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/complit12.C
    old new  
     1// PR c++/40948
     2// { dg-do run }
     3// { dg-options "" }
     4
     5int c;
     6struct M
     7{
     8  M () { ++c; }
     9  M (const M&) { ++c; }
     10  ~M () { --c; }
     11};
     12
     13struct S
     14{
     15  S ();
     16  M m[1];
     17};
     18
     19S::S () : m ((M[1]) { M () })
     20{
     21}
     22
     23struct T
     24{
     25  T ();
     26  M m[4];
     27};
     28
     29T::T () : m ((M[4]) { M (), M (), M (), M () })
     30{
     31}
     32
     33typedef M MA[1];
     34MA &bar (MA, MA& r) { return r; }
     35
     36M f(M m) { return m; }
     37
     38int main ()
     39{
     40  {
     41    M m[1] = (M[1]) { M () };
     42    if (c != 1)
     43      return 1;
     44    M n = (M) { M () };
     45    if (c != 2)
     46      return 2;
     47    M o[4] = (M[4]) { M (), M (), M (), M () };
     48    if (c != 6)
     49      return 3;
     50    S s;
     51    if (c != 7)
     52      return 4;
     53    T t;
     54    if (c != 11)
     55      return 5;
     56    MA ma = bar ((M[2]) { M(), M() }, m);
     57    if (c != 12)
     58      return 7;
     59    M mm[2] = ((M[2]) { f(M()), f(M()) });
     60    if (c != 14)
     61      return 8;
     62  }
     63  if (c != 0)
     64    return 6;
     65}
  • gcc/testsuite/g++.dg/lookup/using21.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/lookup/using21.C gcc-4.4.1/gcc/testsuite/g++.dg/lookup/using21.C
    old new  
     1// PR c++/40799
     2
     3namespace Bar {
     4  typedef int A;
     5}
     6class CollectionDeleteGuard {
     7public:
     8  CollectionDeleteGuard(int);
     9};
     10CollectionDeleteGuard::CollectionDeleteGuard(int)
     11{
     12  using Bar::A;
     13}
  • gcc/testsuite/g++.dg/opt/pr40496.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/opt/pr40496.C gcc-4.4.1/gcc/testsuite/g++.dg/opt/pr40496.C
    old new  
     1// { dg-do compile }
     2// { dg-options "-O2 -fprefetch-loop-arrays -msse2" { target i?86-*-* x86_64-*-* } }
     3
     4struct DOMStringHandle
     5{
     6  unsigned int fLength;
     7  int fRefCount;
     8};
     9static void *freeListPtr;
     10void foo(DOMStringHandle *dsg)
     11{
     12  int i;
     13  for (i = 1; i < 1023; i++)
     14    {
     15      *(void **) &dsg[i] = freeListPtr;
     16      freeListPtr = &dsg[i];
     17    }
     18}
  • gcc/testsuite/g++.dg/other/gc4.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/other/gc4.C gcc-4.4.1/gcc/testsuite/g++.dg/other/gc4.C
    old new  
     1// PR c++/41120
     2// { dg-options "--param ggc-min-heapsize=0 --param ggc-min-expand=0" }
     3
     4struct A
     5{
     6  A();
     7};
     8
     9struct B
     10{
     11  A a;
     12};
     13
     14B b;
  • gcc/testsuite/g++.dg/other/typedef3.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/other/typedef3.C gcc-4.4.1/gcc/testsuite/g++.dg/other/typedef3.C
    old new  
     1// Contributed by Dodji Seketeli <dodji@redhat.com>
     2// Origin: PR c++/40357
     3// { dg-do compile }
     4
     5struct XalanCProcessor
     6{
     7      typedef enum {eInvalid, eXalanSourceTree, eXercesDOM} ParseOptionType;
     8          ParseOptionType getParseOption(void);
     9};
     10typedef XalanCProcessor::ParseOptionType ParseOptionType;
     11ParseOptionType XalanCProcessor::getParseOption(void) {}
     12
  • gcc/testsuite/g++.dg/overload/defarg4.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/overload/defarg4.C gcc-4.4.1/gcc/testsuite/g++.dg/overload/defarg4.C
    old new  
     1// Contributed by Dodji Seketeli <dodji@redhat.com>
     2// Origin PR c++/39987
     3// { dg-do "compile" }
     4
     5class foo
     6{
     7 template<typename U>
     8 static bool func(const U& x)
     9 {}
     10public:
     11 template<typename U>
     12 unsigned int Find(const U& x, bool (*pFunc) (const U&) = func) const
     13 {}
     14};
     15
     16class bar {
     17 bool Initialize();
     18protected:
     19 foo b;
     20};
     21
     22bool bar::Initialize()
     23{
     24        b.Find(b);
     25}
     26
  • gcc/testsuite/g++.dg/parse/enum5.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/parse/enum5.C gcc-4.4.1/gcc/testsuite/g++.dg/parse/enum5.C
    old new  
     1// PR c++/41127
     2
     3#define CHAR_BIT 8
     4enum EE {ee};
     5typedef unsigned int T;
     6
     7struct D {
     8        T : sizeof(unsigned int) * CHAR_BIT; // OK
     9        EE : sizeof(EE) * CHAR_BIT; // OK
     10        enum EE : sizeof(EE) * CHAR_BIT; // not OK
     11        enum EE xxxx : sizeof(EE) * CHAR_BIT; // OK
     12        T x : sizeof(unsigned int) * CHAR_BIT; // OK
     13        enum FF {ff} : sizeof(int) * CHAR_BIT; // OK
     14} element;
     15
     16enum EE xx;
     17EE yy;
  • gcc/testsuite/g++.dg/torture/pr40321.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40321.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40321.C
    old new  
     1/* { dg-do compile } */
     2
     3struct VectorD2
     4{
     5  VectorD2() : x(0), y(0) { }
     6  VectorD2(int _x, int _y) : x(_x), y(_y) { }
     7  int x, y;
     8  int GetLength2() const { return x*x + y*y; };
     9  VectorD2 operator+(const VectorD2 vec) const {
     10      return VectorD2(x+vec.x,y+vec.y);
     11  }
     12};
     13struct Shape
     14{
     15  enum Type { ST_RECT, ST_CIRCLE } type;
     16  VectorD2 pos;
     17  VectorD2 radius;
     18  bool CollisionWith(const Shape& s) const;
     19};
     20bool Shape::CollisionWith(const Shape& s) const
     21{
     22  if(type == ST_CIRCLE && s.type == ST_RECT)
     23    return s.CollisionWith(*this);
     24  return (pos + s.pos).GetLength2() < (radius + s.radius).GetLength2();
     25}
  • gcc/testsuite/g++.dg/torture/pr40834.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40834.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40834.C
    old new  
     1/* { dg-do run } */
     2
     3extern "C" void abort (void);
     4class XalanDOMString
     5{
     6public:
     7  int y;
     8};
     9
     10class XObject
     11{
     12public:
     13  const XalanDOMString& str() const { return x; }
     14  XalanDOMString x;
     15};
     16
     17class XObjectPtr
     18{
     19public:
     20  XObjectPtr(const XObjectPtr& theSource)
     21    {
     22      m_xobjectPtr = theSource.m_xobjectPtr;
     23    }
     24  const XObject* operator->() const
     25    {
     26      return m_xobjectPtr;
     27    };
     28  XObjectPtr(XObject *p) { m_xobjectPtr = p; }
     29  XObject* m_xobjectPtr;
     30};
     31
     32class FunctionSubstringBefore
     33{
     34public:
     35  int execute( const XObjectPtr arg1) const
     36    {
     37      const XalanDOMString& theFirstString = arg1->str();
     38      return theFirstString.y;
     39    }
     40};
     41
     42int
     43main ()
     44{
     45  XObject x;
     46  XObjectPtr y (&x);
     47  x.x.y = -1;
     48  FunctionSubstringBefore z;
     49  if (z.execute (y) != -1)
     50    abort ();
     51  return 0;
     52}
  • gcc/testsuite/g++.dg/torture/pr40924.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40924.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40924.C
    old new  
     1// PR rtl-optimization/40924
     2// { dg-do run }
     3
     4extern "C" void abort (void);
     5
     6#define MAY_ALIAS __attribute__((__may_alias__))
     7
     8typedef struct { float v[2]; } floata;
     9typedef struct { int v[2]; } inta;
     10
     11typedef unsigned int uint MAY_ALIAS;
     12typedef signed int sint MAY_ALIAS;
     13typedef float flt MAY_ALIAS;
     14
     15static inline unsigned short
     16less_than (inta a, inta b)
     17{
     18  unsigned short r = 0;
     19  const uint *p1 = (const uint *) &a;
     20  const uint *p2 = (const uint *) &b;
     21  for (int i=0; i < 2; i++)
     22    if (p1[i] < p2[i]) r |= (1 << i);
     23  return r;
     24}
     25
     26static inline inta
     27multiply (inta b, inta c)
     28{
     29  inta r;
     30  sint *p3 = (sint *) &c;
     31  for (int i=0; i < 2; i++)
     32    r.v[i] = (int) (b.v[i] * p3[i] & 0xFFFFFFFF);
     33  return r;
     34}
     35
     36static inline floata
     37gather (inta indexes, const void *baseAddr)
     38{
     39  floata r;
     40
     41  sint *idx = (sint *) &indexes;
     42  flt *src = (flt *) baseAddr;
     43  for (int i=0; i < 2; i++)
     44    r.v[i] = *(src + idx[i]);
     45  return r;
     46}
     47
     48static inline inta
     49add (const inta &b, const inta &c)
     50{
     51  inta result;
     52  sint *r = (sint *) &result;
     53
     54  for (int i=0; i < 2; i++)
     55    r[i] = b.v[i] + c.v[i];
     56  return result;
     57}
     58
     59struct uintv
     60{
     61  inta data;
     62  inline uintv () { data.v[0] = 0; data.v[1] = 1; }
     63  inline uintv (unsigned int a)
     64  {
     65    for (int i=0; i < 2; i++)
     66      *(uint *) &data.v[i] = a;
     67  }
     68  inline uintv (inta x) : data (x) {}
     69  inline uintv operator* (const uintv &x) const
     70  { return multiply (data, x.data); }
     71  inline uintv operator+ (const uintv &x) const
     72  { return uintv (add (data, x.data)); }
     73  inline unsigned short operator< (const uintv &x) const
     74  { return less_than (data, x.data); }
     75};
     76
     77struct floatv
     78{
     79  floata data;
     80  explicit inline floatv (const uintv &x)
     81  {
     82    uint *p2 = (uint *) &x.data;
     83    for (int i=0; i < 2; i++)
     84      data.v[i] = p2[i];
     85  }
     86  inline floatv (const float *array, const uintv &indexes)
     87  {
     88    const uintv &offsets = indexes * uintv (1);
     89    data = gather (offsets.data, array);
     90  }
     91  unsigned short operator== (const floatv &x) const
     92  {
     93    unsigned short r = 0;
     94    for (int i=0; i < 2; i++)
     95      if (data.v[i] == x.data.v[i]) r |= (1 << i);
     96    return r;
     97  }
     98};
     99
     100int
     101main ()
     102{
     103  const float array[2] = { 2, 3 };
     104  for (uintv i; (i < 2) == 3; i = i + 2)
     105    {
     106      const floatv ii (i + 2);
     107      floatv a (array, i);
     108      if ((a == ii) != 3)
     109        abort ();
     110    }
     111}
  • gcc/testsuite/g++.dg/torture/pr40991.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40991.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40991.C
    old new  
     1/* { dg-options "-std=gnu++0x" } */
     2
     3typedef __SIZE_TYPE__ size_t;
     4namespace std __attribute__ ((__visibility__ ("default"))) {
     5    using ::size_t;
     6    void __throw_bad_function_call() __attribute__((__noreturn__));
     7}
     8inline void* operator new(std::size_t, void* __p) throw() {
     9    return __p;
     10}
     11namespace std {
     12    class type_info {
     13    public:
     14        bool operator==(const type_info& __arg) const { }
     15    };
     16    namespace tr1 {
     17        template<typename _Tp, _Tp __v> struct integral_constant { };
     18        typedef integral_constant<bool, true> true_type;
     19        template<typename _Res, typename... _ArgTypes>
     20        struct _Maybe_unary_or_binary_function { };
     21        class _Undefined_class;
     22        union _Nocopy_types {
     23            void (_Undefined_class::*_M_member_pointer)();
     24        };
     25        union _Any_data {
     26            void* _M_access() {
     27                return &_M_pod_data[0];
     28            }
     29            char _M_pod_data[sizeof(_Nocopy_types)];
     30        };
     31        enum _Manager_operation { __get_type_info, __get_functor_ptr, __clone_functor, __destroy_functor };
     32        template<typename _Tp> struct _Simple_type_wrapper {
     33            _Simple_type_wrapper(_Tp __value) : __value(__value) { }
     34            _Tp __value;
     35        };
     36        template<typename _Signature> class function;
     37        class _Function_base {
     38        public:
     39            static const std::size_t _M_max_size = sizeof(_Nocopy_types);
     40            static const std::size_t _M_max_align = __alignof__(_Nocopy_types);
     41            template<typename _Functor> class _Base_manager {
     42                static const bool __stored_locally = (sizeof(_Functor) <= _M_max_size && __alignof__(_Functor) <= _M_max_align && (_M_max_align % __alignof__(_Functor) == 0));
     43                typedef integral_constant<bool, __stored_locally> _Local_storage;
     44            public:
     45                static bool _M_manager(_Any_data& __dest, const _Any_data& __source, _Manager_operation __op) { }
     46                static void _M_init_functor(_Any_data& __functor, const _Functor& __f) {
     47                    _M_init_functor(__functor, __f, _Local_storage());
     48                }
     49                template<typename _Class, typename _Tp> static bool _M_not_empty_function(_Tp _Class::* const& __mp) {
     50                    return __mp;
     51                }
     52                static void _M_init_functor(_Any_data& __functor, const _Functor& __f, true_type) {
     53                    new (__functor._M_access()) _Functor(__f);
     54                }
     55            };
     56            ~_Function_base() {
     57                if (_M_manager) _M_manager(_M_functor, _M_functor, __destroy_functor);
     58            }
     59            bool _M_empty() const {
     60                return !_M_manager;
     61            }
     62            typedef bool (*_Manager_type)(_Any_data&, const _Any_data&, _Manager_operation);
     63            _Any_data _M_functor;
     64            _Manager_type _M_manager;
     65        };
     66        template<typename _Signature, typename _Functor> class _Function_handler;
     67        template<typename _Class, typename _Member, typename _Res, typename... _ArgTypes> class _Function_handler<_Res(_ArgTypes...), _Member _Class::*> : public _Function_handler<void(_ArgTypes...), _Member _Class::*> {
     68        public:
     69            static _Res _M_invoke(const _Any_data& __functor, _ArgTypes... __args) { }
     70        };
     71        template<typename _Class, typename _Member, typename... _ArgTypes> class _Function_handler<void(_ArgTypes...), _Member _Class::*> : public _Function_base::_Base_manager< _Simple_type_wrapper< _Member _Class::* > > { };
     72        template<typename _Res, typename... _ArgTypes> class function<_Res(_ArgTypes...)> : public _Maybe_unary_or_binary_function<_Res, _ArgTypes...>, private _Function_base {
     73            typedef _Res _Signature_type(_ArgTypes...);
     74            struct _Useless { };
     75        public:
     76            template<typename _Functor> function(_Functor __f, _Useless = _Useless());
     77            _Res operator()(_ArgTypes... __args) const;
     78            const type_info& target_type() const;
     79            typedef _Res (*_Invoker_type)(const _Any_data&, _ArgTypes...);
     80            _Invoker_type _M_invoker;
     81        };
     82        template<typename _Res, typename... _ArgTypes> template<typename _Functor> function<_Res(_ArgTypes...)>:: function(_Functor __f, _Useless) : _Function_base() {
     83            typedef _Function_handler<_Signature_type, _Functor> _My_handler;
     84            if (_My_handler::_M_not_empty_function(__f)) {
     85                _M_invoker = &_My_handler::_M_invoke;
     86                _M_manager = &_My_handler::_M_manager;
     87                _My_handler::_M_init_functor(_M_functor, __f);
     88            }
     89        }
     90        template<typename _Res, typename... _ArgTypes> _Res function<_Res(_ArgTypes...)>:: operator()(_ArgTypes... __args) const {
     91            if (_M_empty()) {
     92                __throw_bad_function_call();
     93            }
     94            return _M_invoker(_M_functor, __args...);
     95        }
     96        template<typename _Res, typename... _ArgTypes> const type_info& function<_Res(_ArgTypes...)>:: target_type() const {
     97            if (_M_manager) {
     98                _Any_data __typeinfo_result;
     99                _M_manager(__typeinfo_result, _M_functor, __get_type_info);
     100            }
     101        }
     102    }
     103}
     104struct X {
     105    int bar;
     106};
     107void test05() {
     108    using std::tr1::function;
     109    X x;
     110    function<int(X&)> frm(&X::bar);
     111    frm(x) == 17;
     112    typeid(int X::*) == frm.target_type();
     113}
  • gcc/testsuite/g++.dg/torture/pr41144.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41144.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41144.C
    old new  
     1/* { dg-do compile } */
     2
     3struct rgba8;
     4template<class ColorT> class span_gouraud     {
     5public:
     6    struct coord_type { };
     7    coord_type m_coord[3];
     8};
     9template<class ColorT> class span_gouraud_rgba : public span_gouraud<ColorT>   
     10{
     11  typedef ColorT color_type;
     12  typedef span_gouraud<color_type> base_type;
     13  typedef typename base_type::coord_type coord_type;
     14public:
     15  void prepare()         {
     16      coord_type coord[3];
     17  }
     18};
     19void the_application() {
     20    typedef span_gouraud_rgba<rgba8> gouraud_span_gen_type;
     21    gouraud_span_gen_type span_gouraud;
     22    span_gouraud.prepare();
     23}
  • gcc/testsuite/g++.dg/torture/pr41257-2.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41257-2.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41257-2.C
    old new  
     1/* { dg-do link } */
     2
     3struct A
     4{
     5  virtual ~A();
     6};
     7
     8struct B : virtual A
     9{
     10  virtual ~B() {}
     11};
     12
     13int main()
     14{
     15  return 0;
     16}
  • gcc/testsuite/g++.dg/torture/pr41257.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41257.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41257.C
    old new  
     1/* { dg-do compile } */
     2
     3struct A
     4{
     5  virtual void foo();
     6  virtual ~A();
     7  int i;
     8};
     9
     10struct B : virtual A {};
     11
     12struct C : B
     13{
     14  virtual void foo();
     15};
     16
     17void bar()
     18{
     19  C().foo();
     20}
  • gcc/testsuite/g++.dg/torture/pr41273.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41273.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41273.C
    old new  
     1/* { dg-do compile } */
     2/* { dg-options "-g" } */
     3
     4long *H2_ipX_ener_sort;
     5double H2_old_populations[2];
     6double H2_total;
     7
     8void H2_LevelPops()
     9{
     10  double sum_pop = 0.;
     11  long nEner = 0;
     12  while( nEner < 3 && sum_pop/H2_total < 0.99999 )
     13    {
     14      long ip = H2_ipX_ener_sort[nEner];
     15      sum_pop += H2_old_populations[ip];
     16      ++nEner;
     17    }
     18}
  • gcc/testsuite/g++.dg/warn/Wreturn-type-6.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/warn/Wreturn-type-6.C gcc-4.4.1/gcc/testsuite/g++.dg/warn/Wreturn-type-6.C
    old new  
     1/* PR c++/40749 */
     2/* { dg-do "compile" } */
     3/* { dg-options "-Wreturn-type" } */
     4
     5struct A {};
     6const A a() {} /* { dg-warning "no return statement" } */
     7const A& b() {} /* { dg-warning "no return statement" } */
     8
     9const int c() {} /* { dg-warning "no return statement" } */
     10
     11template<class T>
     12const int foo(T t) {} /* { dg-warning "no return statement" } */
     13int d = foo<int>(0), e = foo<int>(1);
  • gcc/testsuite/gfortran.dg/altreturn_7.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/altreturn_7.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/altreturn_7.f90
    old new  
     1! { dg-do compile }
     2!
     3! PR 40848: [4.5 Regression] ICE with alternate returns
     4!
     5! Contributed by Joost VandeVondele <jv244@cam.ac.uk>
     6
     7MODULE TT
     8
     9INTERFACE M
     10 MODULE PROCEDURE M1,M2
     11END INTERFACE
     12
     13CONTAINS
     14
     15 SUBROUTINE M1(I,*)
     16   INTEGER :: I
     17   RETURN 1
     18 END SUBROUTINE
     19
     20 SUBROUTINE M2(I,J)
     21   INTEGER :: I,J
     22 END SUBROUTINE
     23
     24END MODULE
     25
     26
     27  USE TT
     28  CALL M(1,*2)
     29  CALL ABORT()
     302 CONTINUE
     31END
     32
     33! { dg-final { cleanup-modules "tt" } }
     34
  • gcc/testsuite/gfortran.dg/c_f_pointer_tests_4.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/c_f_pointer_tests_4.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/c_f_pointer_tests_4.f90
    old new  
     1! { dg-do run }
     2program main
     3   use iso_c_binding, only: c_ptr, c_loc, c_f_pointer
     4   implicit none
     5   integer, dimension(2,1,2), target :: table
     6   table = reshape ( (/ 1,2,-1,-2/), (/2,1,2/))
     7   call set_table (c_loc (table))
     8contains
     9   subroutine set_table (cptr)
     10     type(c_ptr), intent(in) :: cptr
     11     integer, dimension(:,:,:), pointer :: table_tmp
     12     call c_f_pointer (cptr, table_tmp, (/2,1,2/))
     13     if (any(table_tmp /= table)) call abort
     14   end subroutine set_table
     15end program main
  • gcc/testsuite/gfortran.dg/char_length_16.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/char_length_16.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/char_length_16.f90
    old new  
     1! { dg-do compile }
     2!
     3! PR 40822: [4.5 Regression] Internal compiler error when Fortran intrinsic LEN referenced before explicit declaration
     4!
     5! Contributed by Mat Cross <mathewc@nag.co.uk>
     6
     7SUBROUTINE SEARCH(ITEMVAL)
     8  CHARACTER (*) :: ITEMVAL
     9  CHARACTER (LEN(ITEMVAL)) :: ITEM
     10  INTRINSIC LEN
     11END
     12
  • gcc/testsuite/gfortran.dg/derived_init_3.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/derived_init_3.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/derived_init_3.f90
    old new  
     1! { dg-do run }
     2!
     3! PR fortran/40851
     4!
     5! Make sure the an INTENT(OUT) dummy is not initialized
     6! when it is a pointer.
     7!
     8! Contributed by Juergen Reuter <juergen.reuter@desy.de>.
     9!
     10program main
     11
     12  type :: string
     13     character,dimension(:),allocatable :: chars
     14  end type string
     15
     16  type :: string_container
     17     type(string) :: string
     18  end type string_container
     19
     20  type(string_container), target :: tgt
     21  type(string_container), pointer :: ptr
     22
     23  ptr => tgt
     24  call set_ptr (ptr)
     25  if (associated(ptr)) call abort()
     26
     27contains
     28
     29  subroutine set_ptr (ptr)
     30    type(string_container), pointer, intent(out) :: ptr
     31    ptr => null ()
     32  end subroutine set_ptr
     33
     34end program main
  • gcc/testsuite/gfortran.dg/fmt_cache_1.f

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/fmt_cache_1.f gcc-4.4.1/gcc/testsuite/gfortran.dg/fmt_cache_1.f
    old new  
     1! { dg-do run { target fd_truncate } }
     2! pr40662 segfaults when specific format is invoked twice.
     3! pr40330  incorrect io.
     4! test case derived from pr40662, <jvdelisle@gcc.gnu.org>
     5      program astap
     6      character(40) teststring
     7      arlxca = 0.0
     8      open(10)
     9      write(10,40) arlxca
     10      write(10,40) arlxca
     1140    format(t4,"arlxca = ",1pg13.6,t27,"arlxcc = ",g13.6,t53,
     12     .            "atmpca = ",g13.6,t79,"atmpcc = ",g13.6,t105,
     13     .            "backup = ",g13.6,/,
     14     .         t4,"csgfac = ",g13.6,t27,"csgmax = ",g13.6,t53,
     15     .            "csgmin = ",g13.6,t79,"drlxca = ",g13.6,t105,
     16     .            "drlxcc = ",g13.6,/,
     17     .         t4,"dtimeh = ",g13.6,t27,"dtimei = ",g13.6,t53,
     18     .            "dtimel = ",g13.6,t79,"dtimeu = ",g13.6,t105,
     19     .            "dtmpca = ",g13.6,/,
     20     .         t4,"dtmpcc = ",g13.6,t27,"ebalna = ",g13.6,t53,
     21     .            "ebalnc = ",g13.6,t79,"ebalsa = ",g13.6,t105,
     22     .            "ebalsc = ",g13.6)
     23      rewind 10
     24      rewind 10
     25      teststring = ""
     26      read(10,'(a)') teststring
     27      if (teststring.ne."   arlxca =   0.00000     arlxcc = ")call abort
     28      teststring = ""
     29      read(10,'(a)') teststring
     30      if (teststring.ne."   arlxca =   0.00000     arlxcc = ")call abort
     31      end program astap
     32
     33
  • gcc/testsuite/gfortran.dg/gomp/pr40878-1.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/gomp/pr40878-1.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/gomp/pr40878-1.f90
    old new  
     1! PR fortran/40878
     2! { dg-do compile }
     3! { dg-options "-fopenmp" }
     4
     5subroutine test1
     6  integer :: j, k
     7  integer :: m = 2
     8!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "Constant expression required" }
     9  do k = 1, 2
     10    do j = 1, 6
     11    enddo
     12  enddo
     13!$omp end parallel do
     14end
     15subroutine test2
     16  integer :: j, k
     17  integer :: m
     18  m = 2
     19!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "Constant expression required" }
     20  do k = 1, 2
     21    do j = 1, 6
     22    enddo
     23  enddo
     24!$omp end parallel do
     25end
     26subroutine test3
     27  integer :: j, k
     28  integer, parameter :: m = 0
     29!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "not constant positive integer" }
     30  do k = 1, 2
     31    do j = 1, 6
     32    enddo
     33  enddo
     34!$omp end parallel do
     35end
     36subroutine test4
     37  integer :: j, k
     38  integer, parameter :: m = -2
     39!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "not constant positive integer" }
     40  do k = 1, 2
     41    do j = 1, 6
     42    enddo
     43  enddo
     44!$omp end parallel do
     45end
     46subroutine test5
     47  integer :: j, k
     48!$omp parallel do collapse(0) schedule (static,1) ! { dg-error "not constant positive integer" }
     49  do k = 1, 2
     50    do j = 1, 6
     51    enddo
     52  enddo
     53!$omp end parallel do
     54end
     55subroutine test6
     56  integer :: j, k
     57!$omp parallel do collapse(-1) schedule (static,1) ! { dg-error "not constant positive integer" }
     58  do k = 1, 2
     59    do j = 1, 6
     60    enddo
     61  enddo
     62!$omp end parallel do
     63end
  • gcc/testsuite/gfortran.dg/gomp/pr40878-2.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/gomp/pr40878-2.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/gomp/pr40878-2.f90
    old new  
     1! PR fortran/40878
     2! { dg-do compile }
     3! { dg-options "-fopenmp" }
     4
     5subroutine test1
     6  integer :: j, k
     7  integer, parameter :: m = 2
     8!$omp parallel do collapse(m) schedule (static,1)
     9  do k = 1, 2
     10    do j = 1, 6
     11    enddo
     12  enddo
     13!$omp end parallel do
     14end
     15subroutine test2
     16  integer :: j, k
     17!$omp parallel do collapse(2) schedule (static,1)
     18  do k = 1, 2
     19    do j = 1, 6
     20    enddo
     21  enddo
     22!$omp end parallel do
     23end
  • gcc/testsuite/gfortran.dg/intrinsic_3.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_3.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_3.f90
    old new  
     1! { dg-do compile }
     2! { dg-options "-std=f95" }
     3!
     4! PR 39876: module procedure name that collides with the GNU intrinsic
     5!
     6! Contributed by Alexei Matveev <alexei.matveev+gcc@gmail.com>
     7
     8module p                           
     9  implicit none                                                                 
     10
     11  contains
     12
     13    subroutine test()
     14      implicit none
     15      print *, avg(erfc)
     16    end subroutine test
     17
     18    function avg(f)
     19      implicit none
     20      double precision :: avg
     21      interface
     22        double precision function f(x)
     23          implicit none
     24          double precision, intent(in) :: x
     25        end function f
     26      end interface
     27      avg = ( f(1.0D0) + f(2.0D0) ) / 2
     28    end function avg
     29
     30    function erfc(x)
     31      implicit none
     32      double precision, intent(in) :: x
     33      double precision             :: erfc
     34      erfc = x
     35    end function erfc
     36
     37end module p
     38
     39! { dg-final { cleanup-modules "p" } }
     40
  • gcc/testsuite/gfortran.dg/intrinsic_4.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_4.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_4.f90
    old new  
     1! { dg-do compile }
     2! { dg-options "-Wsurprising" }
     3!
     4! PR 40995: [4.5 Regression] Spurious "Type specified for intrinsic function...ignored" message
     5!
     6! Contributed by Mat Cross <mathewc@nag.co.uk>
     7
     8subroutine sub(n,x)
     9  intrinsic abs
     10  integer n, x(abs(n))
     11end
     12
  • gcc/testsuite/gfortran.dg/intrinsic_5.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_5.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_5.f90
    old new  
     1! { dg-do compile }
     2! { dg-options "-fimplicit-none" }
     3!
     4! PR 41121: [4.5 Regression] compile-time error when building BLAS with -fimplicit-none
     5!
     6! Original test case: http://www.netlib.org/blas/dgbmv.f
     7! Reduced by Joost VandeVondele <jv244@cam.ac.uk>
     8
     9  INTRINSIC MIN
     10  INTEGER :: I,J
     11  print *,MIN(I,J)
     12END
     13
  • gcc/testsuite/gfortran.dg/intrinsic_cmplx.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_cmplx.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_cmplx.f90
    old new  
     1! { dg-do compile }
     2! PR fortran/40727
     3program test
     4  integer, parameter :: sp = kind(1.e0), dp = kind(1.d0)
     5  complex(sp) :: s
     6  complex(dp) :: d
     7  s =  cmplx(0.e0, cmplx(0.e0,0.e0)) ! { dg-error "either REAL or INTEGER" }
     8  d = dcmplx(0.d0, cmplx(0.d0,0.d0)) ! { dg-error "either REAL or INTEGER" }
     9end program test
  • gcc/testsuite/gfortran.dg/namelist_40.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/namelist_40.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/namelist_40.f90
    old new  
    1 ! { dg-do run { target fd_truncate } }
     1! { dg-do run }
    22! PR33672 Additional runtime checks needed for namelist reads
    33! Submitted by Jerry DeLisle  <jvdelisle@gcc.gnu.org>
    44
     
    4747end subroutine writenml
    4848
    4949end program namelist_40
    50 ! { dg-output "Multiple sub-objects with non-zero rank in namelist object x(\n|\r\n|\r)" }
     50! { dg-output "Multiple sub-objects with non-zero rank in namelist object x%m%ch(\n|\r\n|\r)" }
    5151! { dg-output "Missing colon in substring qualifier for namelist variable x%m%ch(\n|\r\n|\r)" }
    5252! { dg-output "Substring out of range for namelist variable x%m%ch(\n|\r\n|\r)" }
    5353! { dg-output "Bad character in substring qualifier for namelist variable x%m%ch(\n|\r\n|\r)" }
  • gcc/testsuite/gfortran.dg/namelist_47.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/namelist_47.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/namelist_47.f90
    old new  
    1 ! { dg-do run { target fd_truncate } }
     1! { dg-do run }
    22
    33module nml_47
    44  type             ::  mt
     
    4545end subroutine writenml
    4646
    4747end program namelist_47
    48 ! { dg-output "Multiple sub-objects with non-zero rank in namelist object x(\n|\r\n|\r)" }
     48! { dg-output "Multiple sub-objects with non-zero rank in namelist object x%m%c012345678901234567890123456789012345678901234567890123456789h(\n|\r\n|\r)" }
    4949! { dg-output "Missing colon in substring qualifier for namelist variable x%m%c012345678901234567890123456789012345678901234567890123456789h(\n|\r\n|\r)" }
    5050! { dg-output "Substring out of range for namelist variable x%m%c012345678901234567890123456789012345678901234567890123456789h(\n|\r\n|\r)" }
    5151! { dg-output "Bad character in substring qualifier for namelist variable x%m%c012345678901234567890123456789012345678901234567890123456789h(\n|\r\n|\r)" }
  • gcc/testsuite/gfortran.dg/namelist_58.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/namelist_58.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/namelist_58.f90
    old new  
     1! { dg-do run }
     2! PR40853 Error in namelist IO.
     3! Test case derived from example given in PR. < jvdelisle@gcc.gnu.org >
     4program test
     5  implicit none
     6  type tao_title_struct
     7    character(2) justify   
     8  end type
     9  type tao_plot_page_struct
     10    real shape_height_max
     11    type (tao_title_struct) title ! Comment this line out and the bug goes away.
     12    real size(2)
     13  end type
     14  type (tao_plot_page_struct) plot_page
     15  namelist / params / plot_page
     16  open (10, status="scratch")
     17  write(10,'(a)')"  &params"
     18  write(10,'(a)')"  plot_page%size=5 , 2,"
     19  write(10,'(a)')"/"
     20  rewind(10)
     21  read (10, nml = params)
     22  if (any(plot_page%size .ne. (/ 5, 2 /))) call abort
     23  close (10)
     24end program
     25
  • gcc/testsuite/gfortran.dg/pr41126.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41126.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41126.f90
    old new  
     1! { dg-do compile }
     2SUBROUTINE write_cputime( checkpoint  )
     3  CHARACTER(LEN=*), INTENT(IN)             :: checkpoint
     4  CHARACTER(LEN=LEN_TRIM(checkpoint)+7)    :: string1
     5    string1 = ADJUSTL(string1)
     6END SUBROUTINE write_cputime
  • gcc/testsuite/gfortran.dg/pr41162.f

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41162.f gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41162.f
    old new  
     1! { dg-do compile }
     2! PRs 41154/41162
     3      write (*,'(1PD24.15,F4.2,0P)') 1.0d0
     4      write (*,'(1PD24.15,F4.2,0P/)') 1.0d0
     5      end
  • gcc/testsuite/gfortran.dg/pr41225.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41225.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41225.f90
    old new  
     1! { dg-do compile }
     2! { dg-options "-O2 -ffast-math -funroll-loops -ftree-vectorize -g" }
     3  SUBROUTINE block_15_1_1_1(kbd,kbc,kad,kac,pbd,pbc,pad,pac,prim,scale)
     4    INTEGER, PARAMETER :: dp=8
     5    REAL(KIND=dp) :: kbd(1*1), kbc(1*1), kad(15*1), kac(15*1), pbd(1*1), &
     6      pbc(1*1), pad(15*1), pac(15*1), prim(15*1*1*1), scale
     7    INTEGER                                  :: ma, mb, mc, md, p_index
     8      DO md = 1,1
     9        DO mc = 1,1
     10          DO mb = 1,1
     11            DO ma = 1,15
     12              p_index=p_index+1
     13              tmp = scale*prim(p_index)
     14              ks_bd = ks_bd + tmp* pac((mc-1)*15+ma)
     15            END DO
     16            kbd((md-1)*1+mb) = kbd((md-1)*1+mb) - ks_bd
     17          END DO
     18        END DO
     19      END DO
     20  END SUBROUTINE block_15_1_1_1
  • gcc/testsuite/gfortran.dg/pr41229.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41229.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41229.f90
    old new  
     1! { dg-do compile }
     2! { dg-options "-O2 -g" }
     3SUBROUTINE cp_fm_triangular_multiply()
     4    INTEGER, PARAMETER :: dp=KIND(0.0D0)
     5    REAL(dp), ALLOCATABLE, DIMENSION(:)      :: tau, work
     6    REAL(KIND=dp), DIMENSION(:, :), POINTER  :: a
     7    ndim = SIZE(a,2)
     8    ALLOCATE(tau(ndim),STAT=istat)
     9    ALLOCATE(work(2*ndim),STAT=istat)
     10END SUBROUTINE
  • gcc/testsuite/gfortran.dg/proc_ptr_25.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/proc_ptr_25.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/proc_ptr_25.f90
    old new  
     1! { dg-do run }
     2!
     3! PR 41139: [4.5 Regression] a procedure pointer call as actual argument
     4!
     5! Original test case by Barron Bichon <barron.bichon@swri.org>
     6! Modified by Janus Weil <janus@gcc.gnu.org>
     7
     8PROGRAM test
     9
     10 PROCEDURE(add), POINTER :: f
     11 logical :: g
     12
     13 ! Passing the function works
     14 g=greater(4.,add(1.,2.))
     15 if (.not. g) call abort()
     16
     17 ! Passing the procedure pointer fails
     18 f => add
     19 g=greater(4.,f(1.,2.))
     20 if (.not. g) call abort()
     21
     22CONTAINS
     23
     24 REAL FUNCTION add(x,y)
     25   REAL, INTENT(in) :: x,y
     26   print *,"add:",x,y
     27   add = x+y
     28 END FUNCTION add
     29
     30 LOGICAL FUNCTION greater(x,y)
     31   REAL, INTENT(in) :: x, y
     32   greater = (x > y)
     33 END FUNCTION greater
     34
     35END PROGRAM test
     36
  • gcc/testsuite/gfortran.dg/structure_constructor_10.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/structure_constructor_10.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/structure_constructor_10.f90
    old new  
     1! { dg-do compile }
     2!
     3! PR 41070: [4.5 Regression] Error: Components of structure constructor '' at (1) are PRIVATE
     4!
     5! Contributed by Michael Richmond <michael.a.richmond@nasa.gov>
     6
     7MODULE cdf_aux_mod
     8IMPLICIT NONE
     9
     10TYPE :: one_parameter
     11  CHARACTER (8) :: name
     12END TYPE one_parameter
     13
     14TYPE :: the_distribution
     15  CHARACTER (8) :: name
     16END TYPE the_distribution
     17
     18TYPE (the_distribution), PARAMETER :: the_beta = the_distribution('cdf_beta')
     19END MODULE cdf_aux_mod
     20
     21SUBROUTINE cdf_beta()
     22  USE cdf_aux_mod
     23  IMPLICIT NONE
     24  CALL check_complements(the_beta%name)
     25END SUBROUTINE cdf_beta
     26
     27! { dg-final { cleanup-modules "cdf_aux_mod" } }
     28
  • gcc/testsuite/gfortran.dg/transfer_resolve_1.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/transfer_resolve_1.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/transfer_resolve_1.f90
    old new  
     1! { dg-do run }
     2! PR40847 - an error in gfc_resolve_transfer caused the character length
     3! of 'mold' to be set incorrectly.
     4!
     5! Contributed by Joost VandeVondele <jv244@cam.ac.uk>
     6!
     7program test_elemental
     8
     9if (any (transfer_size((/0.,0./),(/'a','b'/)) .ne. [4 ,4])) call abort
     10
     11contains
     12
     13   elemental function transfer_size (source, mold)
     14     real, intent(in)         :: source
     15     character(*), intent(in) :: mold
     16     integer                  :: transfer_size
     17     transfer_size = SIZE(TRANSFER(source, (/mold/)))
     18     return
     19   end function transfer_size
     20
     21end program test_elemental
  • gcc/testsuite/gfortran.dg/typebound_proc_12.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/typebound_proc_12.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/typebound_proc_12.f90
    old new  
     1! { dg-do compile }
     2! Test the fix for PR41258, where an ICE was caused by a search
     3! for a typebound procedure to resolve d%c%e
     4!
     5! Contributed by Joost VandeVondele <jv244@cam.ac.uk>
     6!
     7  TYPE a
     8    TYPE(b), DIMENSION(:), POINTER :: c  ! { dg-error "type that has not been declared" }
     9  END TYPE
     10  TYPE(a), POINTER :: d
     11  CALL X(d%c%e)         ! { dg-error "before it is defined" }
     12end
  • gcc/testsuite/gfortran.dg/use_only_4.f90

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/use_only_4.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/use_only_4.f90
    old new  
     1! { dg-do compile }
     2! Test the fix for PR41062, in which an ICE would ensue because
     3! of confusion between the two 'one's in the creation of module
     4! debug info.
     5!
     6! Reported by Norman S. Clerman <clerman@fuse.net>
     7! Reduced testcase by Tobias Burnus <burnus@gcc.gnu.org>
     8!
     9module m1
     10   interface one  ! GENERIC "one"
     11     module procedure one1
     12   end interface
     13contains
     14  subroutine one1()
     15    call abort
     16  end subroutine one1
     17end module m1
     18
     19module m2
     20use m1, only : one  ! USE generic "one"
     21contains
     22  subroutine two()
     23    call one()  ! Call internal "one"
     24  contains
     25    subroutine one() ! Internal "one"
     26      print *, "m2"
     27    end subroutine one
     28  end subroutine two
     29end module m2
     30
     31  use m2
     32  call two
     33end
     34! { dg-final { cleanup-modules "m1 m2" } }
  • gcc/testsuite/gnat.dg/array8.adb

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/gnat.dg/array8.adb gcc-4.4.1/gcc/testsuite/gnat.dg/array8.adb
    old new  
     1-- { dg-do compile }
     2-- { dg-options "-O2" }
     3
     4PROCEDURE Array8 IS
     5
     6  function ID (I : Integer) return Integer is
     7  begin
     8    return I;
     9  end;
     10
     11  SUBTYPE STB IS INTEGER RANGE ID(-8) .. -5;
     12
     13  TYPE TB IS ARRAY (STB RANGE <>) OF INTEGER;
     14
     15  GENERIC
     16    B1 : TB;
     17  PROCEDURE PROC1;
     18
     19  PROCEDURE PROC1 IS
     20  BEGIN
     21    IF B1'FIRST /= -8 THEN
     22      raise Program_Error;
     23    ELSIF B1'LAST /= ID(-5) THEN
     24      raise Program_Error;
     25    ELSIF B1 /= (7, 6, 5, 4) THEN
     26      raise Program_Error;
     27    END IF;
     28  END;
     29
     30  PROCEDURE PROC2 IS NEW PROC1 ((7, 6, ID(5), 4));
     31
     32BEGIN
     33  PROC2;
     34END;
  • gcc/testsuite/g++.old-deja/g++.brendan/init4.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.old-deja/g++.brendan/init4.C gcc-4.4.1/gcc/testsuite/g++.old-deja/g++.brendan/init4.C
    old new  
    22// GROUPS passed initialization
    33struct CharList { int i; };
    44
    5 const CharList& terminals = { 1 };// { dg-error "" } .*
     5const CharList& terminals = { 1 }; // { dg-error "initializer lists" } c++0x
  • gcc/testsuite/g++.old-deja/g++.jason/thunk2.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.old-deja/g++.jason/thunk2.C gcc-4.4.1/gcc/testsuite/g++.old-deja/g++.jason/thunk2.C
    old new  
    11// { dg-do run { target fpic } }
    22// { dg-options "-fPIC" }
    3 // { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))|\[Bb\]ad fixup at .DATA.:" "PIC unsupported" { xfail *-*-netware* } 0 }
    43// { dg-skip-if "requires unsupported run-time relocation" { spu-*-* } { "*" } { "" } }
    54// Test that non-variadic function calls using thunks and PIC work right.
    65
  • gcc/testsuite/g++.old-deja/g++.law/weak.C

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.old-deja/g++.law/weak.C gcc-4.4.1/gcc/testsuite/g++.old-deja/g++.law/weak.C
    old new  
    11// { dg-do link { target i?86-*-linux* x86_64-*-linux* } }
     2// { dg-require-effective-target static }
    23// { dg-options "-static" }
    34// Bug: g++ fails to instantiate operator<<.
    45
  • gcc/testsuite/lib/target-supports.exp

    diff -Naur gcc-4.4.1.orig/gcc/testsuite/lib/target-supports.exp gcc-4.4.1/gcc/testsuite/lib/target-supports.exp
    old new  
    611611    } "-pthread"]
    612612}
    613613
     614# Return 1 if the target supports -static
     615proc check_effective_target_static {} {
     616    return [check_no_compiler_messages static executable {
     617        int main (void) { return 0; }
     618    } "-static"]
     619}
     620
    614621# Return 1 if the target supports -fstack-protector
    615622proc check_effective_target_fstack_protector {} {
    616623    return [check_runtime fstack_protector {
     
    12691276        verbose "check_effective_target_vect_cmdline_needed: using cached result" 2
    12701277    } else {
    12711278        set et_vect_cmdline_needed_saved 1
    1272         if { [istarget ia64-*-*]
     1279        if { [istarget alpha*-*-*]
     1280             || [istarget ia64-*-*]
    12731281             || (([istarget x86_64-*-*] || [istarget i?86-*-*])
    12741282                 && [check_effective_target_lp64])
    12751283             || ([istarget powerpc*-*-*]
  • gcc/tree-ssa.c

    diff -Naur gcc-4.4.1.orig/gcc/tree-ssa.c gcc-4.4.1/gcc/tree-ssa.c
    old new  
    14721472
    14731473  /* We do not care about LHS.  */
    14741474  if (wi->is_lhs)
    1475     return NULL_TREE;
     1475    {
     1476      /* Except for operands of INDIRECT_REF.  */
     1477      if (!INDIRECT_REF_P (t))
     1478        return NULL_TREE;
     1479      t = TREE_OPERAND (t, 0);
     1480    }
    14761481
    14771482  switch (TREE_CODE (t))
    14781483    {
  • gcc/tree-ssa-ifcombine.c

    diff -Naur gcc-4.4.1.orig/gcc/tree-ssa-ifcombine.c gcc-4.4.1/gcc/tree-ssa-ifcombine.c
    old new  
    151151    {
    152152      gimple def_stmt = SSA_NAME_DEF_STMT (candidate);
    153153      if (is_gimple_assign (def_stmt)
    154           && gimple_assign_cast_p (def_stmt))
     154          && CONVERT_EXPR_CODE_P (gimple_assign_rhs_code (def_stmt)))
    155155        {
    156156          if (TYPE_PRECISION (TREE_TYPE (candidate))
    157157              <= TYPE_PRECISION (TREE_TYPE (gimple_assign_rhs1 (def_stmt))))
     
    162162  return candidate;
    163163}
    164164
    165 /* Helpers for recognize_single_bit_test defined mainly for source code
    166    formating.  */
    167 
    168 static int
    169 operand_precision (tree t)
    170 {
    171   return TYPE_PRECISION (TREE_TYPE (t));
    172 }
    173 
    174 static bool
    175 integral_operand_p (tree t)
    176 {
    177   return INTEGRAL_TYPE_P (TREE_TYPE (t));
    178 }
    179 
    180165/* Recognize a single bit test pattern in GIMPLE_COND and its defining
    181166   statements.  Store the name being tested in *NAME and the bit
    182167   in *BIT.  The GIMPLE_COND computes *NAME & (1 << *BIT).
     
    212197      stmt = SSA_NAME_DEF_STMT (orig_name);
    213198
    214199      while (is_gimple_assign (stmt)
    215              && (gimple_assign_ssa_name_copy_p (stmt)
    216                  || (gimple_assign_cast_p (stmt)
    217                      && integral_operand_p (gimple_assign_lhs (stmt))
    218                      && integral_operand_p (gimple_assign_rhs1 (stmt))
    219                      && (operand_precision (gimple_assign_lhs (stmt))
    220                          <= operand_precision (gimple_assign_rhs1 (stmt))))))
    221         {
    222           stmt = SSA_NAME_DEF_STMT (gimple_assign_rhs1 (stmt));
    223         }
     200             && ((CONVERT_EXPR_CODE_P (gimple_assign_rhs_code (stmt))
     201                  && (TYPE_PRECISION (TREE_TYPE (gimple_assign_lhs (stmt)))
     202                      <= TYPE_PRECISION (TREE_TYPE (gimple_assign_rhs1 (stmt)))))
     203                 || gimple_assign_ssa_name_copy_p (stmt)))
     204        stmt = SSA_NAME_DEF_STMT (gimple_assign_rhs1 (stmt));
    224205
    225206      /* If we found such, decompose it.  */
    226207      if (is_gimple_assign (stmt)
  • gcc/tree-ssa-pre.c

    diff -Naur gcc-4.4.1.orig/gcc/tree-ssa-pre.c gcc-4.4.1/gcc/tree-ssa-pre.c
    old new  
    35073507}
    35083508
    35093509
    3510 /* Add OP to EXP_GEN (block), and possibly to the maximal set if it is
    3511    not defined by a phi node.
    3512    PHI nodes can't go in the maximal sets because they are not in
    3513    TMP_GEN, so it is possible to get into non-monotonic situations
    3514    during ANTIC calculation, because it will *add* bits.  */
     3510/* Add OP to EXP_GEN (block), and possibly to the maximal set.  */
    35153511
    35163512static void
    35173513add_to_exp_gen (basic_block block, tree op)
     
    35233519        return;
    35243520      result = get_or_alloc_expr_for_name (op);
    35253521      bitmap_value_insert_into_set (EXP_GEN (block), result);
    3526       if (TREE_CODE (op) != SSA_NAME
    3527           || gimple_code (SSA_NAME_DEF_STMT (op)) != GIMPLE_PHI)
    3528         bitmap_value_insert_into_set (maximal_set, result);
     3522      bitmap_value_insert_into_set (maximal_set, result);
    35293523    }
    35303524}
    35313525
     
    35443538      add_to_value (get_expr_value_id (e), e);
    35453539      bitmap_insert_into_set (PHI_GEN (block), e);
    35463540      bitmap_value_insert_into_set (AVAIL_OUT (block), e);
     3541      if (!in_fre)
     3542        {
     3543          unsigned i;
     3544          for (i = 0; i < gimple_phi_num_args (phi); ++i)
     3545            {
     3546              tree arg = gimple_phi_arg_def (phi, i);
     3547              if (TREE_CODE (arg) == SSA_NAME)
     3548                {
     3549                  e = get_or_alloc_expr_for_name (arg);
     3550                  add_to_value (get_expr_value_id (e), e);
     3551                  bitmap_value_insert_into_set (maximal_set, e);
     3552                }
     3553            }
     3554        }
    35473555    }
    35483556}
    35493557
     
    42544262      FOR_ALL_BB (bb)
    42554263        {
    42564264          print_bitmap_set (dump_file, EXP_GEN (bb), "exp_gen", bb->index);
    4257           print_bitmap_set (dump_file, TMP_GEN (bb), "tmp_gen",
    4258                                   bb->index);
    4259           print_bitmap_set (dump_file, AVAIL_OUT (bb), "avail_out",
    4260                                   bb->index);
     4265          print_bitmap_set (dump_file, PHI_GEN (bb), "phi_gen", bb->index);
     4266          print_bitmap_set (dump_file, TMP_GEN (bb), "tmp_gen", bb->index);
     4267          print_bitmap_set (dump_file, AVAIL_OUT (bb), "avail_out", bb->index);
    42614268        }
     4269
     4270      print_bitmap_set (dump_file, maximal_set, "maximal", 0);
    42624271    }
    42634272
    42644273  /* Insert can get quite slow on an incredibly large number of basic
  • gcc/version.c

    diff -Naur gcc-4.4.1.orig/gcc/version.c gcc-4.4.1/gcc/version.c
    old new  
    1414   Makefile.  */
    1515
    1616const char version_string[] = BASEVER DATESTAMP DEVPHASE REVISION;
    17 const char pkgversion_string[] = PKGVERSION;
     17const char pkgversion_string[] = "(GCC for Cross-LFS 4.4.1.20090912) ";
  • libcpp/macro.c

    diff -Naur gcc-4.4.1.orig/libcpp/macro.c gcc-4.4.1/libcpp/macro.c
    old new  
    375375        }
    376376
    377377      escape_it = (token->type == CPP_STRING || token->type == CPP_CHAR
    378                    || token->type == CPP_WSTRING || token->type == CPP_STRING
     378                   || token->type == CPP_WSTRING || token->type == CPP_WCHAR
    379379                   || token->type == CPP_STRING32 || token->type == CPP_CHAR32
    380380                   || token->type == CPP_STRING16 || token->type == CPP_CHAR16);
    381381
  • libdecnumber/decCommon.c

    diff -Naur gcc-4.4.1.orig/libdecnumber/decCommon.c gcc-4.4.1/libdecnumber/decCommon.c
    old new  
    10891089  return 10;
    10901090  } /* decFloatRadix */
    10911091
     1092#if (DECCHECK || DECTRACE)
    10921093/* ------------------------------------------------------------------ */
    10931094/* decFloatShow -- printf a decFloat in hexadecimal and decimal       */
    10941095/*   df  is the decFloat to show                                      */
     
    11151116  printf(">%s> %s [big-endian]  %s\n", tag, hexbuf, buff);
    11161117  return;
    11171118  } /* decFloatShow */
     1119#endif
    11181120
    11191121/* ------------------------------------------------------------------ */
    11201122/* decFloatToBCD -- get sign, exponent, and BCD8 from a decFloat      */
  • libgfortran/intrinsics/dtime.c

    diff -Naur gcc-4.4.1.orig/libgfortran/intrinsics/dtime.c gcc-4.4.1/libgfortran/intrinsics/dtime.c
    old new  
    3838void
    3939dtime_sub (gfc_array_r4 *t, GFC_REAL_4 *result)
    4040{
    41   static GFC_REAL_4 tu = 0.0, ts = 0.0, tt = 0.0;
    4241  GFC_REAL_4 *tp;
    4342  long user_sec, user_usec, system_sec, system_usec;
     43  static long us = 0, uu = 0, ss = 0 , su = 0;
     44  GFC_REAL_4 tu, ts, tt;
    4445
    4546  if (((t->dim[0].ubound + 1 - t->dim[0].lbound)) < 2)
    4647    runtime_error ("Insufficient number of elements in TARRAY.");
     
    4849  __gthread_mutex_lock (&dtime_update_lock);
    4950  if (__time_1 (&user_sec, &user_usec, &system_sec, &system_usec) == 0)
    5051    {
    51       tu = (GFC_REAL_4)(user_sec + 1.e-6 * user_usec) - tu;
    52       ts = (GFC_REAL_4)(system_sec + 1.e-6 * system_usec) - ts;
     52      tu = (GFC_REAL_4) ((user_sec - us) + 1.e-6 * (user_usec - uu));
     53      ts = (GFC_REAL_4) ((system_sec - ss) + 1.e-6 * (system_usec - su));
    5354      tt = tu + ts;
     55      us = user_sec;
     56      uu = user_usec;
     57      ss = system_sec;
     58      su = system_usec;
    5459    }
    5560  else
    5661    {
    57       tu = (GFC_REAL_4)-1.0;
    58       ts = (GFC_REAL_4)-1.0;
    59       tt = (GFC_REAL_4)-1.0;
     62      tu = -1;
     63      ts = -1;
     64      tt = -1;
    6065    }
    6166
    6267  tp = t->data;
  • libgfortran/intrinsics/iso_c_binding.c

    diff -Naur gcc-4.4.1.orig/libgfortran/intrinsics/iso_c_binding.c gcc-4.4.1/libgfortran/intrinsics/iso_c_binding.c
    old new  
    137137      f_ptr_out->offset = f_ptr_out->dim[0].lbound * f_ptr_out->dim[0].stride;
    138138      for (i = 1; i < shapeSize; i++)
    139139        {
    140           f_ptr_out->dim[i].stride = (f_ptr_out->dim[i-1].ubound + 1)
    141             - f_ptr_out->dim[i-1].lbound;
     140          f_ptr_out->dim[i].stride = ((f_ptr_out->dim[i-1].ubound + 1)
     141            - f_ptr_out->dim[i-1].lbound) * f_ptr_out->dim[i-1].stride;
    142142          f_ptr_out->offset += f_ptr_out->dim[i].lbound
    143143            * f_ptr_out->dim[i].stride;
    144144        }
  • libgfortran/intrinsics/time_1.h

    diff -Naur gcc-4.4.1.orig/libgfortran/intrinsics/time_1.h gcc-4.4.1/libgfortran/intrinsics/time_1.h
    old new  
    5151#  endif
    5252#endif
    5353
     54#ifdef HAVE_SYS_TYPES_H
     55     #include <sys/types.h>
     56#endif
     57
    5458/* The most accurate way to get the CPU time is getrusage (). */
    5559#if defined (HAVE_GETRUSAGE) && defined (HAVE_SYS_RESOURCE_H)
    5660#  include <sys/resource.h>
     
    112116{
    113117#if defined (HAVE_GETRUSAGE) && defined (HAVE_SYS_RESOURCE_H)
    114118  struct rusage usage;
    115   getrusage (0, &usage);
     119  getrusage (RUSAGE_SELF, &usage);
    116120
    117121  *user_sec = usage.ru_utime.tv_sec;
    118122  *user_usec = usage.ru_utime.tv_usec;
  • libgfortran/io/list_read.c

    diff -Naur gcc-4.4.1.orig/libgfortran/io/list_read.c gcc-4.4.1/libgfortran/io/list_read.c
    old new  
    27722772
    27732773  if (nl->type == GFC_DTYPE_DERIVED)
    27742774    nml_touch_nodes (nl);
    2775   if (component_flag && nl->var_rank > 0)
     2775  if (component_flag && nl->var_rank > 0 && nl->next)
    27762776    nl = first_nl;
    27772777
    27782778  /* Make sure no extraneous qualifiers are there.  */
  • libgomp/omp_lib.h.in

    diff -Naur gcc-4.4.1.orig/libgomp/omp_lib.h.in gcc-4.4.1/libgomp/omp_lib.h.in
    old new  
    4242      external omp_set_num_threads
    4343
    4444      external omp_get_dynamic, omp_get_nested
    45       logical*4 omp_get_dynamic, omp_get_nested
     45      logical(4) omp_get_dynamic, omp_get_nested
    4646      external omp_test_lock, omp_in_parallel
    47       logical*4 omp_test_lock, omp_in_parallel
     47      logical(4) omp_test_lock, omp_in_parallel
    4848
    4949      external omp_get_max_threads, omp_get_num_procs
    50       integer*4 omp_get_max_threads, omp_get_num_procs
     50      integer(4) omp_get_max_threads, omp_get_num_procs
    5151      external omp_get_num_threads, omp_get_thread_num
    52       integer*4 omp_get_num_threads, omp_get_thread_num
     52      integer(4) omp_get_num_threads, omp_get_thread_num
    5353      external omp_test_nest_lock
    54       integer*4 omp_test_nest_lock
     54      integer(4) omp_test_nest_lock
    5555
    5656      external omp_get_wtick, omp_get_wtime
    5757      double precision omp_get_wtick, omp_get_wtime
     
    6161      external omp_get_max_active_levels, omp_get_level
    6262      external omp_get_ancestor_thread_num, omp_get_team_size
    6363      external omp_get_active_level
    64       integer*4 omp_get_thread_limit, omp_get_max_active_levels
    65       integer*4 omp_get_level, omp_get_ancestor_thread_num
    66       integer*4 omp_get_team_size, omp_get_active_level
     64      integer(4) omp_get_thread_limit, omp_get_max_active_levels
     65      integer(4) omp_get_level, omp_get_ancestor_thread_num
     66      integer(4) omp_get_team_size, omp_get_active_level
  • libjava/contrib/aotcompile.py.in

    diff -Naur gcc-4.4.1.orig/libjava/contrib/aotcompile.py.in gcc-4.4.1/libjava/contrib/aotcompile.py.in
    old new  
    1515
    1616import classfile
    1717import copy
    18 import md5
     18# The md5 module is deprecated in Python 2.5
     19try:
     20    from hashlib import md5
     21except ImportError:
     22    from md5 import md5
    1923import operator
    2024import os
    2125import sys
     
    182186    def addClass(self, bytes, name):
    183187        """Subclasses call this from their __init__ method for
    184188        every class they find."""
    185         digest = md5.new(bytes).digest()
     189        digest = md5(bytes).digest()
    186190        self.classes[digest] = bytes
    187191        self.classnames[digest] = name
    188192
  • libstdc++-v3/config/abi/pre/gnu.ver

    diff -Naur gcc-4.4.1.orig/libstdc++-v3/config/abi/pre/gnu.ver gcc-4.4.1/libstdc++-v3/config/abi/pre/gnu.ver
    old new  
    3232      std::a[e-z]*;
    3333#     std::ba[a-r]*;
    3434      std::basic_[a-e]*;
    35       std::basic_f[a-r]*;
     35      std::basic_f[a-h]*;
     36#     std::basic_filebuf;
     37      std::basic_f[j-r]*;
    3638#     std::basic_fstream;
    3739      std::basic_f[t-z]*;
    3840      std::basic_[g-h]*;
     
    273275    _ZNSdC*;
    274276    _ZNSdD*;
    275277
     278    # std::basic_filebuf
     279    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EEC*;
     280    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EED*;
     281    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE[0-3]*;
     282    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE4openEPKc*;
     283    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE4sync*;
     284    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE[5-9]*;
     285    _ZNKSt13basic_filebufI[cw]St11char_traitsI[cw]EE7is_openEv;
     286
    276287    # std::basic_fstream
    277     _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EEC*;
     288    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EEC[12]Ev;
     289    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EEC[12]EPKc*;
    278290    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EED*;
    279291    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE5closeEv;
    280292    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE7is_openEv;
    281     _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE4open*;
     293    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE4openEPKc*;
    282294    _ZNKSt13basic_fstreamI[cw]St11char_traitsI[cw]EE5rdbufEv;
    283295
    284296    # std::basic_ifstream
    285     _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EEC*;
     297    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EEC[12]Ev;
     298    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EEC[12]EPKc*;
    286299    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EED*;
    287300    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE5closeEv;
    288301    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE7is_openEv;
    289     _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE4open*;
     302    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE4openEPKc*;
    290303    _ZNKSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE5rdbufEv;
    291304
    292305    # std::basic_ofstream
    293     _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EEC*;
     306    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EEC[12]Ev;
     307    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EEC[12]EPKc*;
    294308    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EED*;
    295309    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE5closeEv;
    296310    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE7is_openEv;
    297     _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE4open*;
     311    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE4openEPKc*;
    298312    _ZNKSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE5rdbufEv;
    299313
    300314    # std::basic_istream<char>
     
    966980
    967981} GLIBCXX_3.4.11;
    968982
     983GLIBCXX_3.4.13 {
     984
     985    # new fstream members
     986    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE4openERKSsSt13_Ios_Openmode;
     987    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EEC[12]ERKSsSt13_Ios_Openmode;
     988    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE4openERKSsSt13_Ios_Openmode;
     989    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EEC[12]ERKSsSt13_Ios_Openmode;
     990    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE4openERKSsSt13_Ios_Openmode;
     991    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EEC[12]ERKSsSt13_Ios_Openmode;
     992    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE4openERKSsSt13_Ios_Openmode;
     993
     994} GLIBCXX_3.4.12;
     995
    969996# Symbols in the support library (libsupc++) have their own tag.
    970997CXXABI_1.3 {
    971998
  • libstdc++-v3/configure

    diff -Naur gcc-4.4.1.orig/libstdc++-v3/configure gcc-4.4.1/libstdc++-v3/configure
    old new  
    15671567### am handles this now?  ORIGINAL_LD_FOR_MULTILIBS=$LD
    15681568
    15691569# For libtool versioning info, format is CURRENT:REVISION:AGE
    1570 libtool_VERSION=6:12:0
     1570libtool_VERSION=6:13:0
    15711571
    15721572
    15731573# Find the rest of the source tree framework.
  • libstdc++-v3/configure.ac

    diff -Naur gcc-4.4.1.orig/libstdc++-v3/configure.ac gcc-4.4.1/libstdc++-v3/configure.ac
    old new  
    1212### am handles this now?  ORIGINAL_LD_FOR_MULTILIBS=$LD
    1313
    1414# For libtool versioning info, format is CURRENT:REVISION:AGE
    15 libtool_VERSION=6:12:0
     15libtool_VERSION=6:13:0
    1616AC_SUBST(libtool_VERSION)
    1717
    1818# Find the rest of the source tree framework.
  • libstdc++-v3/include/parallel/multiway_merge.h

    diff -Naur gcc-4.4.1.orig/libstdc++-v3/include/parallel/multiway_merge.h gcc-4.4.1/libstdc++-v3/include/parallel/multiway_merge.h
    old new  
    12241224                offsets[num_threads - 1].begin(),  comp);
    12251225        }
    12261226    }
    1227 
     1227  delete[] borders;
    12281228
    12291229  for (int slab = 0; slab < num_threads; ++slab)
    12301230    {
     
    13051305        std::iterator_traits<RandomAccessIterator1>::value_type value_type;
    13061306
    13071307      // Leave only non-empty sequences.
    1308       std::pair<RandomAccessIterator1, RandomAccessIterator1>* ne_seqs =
    1309         static_cast<std::pair<RandomAccessIterator1, RandomAccessIterator1>*>(
    1310         ::operator new(
    1311             sizeof(std::pair<RandomAccessIterator1, RandomAccessIterator1>)
    1312               * (seqs_end - seqs_begin)));
     1308      typedef std::pair<RandomAccessIterator1, RandomAccessIterator1> seq_type;
     1309      seq_type* ne_seqs = new seq_type[seqs_end - seqs_begin];
    13131310      int k = 0;
    13141311      difference_type total_length = 0;
    13151312      for (RandomAccessIteratorIterator raii = seqs_begin;
     
    13191316          if(seq_length > 0)
    13201317            {
    13211318              total_length += seq_length;
    1322               //ne_seqs[k] = *raii;
    1323               new(&(ne_seqs[k++]))
    1324                 std::pair<RandomAccessIterator1, RandomAccessIterator1>(*raii);
     1319              ne_seqs[k++] = *raii;
    13251320            }
    13261321        }
    13271322
     
    13311326
    13321327      if (total_length == 0 || k == 0)
    13331328      {
    1334         ::operator delete(ne_seqs);
     1329        delete[] ne_seqs;
    13351330        return target;
    13361331      }
    13371332
     
    13661361          for (int c = 0; c < k; ++c)
    13671362            target_position += pieces[iam][c].first;
    13681363
    1369           std::pair<RandomAccessIterator1, RandomAccessIterator1>* chunks
    1370             = new std::pair<RandomAccessIterator1, RandomAccessIterator1>[k];
     1364          seq_type* chunks = new seq_type[k];
    13711365
    13721366          for (int s = 0; s < k; ++s)
    13731367            {
     
    13991393        }
    14001394
    14011395      delete[] pieces;
     1396      delete[] ne_seqs;
    14021397
    14031398      return target + length;
    14041399    }
  • libstdc++-v3/include/std/valarray

    diff -Naur gcc-4.4.1.orig/libstdc++-v3/include/std/valarray gcc-4.4.1/libstdc++-v3/include/std/valarray
    old new  
    11// The template and inlines for the -*- C++ -*- valarray class.
    22
    33// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
    4 // 2006, 2007, 2009
     4// 2006, 2007, 2008, 2009
    55// Free Software Foundation, Inc.
    66//
    77// This file is part of the GNU ISO C++ Library.  This library is free
     
    647647  template<typename _Tp>
    648648    inline
    649649    valarray<_Tp>::valarray(initializer_list<_Tp> __l)
    650       : _M_size(__l.size()), _M_data(__valarray_get_storage<_Tp>(__l.size()))
     650    : _M_size(__l.size()), _M_data(__valarray_get_storage<_Tp>(__l.size()))
    651651    { std::__valarray_copy_construct (__l.begin(), __l.end(), _M_data); }
    652652#endif
    653653
     
    681681    {
    682682      _GLIBCXX_DEBUG_ASSERT(_M_size == __l.size());
    683683      std::__valarray_copy(__l.begin(), __l.size(), _M_data);
     684      return *this;
    684685    }
    685686#endif
    686687
  • libstdc++-v3/src/Makefile.am

    diff -Naur gcc-4.4.1.orig/libstdc++-v3/src/Makefile.am gcc-4.4.1/libstdc++-v3/src/Makefile.am
    old new  
    277277atomic.o: atomic.cc
    278278        $(CXXCOMPILE) -std=gnu++0x -c $<
    279279
     280fstream-inst.lo: fstream-inst.cc
     281        $(LTCXXCOMPILE) -std=gnu++0x -c $<
     282fstream-inst.o: fstream-inst.cc
     283        $(CXXCOMPILE) -std=gnu++0x -c $<
     284
    280285string-inst.lo: string-inst.cc
    281286        $(LTCXXCOMPILE) -std=gnu++0x -c $<
    282287string-inst.o: string-inst.cc
  • libstdc++-v3/src/Makefile.in

    diff -Naur gcc-4.4.1.orig/libstdc++-v3/src/Makefile.in gcc-4.4.1/libstdc++-v3/src/Makefile.in
    old new  
    888888atomic.o: atomic.cc
    889889        $(CXXCOMPILE) -std=gnu++0x -c $<
    890890
     891fstream-inst.lo: fstream-inst.cc
     892        $(LTCXXCOMPILE) -std=gnu++0x -c $<
     893fstream-inst.o: fstream-inst.cc
     894        $(CXXCOMPILE) -std=gnu++0x -c $<
     895
    891896string-inst.lo: string-inst.cc
    892897        $(LTCXXCOMPILE) -std=gnu++0x -c $<
    893898string-inst.o: string-inst.cc
  • libstdc++-v3/testsuite/util/testsuite_abi.cc

    diff -Naur gcc-4.4.1.orig/libstdc++-v3/testsuite/util/testsuite_abi.cc gcc-4.4.1/libstdc++-v3/testsuite/util/testsuite_abi.cc
    old new  
    184184      known_versions.push_back("GLIBCXX_3.4.10");
    185185      known_versions.push_back("GLIBCXX_3.4.11");
    186186      known_versions.push_back("GLIBCXX_3.4.12");
     187      known_versions.push_back("GLIBCXX_3.4.13");
    187188      known_versions.push_back("GLIBCXX_LDBL_3.4");
    188189      known_versions.push_back("GLIBCXX_LDBL_3.4.7");
    189190      known_versions.push_back("GLIBCXX_LDBL_3.4.10");
Note: See TracBrowser for help on using the repository browser.