source: patches/gcc-4.4.1-branch_update-4.patch @ 0cbb4b7

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

Updated GCC Patches

  • Property mode set to 100644
File size: 240.3 KB
RevLine 
[0cbb4b7]1Submitted By: Jim Gifford (jim at cross-lfs dot org)
2Date: 09-12-2009
3Initial Package Version: 4.4.1
4Origin: Upstream
5Upstream Status: Applied
6Description: This is a branch update for gcc-4.4.1, and should be
7             rechecked periodically.
8
9This patch was made from Revision # 151655.
10
11diff -Naur gcc-4.4.1.orig/contrib/compare-debug gcc-4.4.1/contrib/compare-debug
12--- gcc-4.4.1.orig/contrib/compare-debug        2007-11-25 22:40:31.000000000 -0800
13+++ gcc-4.4.1/contrib/compare-debug     2009-08-18 12:46:20.000000000 -0700
14@@ -2,7 +2,7 @@
15 
16 # Compare stripped copies of two given object files.
17 
18-# Copyright (C) 2007 Free Software Foundation
19+# Copyright (C) 2007, 2008, 2009 Free Software Foundation
20 # Originally by Alexandre Oliva <aoliva@redhat.com>
21 
22 # This file is part of GCC.
23@@ -67,6 +67,74 @@
24   status=0
25 else
26   status=1
27+
28+  # Assembler-generated CFI will add an .eh_frame section for -g not
29+  # present in -g0.  Try to cope with it by checking that an .eh_frame
30+  # section is present in either object file, and then stripping it
31+  # off before re-comparing.
32+
33+  cmd=
34+  cmp1=
35+  cmp2=
36+
37+  for t in objdump readelf eu-readelf; do
38+    if ($t --help) 2>&1 | grep -e '--\[*section-\]*headers' > /dev/null; then
39+      cmd=$t
40+
41+      $cmd --section-headers "$1.$suf1" | grep '\.eh_frame' > /dev/null
42+      cmp1=$?
43+
44+      $cmd --section-headers "$2.$suf2" | grep '\.eh_frame' > /dev/null
45+      cmp2=$?
46+
47+      break
48+    fi
49+  done
50+
51+  # If we found .eh_frame in one but not the other, or if we could not
52+  # find a command to tell, try to strip off the .eh_frame section
53+  # from both.
54+  if test "x$cmp1" != "x$cmp2" || test "x$cmd" = "x"; then
55+    suf3=$suf1.
56+    while test -f "$1.$suf3"; do
57+      suf3=$suf3.
58+    done
59+
60+    suf4=$suf2.
61+    while test -f "$2.$suf4"; do
62+      suf4=$suf4.
63+    done
64+
65+    trap 'rm -f "$1.$suf1" "$2.$suf2" "$1.$suf3" "$2.$suf4"' 0 1 2 15
66+
67+    echo stripping off .eh_frame, then retrying >&2
68+
69+    if (objcopy -v) 2>&1 | grep -e "--remove-section" > /dev/null; then
70+      objcopy --remove-section .eh_frame --remove-section .rel.eh_frame --remove-section .rela.eh_frame "$1.$suf1" "$1.$suf3"
71+      mv "$1.$suf3" "$1.$suf1"
72+
73+      objcopy --remove-section .eh_frame --remove-section .rel.eh_frame --remove-section .rela.eh_frame "$2.$suf2" "$2.$suf4"
74+      mv "$2.$suf4" "$2.$suf2"
75+    elif (strip --help) 2>&1 | grep -e --remove-section > /dev/null; then
76+      cp "$1.$suf1" "$1.$suf3"
77+      strip --remove-section .eh_frame --remove-section .rel.eh_frame --remove-section .rela.eh_frame "$1.$suf3"
78+      mv "$1.$suf3" "$1.$suf1"
79+
80+      cp "$2.$suf2" "$2.$suf4"
81+      strip --remove-section .eh_frame --remove-section .rel.eh_frame --remove-section .rela.eh_frame "$2.$suf4"
82+      mv "$2.$suf4" "$2.$suf2"
83+    else
84+      echo failed to strip off .eh_frame >&2
85+    fi
86+
87+    trap 'rm -f "$1.$suf1" "$2.$suf2"' 0 1 2 15
88+
89+    if cmp "$1.$suf1" "$2.$suf2"; then
90+      status=0
91+    else
92+      status=1
93+    fi
94+  fi
95 fi
96 
97 $rm "$1.$suf1" "$2.$suf2"
98diff -Naur gcc-4.4.1.orig/gcc/alias.c gcc-4.4.1/gcc/alias.c
99--- gcc-4.4.1.orig/gcc/alias.c  2009-04-27 04:55:13.000000000 -0700
100+++ gcc-4.4.1/gcc/alias.c       2009-08-12 23:28:28.000000000 -0700
101@@ -1932,6 +1932,9 @@
102 {
103   const_tree fieldx, fieldy, typex, typey, orig_y;
104 
105+  if (!flag_strict_aliasing)
106+    return false;
107+
108   do
109     {
110       /* The comparison has to be done at a common type, since we don't
111diff -Naur gcc-4.4.1.orig/gcc/builtins.c gcc-4.4.1/gcc/builtins.c
112--- gcc-4.4.1.orig/gcc/builtins.c       2009-05-29 08:47:31.000000000 -0700
113+++ gcc-4.4.1/gcc/builtins.c    2009-08-24 02:52:03.000000000 -0700
114@@ -8634,15 +8634,18 @@
115            }
116        }
117 
118-      /* Optimize pow(pow(x,y),z) = pow(x,y*z).  */
119+      /* Optimize pow(pow(x,y),z) = pow(x,y*z) iff x is nonnegative.  */
120       if (fcode == BUILT_IN_POW
121          || fcode == BUILT_IN_POWF
122          || fcode == BUILT_IN_POWL)
123        {
124          tree arg00 = CALL_EXPR_ARG (arg0, 0);
125-         tree arg01 = CALL_EXPR_ARG (arg0, 1);
126-         tree narg1 = fold_build2 (MULT_EXPR, type, arg01, arg1);
127-         return build_call_expr (fndecl, 2, arg00, narg1);
128+         if (tree_expr_nonnegative_p (arg00))
129+           {
130+             tree arg01 = CALL_EXPR_ARG (arg0, 1);
131+             tree narg1 = fold_build2 (MULT_EXPR, type, arg01, arg1);
132+             return build_call_expr (fndecl, 2, arg00, narg1);
133+           }
134        }
135     }
136 
137diff -Naur gcc-4.4.1.orig/gcc/config/alpha/alpha.c gcc-4.4.1/gcc/config/alpha/alpha.c
138--- gcc-4.4.1.orig/gcc/config/alpha/alpha.c     2009-03-17 13:18:21.000000000 -0700
139+++ gcc-4.4.1/gcc/config/alpha/alpha.c  2009-08-28 02:57:51.000000000 -0700
140@@ -2052,11 +2052,22 @@
141 
142   switch (GET_CODE (x))
143     {
144-    case CONST:
145     case LABEL_REF:
146     case HIGH:
147       return true;
148 
149+    case CONST:
150+      if (GET_CODE (XEXP (x, 0)) == PLUS
151+         && GET_CODE (XEXP (XEXP (x, 0), 1)) == CONST_INT)
152+       x = XEXP (XEXP (x, 0), 0);
153+      else
154+       return true;
155+
156+      if (GET_CODE (x) != SYMBOL_REF)
157+       return true;
158+
159+      /* FALLTHRU */
160+
161     case SYMBOL_REF:
162       /* TLS symbols are never valid.  */
163       return SYMBOL_REF_TLS_MODEL (x) == 0;
164@@ -3542,7 +3553,7 @@
165              emit_insn (gen_insll_le (insl, gen_lowpart (SImode, src), addr));
166              break;
167            case 8:
168-             emit_insn (gen_insql_le (insl, src, addr));
169+             emit_insn (gen_insql_le (insl, gen_lowpart (DImode, src), addr));
170              break;
171            }
172        }
173@@ -8279,7 +8290,7 @@
174   insn = get_last_insn ();
175   if (!INSN_P (insn))
176     insn = prev_active_insn (insn);
177-  if (GET_CODE (insn) == CALL_INSN)
178+  if (insn && GET_CODE (insn) == CALL_INSN)
179     output_asm_insn (get_insn_template (CODE_FOR_nop, NULL), NULL);
180 
181 #if TARGET_ABI_OSF
182diff -Naur gcc-4.4.1.orig/gcc/config/alpha/alpha.md gcc-4.4.1/gcc/config/alpha/alpha.md
183--- gcc-4.4.1.orig/gcc/config/alpha/alpha.md    2009-02-20 07:20:38.000000000 -0800
184+++ gcc-4.4.1/gcc/config/alpha/alpha.md 2009-08-28 02:57:51.000000000 -0700
185@@ -256,16 +256,7 @@
186        (sign_extend:DI (match_dup 1)))]
187   "")
188 
189-;; Don't say we have addsi3 if optimizing.  This generates better code.  We
190-;; have the anonymous addsi3 pattern below in case combine wants to make it.
191-(define_expand "addsi3"
192-  [(set (match_operand:SI 0 "register_operand" "")
193-       (plus:SI (match_operand:SI 1 "reg_or_0_operand" "")
194-                (match_operand:SI 2 "add_operand" "")))]
195-  "! optimize"
196-  "")
197-
198-(define_insn "*addsi_internal"
199+(define_insn "addsi3"
200   [(set (match_operand:SI 0 "register_operand" "=r,r,r,r")
201        (plus:SI (match_operand:SI 1 "reg_or_0_operand" "%rJ,rJ,rJ,rJ")
202                 (match_operand:SI 2 "add_operand" "rI,O,K,L")))]
203@@ -619,14 +610,7 @@
204   ""
205   "subqv $31,%1,%0")
206 
207-(define_expand "subsi3"
208-  [(set (match_operand:SI 0 "register_operand" "")
209-       (minus:SI (match_operand:SI 1 "reg_or_0_operand" "")
210-                 (match_operand:SI 2 "reg_or_8bit_operand" "")))]
211-  "! optimize"
212-  "")
213-
214-(define_insn "*subsi_internal"
215+(define_insn "subsi3"
216   [(set (match_operand:SI 0 "register_operand" "=r")
217        (minus:SI (match_operand:SI 1 "reg_or_0_operand" "rJ")
218                  (match_operand:SI 2 "reg_or_8bit_operand" "rI")))]
219@@ -3716,19 +3700,7 @@
220        (match_operator:DF 1 "alpha_fp_comparison_operator"
221                           [(match_operand:DF 2 "reg_or_0_operand" "fG")
222                            (match_operand:DF 3 "reg_or_0_operand" "fG")]))]
223-  "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
224-  "cmp%-%C1%/ %R2,%R3,%0"
225-  [(set_attr "type" "fadd")
226-   (set_attr "trap" "yes")
227-   (set_attr "trap_suffix" "su")])
228-
229-(define_insn "*cmpdf_ieee_ext1"
230-  [(set (match_operand:DF 0 "register_operand" "=&f")
231-       (match_operator:DF 1 "alpha_fp_comparison_operator"
232-                          [(float_extend:DF
233-                            (match_operand:SF 2 "reg_or_0_operand" "fG"))
234-                           (match_operand:DF 3 "reg_or_0_operand" "fG")]))]
235-  "TARGET_FP && alpha_fptm >= ALPHA_FPTM_SU"
236+  "TARGET_FP"
237   "cmp%-%C1%/ %R2,%R3,%0"
238   [(set_attr "type" "fadd")
239    (set_attr "trap" "yes")
240@@ -3746,18 +3718,6 @@
241    (set_attr "trap" "yes")
242    (set_attr "trap_suffix" "su")])
243 
244-(define_insn "*cmpdf_ieee_ext2"
245-  [(set (match_operand:DF 0 "register_operand" "=&f")
246-       (match_operator:DF 1 "alpha_fp_comparison_operator"
247-                          [(match_operand:DF 2 "reg_or_0_operand" "fG")
248-                           (float_extend:DF
249-                            (match_operand:SF 3 "reg_or_0_operand" "fG"))]))]
250-  "TARGET_FP && alpha_fptm >= ALPHA_FPTM_SU"
251-  "cmp%-%C1%/ %R2,%R3,%0"
252-  [(set_attr "type" "fadd")
253-   (set_attr "trap" "yes")
254-   (set_attr "trap_suffix" "su")])
255-
256 (define_insn "*cmpdf_ext2"
257   [(set (match_operand:DF 0 "register_operand" "=f")
258        (match_operator:DF 1 "alpha_fp_comparison_operator"
259@@ -3770,19 +3730,6 @@
260    (set_attr "trap" "yes")
261    (set_attr "trap_suffix" "su")])
262 
263-(define_insn "*cmpdf_ieee_ext3"
264-  [(set (match_operand:DF 0 "register_operand" "=&f")
265-       (match_operator:DF 1 "alpha_fp_comparison_operator"
266-                          [(float_extend:DF
267-                            (match_operand:SF 2 "reg_or_0_operand" "fG"))
268-                           (float_extend:DF
269-                            (match_operand:SF 3 "reg_or_0_operand" "fG"))]))]
270-  "TARGET_FP && alpha_fptm >= ALPHA_FPTM_SU"
271-  "cmp%-%C1%/ %R2,%R3,%0"
272-  [(set_attr "type" "fadd")
273-   (set_attr "trap" "yes")
274-   (set_attr "trap_suffix" "su")])
275-
276 (define_insn "*cmpdf_ext3"
277   [(set (match_operand:DF 0 "register_operand" "=f")
278        (match_operator:DF 1 "alpha_fp_comparison_operator"
279@@ -3832,7 +3779,7 @@
280                          (match_operand:DF 2 "const0_operand" "G,G")])
281         (float_extend:DF (match_operand:SF 1 "reg_or_0_operand" "fG,0"))
282         (match_operand:DF 5 "reg_or_0_operand" "0,fG")))]
283-  "TARGET_FP"
284+  "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
285   "@
286    fcmov%C3 %R4,%R1,%0
287    fcmov%D3 %R4,%R5,%0"
288@@ -3847,7 +3794,7 @@
289                          (match_operand:DF 2 "const0_operand" "G,G")])
290         (match_operand:DF 1 "reg_or_0_operand" "fG,0")
291         (match_operand:DF 5 "reg_or_0_operand" "0,fG")))]
292-  "TARGET_FP"
293+  "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
294   "@
295    fcmov%C3 %R4,%R1,%0
296    fcmov%D3 %R4,%R5,%0"
297@@ -3862,7 +3809,7 @@
298                          (match_operand:DF 2 "const0_operand" "G,G")])
299         (match_operand:SF 1 "reg_or_0_operand" "fG,0")
300         (match_operand:SF 5 "reg_or_0_operand" "0,fG")))]
301-  "TARGET_FP"
302+  "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
303   "@
304    fcmov%C3 %R4,%R1,%0
305    fcmov%D3 %R4,%R5,%0"
306@@ -3877,7 +3824,7 @@
307                          (match_operand:DF 2 "const0_operand" "G,G")])
308         (float_extend:DF (match_operand:SF 1 "reg_or_0_operand" "fG,0"))
309         (match_operand:DF 5 "reg_or_0_operand" "0,fG")))]
310-  "TARGET_FP"
311+  "TARGET_FP && alpha_fptm < ALPHA_FPTM_SU"
312   "@
313    fcmov%C3 %R4,%R1,%0
314    fcmov%D3 %R4,%R5,%0"
315diff -Naur gcc-4.4.1.orig/gcc/config/alpha/sync.md gcc-4.4.1/gcc/config/alpha/sync.md
316--- gcc-4.4.1.orig/gcc/config/alpha/sync.md     2009-02-20 07:20:38.000000000 -0800
317+++ gcc-4.4.1/gcc/config/alpha/sync.md  2009-08-28 02:57:51.000000000 -0700
318@@ -62,11 +62,8 @@
319   [(set_attr "type" "st_c")])
320 
321 ;; The Alpha Architecture Handbook says that it is UNPREDICTABLE whether
322-;; the lock is cleared by a TAKEN branch.  If we were to honor that, it
323-;; would mean that we could not expand a ll/sc sequence until after the
324-;; final basic-block reordering pass.  Fortunately, it appears that no
325-;; Alpha implementation ever built actually clears the lock on branches,
326-;; taken or not.
327+;; the lock is cleared by a TAKEN branch.  This means that we can not
328+;; expand a ll/sc sequence until after the final basic-block reordering pass.
329 
330 (define_insn_and_split "sync_<fetchop_name><mode>"
331   [(set (match_operand:I48MODE 0 "memory_operand" "+m")
332@@ -77,7 +74,7 @@
333    (clobber (match_scratch:I48MODE 2 "=&r"))]
334   ""
335   "#"
336-  "reload_completed"
337+  "epilogue_completed"
338   [(const_int 0)]
339 {
340   alpha_split_atomic_op (<CODE>, operands[0], operands[1],
341@@ -96,7 +93,7 @@
342    (clobber (match_scratch:I48MODE 2 "=&r"))]
343   ""
344   "#"
345-  "reload_completed"
346+  "epilogue_completed"
347   [(const_int 0)]
348 {
349   alpha_split_atomic_op (NOT, operands[0], operands[1],
350@@ -116,7 +113,7 @@
351    (clobber (match_scratch:I48MODE 3 "=&r"))]
352   ""
353   "#"
354-  "reload_completed"
355+  "epilogue_completed"
356   [(const_int 0)]
357 {
358   alpha_split_atomic_op (<CODE>, operands[1], operands[2],
359@@ -137,7 +134,7 @@
360    (clobber (match_scratch:I48MODE 3 "=&r"))]
361   ""
362   "#"
363-  "reload_completed"
364+  "epilogue_completed"
365   [(const_int 0)]
366 {
367   alpha_split_atomic_op (NOT, operands[1], operands[2],
368@@ -158,7 +155,7 @@
369    (clobber (match_scratch:I48MODE 3 "=&r"))]
370   ""
371   "#"
372-  "reload_completed"
373+  "epilogue_completed"
374   [(const_int 0)]
375 {
376   alpha_split_atomic_op (<CODE>, operands[1], operands[2],
377@@ -179,7 +176,7 @@
378    (clobber (match_scratch:I48MODE 3 "=&r"))]
379   ""
380   "#"
381-  "reload_completed"
382+  "epilogue_completed"
383   [(const_int 0)]
384 {
385   alpha_split_atomic_op (NOT, operands[1], operands[2],
386@@ -214,7 +211,7 @@
387    (clobber (match_scratch:DI 6 "=X,&r"))]
388   ""
389   "#"
390-  "reload_completed"
391+  "epilogue_completed"
392   [(const_int 0)]
393 {
394   alpha_split_compare_and_swap_12 (<MODE>mode, operands[0], operands[1],
395@@ -251,7 +248,7 @@
396    (clobber (match_scratch:I48MODE 4 "=&r"))]
397   ""
398   "#"
399-  "reload_completed"
400+  "epilogue_completed"
401   [(const_int 0)]
402 {
403   alpha_split_compare_and_swap (operands[0], operands[1], operands[2],
404@@ -282,7 +279,7 @@
405    (clobber (match_scratch:DI 4 "=&r"))]
406   ""
407   "#"
408-  "reload_completed"
409+  "epilogue_completed"
410   [(const_int 0)]
411 {
412   alpha_split_lock_test_and_set_12 (<MODE>mode, operands[0], operands[1],
413@@ -301,7 +298,7 @@
414    (clobber (match_scratch:I48MODE 3 "=&r"))]
415   ""
416   "#"
417-  "reload_completed"
418+  "epilogue_completed"
419   [(const_int 0)]
420 {
421   alpha_split_lock_test_and_set (operands[0], operands[1],
422diff -Naur gcc-4.4.1.orig/gcc/config/arm/arm.md gcc-4.4.1/gcc/config/arm/arm.md
423--- gcc-4.4.1.orig/gcc/config/arm/arm.md        2009-05-16 06:28:27.000000000 -0700
424+++ gcc-4.4.1/gcc/config/arm/arm.md     2009-08-05 09:11:25.000000000 -0700
425@@ -472,9 +472,9 @@
426   if (TARGET_THUMB1)
427     {
428       if (GET_CODE (operands[1]) != REG)
429-        operands[1] = force_reg (SImode, operands[1]);
430+        operands[1] = force_reg (DImode, operands[1]);
431       if (GET_CODE (operands[2]) != REG)
432-        operands[2] = force_reg (SImode, operands[2]);
433+        operands[2] = force_reg (DImode, operands[2]);
434      }
435   "
436 )
437diff -Naur gcc-4.4.1.orig/gcc/config/avr/avr.c gcc-4.4.1/gcc/config/avr/avr.c
438--- gcc-4.4.1.orig/gcc/config/avr/avr.c 2009-04-01 00:18:47.000000000 -0700
439+++ gcc-4.4.1/gcc/config/avr/avr.c      2009-08-25 12:03:53.000000000 -0700
440@@ -996,7 +996,7 @@
441              start_sequence ();
442 
443              emit_move_insn (myfp,
444-                             gen_rtx_PLUS (HImode, myfp,
445+                             gen_rtx_PLUS (GET_MODE (myfp), myfp,
446                                            gen_int_mode (size,
447                                                          GET_MODE(myfp))));
448 
449diff -Naur gcc-4.4.1.orig/gcc/config/i386/i386.c gcc-4.4.1/gcc/config/i386/i386.c
450--- gcc-4.4.1.orig/gcc/config/i386/i386.c       2009-07-21 00:22:51.000000000 -0700
451+++ gcc-4.4.1/gcc/config/i386/i386.c    2009-09-09 12:08:31.000000000 -0700
452@@ -7340,7 +7340,8 @@
453     return 0;
454 
455   ix86_compute_frame_layout (&frame);
456-  return frame.to_allocate == 0 && (frame.nregs + frame.nsseregs) == 0;
457+  return frame.to_allocate == 0 && frame.padding0 == 0
458+         && (frame.nregs + frame.nsseregs) == 0;
459 }
460 
461 /* Value should be nonzero if functions must have frame pointers.
462@@ -8328,7 +8329,7 @@
463          && (! TARGET_STACK_PROBE || allocate < CHECK_STACK_LIMIT)))
464     {
465       if (!frame_pointer_needed
466-         || !frame.to_allocate
467+         || !(frame.to_allocate + frame.padding0)
468          || crtl->stack_realign_needed)
469         ix86_emit_save_regs_using_mov (stack_pointer_rtx,
470                                       frame.to_allocate
471@@ -8338,7 +8339,7 @@
472                                       -frame.nregs * UNITS_PER_WORD);
473     }
474   if (!frame_pointer_needed
475-      || !frame.to_allocate
476+      || !(frame.to_allocate + frame.padding0)
477       || crtl->stack_realign_needed)
478     ix86_emit_save_sse_regs_using_mov (stack_pointer_rtx,
479                                       frame.to_allocate);
480@@ -8524,8 +8525,10 @@
481   if ((!sp_valid && (frame.nregs + frame.nsseregs) <= 1)
482       || (TARGET_EPILOGUE_USING_MOVE
483          && cfun->machine->use_fast_prologue_epilogue
484-         && ((frame.nregs + frame.nsseregs) > 1 || frame.to_allocate))
485-      || (frame_pointer_needed && !(frame.nregs + frame.nsseregs) && frame.to_allocate)
486+         && ((frame.nregs + frame.nsseregs) > 1
487+             || (frame.to_allocate + frame.padding0) != 0))
488+      || (frame_pointer_needed && !(frame.nregs + frame.nsseregs)
489+          && (frame.to_allocate + frame.padding0) != 0)
490       || (frame_pointer_needed && TARGET_USE_LEAVE
491          && cfun->machine->use_fast_prologue_epilogue
492          && (frame.nregs + frame.nsseregs) == 1)
493@@ -8535,13 +8538,13 @@
494         locations.  If both are available, default to ebp, since offsets
495         are known to be small.  Only exception is esp pointing directly
496         to the end of block of saved registers, where we may simplify
497-        addressing mode. 
498+        addressing mode.
499 
500         If we are realigning stack with bp and sp, regs restore can't
501         be addressed by bp. sp must be used instead.  */
502 
503       if (!frame_pointer_needed
504-         || (sp_valid && !frame.to_allocate)
505+         || (sp_valid && !(frame.to_allocate + frame.padding0))
506          || stack_realign_fp)
507        {
508          ix86_emit_restore_sse_regs_using_mov (stack_pointer_rtx,
509@@ -8630,9 +8633,10 @@
510           ix86_emit_restore_sse_regs_using_mov (stack_pointer_rtx,
511                                                frame.to_allocate, style == 2);
512          pro_epilogue_adjust_stack (stack_pointer_rtx, stack_pointer_rtx,
513-                                    GEN_INT (frame.nsseregs * 16), style);
514+                                    GEN_INT (frame.nsseregs * 16 +
515+                                      frame.padding0), style);
516        }
517-      else if (frame.to_allocate || frame.nsseregs)
518+      else if (frame.to_allocate || frame.padding0 || frame.nsseregs)
519        {
520           ix86_emit_restore_sse_regs_using_mov (stack_pointer_rtx,
521                                                frame.to_allocate,
522@@ -12090,16 +12094,18 @@
523 output_387_ffreep (rtx *operands ATTRIBUTE_UNUSED, int opno)
524 {
525   if (TARGET_USE_FFREEP)
526-#if HAVE_AS_IX86_FFREEP
527+#ifdef HAVE_AS_IX86_FFREEP
528     return opno ? "ffreep\t%y1" : "ffreep\t%y0";
529 #else
530     {
531-      static char retval[] = ".word\t0xc_df";
532+      static char retval[32];
533       int regno = REGNO (operands[opno]);
534 
535       gcc_assert (FP_REGNO_P (regno));
536 
537-      retval[9] = '0' + (regno - FIRST_STACK_REG);
538+      regno -= FIRST_STACK_REG;
539+
540+      snprintf (retval, sizeof (retval), ASM_SHORT "0xc%ddf", regno);
541       return retval;
542     }
543 #endif
544@@ -16307,10 +16313,20 @@
545   /* When emitting push, take care for source operands on the stack.  */
546   if (push && MEM_P (operands[1])
547       && reg_overlap_mentioned_p (stack_pointer_rtx, operands[1]))
548-    for (i = 0; i < nparts - 1; i++)
549-      part[1][i] = change_address (part[1][i],
550-                                  GET_MODE (part[1][i]),
551-                                  XEXP (part[1][i + 1], 0));
552+    {
553+      rtx src_base = XEXP (part[1][nparts - 1], 0);
554+
555+      /* Compensate for the stack decrement by 4.  */
556+      if (!TARGET_64BIT && nparts == 3
557+         && mode == XFmode && TARGET_128BIT_LONG_DOUBLE)
558+       src_base = plus_constant (src_base, 4);
559+
560+      /* src_base refers to the stack pointer and is
561+        automatically decreased by emitted push.  */
562+      for (i = 0; i < nparts; i++)
563+       part[1][i] = change_address (part[1][i],
564+                                    GET_MODE (part[1][i]), src_base);
565+    }
566 
567   /* We need to do copy in the right order in case an address register
568      of the source overlaps the destination.  */
569@@ -16380,7 +16396,8 @@
570          if (nparts == 3)
571            {
572              if (TARGET_128BIT_LONG_DOUBLE && mode == XFmode)
573-                emit_insn (gen_addsi3 (stack_pointer_rtx, stack_pointer_rtx, GEN_INT (-4)));
574+                emit_insn (gen_addsi3 (stack_pointer_rtx,
575+                                      stack_pointer_rtx, GEN_INT (-4)));
576              emit_move_insn (part[0][2], part[1][2]);
577            }
578          else if (nparts == 4)
579@@ -25306,7 +25323,7 @@
580 static tree
581 ix86_vectorize_builtin_conversion (unsigned int code, tree type)
582 {
583-  if (TREE_CODE (type) != VECTOR_TYPE
584+  if (!TARGET_SSE2 || TREE_CODE (type) != VECTOR_TYPE
585       /* There are only conversions from/to signed integers.  */
586       || TYPE_UNSIGNED (TREE_TYPE (type)))
587     return NULL_TREE;
588diff -Naur gcc-4.4.1.orig/gcc/config/i386/i386.md gcc-4.4.1/gcc/config/i386/i386.md
589--- gcc-4.4.1.orig/gcc/config/i386/i386.md      2009-07-08 09:59:15.000000000 -0700
590+++ gcc-4.4.1/gcc/config/i386/i386.md   2009-08-23 05:47:57.000000000 -0700
591@@ -14973,22 +14973,25 @@
592         (match_operand:SI 1 "" ""))
593    (set (reg:SI SP_REG) (plus:SI (reg:SI SP_REG)
594                            (match_operand:SI 2 "immediate_operand" "i")))]
595-  "!TARGET_64BIT"
596+  "!SIBLING_CALL_P (insn) && !TARGET_64BIT"
597 {
598   if (constant_call_address_operand (operands[0], Pmode))
599-    {
600-      if (SIBLING_CALL_P (insn))
601-       return "jmp\t%P0";
602-      else
603-       return "call\t%P0";
604-    }
605-  if (SIBLING_CALL_P (insn))
606-    return "jmp\t%A0";
607-  else
608-    return "call\t%A0";
609+    return "call\t%P0";
610+  return "call\t%A0";
611 }
612   [(set_attr "type" "call")])
613 
614+(define_insn "*sibcall_pop_1"
615+  [(call (mem:QI (match_operand:SI 0 "sibcall_insn_operand" "s,U"))
616+        (match_operand:SI 1 "" ""))
617+   (set (reg:SI SP_REG) (plus:SI (reg:SI SP_REG)
618+                           (match_operand:SI 2 "immediate_operand" "i,i")))]
619+  "SIBLING_CALL_P (insn) && !TARGET_64BIT"
620+  "@
621+   jmp\t%P0
622+   jmp\t%A0"
623+  [(set_attr "type" "call")])
624+
625 (define_expand "call"
626   [(call (match_operand:QI 0 "" "")
627         (match_operand 1 "" ""))
628@@ -15920,7 +15923,7 @@
629    (unspec:DI [(match_operand:DI 1 "tls_symbolic_operand" "")]
630              UNSPEC_TLS_GD)]
631   "TARGET_64BIT"
632-  ".byte\t0x66\;lea{q}\t{%a1@TLSGD(%%rip), %%rdi|rdi, %a1@TLSGD[rip]}\;.word\t0x6666\;rex64\;call\t%P2"
633+  { 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"; }
634   [(set_attr "type" "multi")
635    (set_attr "length" "16")])
636 
637@@ -21469,22 +21472,26 @@
638              (match_operand:SI 2 "" "")))
639    (set (reg:SI SP_REG) (plus:SI (reg:SI SP_REG)
640                            (match_operand:SI 3 "immediate_operand" "i")))]
641-  "!TARGET_64BIT"
642+  "!SIBLING_CALL_P (insn) && !TARGET_64BIT"
643 {
644   if (constant_call_address_operand (operands[1], Pmode))
645-    {
646-      if (SIBLING_CALL_P (insn))
647-       return "jmp\t%P1";
648-      else
649-       return "call\t%P1";
650-    }
651-  if (SIBLING_CALL_P (insn))
652-    return "jmp\t%A1";
653-  else
654-    return "call\t%A1";
655+    return "call\t%P1";
656+  return "call\t%A1";
657 }
658   [(set_attr "type" "callv")])
659 
660+(define_insn "*sibcall_value_pop_1"
661+  [(set (match_operand 0 "" "")
662+       (call (mem:QI (match_operand:SI 1 "sibcall_insn_operand" "s,U"))
663+             (match_operand:SI 2 "" "")))
664+   (set (reg:SI SP_REG) (plus:SI (reg:SI SP_REG)
665+                           (match_operand:SI 3 "immediate_operand" "i,i")))]
666+  "SIBLING_CALL_P (insn) && !TARGET_64BIT"
667+  "@
668+   jmp\t%P1
669+   jmp\t%A1"
670+  [(set_attr "type" "callv")])
671+
672 (define_insn "*call_value_0"
673   [(set (match_operand 0 "" "")
674        (call (mem:QI (match_operand:SI 1 "constant_call_address_operand" ""))
675diff -Naur gcc-4.4.1.orig/gcc/config/i386/netware.c gcc-4.4.1/gcc/config/i386/netware.c
676--- gcc-4.4.1.orig/gcc/config/i386/netware.c    2008-07-01 23:43:45.000000000 -0700
677+++ gcc-4.4.1/gcc/config/i386/netware.c 2009-08-28 08:40:31.000000000 -0700
678@@ -30,6 +30,7 @@
679 #include "flags.h"
680 #include "tm_p.h"
681 #include "toplev.h"
682+#include "langhooks.h"
683 #include "ggc.h"
684 
685 /* Return string which is the function name, identified by ID, modified
686@@ -179,16 +180,15 @@
687 {
688   default_encode_section_info (decl, rtl, first);
689 
690-  if (first
691-      && TREE_CODE (decl) == FUNCTION_DECL
692+  if (TREE_CODE (decl) == FUNCTION_DECL
693       /* Do not change the identifier if a verbatim asmspec
694         or if stdcall suffix already added.  */
695       && *IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl)) != '*'
696-      && !strchr (IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl)), '@'))
697+      && !strchr (IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl)), '@')
698+      /* FIXME:  Imported stdcall names are not modified by the Ada frontend.
699+        Check and decorate the RTL name now.  */
700+      && strcmp (lang_hooks.name, "GNU Ada") == 0)
701     {
702-      /* FIXME: In Ada, and perhaps other language frontends,
703-        imported stdcall names may not yet have been modified.
704-        Check and do it know.  */
705       rtx symbol = XEXP (rtl, 0);
706       tree new_id;
707       tree old_id = DECL_ASSEMBLER_NAME (decl);
708@@ -196,14 +196,7 @@
709       gcc_assert (GET_CODE (symbol) == SYMBOL_REF);
710 
711       if ((new_id = i386_nlm_maybe_mangle_decl_assembler_name (decl, old_id)))
712-       {
713-         /* These attributes must be present on first declaration,
714-            change_decl_assembler_name will warn if they are added
715-            later and the decl has been referenced, but duplicate_decls
716-            should catch the mismatch first.  */
717-         change_decl_assembler_name (decl, new_id);
718-         XSTR (symbol, 0) = IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl));
719-       }
720+       XSTR (symbol, 0) = IDENTIFIER_POINTER (new_id);
721     }
722 }
723 
724@@ -233,24 +226,3 @@
725     }
726   return name;
727 }
728-
729-/* Sometimes certain combinations of command options do not make
730-   sense on a particular target machine.  You can define a macro
731-   `OVERRIDE_OPTIONS' to take account of this.  This macro, if
732-   defined, is executed once just after all the command options have
733-   been parsed.
734-
735-   Don't use this macro to turn on various extra optimizations for
736-   `-O'.  That is what `OPTIMIZATION_OPTIONS' is for.  */
737-
738-void
739-netware_override_options (void)
740-{
741-  override_options ();
742-
743-  if (flag_pic)
744-    {
745-      error ("-fPIC and -fpic are not supported for this target");
746-      flag_pic = 0;
747-    }
748-}
749diff -Naur gcc-4.4.1.orig/gcc/config/i386/netware.h gcc-4.4.1/gcc/config/i386/netware.h
750--- gcc-4.4.1.orig/gcc/config/i386/netware.h    2009-02-20 07:20:38.000000000 -0800
751+++ gcc-4.4.1/gcc/config/i386/netware.h 2009-08-28 08:40:31.000000000 -0700
752@@ -72,17 +72,16 @@
753 #define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP | \
754        MASK_FLOAT_RETURNS | MASK_ALIGN_DOUBLE | MASK_MS_BITFIELD_LAYOUT)
755 
756-/* Sometimes certain combinations of command options do not make
757-   sense on a particular target machine.  You can define a macro
758-   `OVERRIDE_OPTIONS' to take account of this.  This macro, if
759-   defined, is executed once just after all the command options have
760-   been parsed.
761-
762-   Don't use this macro to turn on various extra optimizations for
763-   `-O'.  That is what `OPTIMIZATION_OPTIONS' is for.  */
764-#undef  OVERRIDE_OPTIONS
765-extern void netware_override_options (void);
766-#define OVERRIDE_OPTIONS netware_override_options ()
767+/* Don't allow flag_pic to propagate since invalid relocations will
768+   result otherwise.  */
769+#define SUBTARGET_OVERRIDE_OPTIONS                                     \
770+do {                                                                   \
771+  if (flag_pic)                                                                \
772+    {                                                                  \
773+      error ("-fPIC and -fpic are not supported for this target");     \
774+      flag_pic = 0;                                                    \
775+    }                                                                  \
776+} while (0)
777 
778 #undef MATH_LIBRARY
779 #define MATH_LIBRARY ""
780@@ -99,6 +98,9 @@
781 #undef KEEP_AGGREGATE_RETURN_POINTER
782 #define KEEP_AGGREGATE_RETURN_POINTER 1
783 
784+#undef ASM_COMMENT_START
785+#define ASM_COMMENT_START "#"
786+
787 #undef DBX_REGISTER_NUMBER
788 #define DBX_REGISTER_NUMBER(n) (svr4_dbx_register_map[n])
789 
790diff -Naur gcc-4.4.1.orig/gcc/config/i386/nwld.h gcc-4.4.1/gcc/config/i386/nwld.h
791--- gcc-4.4.1.orig/gcc/config/i386/nwld.h       2007-08-02 03:49:31.000000000 -0700
792+++ gcc-4.4.1/gcc/config/i386/nwld.h    2009-08-28 08:40:31.000000000 -0700
793@@ -55,6 +55,13 @@
794 #define TARGET_ASM_CONSTRUCTOR nwld_named_section_asm_out_constructor
795 #define TARGET_ASM_DESTRUCTOR  nwld_named_section_asm_out_destructor
796 
797+#define SUBSUBTARGET_OVERRIDE_OPTIONS                                  \
798+do {                                                                   \
799+  /* XXX This can be enabled once gas output meets nwld's needs. */    \
800+  /* if (!flag_unwind_tables && !flag_exceptions) */                   \
801+    flag_dwarf2_cfi_asm = 0;                                           \
802+} while (0)
803+
804 #undef  EH_FRAME_SECTION_NAME
805 #define EH_FRAME_SECTION_NAME ".eh_frame"TARGET_SUB_SECTION_SEPARATOR
806 
807diff -Naur gcc-4.4.1.orig/gcc/config/i386/sse.md gcc-4.4.1/gcc/config/i386/sse.md
808--- gcc-4.4.1.orig/gcc/config/i386/sse.md       2009-05-06 06:20:41.000000000 -0700
809+++ gcc-4.4.1/gcc/config/i386/sse.md    2009-08-16 12:34:49.000000000 -0700
810@@ -64,6 +64,10 @@
811 (define_mode_iterator SSEMODE4S [V4SF V4SI])
812 (define_mode_iterator SSEMODE2D [V2DF V2DI])
813 
814+;; Modes handled by integer vcond pattern
815+(define_mode_iterator SSEMODE124C8 [V16QI V8HI V4SI
816+                                   (V2DI "TARGET_SSE4_2 || TARGET_SSE5")])
817+
818 ;; Mapping from float mode to required SSE level
819 (define_mode_attr sse [(SF "sse") (DF "sse2") (V4SF "sse") (V2DF "sse2")])
820 
821@@ -1493,10 +1497,9 @@
822           (match_operand:SSEMODEF2P 2 "general_operand" "")))]
823   "SSE_VEC_FLOAT_MODE_P (<MODE>mode)"
824 {
825-  if (ix86_expand_fp_vcond (operands))
826-    DONE;
827-  else
828-    FAIL;
829+  bool ok = ix86_expand_fp_vcond (operands);
830+  gcc_assert (ok);
831+  DONE;
832 })
833 
834 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
835@@ -5837,35 +5840,33 @@
836    (set_attr "mode" "TI")])
837 
838 (define_expand "vcond<mode>"
839-  [(set (match_operand:SSEMODEI 0 "register_operand" "")
840-        (if_then_else:SSEMODEI
841+  [(set (match_operand:SSEMODE124C8 0 "register_operand" "")
842+        (if_then_else:SSEMODE124C8
843           (match_operator 3 ""
844-            [(match_operand:SSEMODEI 4 "nonimmediate_operand" "")
845-             (match_operand:SSEMODEI 5 "nonimmediate_operand" "")])
846-          (match_operand:SSEMODEI 1 "general_operand" "")
847-          (match_operand:SSEMODEI 2 "general_operand" "")))]
848+            [(match_operand:SSEMODE124C8 4 "nonimmediate_operand" "")
849+             (match_operand:SSEMODE124C8 5 "nonimmediate_operand" "")])
850+          (match_operand:SSEMODE124C8 1 "general_operand" "")
851+          (match_operand:SSEMODE124C8 2 "general_operand" "")))]
852   "TARGET_SSE2"
853 {
854-  if (ix86_expand_int_vcond (operands))
855-    DONE;
856-  else
857-    FAIL;
858+  bool ok = ix86_expand_int_vcond (operands);
859+  gcc_assert (ok);
860+  DONE;
861 })
862 
863 (define_expand "vcondu<mode>"
864-  [(set (match_operand:SSEMODEI 0 "register_operand" "")
865-        (if_then_else:SSEMODEI
866+  [(set (match_operand:SSEMODE124C8 0 "register_operand" "")
867+        (if_then_else:SSEMODE124C8
868           (match_operator 3 ""
869-            [(match_operand:SSEMODEI 4 "nonimmediate_operand" "")
870-             (match_operand:SSEMODEI 5 "nonimmediate_operand" "")])
871-          (match_operand:SSEMODEI 1 "general_operand" "")
872-          (match_operand:SSEMODEI 2 "general_operand" "")))]
873+            [(match_operand:SSEMODE124C8 4 "nonimmediate_operand" "")
874+             (match_operand:SSEMODE124C8 5 "nonimmediate_operand" "")])
875+          (match_operand:SSEMODE124C8 1 "general_operand" "")
876+          (match_operand:SSEMODE124C8 2 "general_operand" "")))]
877   "TARGET_SSE2"
878 {
879-  if (ix86_expand_int_vcond (operands))
880-    DONE;
881-  else
882-    FAIL;
883+  bool ok = ix86_expand_int_vcond (operands);
884+  gcc_assert (ok);
885+  DONE;
886 })
887 
888 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
889diff -Naur gcc-4.4.1.orig/gcc/config/pa/pa.c gcc-4.4.1/gcc/config/pa/pa.c
890--- gcc-4.4.1.orig/gcc/config/pa/pa.c   2009-02-20 07:20:38.000000000 -0800
891+++ gcc-4.4.1/gcc/config/pa/pa.c        2009-07-27 08:26:05.000000000 -0700
892@@ -2217,9 +2217,9 @@
893   else
894     {
895       /* Find the width of the bitstring in IMM.  */
896-      for (len = 5; len < 32; len++)
897+      for (len = 5; len < 32 - lsb; len++)
898        {
899-         if ((imm & (1 << len)) == 0)
900+         if ((imm & ((unsigned HOST_WIDE_INT) 1 << len)) == 0)
901            break;
902        }
903 
904@@ -2238,10 +2238,12 @@
905 void
906 compute_zdepdi_operands (unsigned HOST_WIDE_INT imm, unsigned *op)
907 {
908-  HOST_WIDE_INT lsb, len;
909+  int lsb, len, maxlen;
910+
911+  maxlen = MIN (HOST_BITS_PER_WIDE_INT, 64);
912 
913   /* Find the least significant set bit in IMM.  */
914-  for (lsb = 0; lsb < HOST_BITS_PER_WIDE_INT; lsb++)
915+  for (lsb = 0; lsb < maxlen; lsb++)
916     {
917       if ((imm & 1) != 0)
918         break;
919@@ -2250,17 +2252,20 @@
920 
921   /* Choose variants based on *sign* of the 5-bit field.  */
922   if ((imm & 0x10) == 0)
923-    len = ((lsb <= HOST_BITS_PER_WIDE_INT - 4)
924-          ? 4 : HOST_BITS_PER_WIDE_INT - lsb);
925+    len = (lsb <= maxlen - 4) ? 4 : maxlen - lsb;
926   else
927     {
928       /* Find the width of the bitstring in IMM.  */
929-      for (len = 5; len < HOST_BITS_PER_WIDE_INT; len++)
930+      for (len = 5; len < maxlen - lsb; len++)
931        {
932          if ((imm & ((unsigned HOST_WIDE_INT) 1 << len)) == 0)
933            break;
934        }
935 
936+      /* Extend length if host is narrow and IMM is negative.  */
937+      if (HOST_BITS_PER_WIDE_INT == 32 && len == maxlen - lsb)
938+       len += 32;
939+
940       /* Sign extend IMM as a 5-bit value.  */
941       imm = (imm & 0xf) - 0x10;
942     }
943diff -Naur gcc-4.4.1.orig/gcc/config/rs6000/freebsd.h gcc-4.4.1/gcc/config/rs6000/freebsd.h
944--- gcc-4.4.1.orig/gcc/config/rs6000/freebsd.h  2007-08-02 03:49:31.000000000 -0700
945+++ gcc-4.4.1/gcc/config/rs6000/freebsd.h       2009-08-10 11:22:22.000000000 -0700
946@@ -1,5 +1,5 @@
947 /* Definitions for PowerPC running FreeBSD using the ELF format
948-   Copyright (C) 2001, 2003, 2007 Free Software Foundation, Inc.
949+   Copyright (C) 2001, 2003, 2007, 2009 Free Software Foundation, Inc.
950    Contributed by David E. O'Brien <obrien@FreeBSD.org> and BSDi.
951 
952    This file is part of GCC.
953@@ -69,3 +69,6 @@
954 /* Override rs6000.h definition.  */
955 #undef  ASM_APP_OFF
956 #define ASM_APP_OFF "#NO_APP\n"
957+/* Define SVR4_ASM_SPEC, we use GAS by default. See svr4.h for details.  */
958+#define SVR4_ASM_SPEC \
959+  "%{v:-V} %{Wa,*:%*}"
960diff -Naur gcc-4.4.1.orig/gcc/config/rs6000/rs6000.c gcc-4.4.1/gcc/config/rs6000/rs6000.c
961--- gcc-4.4.1.orig/gcc/config/rs6000/rs6000.c   2009-03-17 13:18:21.000000000 -0700
962+++ gcc-4.4.1/gcc/config/rs6000/rs6000.c        2009-08-18 04:43:16.000000000 -0700
963@@ -3808,6 +3808,8 @@
964 rs6000_legitimize_address (rtx x, rtx oldx ATTRIBUTE_UNUSED,
965                           enum machine_mode mode)
966 {
967+  unsigned int extra = 0;
968+
969   if (GET_CODE (x) == SYMBOL_REF)
970     {
971       enum tls_model model = SYMBOL_REF_TLS_MODEL (x);
972@@ -3815,10 +3817,32 @@
973        return rs6000_legitimize_tls_address (x, model);
974     }
975 
976+  switch (mode)
977+    {
978+    case DFmode:
979+    case DDmode:
980+      extra = 4;
981+      break;
982+    case DImode:
983+      if (!TARGET_POWERPC64)
984+       extra = 4;
985+      break;
986+    case TFmode:
987+    case TDmode:
988+      extra = 12;
989+      break;
990+    case TImode:
991+      extra = TARGET_POWERPC64 ? 8 : 12;
992+      break;
993+    default:
994+      break;
995+    }
996+
997   if (GET_CODE (x) == PLUS
998       && GET_CODE (XEXP (x, 0)) == REG
999       && GET_CODE (XEXP (x, 1)) == CONST_INT
1000-      && (unsigned HOST_WIDE_INT) (INTVAL (XEXP (x, 1)) + 0x8000) >= 0x10000
1001+      && ((unsigned HOST_WIDE_INT) (INTVAL (XEXP (x, 1)) + 0x8000)
1002+         >= 0x10000 - extra)
1003       && !((TARGET_POWERPC64
1004            && (mode == DImode || mode == TImode)
1005            && (INTVAL (XEXP (x, 1)) & 3) != 0)
1006@@ -3831,10 +3855,12 @@
1007       HOST_WIDE_INT high_int, low_int;
1008       rtx sum;
1009       low_int = ((INTVAL (XEXP (x, 1)) & 0xffff) ^ 0x8000) - 0x8000;
1010+      if (low_int >= 0x8000 - extra)
1011+       low_int = 0;
1012       high_int = INTVAL (XEXP (x, 1)) - low_int;
1013       sum = force_operand (gen_rtx_PLUS (Pmode, XEXP (x, 0),
1014                                         GEN_INT (high_int)), 0);
1015-      return gen_rtx_PLUS (Pmode, sum, GEN_INT (low_int));
1016+      return plus_constant (sum, low_int);
1017     }
1018   else if (GET_CODE (x) == PLUS
1019           && GET_CODE (XEXP (x, 0)) == REG
1020diff -Naur gcc-4.4.1.orig/gcc/config/s390/2084.md gcc-4.4.1/gcc/config/s390/2084.md
1021--- gcc-4.4.1.orig/gcc/config/s390/2084.md      2009-02-20 07:20:38.000000000 -0800
1022+++ gcc-4.4.1/gcc/config/s390/2084.md   2009-09-04 03:05:45.000000000 -0700
1023@@ -163,17 +163,17 @@
1024 
1025 (define_insn_reservation "x_fsimptf" 7
1026   (and (eq_attr "cpu" "z990,z9_109")
1027-       (eq_attr "type" "fsimptf"))
1028+       (eq_attr "type" "fsimptf,fhex"))
1029   "x_e1_t*2,x-wr-fp")
1030 
1031 (define_insn_reservation "x_fsimpdf" 6
1032   (and (eq_attr "cpu" "z990,z9_109")
1033-       (eq_attr "type" "fsimpdf,fmuldf"))
1034+       (eq_attr "type" "fsimpdf,fmuldf,fhex"))
1035   "x_e1_t,x-wr-fp")
1036 
1037 (define_insn_reservation "x_fsimpsf" 6
1038   (and (eq_attr "cpu" "z990,z9_109")
1039-       (eq_attr "type" "fsimpsf,fmulsf"))
1040+       (eq_attr "type" "fsimpsf,fmulsf,fhex"))
1041   "x_e1_t,x-wr-fp")
1042 
1043 
1044diff -Naur gcc-4.4.1.orig/gcc/config/s390/2097.md gcc-4.4.1/gcc/config/s390/2097.md
1045--- gcc-4.4.1.orig/gcc/config/s390/2097.md      2008-08-15 00:36:40.000000000 -0700
1046+++ gcc-4.4.1/gcc/config/s390/2097.md   2009-09-04 03:05:45.000000000 -0700
1047@@ -463,29 +463,34 @@
1048 
1049 ; BFP multiplication and general instructions
1050 
1051-(define_insn_reservation "z10_fsimpdf" 12
1052+(define_insn_reservation "z10_fsimpdf" 6
1053   (and (eq_attr "cpu" "z10")
1054        (eq_attr "type" "fsimpdf,fmuldf"))
1055   "z10_e1_BOTH, z10_Gate_FP")
1056-; Wg "z10_e1_T, z10_Gate_FP")
1057 
1058-(define_insn_reservation "z10_fsimpsf" 12
1059+; LOAD ZERO produces a hex value but we need bin. Using the stage 7
1060+; bypass causes an exception for format conversion which is very
1061+; expensive. So, make sure subsequent instructions only get the zero
1062+; in the normal way.
1063+(define_insn_reservation "z10_fhex" 12
1064+  (and (eq_attr "cpu" "z10")
1065+       (eq_attr "type" "fhex"))
1066+  "z10_e1_BOTH, z10_Gate_FP")
1067+
1068+(define_insn_reservation "z10_fsimpsf" 6
1069   (and (eq_attr "cpu" "z10")
1070        (eq_attr "type" "fsimpsf,fmulsf"))
1071   "z10_e1_BOTH, z10_Gate_FP")
1072-; Wg "z10_e1_T, z10_Gate_FP")
1073 
1074 (define_insn_reservation "z10_fmultf" 52
1075   (and (eq_attr "cpu" "z10")
1076        (eq_attr "type" "fmultf"))
1077   "z10_e1_BOTH*4, z10_Gate_FP")
1078-; Wg  "z10_e1_T*4, z10_Gate_FP")
1079 
1080 (define_insn_reservation "z10_fsimptf" 14
1081   (and (eq_attr "cpu" "z10")
1082        (eq_attr "type" "fsimptf"))
1083   "z10_e1_BOTH*2, z10_Gate_FP")
1084-; Wg  "z10_e1_T*2, z10_Gate_FP")
1085 
1086 
1087 ; BFP division
1088@@ -531,12 +536,12 @@
1089        (eq_attr "type" "floadtf"))
1090   "z10_e1_T, z10_Gate_FP")
1091 
1092-(define_insn_reservation "z10_floaddf" 12
1093+(define_insn_reservation "z10_floaddf" 1
1094   (and (eq_attr "cpu" "z10")
1095        (eq_attr "type" "floaddf"))
1096   "z10_e1_T, z10_Gate_FP")
1097 
1098-(define_insn_reservation "z10_floadsf" 12
1099+(define_insn_reservation "z10_floadsf" 1
1100   (and (eq_attr "cpu" "z10")
1101        (eq_attr "type" "floadsf"))
1102   "z10_e1_T, z10_Gate_FP")
1103@@ -553,12 +558,12 @@
1104 
1105 
1106 ; BFP truncate
1107-(define_insn_reservation "z10_ftrunctf" 12
1108+(define_insn_reservation "z10_ftrunctf" 16
1109   (and (eq_attr "cpu" "z10")
1110        (eq_attr "type" "ftrunctf"))
1111   "z10_e1_T, z10_Gate_FP")
1112 
1113-(define_insn_reservation "z10_ftruncdf" 16
1114+(define_insn_reservation "z10_ftruncdf" 12
1115   (and (eq_attr "cpu" "z10")
1116        (eq_attr "type" "ftruncdf"))
1117   "z10_e1_T, z10_Gate_FP")
1118@@ -585,8 +590,8 @@
1119 ; BFP-related bypasses.  There is no bypass for extended mode.
1120 (define_bypass 1 "z10_fsimpdf" "z10_fstoredf")
1121 (define_bypass 1 "z10_fsimpsf" "z10_fstoresf")
1122-(define_bypass 1 "z10_floaddf" "z10_fsimpdf, z10_fstoredf, z10_floaddf")
1123-(define_bypass 1 "z10_floadsf" "z10_fsimpsf, z10_fstoresf, z10_floadsf")
1124+(define_bypass 1 "z10_floaddf" "z10_fsimpdf, z10_fstoredf")
1125+(define_bypass 1 "z10_floadsf" "z10_fsimpsf, z10_fstoresf")
1126 
1127 
1128 ;
1129diff -Naur gcc-4.4.1.orig/gcc/config/s390/constraints.md gcc-4.4.1/gcc/config/s390/constraints.md
1130--- gcc-4.4.1.orig/gcc/config/s390/constraints.md       2009-04-24 07:51:17.000000000 -0700
1131+++ gcc-4.4.1/gcc/config/s390/constraints.md    2009-07-30 05:32:19.000000000 -0700
1132@@ -66,9 +66,14 @@
1133 ;;    B -- Multiple letter constraint followed by Q, R, S, or T:
1134 ;;         Memory reference of the type specified by second letter that
1135 ;;         does *not* refer to a literal pool entry.
1136-;;    U -- Pointer with short displacement.
1137-;;    W -- Pointer with long displacement.
1138+;;    U -- Pointer with short displacement. (deprecated - use ZQZR)
1139+;;    W -- Pointer with long displacement. (deprecated - use ZSZT)
1140 ;;    Y -- Shift count operand.
1141+;;    ZQ -- Pointer without index register and with short displacement.
1142+;;    ZR -- Pointer with index register and short displacement.
1143+;;    ZS -- Pointer without index register but with long displacement.
1144+;;    ZT -- Pointer with index register and long displacement.
1145+;;
1146 ;;
1147 
1148 
1149@@ -462,11 +467,26 @@
1150 
1151 
1152 (define_address_constraint "U"
1153-  "Pointer with short displacement"
1154+  "Pointer with short displacement. (deprecated - use ZQZR)"
1155   (match_test "s390_mem_constraint (\"U\", op)"))
1156 
1157-
1158-
1159 (define_address_constraint "W"
1160-  "Pointer with long displacement"
1161+  "Pointer with long displacement. (deprecated - use ZSZT)"
1162   (match_test "s390_mem_constraint (\"W\", op)"))
1163+
1164+
1165+(define_address_constraint "ZQ"
1166+  "Pointer without index register and with short displacement."
1167+  (match_test "s390_mem_constraint (\"ZQ\", op)"))
1168+
1169+(define_address_constraint "ZR"
1170+  "Pointer with index register and short displacement."
1171+  (match_test "s390_mem_constraint (\"ZR\", op)"))
1172+
1173+(define_address_constraint "ZS"
1174+  "Pointer without index register but with long displacement."
1175+  (match_test "s390_mem_constraint (\"ZS\", op)"))
1176+
1177+(define_address_constraint "ZT"
1178+  "Pointer with index register and long displacement."
1179+  (match_test "s390_mem_constraint (\"ZT\", op)"))
1180diff -Naur gcc-4.4.1.orig/gcc/config/s390/s390.c gcc-4.4.1/gcc/config/s390/s390.c
1181--- gcc-4.4.1.orig/gcc/config/s390/s390.c       2009-02-27 06:56:19.000000000 -0800
1182+++ gcc-4.4.1/gcc/config/s390/s390.c    2009-09-04 03:05:45.000000000 -0700
1183@@ -52,6 +52,7 @@
1184 #include "optabs.h"
1185 #include "gimple.h"
1186 #include "df.h"
1187+#include "params.h"
1188 
1189 
1190 /* Define the specific costs for a given cpu.  */
1191@@ -204,13 +205,13 @@
1192   COSTS_N_INSNS (10),    /* MSGFR */
1193   COSTS_N_INSNS (10),    /* MSGR  */
1194   COSTS_N_INSNS (10),    /* MSR   */
1195-  COSTS_N_INSNS (10),    /* multiplication in DFmode */
1196+  COSTS_N_INSNS (1) ,    /* multiplication in DFmode */
1197   COSTS_N_INSNS (50),    /* MXBR */
1198   COSTS_N_INSNS (120),   /* SQXBR */
1199   COSTS_N_INSNS (52),    /* SQDBR */
1200   COSTS_N_INSNS (38),    /* SQEBR */
1201-  COSTS_N_INSNS (10),    /* MADBR */
1202-  COSTS_N_INSNS (10),    /* MAEBR */
1203+  COSTS_N_INSNS (1),     /* MADBR */
1204+  COSTS_N_INSNS (1),     /* MAEBR */
1205   COSTS_N_INSNS (111),   /* DXBR */
1206   COSTS_N_INSNS (39),    /* DDBR */
1207   COSTS_N_INSNS (32),    /* DEBR */
1208@@ -352,6 +353,10 @@
1209 #define REGNO_PAIR_OK(REGNO, MODE)                               \
1210   (HARD_REGNO_NREGS ((REGNO), (MODE)) == 1 || !((REGNO) & 1))
1211 
1212+/* That's the read ahead of the dynamic branch prediction unit in
1213+   bytes on a z10 CPU.  */
1214+#define Z10_PREDICT_DISTANCE 384
1215+
1216 static enum machine_mode
1217 s390_libgcc_cmp_return_mode (void)
1218 {
1219@@ -1641,6 +1646,10 @@
1220   if (!(target_flags_explicit & MASK_LONG_DOUBLE_128))
1221     target_flags |= MASK_LONG_DOUBLE_128;
1222 #endif
1223+
1224+  if (s390_tune == PROCESSOR_2097_Z10
1225+      && !PARAM_SET_P (PARAM_MAX_UNROLLED_INSNS))
1226+    set_param_value ("max-unrolled-insns", 100);
1227 }
1228 
1229 /* Map for smallest class containing reg regno.  */
1230@@ -1678,6 +1687,11 @@
1231   if (!disp)
1232     return true;
1233 
1234+  /* Without the long displacement facility we don't need to
1235+     distingiush between long and short displacement.  */
1236+  if (!TARGET_LONG_DISPLACEMENT)
1237+    return true;
1238+
1239   /* Integer displacement in range.  */
1240   if (GET_CODE (disp) == CONST_INT)
1241     return INTVAL (disp) >= 0 && INTVAL (disp) < 4096;
1242@@ -2046,79 +2060,93 @@
1243 }
1244 
1245 
1246-/* Evaluates constraint strings described by the regular expression
1247-   ([A|B](Q|R|S|T))|U|W and returns 1 if OP is a valid operand for the
1248-   constraint given in STR, or 0 else.  */
1249+/* Return true if ADDR is of kind symbol_ref or symbol_ref + const_int
1250+   and return these parts in SYMREF and ADDEND.  You can pass NULL in
1251+   SYMREF and/or ADDEND if you are not interested in these values.  */
1252 
1253-int
1254-s390_mem_constraint (const char *str, rtx op)
1255+static bool
1256+s390_symref_operand_p (rtx addr, rtx *symref, HOST_WIDE_INT *addend)
1257 {
1258-  struct s390_address addr;
1259-  char c = str[0];
1260+  HOST_WIDE_INT tmpaddend = 0;
1261 
1262-  /* Check for offsettable variants of memory constraints.  */
1263-  if (c == 'A')
1264+  if (GET_CODE (addr) == CONST)
1265+    addr = XEXP (addr, 0);
1266+
1267+  if (GET_CODE (addr) == PLUS)
1268     {
1269-      /* Only accept non-volatile MEMs.  */
1270-      if (!MEM_P (op) || MEM_VOLATILE_P (op))
1271-       return 0;
1272+      if (GET_CODE (XEXP (addr, 0)) == SYMBOL_REF
1273+         && CONST_INT_P (XEXP (addr, 1)))
1274+       {
1275+         tmpaddend = INTVAL (XEXP (addr, 1));
1276+         addr = XEXP (addr, 0);
1277+       }
1278+      else
1279+       return false;
1280+    }
1281+  else
1282+    if (GET_CODE (addr) != SYMBOL_REF)
1283+       return false;
1284 
1285-      if ((reload_completed || reload_in_progress)
1286-         ? !offsettable_memref_p (op) : !offsettable_nonstrict_memref_p (op))
1287-       return 0;
1288+  if (symref)
1289+    *symref = addr;
1290+  if (addend)
1291+    *addend = tmpaddend;
1292+
1293+  return true;
1294+}
1295 
1296-      c = str[1];
1297-    }
1298 
1299-  /* Check for non-literal-pool variants of memory constraints.  */
1300-  else if (c == 'B')
1301+/* Return true if the address in OP is valid for constraint letter C
1302+   if wrapped in a MEM rtx.  Set LIT_POOL_OK to true if it literal
1303+   pool MEMs should be accepted.  Only the Q, R, S, T constraint
1304+   letters are allowed for C.  */
1305+
1306+static int
1307+s390_check_qrst_address (char c, rtx op, bool lit_pool_ok)
1308+{
1309+  struct s390_address addr;
1310+  bool decomposed = false;
1311+
1312+  /* This check makes sure that no symbolic address (except literal
1313+     pool references) are accepted by the R or T constraints.  */
1314+  if (s390_symref_operand_p (op, NULL, NULL))
1315     {
1316-      if (GET_CODE (op) != MEM)
1317+      if (!lit_pool_ok)
1318        return 0;
1319-      if (!s390_decompose_address (XEXP (op, 0), &addr))
1320+      if (!s390_decompose_address (op, &addr))
1321        return 0;
1322-      if (addr.literal_pool)
1323+      if (!addr.literal_pool)
1324        return 0;
1325-
1326-      c = str[1];
1327+      decomposed = true;
1328     }
1329 
1330   switch (c)
1331     {
1332-    case 'Q':
1333-      if (GET_CODE (op) != MEM)
1334-       return 0;
1335-      if (!s390_decompose_address (XEXP (op, 0), &addr))
1336+    case 'Q': /* no index short displacement */
1337+      if (!decomposed && !s390_decompose_address (op, &addr))
1338        return 0;
1339       if (addr.indx)
1340        return 0;
1341-
1342-      if (TARGET_LONG_DISPLACEMENT)
1343-       {
1344-         if (!s390_short_displacement (addr.disp))
1345-           return 0;
1346-       }
1347-      break;
1348-
1349-    case 'R':
1350-      if (GET_CODE (op) != MEM)
1351+      if (!s390_short_displacement (addr.disp))
1352        return 0;
1353+      break;
1354 
1355+    case 'R': /* with index short displacement */
1356       if (TARGET_LONG_DISPLACEMENT)
1357        {
1358-         if (!s390_decompose_address (XEXP (op, 0), &addr))
1359+         if (!decomposed && !s390_decompose_address (op, &addr))
1360            return 0;
1361          if (!s390_short_displacement (addr.disp))
1362            return 0;
1363        }
1364+      /* Any invalid address here will be fixed up by reload,
1365+        so accept it for the most generic constraint.  */
1366       break;
1367 
1368-    case 'S':
1369+    case 'S': /* no index long displacement */
1370       if (!TARGET_LONG_DISPLACEMENT)
1371        return 0;
1372-      if (GET_CODE (op) != MEM)
1373-       return 0;
1374-      if (!s390_decompose_address (XEXP (op, 0), &addr))
1375+      if (!decomposed && !s390_decompose_address (op, &addr))
1376        return 0;
1377       if (addr.indx)
1378        return 0;
1379@@ -2126,52 +2154,74 @@
1380        return 0;
1381       break;
1382 
1383-    case 'T':
1384+    case 'T': /* with index long displacement */
1385       if (!TARGET_LONG_DISPLACEMENT)
1386        return 0;
1387-      if (GET_CODE (op) != MEM)
1388-       return 0;
1389-      if (!s390_decompose_address (XEXP (op, 0), &addr))
1390-       return 0;
1391-      if (s390_short_displacement (addr.disp))
1392+      /* Any invalid address here will be fixed up by reload,
1393+        so accept it for the most generic constraint.  */
1394+      if ((decomposed || s390_decompose_address (op, &addr))
1395+         && s390_short_displacement (addr.disp))
1396        return 0;
1397       break;
1398+    default:
1399+      return 0;
1400+    }
1401+  return 1;
1402+}
1403 
1404-    case 'U':
1405-      if (TARGET_LONG_DISPLACEMENT)
1406-       {
1407-         if (!s390_decompose_address (op, &addr))
1408-           return 0;
1409-         if (!s390_short_displacement (addr.disp))
1410-           return 0;
1411-       }
1412-      break;
1413 
1414-    case 'W':
1415-      if (!TARGET_LONG_DISPLACEMENT)
1416+/* Evaluates constraint strings described by the regular expression
1417+   ([A|B|Z](Q|R|S|T))|U|W|Y and returns 1 if OP is a valid operand for
1418+   the constraint given in STR, or 0 else.  */
1419+
1420+int
1421+s390_mem_constraint (const char *str, rtx op)
1422+{
1423+  char c = str[0];
1424+
1425+  switch (c)
1426+    {
1427+    case 'A':
1428+      /* Check for offsettable variants of memory constraints.  */
1429+      if (!MEM_P (op) || MEM_VOLATILE_P (op))
1430        return 0;
1431-      if (!s390_decompose_address (op, &addr))
1432+      if ((reload_completed || reload_in_progress)
1433+         ? !offsettable_memref_p (op) : !offsettable_nonstrict_memref_p (op))
1434        return 0;
1435-      if (s390_short_displacement (addr.disp))
1436+      return s390_check_qrst_address (str[1], XEXP (op, 0), true);
1437+    case 'B':
1438+      /* Check for non-literal-pool variants of memory constraints.  */
1439+      if (!MEM_P (op))
1440        return 0;
1441-      break;
1442-
1443+      return s390_check_qrst_address (str[1], XEXP (op, 0), false);
1444+    case 'Q':
1445+    case 'R':
1446+    case 'S':
1447+    case 'T':
1448+      if (GET_CODE (op) != MEM)
1449+       return 0;
1450+      return s390_check_qrst_address (c, XEXP (op, 0), true);
1451+    case 'U':
1452+      return (s390_check_qrst_address ('Q', op, true)
1453+             || s390_check_qrst_address ('R', op, true));
1454+    case 'W':
1455+      return (s390_check_qrst_address ('S', op, true)
1456+             || s390_check_qrst_address ('T', op, true));
1457     case 'Y':
1458       /* Simply check for the basic form of a shift count.  Reload will
1459         take care of making sure we have a proper base register.  */
1460       if (!s390_decompose_shift_count (op, NULL, NULL))
1461        return 0;
1462       break;
1463-
1464+    case 'Z':
1465+      return s390_check_qrst_address (str[1], op, true);
1466     default:
1467       return 0;
1468     }
1469-
1470   return 1;
1471 }
1472 
1473 
1474-
1475 /* Evaluates constraint strings starting with letter O.  Input
1476    parameter C is the second letter following the "O" in the constraint
1477    string. Returns 1 if VALUE meets the respective constraint and 0
1478@@ -2789,41 +2839,6 @@
1479   return rclass;
1480 }
1481 
1482-/* Return true if ADDR is of kind symbol_ref or symbol_ref + const_int
1483-   and return these parts in SYMREF and ADDEND.  You can pass NULL in
1484-   SYMREF and/or ADDEND if you are not interested in these values.  */
1485-
1486-static bool
1487-s390_symref_operand_p (rtx addr, rtx *symref, HOST_WIDE_INT *addend)
1488-{
1489-  HOST_WIDE_INT tmpaddend = 0;
1490-
1491-  if (GET_CODE (addr) == CONST)
1492-    addr = XEXP (addr, 0);
1493-
1494-  if (GET_CODE (addr) == PLUS)
1495-    {
1496-      if (GET_CODE (XEXP (addr, 0)) == SYMBOL_REF
1497-         && CONST_INT_P (XEXP (addr, 1)))
1498-       {
1499-         tmpaddend = INTVAL (XEXP (addr, 1));
1500-         addr = XEXP (addr, 0);
1501-       }
1502-      else
1503-       return false;
1504-    }
1505-  else
1506-    if (GET_CODE (addr) != SYMBOL_REF)
1507-       return false;
1508-
1509-  if (symref)
1510-    *symref = addr;
1511-  if (addend)
1512-    *addend = tmpaddend;
1513-
1514-  return true;
1515-}
1516-
1517 /* Return true if ADDR is SYMBOL_REF + addend with addend being a
1518    multiple of ALIGNMENT and the SYMBOL_REF being naturally
1519    aligned.  */
1520@@ -5276,6 +5291,7 @@
1521    A STD instruction should be scheduled earlier,
1522    in order to use the bypass.  */
1523 
1524+
1525 static int
1526 s390_adjust_priority (rtx insn ATTRIBUTE_UNUSED, int priority)
1527 {
1528@@ -5283,7 +5299,8 @@
1529     return priority;
1530 
1531   if (s390_tune != PROCESSOR_2084_Z990
1532-      && s390_tune != PROCESSOR_2094_Z9_109)
1533+      && s390_tune != PROCESSOR_2094_Z9_109
1534+      && s390_tune != PROCESSOR_2097_Z10)
1535     return priority;
1536 
1537   switch (s390_safe_attr_type (insn))
1538@@ -5302,6 +5319,7 @@
1539   return priority;
1540 }
1541 
1542+
1543 /* The number of instructions that can be issued per cycle.  */
1544 
1545 static int
1546@@ -9589,6 +9607,66 @@
1547     }
1548 }
1549 
1550+/* On z10 the dynamic branch prediction must see the backward jump in
1551+   a window of 384 bytes. If not it falls back to the static
1552+   prediction.  This function rearranges the loop backward branch in a
1553+   way which makes the static prediction always correct.  The function
1554+   returns true if it added an instruction.  */
1555+static bool
1556+s390_z10_fix_long_loop_prediction (rtx insn)
1557+{
1558+  rtx set = single_set (insn);
1559+  rtx code_label, label_ref, new_label;
1560+  rtx uncond_jump;
1561+  rtx cur_insn;
1562+  rtx tmp;
1563+  int distance;
1564+
1565+  /* This will exclude branch on count and branch on index patterns
1566+     since these are correctly statically predicted.  */
1567+  if (!set
1568+      || SET_DEST (set) != pc_rtx
1569+      || GET_CODE (SET_SRC(set)) != IF_THEN_ELSE)
1570+    return false;
1571+
1572+  label_ref = (GET_CODE (XEXP (SET_SRC (set), 1)) == LABEL_REF ?
1573+              XEXP (SET_SRC (set), 1) : XEXP (SET_SRC (set), 2));
1574+
1575+  gcc_assert (GET_CODE (label_ref) == LABEL_REF);
1576+
1577+  code_label = XEXP (label_ref, 0);
1578+
1579+  if (INSN_ADDRESSES (INSN_UID (code_label)) == -1
1580+      || INSN_ADDRESSES (INSN_UID (insn)) == -1
1581+      || (INSN_ADDRESSES (INSN_UID (insn))
1582+         - INSN_ADDRESSES (INSN_UID (code_label)) < Z10_PREDICT_DISTANCE))
1583+    return false;
1584+
1585+  for (distance = 0, cur_insn = PREV_INSN (insn);
1586+       distance < Z10_PREDICT_DISTANCE - 6;
1587+       distance += get_attr_length (cur_insn), cur_insn = PREV_INSN (cur_insn))
1588+    if (!cur_insn || JUMP_P (cur_insn) || LABEL_P (cur_insn))
1589+      return false;
1590+
1591+  new_label = gen_label_rtx ();
1592+  uncond_jump = emit_jump_insn_after (
1593+                 gen_rtx_SET (VOIDmode, pc_rtx,
1594+                              gen_rtx_LABEL_REF (VOIDmode, code_label)),
1595+                 insn);
1596+  emit_label_after (new_label, uncond_jump);
1597+
1598+  tmp = XEXP (SET_SRC (set), 1);
1599+  XEXP (SET_SRC (set), 1) = XEXP (SET_SRC (set), 2);
1600+  XEXP (SET_SRC (set), 2) = tmp;
1601+  INSN_CODE (insn) = -1;
1602+
1603+  XEXP (label_ref, 0) = new_label;
1604+  JUMP_LABEL (insn) = new_label;
1605+  JUMP_LABEL (uncond_jump) = code_label;
1606+
1607+  return true;
1608+}
1609+
1610 /* Returns 1 if INSN reads the value of REG for purposes not related
1611    to addressing of memory, and 0 otherwise.  */
1612 static int
1613@@ -9671,97 +9749,87 @@
1614    if that register's value is delivered via a bypass, then the
1615    pipeline recycles, thereby causing significant performance decline.
1616    This function locates such situations and exchanges the two
1617-   operands of the compare.  */
1618-static void
1619-s390_z10_optimize_cmp (void)
1620+   operands of the compare.  The function return true whenever it
1621+   added an insn.  */
1622+static bool
1623+s390_z10_optimize_cmp (rtx insn)
1624 {
1625-  rtx insn, prev_insn, next_insn;
1626-  int added_NOPs = 0;
1627+  rtx prev_insn, next_insn;
1628+  bool insn_added_p = false;
1629+  rtx cond, *op0, *op1;
1630 
1631-  for (insn = get_insns (); insn; insn = NEXT_INSN (insn))
1632+  if (GET_CODE (PATTERN (insn)) == PARALLEL)
1633     {
1634-      rtx cond, *op0, *op1;
1635-
1636-      if (!INSN_P (insn) || INSN_CODE (insn) <= 0)
1637-       continue;
1638-
1639-      if (GET_CODE (PATTERN (insn)) == PARALLEL)
1640-       {
1641-         /* Handle compare and branch and branch on count
1642-            instructions.  */
1643-         rtx pattern = single_set (insn);
1644-
1645-         if (!pattern
1646-             || SET_DEST (pattern) != pc_rtx
1647-             || GET_CODE (SET_SRC (pattern)) != IF_THEN_ELSE)
1648-           continue;
1649+      /* Handle compare and branch and branch on count
1650+        instructions.  */
1651+      rtx pattern = single_set (insn);
1652+
1653+      if (!pattern
1654+         || SET_DEST (pattern) != pc_rtx
1655+         || GET_CODE (SET_SRC (pattern)) != IF_THEN_ELSE)
1656+       return false;
1657 
1658-         cond = XEXP (SET_SRC (pattern), 0);
1659-         op0 = &XEXP (cond, 0);
1660-         op1 = &XEXP (cond, 1);
1661-       }
1662-      else if (GET_CODE (PATTERN (insn)) == SET)
1663-       {
1664-         rtx src, dest;
1665+      cond = XEXP (SET_SRC (pattern), 0);
1666+      op0 = &XEXP (cond, 0);
1667+      op1 = &XEXP (cond, 1);
1668+    }
1669+  else if (GET_CODE (PATTERN (insn)) == SET)
1670+    {
1671+      rtx src, dest;
1672 
1673-         /* Handle normal compare instructions.  */
1674-         src = SET_SRC (PATTERN (insn));
1675-         dest = SET_DEST (PATTERN (insn));
1676+      /* Handle normal compare instructions.  */
1677+      src = SET_SRC (PATTERN (insn));
1678+      dest = SET_DEST (PATTERN (insn));
1679 
1680-         if (!REG_P (dest)
1681-             || !CC_REGNO_P (REGNO (dest))
1682-             || GET_CODE (src) != COMPARE)
1683-           continue;
1684+      if (!REG_P (dest)
1685+         || !CC_REGNO_P (REGNO (dest))
1686+         || GET_CODE (src) != COMPARE)
1687+       return false;
1688 
1689-         /* s390_swap_cmp will try to find the conditional
1690-            jump when passing NULL_RTX as condition.  */
1691-         cond = NULL_RTX;
1692-         op0 = &XEXP (src, 0);
1693-         op1 = &XEXP (src, 1);
1694-       }
1695-      else
1696-       continue;
1697+      /* s390_swap_cmp will try to find the conditional
1698+        jump when passing NULL_RTX as condition.  */
1699+      cond = NULL_RTX;
1700+      op0 = &XEXP (src, 0);
1701+      op1 = &XEXP (src, 1);
1702+    }
1703+  else
1704+    return false;
1705 
1706-      if (!REG_P (*op0) || !REG_P (*op1))
1707-       continue;
1708+  if (!REG_P (*op0) || !REG_P (*op1))
1709+    return false;
1710 
1711-      /* Swap the COMPARE arguments and its mask if there is a
1712-        conflicting access in the previous insn.  */
1713-      prev_insn = PREV_INSN (insn);
1714+  /* Swap the COMPARE arguments and its mask if there is a
1715+     conflicting access in the previous insn.  */
1716+  prev_insn = PREV_INSN (insn);
1717+  if (prev_insn != NULL_RTX && INSN_P (prev_insn)
1718+      && reg_referenced_p (*op1, PATTERN (prev_insn)))
1719+    s390_swap_cmp (cond, op0, op1, insn);
1720+
1721+  /* Check if there is a conflict with the next insn. If there
1722+     was no conflict with the previous insn, then swap the
1723+     COMPARE arguments and its mask.  If we already swapped
1724+     the operands, or if swapping them would cause a conflict
1725+     with the previous insn, issue a NOP after the COMPARE in
1726+     order to separate the two instuctions.  */
1727+  next_insn = NEXT_INSN (insn);
1728+  if (next_insn != NULL_RTX && INSN_P (next_insn)
1729+      && s390_non_addr_reg_read_p (*op1, next_insn))
1730+    {
1731       if (prev_insn != NULL_RTX && INSN_P (prev_insn)
1732-         && reg_referenced_p (*op1, PATTERN (prev_insn)))
1733-       s390_swap_cmp (cond, op0, op1, insn);
1734-
1735-      /* Check if there is a conflict with the next insn. If there
1736-        was no conflict with the previous insn, then swap the
1737-        COMPARE arguments and its mask.  If we already swapped
1738-        the operands, or if swapping them would cause a conflict
1739-        with the previous insn, issue a NOP after the COMPARE in
1740-        order to separate the two instuctions.  */
1741-      next_insn = NEXT_INSN (insn);
1742-      if (next_insn != NULL_RTX && INSN_P (next_insn)
1743-         && s390_non_addr_reg_read_p (*op1, next_insn))
1744+         && s390_non_addr_reg_read_p (*op0, prev_insn))
1745        {
1746-         if (prev_insn != NULL_RTX && INSN_P (prev_insn)
1747-             && s390_non_addr_reg_read_p (*op0, prev_insn))
1748-           {
1749-             if (REGNO (*op1) == 0)
1750-               emit_insn_after (gen_nop1 (), insn);
1751-             else
1752-               emit_insn_after (gen_nop (), insn);
1753-             added_NOPs = 1;
1754-           }
1755+         if (REGNO (*op1) == 0)
1756+           emit_insn_after (gen_nop1 (), insn);
1757          else
1758-           s390_swap_cmp (cond, op0, op1, insn);
1759+           emit_insn_after (gen_nop (), insn);
1760+         insn_added_p = true;
1761        }
1762+      else
1763+       s390_swap_cmp (cond, op0, op1, insn);
1764     }
1765-
1766-  /* Adjust branches if we added new instructions.  */
1767-  if (added_NOPs)
1768-    shorten_branches (get_insns ());
1769+  return insn_added_p;
1770 }
1771 
1772-
1773 /* Perform machine-dependent processing.  */
1774 
1775 static void
1776@@ -9872,10 +9940,33 @@
1777   /* Try to optimize prologue and epilogue further.  */
1778   s390_optimize_prologue ();
1779 
1780-  /* Eliminate z10-specific pipeline recycles related to some compare
1781-     instructions.  */
1782+  /* Walk over the insns and do some z10 specific changes.  */
1783   if (s390_tune == PROCESSOR_2097_Z10)
1784-    s390_z10_optimize_cmp ();
1785+    {
1786+      rtx insn;
1787+      bool insn_added_p = false;
1788+
1789+      /* The insn lengths and addresses have to be up to date for the
1790+        following manipulations.  */
1791+      shorten_branches (get_insns ());
1792+
1793+      for (insn = get_insns (); insn; insn = NEXT_INSN (insn))
1794+       {
1795+         if (!INSN_P (insn) || INSN_CODE (insn) <= 0)
1796+           continue;
1797+
1798+         if (JUMP_P (insn))
1799+           insn_added_p |= s390_z10_fix_long_loop_prediction (insn);
1800+
1801+         if (GET_CODE (PATTERN (insn)) == PARALLEL
1802+             || GET_CODE (PATTERN (insn)) == SET)
1803+           insn_added_p |= s390_z10_optimize_cmp (insn);
1804+       }
1805+
1806+      /* Adjust branches if we added new instructions.  */
1807+      if (insn_added_p)
1808+       shorten_branches (get_insns ());
1809+    }
1810 }
1811 
1812 
1813diff -Naur gcc-4.4.1.orig/gcc/config/s390/s390.md gcc-4.4.1/gcc/config/s390/s390.md
1814--- gcc-4.4.1.orig/gcc/config/s390/s390.md      2009-06-15 02:27:22.000000000 -0700
1815+++ gcc-4.4.1/gcc/config/s390/s390.md   2009-09-04 03:05:45.000000000 -0700
1816@@ -202,7 +202,7 @@
1817 (define_attr "type" "none,integer,load,lr,la,larl,lm,stm,
1818                     cs,vs,store,sem,idiv,
1819                      imulhi,imulsi,imuldi,
1820-                    branch,jsr,fsimptf,fsimpdf,fsimpsf,
1821+                    branch,jsr,fsimptf,fsimpdf,fsimpsf,fhex,
1822                     floadtf,floaddf,floadsf,fstoredf,fstoresf,
1823                     fmultf,fmuldf,fmulsf,fdivtf,fdivdf,fdivsf,
1824                     ftoi,fsqrttf,fsqrtdf,fsqrtsf,
1825@@ -1076,6 +1076,64 @@
1826                       (const_int 6) (const_int 12)))]) ; 8 byte for clr/jg
1827                                                        ; 10 byte for clgr/jg
1828 
1829+; And now the same two patterns as above but with a negated CC mask.
1830+
1831+; cij, cgij, crj, cgrj, cfi, cgfi, cr, cgr
1832+; The following instructions do a complementary access of their second
1833+; operand (z01 only): crj_c, cgrjc, cr, cgr
1834+(define_insn "*icmp_and_br_signed_<mode>"
1835+  [(set (pc)
1836+       (if_then_else (match_operator 0 "s390_signed_integer_comparison"
1837+                       [(match_operand:GPR 1 "register_operand"  "d,d")
1838+                        (match_operand:GPR 2 "nonmemory_operand" "d,C")])
1839+                     (pc)
1840+                     (label_ref (match_operand 3 "" ""))))
1841+   (clobber (reg:CC CC_REGNUM))]
1842+  "TARGET_Z10"
1843+{
1844+  if (get_attr_length (insn) == 6)
1845+    return which_alternative ?
1846+      "c<g>ij%D0\t%1,%c2,%l3" : "c<g>rj%D0\t%1,%2,%l3";
1847+  else
1848+    return which_alternative ?
1849+      "c<g>fi\t%1,%c2\;jg%D0\t%l3" : "c<g>r\t%1,%2\;jg%D0\t%l3";
1850+}
1851+  [(set_attr "op_type" "RIE")
1852+   (set_attr "type"    "branch")
1853+   (set_attr "z10prop" "z10_super_c,z10_super")
1854+   (set (attr "length")
1855+        (if_then_else (lt (abs (minus (pc) (match_dup 3))) (const_int 60000))
1856+                      (const_int 6) (const_int 12)))]) ; 8 byte for cr/jg
1857+                                                       ; 10 byte for cgr/jg
1858+
1859+; clij, clgij, clrj, clgrj, clfi, clgfi, clr, clgr
1860+; The following instructions do a complementary access of their second
1861+; operand (z10 only): clrj, clgrj, clr, clgr
1862+(define_insn "*icmp_and_br_unsigned_<mode>"
1863+  [(set (pc)
1864+       (if_then_else (match_operator 0 "s390_unsigned_integer_comparison"
1865+                       [(match_operand:GPR 1 "register_operand"  "d,d")
1866+                        (match_operand:GPR 2 "nonmemory_operand" "d,I")])
1867+                     (pc)
1868+                     (label_ref (match_operand 3 "" ""))))
1869+   (clobber (reg:CC CC_REGNUM))]
1870+  "TARGET_Z10"
1871+{
1872+  if (get_attr_length (insn) == 6)
1873+    return which_alternative ?
1874+      "cl<g>ij%D0\t%1,%b2,%l3" : "cl<g>rj%D0\t%1,%2,%l3";
1875+  else
1876+    return which_alternative ?
1877+      "cl<g>fi\t%1,%b2\;jg%D0\t%l3" : "cl<g>r\t%1,%2\;jg%D0\t%l3";
1878+}
1879+  [(set_attr "op_type" "RIE")
1880+   (set_attr "type"    "branch")
1881+   (set_attr "z10prop" "z10_super_c,z10_super")
1882+   (set (attr "length")
1883+        (if_then_else (lt (abs (minus (pc) (match_dup 3))) (const_int 60000))
1884+                      (const_int 6) (const_int 12)))]) ; 8 byte for clr/jg
1885+                                                       ; 10 byte for clgr/jg
1886+
1887 ;;
1888 ;;- Move instructions.
1889 ;;
1890@@ -1470,7 +1528,7 @@
1891 
1892 (define_insn "*la_64"
1893   [(set (match_operand:DI 0 "register_operand" "=d,d")
1894-        (match_operand:QI 1 "address_operand" "U,W"))]
1895+        (match_operand:QI 1 "address_operand" "ZQZR,ZSZT"))]
1896   "TARGET_64BIT"
1897   "@
1898    la\t%0,%a1
1899@@ -1653,7 +1711,7 @@
1900 
1901 (define_insn "*la_31"
1902   [(set (match_operand:SI 0 "register_operand" "=d,d")
1903-        (match_operand:QI 1 "address_operand" "U,W"))]
1904+        (match_operand:QI 1 "address_operand" "ZQZR,ZSZT"))]
1905   "!TARGET_64BIT && legitimate_la_operand_p (operands[1])"
1906   "@
1907    la\t%0,%a1
1908@@ -1688,7 +1746,7 @@
1909 
1910 (define_insn "*la_31_and"
1911   [(set (match_operand:SI 0 "register_operand" "=d,d")
1912-        (and:SI (match_operand:QI 1 "address_operand" "U,W")
1913+        (and:SI (match_operand:QI 1 "address_operand" "ZQZR,ZSZT")
1914                 (const_int 2147483647)))]
1915   "!TARGET_64BIT"
1916   "@
1917@@ -1714,7 +1772,7 @@
1918 
1919 (define_insn "force_la_31"
1920   [(set (match_operand:SI 0 "register_operand" "=d,d")
1921-        (match_operand:QI 1 "address_operand" "U,W"))
1922+        (match_operand:QI 1 "address_operand" "ZQZR,ZSZT"))
1923    (use (const_int 0))]
1924   "!TARGET_64BIT"
1925   "@
1926@@ -1909,7 +1967,7 @@
1927    #
1928    #"
1929   [(set_attr "op_type" "RRE,RRE,*,*,RSY,RSY,*,*")
1930-   (set_attr "type"    "fsimptf,fsimptf,*,*,lm,stm,*,*")])
1931+   (set_attr "type"    "fhex,fsimptf,*,*,lm,stm,*,*")])
1932 
1933 (define_insn "*mov<mode>_31"
1934   [(set (match_operand:TD_TF 0 "nonimmediate_operand" "=f,f,f,o")
1935@@ -1921,7 +1979,7 @@
1936    #
1937    #"
1938   [(set_attr "op_type" "RRE,RRE,*,*")
1939-   (set_attr "type"    "fsimptf,fsimptf,*,*")])
1940+   (set_attr "type"    "fhex,fsimptf,*,*")])
1941 
1942 ; TFmode in GPRs splitters
1943 
1944@@ -2029,7 +2087,7 @@
1945    lg\t%0,%1
1946    stg\t%1,%0"
1947   [(set_attr "op_type" "RRE,RR,RRE,RRE,RX,RXY,RX,RXY,RRE,RXY,RXY")
1948-   (set_attr "type" "fsimpdf,floaddf,floaddf,floaddf,floaddf,floaddf,
1949+   (set_attr "type" "fhex,floaddf,floaddf,floaddf,floaddf,floaddf,
1950                      fstoredf,fstoredf,lr,load,store")
1951    (set_attr "z10prop" "*,
1952                         *,
1953@@ -2059,7 +2117,7 @@
1954    lg\t%0,%1
1955    stg\t%1,%0"
1956   [(set_attr "op_type" "RRE,RR,RX,RXY,RX,RXY,RRE,RXY,RXY")
1957-   (set_attr "type" "fsimp<mode>,fload<mode>,fload<mode>,fload<mode>,
1958+   (set_attr "type" "fhex,fload<mode>,fload<mode>,fload<mode>,
1959                      fstore<mode>,fstore<mode>,lr,load,store")
1960    (set_attr "z10prop" "*,
1961                         *,
1962@@ -2091,7 +2149,7 @@
1963    #
1964    #"
1965   [(set_attr "op_type" "RRE,RR,RX,RXY,RX,RXY,RS,RSY,RS,RSY,*,*")
1966-   (set_attr "type" "fsimp<mode>,fload<mode>,fload<mode>,fload<mode>,
1967+   (set_attr "type" "fhex,fload<mode>,fload<mode>,fload<mode>,
1968                      fstore<mode>,fstore<mode>,lm,lm,stm,stm,*,*")])
1969 
1970 (define_split
1971@@ -2158,7 +2216,7 @@
1972    st\t%1,%0
1973    sty\t%1,%0"
1974   [(set_attr "op_type" "RRE,RR,RX,RXY,RX,RXY,RR,RX,RXY,RX,RXY")
1975-   (set_attr "type" "fsimp<mode>,fload<mode>,fload<mode>,fload<mode>,
1976+   (set_attr "type" "fhex,fload<mode>,fload<mode>,fload<mode>,
1977                      fstore<mode>,fstore<mode>,lr,load,load,store,store")
1978    (set_attr "z10prop" "*,
1979                         *,
1980@@ -7407,7 +7465,7 @@
1981   [(set (pc)
1982         (if_then_else
1983           (match_operator 1 "s390_comparison" [(reg CC_REGNUM) (const_int 0)])
1984-          (match_operand 0 "address_operand" "U")
1985+          (match_operand 0 "address_operand" "ZQZR")
1986           (pc)))]
1987   ""
1988 {
1989@@ -7471,7 +7529,7 @@
1990         (if_then_else
1991           (match_operator 1 "s390_comparison" [(reg CC_REGNUM) (const_int 0)])
1992           (pc)
1993-          (match_operand 0 "address_operand" "U")))]
1994+          (match_operand 0 "address_operand" "ZQZR")))]
1995   ""
1996 {
1997   if (get_attr_op_type (insn) == OP_TYPE_RR)
1998@@ -7660,7 +7718,7 @@
1999         (if_then_else
2000           (ne (match_operand:SI 1 "register_operand" "d")
2001               (const_int 1))
2002-          (match_operand 0 "address_operand" "U")
2003+          (match_operand 0 "address_operand" "ZQZR")
2004           (pc)))
2005    (set (match_operand:SI 2 "register_operand" "=1")
2006         (plus:SI (match_dup 1) (const_int -1)))
2007@@ -7771,7 +7829,7 @@
2008 ;
2009 
2010 (define_insn "indirect_jump"
2011- [(set (pc) (match_operand 0 "address_operand" "U"))]
2012+ [(set (pc) (match_operand 0 "address_operand" "ZQZR"))]
2013   ""
2014 {
2015   if (get_attr_op_type (insn) == OP_TYPE_RR)
2016@@ -7790,7 +7848,7 @@
2017 ;
2018 
2019 (define_insn "casesi_jump"
2020- [(set (pc) (match_operand 0 "address_operand" "U"))
2021+ [(set (pc) (match_operand 0 "address_operand" "ZQZR"))
2022    (use (label_ref (match_operand 1 "" "")))]
2023   ""
2024 {
2025@@ -8012,7 +8070,7 @@
2026    (set_attr "type"    "jsr")])
2027 
2028 (define_insn "*basr"
2029-  [(call (mem:QI (match_operand 0 "address_operand" "U"))
2030+  [(call (mem:QI (match_operand 0 "address_operand" "ZQZR"))
2031          (match_operand 1 "const_int_operand" "n"))
2032    (clobber (match_operand 2 "register_operand" "=r"))]
2033   "!SIBLING_CALL_P (insn) && GET_MODE (operands[2]) == Pmode"
2034@@ -8070,7 +8128,7 @@
2035 
2036 (define_insn "*basr_r"
2037   [(set (match_operand 0 "" "")
2038-        (call (mem:QI (match_operand 1 "address_operand" "U"))
2039+        (call (mem:QI (match_operand 1 "address_operand" "ZQZR"))
2040               (match_operand 2 "const_int_operand" "n")))
2041    (clobber (match_operand 3 "register_operand" "=r"))]
2042   "!SIBLING_CALL_P (insn) && GET_MODE (operands[3]) == Pmode"
2043@@ -8170,7 +8228,7 @@
2044 
2045 (define_insn "*basr_tls"
2046   [(set (match_operand 0 "" "")
2047-        (call (mem:QI (match_operand 1 "address_operand" "U"))
2048+        (call (mem:QI (match_operand 1 "address_operand" "ZQZR"))
2049               (match_operand 2 "const_int_operand" "n")))
2050    (clobber (match_operand 3 "register_operand" "=r"))
2051    (use (match_operand 4 "" ""))]
2052@@ -8720,27 +8778,32 @@
2053 ;
2054 
2055 (define_insn "prefetch"
2056-  [(prefetch (match_operand 0 "address_operand" "UW,X")
2057-            (match_operand:SI 1 "const_int_operand" "n,n")
2058-            (match_operand:SI 2 "const_int_operand" "n,n"))]
2059-  "TARGET_Z10"
2060+  [(prefetch (match_operand 0    "address_operand"   "ZQZS,ZRZT,X")
2061+            (match_operand:SI 1 "const_int_operand" "   n,   n,n")
2062+            (match_operand:SI 2 "const_int_operand" "   n,   n,n"))]
2063+  "TARGET_ZARCH && s390_tune == PROCESSOR_2097_Z10"
2064 {
2065-  if (larl_operand (operands[0], Pmode))
2066-    return INTVAL (operands[1]) == 1 ? "pfdrl\t2,%a0" : "pfdrl\t1,%a0";
2067+  switch (which_alternative)
2068+    {
2069+      case 0:
2070+        return INTVAL (operands[1]) == 1 ? "stcmh\t2,0,%a0" : "stcmh\t1,0,%a0";
2071+      case 1:
2072+        return INTVAL (operands[1]) == 1 ? "pfd\t2,%a0" : "pfd\t1,%a0";
2073+      case 2:
2074+        if (larl_operand (operands[0], Pmode))
2075+         return INTVAL (operands[1]) == 1 ? "pfdrl\t2,%a0" : "pfdrl\t1,%a0";
2076+      default:
2077 
2078-  if (s390_mem_constraint ("W", operands[0])
2079-      || s390_mem_constraint ("U", operands[0]))
2080-    return INTVAL (operands[1]) == 1 ? "pfd\t2,%a0" : "pfd\t1,%a0";
2081-
2082-  /* This point might be reached if op0 is a larl operand with an
2083-     uneven addend.  In this case we simply omit issuing a prefetch
2084-     instruction.  */
2085+        /* This might be reached for symbolic operands with an odd
2086+           addend.  We simply omit the prefetch for such rare cases.  */
2087 
2088-  return "";
2089+        return "";
2090+     }
2091 }
2092-  [(set_attr "type" "load,larl")
2093-   (set_attr "op_type" "RXY,RIL")
2094-   (set_attr "z10prop" "z10_super")])
2095+  [(set_attr "type" "store,load,larl")
2096+   (set_attr "op_type" "RSY,RXY,RIL")
2097+   (set_attr "z10prop" "z10_super")
2098+   (set_attr "cpu_facility" "*,z10,z10")])
2099 
2100 
2101 ;
2102diff -Naur gcc-4.4.1.orig/gcc/cp/call.c gcc-4.4.1/gcc/cp/call.c
2103--- gcc-4.4.1.orig/gcc/cp/call.c        2009-07-12 23:06:27.000000000 -0700
2104+++ gcc-4.4.1/gcc/cp/call.c     2009-07-24 11:06:08.000000000 -0700
2105@@ -1211,7 +1211,21 @@
2106       lvalue_p = clk_ordinary;
2107       from = TREE_TYPE (from);
2108     }
2109-  else if (expr)
2110+
2111+  if (expr && BRACE_ENCLOSED_INITIALIZER_P (expr))
2112+    {
2113+      maybe_warn_cpp0x ("extended initializer lists");
2114+      conv = implicit_conversion (to, from, expr, c_cast_p,
2115+                                 flags);
2116+      if (!CLASS_TYPE_P (to)
2117+         && CONSTRUCTOR_NELTS (expr) == 1)
2118+       {
2119+         expr = CONSTRUCTOR_ELT (expr, 0)->value;
2120+         from = TREE_TYPE (expr);
2121+       }
2122+    }
2123+
2124+  if (lvalue_p == clk_none && expr)
2125     lvalue_p = real_lvalue_p (expr);
2126 
2127   tfrom = from;
2128@@ -1347,8 +1361,9 @@
2129      conversion operator).  */
2130   flags |= LOOKUP_NO_TEMP_BIND;
2131 
2132-  conv = implicit_conversion (to, from, expr, c_cast_p,
2133-                             flags);
2134+  if (!conv)
2135+    conv = implicit_conversion (to, from, expr, c_cast_p,
2136+                               flags);
2137   if (!conv)
2138     return NULL;
2139 
2140@@ -6242,6 +6257,14 @@
2141   ref_conv1 = maybe_handle_ref_bind (&ics1);
2142   ref_conv2 = maybe_handle_ref_bind (&ics2);
2143 
2144+  /* List-initialization sequence L1 is a better conversion sequence than
2145+     list-initialization sequence L2 if L1 converts to
2146+     std::initializer_list<X> for some X and L2 does not.  */
2147+  if (ics1->kind == ck_list && ics2->kind != ck_list)
2148+    return 1;
2149+  if (ics2->kind == ck_list && ics1->kind != ck_list)
2150+    return -1;
2151+
2152   /* [over.ics.rank]
2153 
2154      When  comparing  the  basic forms of implicit conversion sequences (as
2155@@ -6292,26 +6315,13 @@
2156       conversion *t1;
2157       conversion *t2;
2158 
2159-      for (t1 = ics1; t1->kind != ck_user && t1->kind != ck_list; t1 = t1->u.next)
2160+      for (t1 = ics1; t1->kind != ck_user; t1 = t1->u.next)
2161        if (t1->kind == ck_ambig || t1->kind == ck_aggr)
2162          return 0;
2163-      for (t2 = ics2; t2->kind != ck_user && t2->kind != ck_list; t2 = t2->u.next)
2164+      for (t2 = ics2; t2->kind != ck_user; t2 = t2->u.next)
2165        if (t2->kind == ck_ambig || t2->kind == ck_aggr)
2166          return 0;
2167 
2168-      /* Conversion to std::initializer_list is better than other
2169-        user-defined conversions.  */
2170-      if (t1->kind == ck_list
2171-         || t2->kind == ck_list)
2172-       {
2173-         if (t2->kind != ck_list)
2174-           return 1;
2175-         else if (t1->kind != ck_list)
2176-           return -1;
2177-         else
2178-           return 0;
2179-       }
2180-
2181       if (t1->cand->fn != t2->cand->fn)
2182        return 0;
2183 
2184@@ -7288,6 +7298,7 @@
2185   if (!conv || conv->bad_p)
2186     {
2187       if (!(TYPE_QUALS (TREE_TYPE (type)) & TYPE_QUAL_CONST)
2188+         && !TYPE_REF_IS_RVALUE (type)
2189          && !real_lvalue_p (expr))
2190        error ("invalid initialization of non-const reference of "
2191               "type %qT from a temporary of type %qT",
2192diff -Naur gcc-4.4.1.orig/gcc/cp/decl.c gcc-4.4.1/gcc/cp/decl.c
2193--- gcc-4.4.1.orig/gcc/cp/decl.c        2009-07-07 15:08:01.000000000 -0700
2194+++ gcc-4.4.1/gcc/cp/decl.c     2009-07-26 09:05:22.000000000 -0700
2195@@ -4345,13 +4345,6 @@
2196       return NULL_TREE;
2197     }
2198 
2199-  if (TREE_CODE (init) == CONSTRUCTOR)
2200-    {
2201-      error ("ISO C++ forbids use of initializer list to "
2202-            "initialize reference %qD", decl);
2203-      return NULL_TREE;
2204-    }
2205-
2206   if (TREE_CODE (init) == TREE_LIST)
2207     init = build_x_compound_expr_from_list (init, "initializer");
2208 
2209@@ -7618,7 +7611,6 @@
2210   bool unsigned_p, signed_p, short_p, long_p, thread_p;
2211   bool type_was_error_mark_node = false;
2212   bool parameter_pack_p = declarator? declarator->parameter_pack_p : false;
2213-  bool set_no_warning = false;
2214   bool template_type_arg = false;
2215 
2216   signed_p = declspecs->specs[(int)ds_signed];
2217@@ -8297,7 +8289,6 @@
2218                /* We now know that the TYPE_QUALS don't apply to the
2219                   decl, but to its return type.  */
2220                type_quals = TYPE_UNQUALIFIED;
2221-               set_no_warning = true;
2222              }
2223 
2224            /* Error about some types functions can't return.  */
2225@@ -9499,9 +9490,6 @@
2226     if (!processing_template_decl)
2227       cp_apply_type_quals_to_decl (type_quals, decl);
2228 
2229-    if (set_no_warning)
2230-        TREE_NO_WARNING (decl) = 1;
2231-
2232     return decl;
2233   }
2234 }
2235diff -Naur gcc-4.4.1.orig/gcc/cp/error.c gcc-4.4.1/gcc/cp/error.c
2236--- gcc-4.4.1.orig/gcc/cp/error.c       2009-07-10 15:31:34.000000000 -0700
2237+++ gcc-4.4.1/gcc/cp/error.c    2009-08-04 05:28:27.000000000 -0700
2238@@ -2181,7 +2181,10 @@
2239     return decl_as_string (decl, TFF_DECL_SPECIFIERS);
2240 
2241   reinit_cxx_pp ();
2242-  if (v == 1 && DECL_CLASS_SCOPE_P (decl))
2243+  if (v == 1
2244+      && (DECL_CLASS_SCOPE_P (decl)
2245+         || (DECL_NAMESPACE_SCOPE_P (decl)
2246+             && CP_DECL_CONTEXT (decl) != global_namespace)))
2247     {
2248       dump_type (CP_DECL_CONTEXT (decl), TFF_PLAIN_IDENTIFIER);
2249       pp_cxx_colon_colon (cxx_pp);
2250diff -Naur gcc-4.4.1.orig/gcc/cp/init.c gcc-4.4.1/gcc/cp/init.c
2251--- gcc-4.4.1.orig/gcc/cp/init.c        2009-07-12 23:06:27.000000000 -0700
2252+++ gcc-4.4.1/gcc/cp/init.c     2009-08-06 10:22:19.000000000 -0700
2253@@ -2695,6 +2695,13 @@
2254     gcc_assert (!init);
2255 
2256   inner_elt_type = strip_array_types (type);
2257+
2258+  /* Look through the TARGET_EXPR around a compound literal.  */
2259+  if (init && TREE_CODE (init) == TARGET_EXPR
2260+      && TREE_CODE (TARGET_EXPR_INITIAL (init)) == CONSTRUCTOR
2261+      && from_array != 2)
2262+    init = TARGET_EXPR_INITIAL (init);
2263+
2264   if (init
2265       && TREE_CODE (atype) == ARRAY_TYPE
2266       && (from_array == 2
2267@@ -2763,6 +2770,17 @@
2268   base = get_temp_regvar (ptype, rval);
2269   iterator = get_temp_regvar (ptrdiff_type_node, maxindex);
2270 
2271+  /* If initializing one array from another, initialize element by
2272+     element.  We rely upon the below calls to do the argument
2273+     checking.  Evaluate the initializer before entering the try block.  */
2274+  if (from_array && init && TREE_CODE (init) != CONSTRUCTOR)
2275+    {
2276+      base2 = decay_conversion (init);
2277+      itype = TREE_TYPE (base2);
2278+      base2 = get_temp_regvar (itype, base2);
2279+      itype = TREE_TYPE (itype);
2280+    }
2281+
2282   /* Protect the entire array initialization so that we can destroy
2283      the partially constructed array if an exception is thrown.
2284      But don't do this if we're assigning.  */
2285@@ -2805,16 +2823,8 @@
2286     }
2287   else if (from_array)
2288     {
2289-      /* If initializing one array from another, initialize element by
2290-        element.  We rely upon the below calls the do argument
2291-        checking.  */
2292       if (init)
2293-       {
2294-         base2 = decay_conversion (init);
2295-         itype = TREE_TYPE (base2);
2296-         base2 = get_temp_regvar (itype, base2);
2297-         itype = TREE_TYPE (itype);
2298-       }
2299+       /* OK, we set base2 above.  */;
2300       else if (TYPE_LANG_SPECIFIC (type)
2301               && TYPE_NEEDS_CONSTRUCTING (type)
2302               && ! TYPE_HAS_DEFAULT_CONSTRUCTOR (type))
2303diff -Naur gcc-4.4.1.orig/gcc/cp/Make-lang.in gcc-4.4.1/gcc/cp/Make-lang.in
2304--- gcc-4.4.1.orig/gcc/cp/Make-lang.in  2008-12-05 00:01:58.000000000 -0800
2305+++ gcc-4.4.1/gcc/cp/Make-lang.in       2009-09-09 01:46:32.000000000 -0700
2306@@ -72,8 +72,8 @@
2307 # Shared with C front end:
2308 CXX_C_OBJS = attribs.o c-common.o c-format.o c-pragma.o c-semantics.o c-lex.o \
2309        c-dump.o $(CXX_TARGET_OBJS) c-pretty-print.o c-opts.o c-pch.o \
2310-       incpath.o cppdefault.o c-ppoutput.o c-cppbuiltin.o prefix.o \
2311-       c-gimplify.o c-omp.o tree-inline.o
2312+       incpath.o c-ppoutput.o c-cppbuiltin.o prefix.o \
2313+       c-gimplify.o c-omp.o
2314 
2315 # Language-specific object files for C++ and Objective C++.
2316 CXX_AND_OBJCXX_OBJS = cp/call.o cp/decl.o cp/expr.o cp/pt.o cp/typeck2.o \
2317diff -Naur gcc-4.4.1.orig/gcc/cp/parser.c gcc-4.4.1/gcc/cp/parser.c
2318--- gcc-4.4.1.orig/gcc/cp/parser.c      2009-06-08 21:23:00.000000000 -0700
2319+++ gcc-4.4.1/gcc/cp/parser.c   2009-08-31 14:20:07.000000000 -0700
2320@@ -11871,11 +11871,19 @@
2321   else
2322     identifier = make_anon_name ();
2323 
2324-  /* Check for the `:' that denotes a specified underlying type in C++0x.  */
2325+  /* Check for the `:' that denotes a specified underlying type in C++0x.
2326+     Note that a ':' could also indicate a bitfield width, however.  */
2327   if (cp_lexer_next_token_is (parser->lexer, CPP_COLON))
2328     {
2329       cp_decl_specifier_seq type_specifiers;
2330 
2331+      /* Consume the `:'.  */
2332+      cp_lexer_consume_token (parser->lexer);
2333+
2334+      /* Parse the type-specifier-seq.  */
2335+      cp_parser_type_specifier_seq (parser, /*is_condition=*/false,
2336+                                    &type_specifiers);
2337+
2338       /* At this point this is surely not elaborated type specifier.  */
2339       if (!cp_parser_parse_definitely (parser))
2340        return NULL_TREE;
2341@@ -11883,15 +11891,8 @@
2342       if (cxx_dialect == cxx98)
2343         maybe_warn_cpp0x ("scoped enums");
2344 
2345-      /* Consume the `:'.  */
2346-      cp_lexer_consume_token (parser->lexer);
2347-
2348       has_underlying_type = true;
2349 
2350-      /* Parse the type-specifier-seq.  */
2351-      cp_parser_type_specifier_seq (parser, /*is_condition=*/false,
2352-                                    &type_specifiers);
2353-
2354       /* If that didn't work, stop.  */
2355       if (type_specifiers.type != error_mark_node)
2356         {
2357diff -Naur gcc-4.4.1.orig/gcc/cp/pt.c gcc-4.4.1/gcc/cp/pt.c
2358--- gcc-4.4.1.orig/gcc/cp/pt.c  2009-07-09 11:00:58.000000000 -0700
2359+++ gcc-4.4.1/gcc/cp/pt.c       2009-08-04 12:59:48.000000000 -0700
2360@@ -8007,11 +8007,11 @@
2361       cp_function_chain->x_current_class_ref = saved_class_ref;
2362     }
2363 
2364-  pop_access_scope (fn);
2365-
2366   /* Make sure the default argument is reasonable.  */
2367   arg = check_default_argument (type, arg);
2368 
2369+  pop_access_scope (fn);
2370+
2371   return arg;
2372 }
2373 
2374diff -Naur gcc-4.4.1.orig/gcc/cp/tree.c gcc-4.4.1/gcc/cp/tree.c
2375--- gcc-4.4.1.orig/gcc/cp/tree.c        2009-07-12 23:06:27.000000000 -0700
2376+++ gcc-4.4.1/gcc/cp/tree.c     2009-08-21 00:10:36.000000000 -0700
2377@@ -132,6 +132,12 @@
2378       return clk_ordinary;
2379 
2380     case CONST_DECL:
2381+      /* CONST_DECL without TREE_STATIC are enumeration values and
2382+        thus not lvalues.  With TREE_STATIC they are used by ObjC++
2383+        in objc_build_string_object and need to be considered as
2384+        lvalues.  */
2385+      if (! TREE_STATIC (ref))
2386+       return clk_none;
2387     case VAR_DECL:
2388       if (TREE_READONLY (ref) && ! TREE_STATIC (ref)
2389          && DECL_LANG_SPECIFIC (ref)
2390diff -Naur gcc-4.4.1.orig/gcc/DATESTAMP gcc-4.4.1/gcc/DATESTAMP
2391--- gcc-4.4.1.orig/gcc/DATESTAMP        2009-07-21 17:16:36.000000000 -0700
2392+++ gcc-4.4.1/gcc/DATESTAMP     2009-09-11 17:16:45.000000000 -0700
2393@@ -1 +1 @@
2394-20090722
2395+20090912
2396diff -Naur gcc-4.4.1.orig/gcc/doc/install.texi gcc-4.4.1/gcc/doc/install.texi
2397--- gcc-4.4.1.orig/gcc/doc/install.texi 2009-03-16 06:23:13.000000000 -0700
2398+++ gcc-4.4.1/gcc/doc/install.texi      2009-08-31 02:09:29.000000000 -0700
2399@@ -2463,7 +2463,7 @@
2400 @samp{make pdf} in place of @samp{make dvi}, you can create documentation
2401 in the form of @file{.pdf} files; this requires @command{texi2pdf}, which
2402 is included with Texinfo version 4.8 and later.  You can also
2403-@uref{http://www.gnu.org/order/order.html,,buy printed manuals from the
2404+@uref{http://shop.fsf.org/,,buy printed manuals from the
2405 Free Software Foundation}, though such manuals may not be for the most
2406 recent version of GCC@.
2407 
2408diff -Naur gcc-4.4.1.orig/gcc/doc/invoke.texi gcc-4.4.1/gcc/doc/invoke.texi
2409--- gcc-4.4.1.orig/gcc/doc/invoke.texi  2009-04-01 00:18:47.000000000 -0700
2410+++ gcc-4.4.1/gcc/doc/invoke.texi       2009-09-12 08:46:57.000000000 -0700
2411@@ -456,7 +456,7 @@
2412 -mfix-cortex-m3-ldrd}
2413 
2414 @emph{AVR Options}
2415-@gccoptlist{-mmcu=@var{mcu}  -msize  -minit-stack=@var{n}  -mno-interrupts @gol
2416+@gccoptlist{-mmcu=@var{mcu}  -msize  -mno-interrupts @gol
2417 -mcall-prologues  -mno-tablejump  -mtiny-stack  -mint8}
2418 
2419 @emph{Blackfin Options}
2420@@ -6513,7 +6513,7 @@
2421 
2422 @item -fstrict-aliasing
2423 @opindex fstrict-aliasing
2424-Allows the compiler to assume the strictest aliasing rules applicable to
2425+Allow the compiler to assume the strictest aliasing rules applicable to
2426 the language being compiled.  For C (and C++), this activates
2427 optimizations based on the type of expressions.  In particular, an
2428 object of one type is assumed never to reside at the same address as an
2429@@ -6530,7 +6530,7 @@
2430 @};
2431 
2432 int f() @{
2433-  a_union t;
2434+  union a_union t;
2435   t.d = 3.0;
2436   return t.i;
2437 @}
2438@@ -6543,7 +6543,7 @@
2439 implementation}.  However, this code might not:
2440 @smallexample
2441 int f() @{
2442-  a_union t;
2443+  union a_union t;
2444   int* ip;
2445   t.d = 3.0;
2446   ip = &t.i;
2447@@ -9277,11 +9277,6 @@
2448 @opindex msize
2449 Output instruction sizes to the asm file.
2450 
2451-@item -minit-stack=@var{N}
2452-@opindex minit-stack
2453-Specify the initial stack address, which may be a symbol or numeric value,
2454-@samp{__stack} is the default.
2455-
2456 @item -mno-interrupts
2457 @opindex mno-interrupts
2458 Generated code is not compatible with hardware interrupts.
2459diff -Naur gcc-4.4.1.orig/gcc/doc/service.texi gcc-4.4.1/gcc/doc/service.texi
2460--- gcc-4.4.1.orig/gcc/doc/service.texi 2002-12-30 13:07:17.000000000 -0800
2461+++ gcc-4.4.1/gcc/doc/service.texi      2009-08-27 17:01:08.000000000 -0700
2462@@ -21,7 +21,7 @@
2463 @item
2464 Look in the service directory for someone who might help you for a fee.
2465 The service directory is found at
2466-@uref{http://www.gnu.org/prep/service.html}.
2467+@uref{http://www.fsf.org/resources/service}.
2468 @end itemize
2469 
2470 For further information, see
2471diff -Naur gcc-4.4.1.orig/gcc/dse.c gcc-4.4.1/gcc/dse.c
2472--- gcc-4.4.1.orig/gcc/dse.c    2009-05-13 14:42:03.000000000 -0700
2473+++ gcc-4.4.1/gcc/dse.c 2009-08-05 05:54:21.000000000 -0700
2474@@ -1070,6 +1070,8 @@
2475 {
2476   rtx mem_address = XEXP (mem, 0);
2477   rtx expanded_address, address;
2478+  int expanded;
2479+
2480   /* Make sure that cselib is has initialized all of the operands of
2481      the address before asking it to do the subst.  */
2482 
2483@@ -1114,72 +1116,88 @@
2484       fprintf (dump_file, "\n");
2485     }
2486 
2487-  /* Use cselib to replace all of the reg references with the full
2488-     expression.  This will take care of the case where we have
2489+  /* First see if just canon_rtx (mem_address) is const or frame,
2490+     if not, try cselib_expand_value_rtx and call canon_rtx on that.  */
2491+  address = NULL_RTX;
2492+  for (expanded = 0; expanded < 2; expanded++)
2493+    {
2494+      if (expanded)
2495+       {
2496+         /* Use cselib to replace all of the reg references with the full
2497+            expression.  This will take care of the case where we have
2498 
2499-     r_x = base + offset;
2500-     val = *r_x;
2501+            r_x = base + offset;
2502+            val = *r_x;
2503   
2504-     by making it into
2505-
2506-     val = *(base + offset); 
2507-  */
2508-
2509-  expanded_address = cselib_expand_value_rtx (mem_address, scratch, 5);
2510+            by making it into
2511 
2512-  /* If this fails, just go with the mem_address.  */
2513-  if (!expanded_address)
2514-    expanded_address = mem_address;
2515+            val = *(base + offset);  */
2516 
2517-  /* Split the address into canonical BASE + OFFSET terms.  */
2518-  address = canon_rtx (expanded_address);
2519+         expanded_address = cselib_expand_value_rtx (mem_address,
2520+                                                     scratch, 5);
2521 
2522-  *offset = 0;
2523+         /* If this fails, just go with the address from first
2524+            iteration.  */
2525+         if (!expanded_address)
2526+           break;
2527+       }
2528+      else
2529+       expanded_address = mem_address;
2530 
2531-  if (dump_file)
2532-    {
2533-      fprintf (dump_file, "\n   after cselib_expand address: ");
2534-      print_inline_rtx (dump_file, expanded_address, 0);
2535-      fprintf (dump_file, "\n");
2536+      /* Split the address into canonical BASE + OFFSET terms.  */
2537+      address = canon_rtx (expanded_address);
2538 
2539-      fprintf (dump_file, "\n   after canon_rtx address: ");
2540-      print_inline_rtx (dump_file, address, 0);
2541-      fprintf (dump_file, "\n");
2542-    }
2543+      *offset = 0;
2544 
2545-  if (GET_CODE (address) == CONST)
2546-    address = XEXP (address, 0);
2547+      if (dump_file)
2548+       {
2549+         if (expanded)
2550+           {
2551+             fprintf (dump_file, "\n   after cselib_expand address: ");
2552+             print_inline_rtx (dump_file, expanded_address, 0);
2553+             fprintf (dump_file, "\n");
2554+           }
2555 
2556-  if (GET_CODE (address) == PLUS && GET_CODE (XEXP (address, 1)) == CONST_INT)
2557-    {
2558-      *offset = INTVAL (XEXP (address, 1));
2559-      address = XEXP (address, 0);
2560-    }
2561+         fprintf (dump_file, "\n   after canon_rtx address: ");
2562+         print_inline_rtx (dump_file, address, 0);
2563+         fprintf (dump_file, "\n");
2564+       }
2565 
2566-  if (const_or_frame_p (address))
2567-    {
2568-      group_info_t group = get_group_info (address);
2569+      if (GET_CODE (address) == CONST)
2570+       address = XEXP (address, 0);
2571 
2572-      if (dump_file)
2573-       fprintf (dump_file, "  gid=%d offset=%d \n", group->id, (int)*offset);
2574-      *base = NULL;
2575-      *group_id = group->id;
2576-    }
2577-  else
2578-    {
2579-      *base = cselib_lookup (address, Pmode, true);
2580-      *group_id = -1;
2581+      if (GET_CODE (address) == PLUS
2582+         && GET_CODE (XEXP (address, 1)) == CONST_INT)
2583+       {
2584+         *offset = INTVAL (XEXP (address, 1));
2585+         address = XEXP (address, 0);
2586+       }
2587 
2588-      if (*base == NULL)
2589+      if (const_or_frame_p (address))
2590        {
2591+         group_info_t group = get_group_info (address);
2592+
2593          if (dump_file)
2594-           fprintf (dump_file, " no cselib val - should be a wild read.\n");
2595-         return false;
2596+           fprintf (dump_file, "  gid=%d offset=%d \n",
2597+                    group->id, (int)*offset);
2598+         *base = NULL;
2599+         *group_id = group->id;
2600+         return true;
2601        }
2602+    }
2603+
2604+  *base = cselib_lookup (address, Pmode, true);
2605+  *group_id = -1;
2606+
2607+  if (*base == NULL)
2608+    {
2609       if (dump_file)
2610-       fprintf (dump_file, "  varying cselib base=%d offset = %d\n",
2611-                (*base)->value, (int)*offset);
2612+       fprintf (dump_file, " no cselib val - should be a wild read.\n");
2613+      return false;
2614     }
2615+  if (dump_file)
2616+    fprintf (dump_file, "  varying cselib base=%d offset = %d\n",
2617+            (*base)->value, (int)*offset);
2618   return true;
2619 }
2620 
2621diff -Naur gcc-4.4.1.orig/gcc/dwarf2out.c gcc-4.4.1/gcc/dwarf2out.c
2622--- gcc-4.4.1.orig/gcc/dwarf2out.c      2009-06-03 10:32:45.000000000 -0700
2623+++ gcc-4.4.1/gcc/dwarf2out.c   2009-08-16 02:07:40.000000000 -0700
2624@@ -14260,7 +14260,13 @@
2625 static void
2626 gen_inlined_subroutine_die (tree stmt, dw_die_ref context_die, int depth)
2627 {
2628-  tree decl = block_ultimate_origin (stmt);
2629+  tree decl;
2630+
2631+  /* The instance of function that is effectively being inlined shall not
2632+     be abstract.  */
2633+  gcc_assert (! BLOCK_ABSTRACT (stmt));
2634+
2635+  decl = block_ultimate_origin (stmt);
2636 
2637   /* Emit info for the abstract instance first, if we haven't yet.  We
2638      must emit this even if the block is abstract, otherwise when we
2639@@ -14281,20 +14287,6 @@
2640       decls_for_scope (stmt, subr_die, depth);
2641       current_function_has_inlines = 1;
2642     }
2643-  else
2644-    /* We may get here if we're the outer block of function A that was
2645-       inlined into function B that was inlined into function C.  When
2646-       generating debugging info for C, dwarf2out_abstract_function(B)
2647-       would mark all inlined blocks as abstract, including this one.
2648-       So, we wouldn't (and shouldn't) expect labels to be generated
2649-       for this one.  Instead, just emit debugging info for
2650-       declarations within the block.  This is particularly important
2651-       in the case of initializers of arguments passed from B to us:
2652-       if they're statement expressions containing declarations, we
2653-       wouldn't generate dies for their abstract variables, and then,
2654-       when generating dies for the real variables, we'd die (pun
2655-       intended :-)  */
2656-    gen_lexical_block_die (stmt, context_die, depth);
2657 }
2658 
2659 /* Generate a DIE for a field in a record, or structure.  */
2660@@ -14921,7 +14913,23 @@
2661   if (must_output_die)
2662     {
2663       if (inlined_func)
2664-       gen_inlined_subroutine_die (stmt, context_die, depth);
2665+       {
2666+         /* If STMT block is abstract, that means we have been called
2667+            indirectly from dwarf2out_abstract_function.
2668+            That function rightfully marks the descendent blocks (of
2669+            the abstract function it is dealing with) as being abstract,
2670+            precisely to prevent us from emitting any
2671+            DW_TAG_inlined_subroutine DIE as a descendent
2672+            of an abstract function instance. So in that case, we should
2673+            not call gen_inlined_subroutine_die.
2674+
2675+            Later though, when cgraph asks dwarf2out to emit info
2676+            for the concrete instance of the function decl into which
2677+            the concrete instance of STMT got inlined, the later will lead
2678+            to the generation of a DW_TAG_inlined_subroutine DIE.  */
2679+         if (! BLOCK_ABSTRACT (stmt))
2680+           gen_inlined_subroutine_die (stmt, context_die, depth);
2681+       }
2682       else
2683        gen_lexical_block_die (stmt, context_die, depth);
2684     }
2685diff -Naur gcc-4.4.1.orig/gcc/expr.c gcc-4.4.1/gcc/expr.c
2686--- gcc-4.4.1.orig/gcc/expr.c   2009-06-16 07:28:47.000000000 -0700
2687+++ gcc-4.4.1/gcc/expr.c        2009-08-19 15:52:11.000000000 -0700
2688@@ -7806,6 +7806,33 @@
2689                          || mode1 == BLKmode
2690                          || bitpos + bitsize > GET_MODE_BITSIZE (mode2));
2691 
2692+       /* Handle CONCAT first.  */
2693+       if (GET_CODE (op0) == CONCAT && !must_force_mem)
2694+         {
2695+           if (bitpos == 0
2696+               && bitsize == GET_MODE_BITSIZE (GET_MODE (op0)))
2697+             return op0;
2698+           if (bitpos == 0
2699+               && bitsize == GET_MODE_BITSIZE (GET_MODE (XEXP (op0, 0)))
2700+               && bitsize)
2701+             {
2702+               op0 = XEXP (op0, 0);
2703+               mode2 = GET_MODE (op0);
2704+             }
2705+           else if (bitpos == GET_MODE_BITSIZE (GET_MODE (XEXP (op0, 0)))
2706+                    && bitsize == GET_MODE_BITSIZE (GET_MODE (XEXP (op0, 1)))
2707+                    && bitpos
2708+                    && bitsize)
2709+             {
2710+               op0 = XEXP (op0, 1);
2711+               bitpos = 0;
2712+               mode2 = GET_MODE (op0);
2713+             }
2714+           else
2715+             /* Otherwise force into memory.  */
2716+             must_force_mem = 1;
2717+         }
2718+
2719        /* If this is a constant, put it in a register if it is a legitimate
2720           constant and we don't need a memory reference.  */
2721        if (CONSTANT_P (op0)
2722@@ -7879,16 +7906,6 @@
2723            MEM_VOLATILE_P (op0) = 1;
2724          }
2725 
2726-       /* The following code doesn't handle CONCAT.
2727-          Assume only bitpos == 0 can be used for CONCAT, due to
2728-          one element arrays having the same mode as its element.  */
2729-       if (GET_CODE (op0) == CONCAT)
2730-         {
2731-           gcc_assert (bitpos == 0
2732-                       && bitsize == GET_MODE_BITSIZE (GET_MODE (op0)));
2733-           return op0;
2734-         }
2735-
2736        /* In cases where an aligned union has an unaligned object
2737           as a field, we might be extracting a BLKmode value from
2738           an integer-mode (e.g., SImode) object.  Handle this case
2739diff -Naur gcc-4.4.1.orig/gcc/fortran/check.c gcc-4.4.1/gcc/fortran/check.c
2740--- gcc-4.4.1.orig/gcc/fortran/check.c  2009-01-09 15:47:55.000000000 -0800
2741+++ gcc-4.4.1/gcc/fortran/check.c       2009-07-23 17:28:43.000000000 -0700
2742@@ -813,6 +813,15 @@
2743                     gfc_current_intrinsic, &y->where);
2744          return FAILURE;
2745        }
2746+
2747+      if (y->ts.type == BT_COMPLEX)
2748+       {
2749+         gfc_error ("'%s' argument of '%s' intrinsic at %L must have a type "
2750+                    "of either REAL or INTEGER", gfc_current_intrinsic_arg[1],
2751+                    gfc_current_intrinsic, &y->where);
2752+         return FAILURE;
2753+       }
2754+
2755     }
2756 
2757   if (kind_check (kind, 2, BT_COMPLEX) == FAILURE)
2758@@ -937,6 +946,14 @@
2759                     gfc_current_intrinsic, &y->where);
2760          return FAILURE;
2761        }
2762+
2763+      if (y->ts.type == BT_COMPLEX)
2764+       {
2765+         gfc_error ("'%s' argument of '%s' intrinsic at %L must have a type "
2766+                    "of either REAL or INTEGER", gfc_current_intrinsic_arg[1],
2767+                    gfc_current_intrinsic, &y->where);
2768+         return FAILURE;
2769+       }
2770     }
2771 
2772   return SUCCESS;
2773diff -Naur gcc-4.4.1.orig/gcc/fortran/intrinsic.c gcc-4.4.1/gcc/fortran/intrinsic.c
2774--- gcc-4.4.1.orig/gcc/fortran/intrinsic.c      2009-01-09 15:47:55.000000000 -0800
2775+++ gcc-4.4.1/gcc/fortran/intrinsic.c   2009-09-11 15:11:06.000000000 -0700
2776@@ -836,13 +836,17 @@
2777   /* See if this intrinsic is allowed in the current standard.  */
2778   if (gfc_check_intrinsic_standard (isym, &symstd, false, loc) == FAILURE)
2779     {
2780-      if (gfc_option.warn_intrinsics_std)
2781-       gfc_warning_now ("The intrinsic '%s' at %L is not included in the"
2782-                        " selected standard but %s and '%s' will be treated as"
2783-                        " if declared EXTERNAL.  Use an appropriate -std=*"
2784-                        " option or define -fall-intrinsics to allow this"
2785-                        " intrinsic.", sym->name, &loc, symstd, sym->name);
2786-      sym->attr.external = 1;
2787+      if (sym->attr.proc == PROC_UNKNOWN)
2788+       {
2789+         if (gfc_option.warn_intrinsics_std)
2790+           gfc_warning_now ("The intrinsic '%s' at %L is not included in the"
2791+                            " selected standard but %s and '%s' will be"
2792+                            " treated as if declared EXTERNAL.  Use an"
2793+                            " appropriate -std=* option or define"
2794+                            " -fall-intrinsics to allow this intrinsic.",
2795+                            sym->name, &loc, symstd, sym->name);
2796+         gfc_add_external (&sym->attr, &loc);
2797+       }
2798 
2799       return false;
2800     }
2801diff -Naur gcc-4.4.1.orig/gcc/fortran/iresolve.c gcc-4.4.1/gcc/fortran/iresolve.c
2802--- gcc-4.4.1.orig/gcc/fortran/iresolve.c       2008-11-01 06:26:19.000000000 -0700
2803+++ gcc-4.4.1/gcc/fortran/iresolve.c    2009-08-16 13:04:40.000000000 -0700
2804@@ -2346,9 +2346,19 @@
2805   /* TODO: Make this do something meaningful.  */
2806   static char transfer0[] = "__transfer0", transfer1[] = "__transfer1";
2807 
2808-  if (mold->ts.type == BT_CHARACTER && !mold->ts.cl->length
2809-       && !(mold->expr_type == EXPR_VARIABLE && mold->symtree->n.sym->attr.dummy))
2810-    mold->ts.cl->length = gfc_int_expr (mold->value.character.length);
2811+  if (mold->ts.type == BT_CHARACTER
2812+       && !mold->ts.cl->length
2813+       && gfc_is_constant_expr (mold))
2814+    {
2815+      int len;
2816+      if (mold->expr_type == EXPR_CONSTANT)
2817+       mold->ts.cl->length = gfc_int_expr (mold->value.character.length);
2818+      else
2819+       {
2820+         len = mold->value.constructor->expr->value.character.length;
2821+         mold->ts.cl->length = gfc_int_expr (len);
2822+       }
2823+    }
2824 
2825   f->ts = mold->ts;
2826 
2827diff -Naur gcc-4.4.1.orig/gcc/fortran/openmp.c gcc-4.4.1/gcc/fortran/openmp.c
2828--- gcc-4.4.1.orig/gcc/fortran/openmp.c 2008-07-19 09:22:12.000000000 -0700
2829+++ gcc-4.4.1/gcc/fortran/openmp.c      2009-07-28 09:33:08.000000000 -0700
2830@@ -396,12 +396,13 @@
2831              const char *p = gfc_extract_int (cexpr, &collapse);
2832              if (p)
2833                {
2834-                 gfc_error (p);
2835+                 gfc_error_now (p);
2836                  collapse = 1;
2837                }
2838              else if (collapse <= 0)
2839                {
2840-                 gfc_error ("COLLAPSE clause argument not constant positive integer at %C");
2841+                 gfc_error_now ("COLLAPSE clause argument not"
2842+                                " constant positive integer at %C");
2843                  collapse = 1;
2844                }
2845              c->collapse = collapse;
2846diff -Naur gcc-4.4.1.orig/gcc/fortran/primary.c gcc-4.4.1/gcc/fortran/primary.c
2847--- gcc-4.4.1.orig/gcc/fortran/primary.c        2009-04-03 13:56:54.000000000 -0700
2848+++ gcc-4.4.1/gcc/fortran/primary.c     2009-09-05 07:25:39.000000000 -0700
2849@@ -1773,7 +1773,11 @@
2850       if (m != MATCH_YES)
2851        return MATCH_ERROR;
2852 
2853-      tbp = gfc_find_typebound_proc (sym, &t, name, false);
2854+      if (sym->f2k_derived)
2855+       tbp = gfc_find_typebound_proc (sym, &t, name, false);
2856+      else
2857+       tbp = NULL;
2858+
2859       if (tbp)
2860        {
2861          gfc_symbol* tbp_sym;
2862diff -Naur gcc-4.4.1.orig/gcc/fortran/resolve.c gcc-4.4.1/gcc/fortran/resolve.c
2863--- gcc-4.4.1.orig/gcc/fortran/resolve.c        2009-06-20 02:21:06.000000000 -0700
2864+++ gcc-4.4.1/gcc/fortran/resolve.c     2009-07-29 02:35:15.000000000 -0700
2865@@ -9414,7 +9414,7 @@
2866       if ((!a->save && !a->dummy && !a->pointer
2867           && !a->in_common && !a->use_assoc
2868           && !(a->function && sym != sym->result))
2869-         || (a->dummy && a->intent == INTENT_OUT))
2870+         || (a->dummy && a->intent == INTENT_OUT && !a->pointer))
2871        apply_default_init (sym);
2872     }
2873 
2874diff -Naur gcc-4.4.1.orig/gcc/fortran/trans-decl.c gcc-4.4.1/gcc/fortran/trans-decl.c
2875--- gcc-4.4.1.orig/gcc/fortran/trans-decl.c     2009-06-03 12:39:09.000000000 -0700
2876+++ gcc-4.4.1/gcc/fortran/trans-decl.c  2009-08-25 11:54:58.000000000 -0700
2877@@ -2826,7 +2826,8 @@
2878   gfc_init_block (&fnblock);
2879   for (f = proc_sym->formal; f; f = f->next)
2880     if (f->sym && f->sym->attr.intent == INTENT_OUT
2881-         && f->sym->ts.type == BT_DERIVED)
2882+       && !f->sym->attr.pointer
2883+       && f->sym->ts.type == BT_DERIVED)
2884       {
2885        if (f->sym->ts.derived->attr.alloc_comp)
2886          {
2887@@ -3253,7 +3254,13 @@
2888              st = gfc_find_symtree (ns->sym_root,
2889                                     rent->local_name[0]
2890                                     ? rent->local_name : rent->use_name);
2891-             gcc_assert (st && st->n.sym->attr.use_assoc);
2892+             gcc_assert (st);
2893+
2894+             /* Fixing-up doubly contained symbols, sometimes results in
2895+                ambiguity, which is caught here.  */
2896+             if (!st->n.sym->attr.use_assoc)
2897+               continue;
2898+
2899              if (st->n.sym->backend_decl
2900                  && DECL_P (st->n.sym->backend_decl)
2901                  && st->n.sym->module
2902@@ -3573,6 +3580,7 @@
2903         automatic lengths.  */
2904       if (sym->attr.dummy && !sym->attr.referenced
2905            && sym->ts.type == BT_DERIVED
2906+           && !sym->attr.pointer
2907            && sym->ts.derived->attr.alloc_comp
2908            && sym->attr.intent == INTENT_OUT)
2909        {
2910diff -Naur gcc-4.4.1.orig/gcc/java/lang.c gcc-4.4.1/gcc/java/lang.c
2911--- gcc-4.4.1.orig/gcc/java/lang.c      2008-09-17 14:39:13.000000000 -0700
2912+++ gcc-4.4.1/gcc/java/lang.c   2009-08-12 02:02:17.000000000 -0700
2913@@ -53,7 +53,7 @@
2914 
2915 static int java_handle_option (size_t scode, const char *arg, int value);
2916 static void put_decl_string (const char *, int);
2917-static void put_decl_node (tree);
2918+static void put_decl_node (tree, int);
2919 static void java_print_error_function (diagnostic_context *, const char *,
2920                                       diagnostic_info *);
2921 static int merge_init_test_initialization (void * *, void *);
2922@@ -355,10 +355,13 @@
2923   decl_bufpos += len;
2924 }
2925 
2926-/* Append to decl_buf a printable name for NODE. */
2927+/* Append to decl_buf a printable name for NODE.
2928+   Depending on VERBOSITY, more information about NODE
2929+   is printed. Read the comments of decl_printable_name in
2930+   langhooks.h for more.  */
2931 
2932 static void
2933-put_decl_node (tree node)
2934+put_decl_node (tree node, int verbosity)
2935 {
2936   int was_pointer = 0;
2937   if (TREE_CODE (node) == POINTER_TYPE)
2938@@ -370,17 +373,32 @@
2939     {
2940       if (TREE_CODE (node) == FUNCTION_DECL)
2941        {
2942+         if (verbosity == 0 && DECL_NAME (node))
2943+         /* We have been instructed to just print the bare name
2944+            of the function.  */
2945+           {
2946+             put_decl_node (DECL_NAME (node), 0);
2947+             return;
2948+           }
2949+
2950          /* We want to print the type the DECL belongs to. We don't do
2951             that when we handle constructors. */
2952          if (! DECL_CONSTRUCTOR_P (node)
2953-             && ! DECL_ARTIFICIAL (node) && DECL_CONTEXT (node))
2954+             && ! DECL_ARTIFICIAL (node) && DECL_CONTEXT (node)
2955+              /* We want to print qualified DECL names only
2956+                 if verbosity is higher than 1.  */
2957+              && verbosity >= 1)
2958            {
2959-             put_decl_node (TYPE_NAME (DECL_CONTEXT (node)));
2960+             put_decl_node (TYPE_NAME (DECL_CONTEXT (node)),
2961+                               verbosity);
2962              put_decl_string (".", 1);
2963            }
2964          if (! DECL_CONSTRUCTOR_P (node))
2965-           put_decl_node (DECL_NAME (node));
2966-         if (TREE_TYPE (node) != NULL_TREE)
2967+           put_decl_node (DECL_NAME (node), verbosity);
2968+         if (TREE_TYPE (node) != NULL_TREE
2969+              /* We want to print function parameters only if verbosity
2970+                 is higher than 2.  */
2971+              && verbosity >= 2)
2972            {
2973              int i = 0;
2974              tree args = TYPE_ARG_TYPES (TREE_TYPE (node));
2975@@ -391,19 +409,22 @@
2976                {
2977                  if (i > 0)
2978                    put_decl_string (",", 1);
2979-                 put_decl_node (TREE_VALUE (args));
2980+                 put_decl_node (TREE_VALUE (args), verbosity);
2981                }
2982              put_decl_string (")", 1);
2983            }
2984        }
2985       else
2986-       put_decl_node (DECL_NAME (node));
2987+       put_decl_node (DECL_NAME (node), verbosity);
2988     }
2989   else if (TYPE_P (node) && TYPE_NAME (node) != NULL_TREE)
2990     {
2991-      if (TREE_CODE (node) == RECORD_TYPE && TYPE_ARRAY_P (node))
2992+      if (TREE_CODE (node) == RECORD_TYPE && TYPE_ARRAY_P (node)
2993+          /* Print detailed array information only if verbosity is higher
2994+            than 2.  */
2995+          && verbosity >= 2)
2996        {
2997-         put_decl_node (TYPE_ARRAY_ELEMENT (node));
2998+         put_decl_node (TYPE_ARRAY_ELEMENT (node), verbosity);
2999          put_decl_string("[]", 2);
3000        }
3001       else if (node == promoted_byte_type_node)
3002@@ -417,7 +438,7 @@
3003       else if (node == void_type_node && was_pointer)
3004        put_decl_string ("null", 4);
3005       else
3006-       put_decl_node (TYPE_NAME (node));
3007+       put_decl_node (TYPE_NAME (node), verbosity);
3008     }
3009   else if (TREE_CODE (node) == IDENTIFIER_NODE)
3010     put_decl_string (IDENTIFIER_POINTER (node), IDENTIFIER_LENGTH (node));
3011@@ -434,10 +455,7 @@
3012 lang_printable_name (tree decl, int v)
3013 {
3014   decl_bufpos = 0;
3015-  if (v == 0 && TREE_CODE (decl) == FUNCTION_DECL)
3016-    put_decl_node (DECL_NAME (decl));
3017-  else
3018-    put_decl_node (decl);
3019+  put_decl_node (decl, v);
3020   put_decl_string ("", 1);
3021   return decl_buf;
3022 }
3023diff -Naur gcc-4.4.1.orig/gcc/longlong.h gcc-4.4.1/gcc/longlong.h
3024--- gcc-4.4.1.orig/gcc/longlong.h       2009-02-12 08:30:53.000000000 -0800
3025+++ gcc-4.4.1/gcc/longlong.h    2009-08-11 15:36:56.000000000 -0700
3026@@ -982,7 +982,7 @@
3027 "      or r1,%0"                                                       \
3028        : "=r" (q), "=&z" (r)                                           \
3029        : "1" (n1), "r" (n0), "rm" (d), "r" (&__udiv_qrnnd_16)          \
3030-       : "r1", "r2", "r4", "r5", "r6", "pr");                          \
3031+       : "r1", "r2", "r4", "r5", "r6", "pr", "t");                     \
3032   } while (0)
3033 
3034 #define UDIV_TIME 80
3035@@ -990,7 +990,7 @@
3036 #define sub_ddmmss(sh, sl, ah, al, bh, bl)                             \
3037   __asm__ ("clrt;subc %5,%1; subc %4,%0"                               \
3038           : "=r" (sh), "=r" (sl)                                       \
3039-          : "0" (ah), "1" (al), "r" (bh), "r" (bl))
3040+          : "0" (ah), "1" (al), "r" (bh), "r" (bl) : "t")
3041 
3042 #endif /* __sh__ */
3043 
3044diff -Naur gcc-4.4.1.orig/gcc/Makefile.in gcc-4.4.1/gcc/Makefile.in
3045--- gcc-4.4.1.orig/gcc/Makefile.in      2009-05-21 16:17:37.000000000 -0700
3046+++ gcc-4.4.1/gcc/Makefile.in   2009-07-25 10:53:35.000000000 -0700
3047@@ -3975,7 +3975,7 @@
3048 # These next rules exist because the output name is not the same as
3049 # the input name, so our implicit %.pod rule will not work.
3050 
3051-gcc.pod: invoke.texi cppenv.texi cppopts.texi
3052+gcc.pod: invoke.texi cppenv.texi cppopts.texi gcc-vers.texi
3053        $(STAMP) $@
3054        -$(TEXI2POD) $< > $@
3055 gfdl.pod: fdl.texi
3056diff -Naur gcc-4.4.1.orig/gcc/resource.c gcc-4.4.1/gcc/resource.c
3057--- gcc-4.4.1.orig/gcc/resource.c       2009-05-21 16:17:37.000000000 -0700
3058+++ gcc-4.4.1/gcc/resource.c    2009-07-22 16:22:24.000000000 -0700
3059@@ -945,10 +945,11 @@
3060 
3061   /* If we found a basic block, get the live registers from it and update
3062      them with anything set or killed between its start and the insn before
3063-     TARGET.  Otherwise, we must assume everything is live.  */
3064+     TARGET; this custom life analysis is really about registers so we need
3065+     to use the LR problem.  Otherwise, we must assume everything is live.  */
3066   if (b != -1)
3067     {
3068-      regset regs_live = df_get_live_in (BASIC_BLOCK (b));
3069+      regset regs_live = DF_LR_IN (BASIC_BLOCK (b));
3070       rtx start_insn, stop_insn;
3071 
3072       /* Compute hard regs live at start of block.  */
3073@@ -1052,7 +1053,7 @@
3074                {
3075                  HARD_REG_SET extra_live;
3076 
3077-                 REG_SET_TO_HARD_REG_SET (extra_live, df_get_live_in (bb));
3078+                 REG_SET_TO_HARD_REG_SET (extra_live, DF_LR_IN (bb));
3079                  IOR_HARD_REG_SET (current_live_regs, extra_live);
3080                }
3081            }
3082diff -Naur gcc-4.4.1.orig/gcc/simplify-rtx.c gcc-4.4.1/gcc/simplify-rtx.c
3083--- gcc-4.4.1.orig/gcc/simplify-rtx.c   2009-02-20 07:20:38.000000000 -0800
3084+++ gcc-4.4.1/gcc/simplify-rtx.c        2009-09-07 13:25:52.000000000 -0700
3085@@ -2009,6 +2009,7 @@
3086       /* x*2 is x+x and x*(-1) is -x */
3087       if (GET_CODE (trueop1) == CONST_DOUBLE
3088          && SCALAR_FLOAT_MODE_P (GET_MODE (trueop1))
3089+         && !DECIMAL_FLOAT_MODE_P (GET_MODE (trueop1))
3090          && GET_MODE (op0) == mode)
3091        {
3092          REAL_VALUE_TYPE d;
3093@@ -5243,6 +5244,7 @@
3094       && GET_MODE_BITSIZE (innermode) >= (2 * GET_MODE_BITSIZE (outermode))
3095       && GET_CODE (XEXP (op, 1)) == CONST_INT
3096       && (INTVAL (XEXP (op, 1)) & (GET_MODE_BITSIZE (outermode) - 1)) == 0
3097+      && INTVAL (XEXP (op, 1)) >= 0
3098       && INTVAL (XEXP (op, 1)) < GET_MODE_BITSIZE (innermode)     
3099       && byte == subreg_lowpart_offset (outermode, innermode))
3100     {
3101diff -Naur gcc-4.4.1.orig/gcc/testsuite/ada/acats/support/impdef.a gcc-4.4.1/gcc/testsuite/ada/acats/support/impdef.a
3102--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/support/impdef.a     2006-01-26 12:39:16.000000000 -0800
3103+++ gcc-4.4.1/gcc/testsuite/ada/acats/support/impdef.a  2009-08-08 11:30:24.000000000 -0700
3104@@ -105,6 +105,8 @@
3105    Minimum_Task_Switch : constant Duration := 0.001;
3106    --                                         ^^^ --- MODIFY HERE AS NEEDED
3107 
3108+   Long_Minimum_Task_Switch : constant Duration := 0.1;
3109+
3110 --=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
3111 
3112    -- This is the time required to activate another task and allow it
3113@@ -117,13 +119,15 @@
3114    Switch_To_New_Task : constant Duration := 0.001;
3115    --                                        ^^^ -- MODIFY HERE AS NEEDED
3116 
3117+   Long_Switch_To_New_Task : constant Duration := 0.1;
3118+
3119 --=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
3120 
3121    -- This is the time which will clear the queues of other tasks
3122    -- waiting to run.  It is expected that this will be about five
3123    -- times greater than Switch_To_New_Task.
3124 
3125-   Clear_Ready_Queue : constant Duration := 1.1;
3126+   Clear_Ready_Queue : constant Duration := 0.1;
3127    --                                       ^^^ --- MODIFY HERE AS NEEDED
3128 
3129 --=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
3130diff -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
3131--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c940005.a   2003-10-27 03:29:00.000000000 -0800
3132+++ gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c940005.a        2009-08-08 11:30:24.000000000 -0700
3133@@ -85,7 +85,7 @@
3134       -- In reality one would expect a time of 5 to 10 seconds.  In
3135       -- the interests of speeding up the test suite a shorter time
3136       -- is used
3137-      Pulse_Time_Delta : constant duration := ImpDef.Switch_To_New_Task;
3138+      Pulse_Time_Delta : constant duration := ImpDef.Long_Switch_To_New_Task;
3139 
3140       -- control over stopping tasks
3141       protected Control is
3142diff -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
3143--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c940007.a   2003-10-27 03:29:00.000000000 -0800
3144+++ gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c940007.a        2009-08-08 11:30:24.000000000 -0700
3145@@ -90,7 +90,7 @@
3146       -- In reality one would expect a time of 5 to 10 seconds.  In
3147       -- the interests of speeding up the test suite a shorter time
3148       -- is used
3149-      Pulse_Time_Delta : constant duration := ImpDef.Switch_To_New_Task;
3150+      Pulse_Time_Delta : constant duration := ImpDef.Long_Switch_To_New_Task;
3151 
3152 
3153       -- control over stopping tasks
3154diff -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
3155--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c94001c.ada 2003-10-27 03:29:00.000000000 -0800
3156+++ gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c94001c.ada      2009-08-08 11:30:24.000000000 -0700
3157@@ -209,7 +209,7 @@
3158 
3159      BEGIN -- (E)
3160           WHILE NOT(OUT_TSK'TERMINATED) AND DELAY_COUNT < 60 LOOP
3161-               DELAY 1.0 * Impdef.One_Second;
3162+               DELAY 1.0 * Impdef.One_Long_Second;
3163                DELAY_COUNT := DELAY_COUNT + 1;
3164           END LOOP;
3165           IF DELAY_COUNT = 60 THEN
3166@@ -252,7 +252,7 @@
3167 
3168      BEGIN
3169           WHILE NOT(OUT_TSK'TERMINATED) AND DELAY_COUNT < 60 LOOP
3170-               DELAY 1.0 * Impdef.One_Second;
3171+               DELAY 1.0 * Impdef.One_Long_Second;
3172                DELAY_COUNT := DELAY_COUNT + 1;
3173           END LOOP;
3174           IF DELAY_COUNT = 60 THEN
3175diff -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
3176--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c94006a.ada 2003-10-27 03:29:00.000000000 -0800
3177+++ gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c94006a.ada      2009-08-08 11:30:24.000000000 -0700
3178@@ -42,7 +42,7 @@
3179           SELECT
3180                ACCEPT E;
3181           OR
3182-               DELAY 30.0 * Impdef.One_Second;
3183+               DELAY 30.0 * Impdef.One_Long_Second;
3184           END SELECT;
3185      END TT;
3186 
3187diff -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
3188--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c94008c.ada 2003-10-27 03:29:00.000000000 -0800
3189+++ gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c94008c.ada      2009-08-08 11:30:24.000000000 -0700
3190@@ -202,7 +202,7 @@
3191                     DELAY 10.0 * Impdef.One_Second;
3192 
3193                     IF TERMINATE_COUNT.GET /= 1 THEN
3194-                         DELAY 20.0 * Impdef.One_Second;
3195+                         DELAY 20.0 * Impdef.One_Long_Second;
3196                     END IF;
3197 
3198                     IF TERMINATE_COUNT.GET /= 1 THEN
3199@@ -243,7 +243,7 @@
3200           DELAY 10.0 * Impdef.One_Second; -- WAIT FOR T1, T2, AND T3 TO GET TO SELECT STMTS.
3201 
3202            IF TERMINATE_COUNT.GET /= 3 THEN
3203-                DELAY 20.0 * Impdef.One_Second;
3204+                DELAY 20.0 * Impdef.One_Long_Second;
3205            END IF;
3206 
3207            IF TERMINATE_COUNT.GET /= 3 THEN
3208diff -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
3209--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c951002.a   2003-10-27 03:29:00.000000000 -0800
3210+++ gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c951002.a        2009-08-08 11:30:24.000000000 -0700
3211@@ -278,14 +278,14 @@
3212       -- Wait until the message is queued on the entry before starting
3213       -- the Credit_Task
3214       while not Hold.TC_Message_is_Queued loop
3215-         delay ImpDef.Minimum_Task_Switch;   
3216+         delay ImpDef.Long_Minimum_Task_Switch;   
3217       end loop;
3218       --
3219       Credit_Task.TC_Start;
3220 
3221       -- Ensure the first part of the test is complete before continuing
3222       while not (Credit_Message'terminated and Credit_Task'terminated) loop
3223-         delay ImpDef.Minimum_Task_Switch;   
3224+         delay ImpDef.Long_Minimum_Task_Switch;   
3225       end loop;
3226 
3227       --======================================================
3228@@ -298,12 +298,12 @@
3229       -- for it to reach the accept statement and call Hold.Set_DB_Overload
3230       -- before starting Debit_Message
3231       --
3232-      delay ImpDef.Switch_To_New_Task;
3233+      delay ImpDef.Long_Switch_To_New_Task;
3234 
3235       Debit_Message.TC_Start;
3236 
3237       while not Debit_Task'terminated loop
3238-         delay ImpDef.Minimum_Task_Switch;   
3239+         delay ImpDef.Long_Minimum_Task_Switch;   
3240       end loop;   
3241   
3242       Hold.Clear_DB_Overload;  -- Allow completion
3243diff -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
3244--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c954a01.a   2003-10-27 03:29:00.000000000 -0800
3245+++ gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c954a01.a        2009-08-08 11:30:24.000000000 -0700
3246@@ -148,7 +148,7 @@
3247          end select;
3248 
3249          -- Allow other tasks to get control
3250-         delay ImpDef.Minimum_Task_Switch;
3251+         delay ImpDef.Long_Minimum_Task_Switch;
3252 
3253       end loop;
3254 
3255@@ -175,7 +175,7 @@
3256 
3257 procedure C954A01 is
3258 
3259-   Long_Enough : constant Duration := ImpDef.Switch_To_New_Task;
3260+   Long_Enough : constant Duration := ImpDef.Long_Switch_To_New_Task;
3261 
3262                --==============================================--
3263 
3264diff -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
3265--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c96001a.ada 2003-10-27 03:29:00.000000000 -0800
3266+++ gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c96001a.ada      2009-08-08 11:30:24.000000000 -0700
3267@@ -51,7 +51,7 @@
3268      ---------------------------------------------
3269 
3270      DECLARE   -- (A)
3271-          X : DURATION := 5.0;
3272+          X : DURATION := 5.0 * Impdef.One_Second;
3273           OLD_TIME : TIME;
3274           LAPSE : DURATION;
3275      BEGIN     -- (A)
3276diff -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
3277--- gcc-4.4.1.orig/gcc/testsuite/ada/acats/tests/c9/c97307a.ada 2003-10-27 03:29:00.000000000 -0800
3278+++ gcc-4.4.1/gcc/testsuite/ada/acats/tests/c9/c97307a.ada      2009-08-08 11:30:24.000000000 -0700
3279@@ -160,7 +160,7 @@
3280                          EXPIRED.READ (EXPIRED_CALLS);
3281                     EXIT WHEN E'COUNT >= DESIRED_QUEUE_LENGTH -
3282                                          EXPIRED_CALLS;
3283-                         DELAY 2.0 * Impdef.One_Second;
3284+                         DELAY 2.0 * Impdef.One_Long_Second;
3285                     END LOOP;
3286                EXIT WHEN DESIRED_QUEUE_LENGTH = 5;
3287                     DISPATCH.READY;
3288@@ -171,7 +171,7 @@
3289                -- LET THE TIMED ENTRY CALLS ISSUED BY CALLER1,
3290                -- CALLER3, AND CALLER5 EXPIRE:
3291 
3292-               DELAY DELAY_TIME + 10.0 * Impdef.One_Second;
3293+               DELAY DELAY_TIME + 10.0 * Impdef.One_Long_Second;
3294 
3295                -- AT THIS POINT, ALL THE TIMED ENTRY CALLS MUST HAVE
3296                -- EXPIRED AND BEEN REMOVED FROM THE ENTRY QUEUE FOR E,
3297diff -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
3298--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c  2008-12-29 02:31:14.000000000 -0800
3299+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c       2009-08-28 02:57:51.000000000 -0700
3300@@ -1,4 +1,5 @@
3301 /* { dg-skip-if "too complex for avr and picochip" { picochip-*-* avr-*-* } { "*" } { "" } } */
3302+/* { dg-timeout-factor 4.0 } */
3303 #define LIM1(x) x##0, x##1, x##2, x##3, x##4, x##5, x##6, x##7, x##8, x##9,
3304 #define LIM2(x) LIM1(x##0) LIM1(x##1) LIM1(x##2) LIM1(x##3) LIM1(x##4) \
3305                LIM1(x##5) LIM1(x##6) LIM1(x##7) LIM1(x##8) LIM1(x##9)
3306diff -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
3307--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40321.c        1969-12-31 16:00:00.000000000 -0800
3308+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40321.c     2009-07-22 07:45:21.000000000 -0700
3309@@ -0,0 +1,12 @@
3310+struct X { int flag; int pos; };
3311+int foo(struct X *a, struct X *b)
3312+{
3313+  while (1)
3314+    {
3315+      if (a->flag)
3316+       break;
3317+      ({ struct X *tmp = a; a = b; b = tmp; });
3318+    }
3319+
3320+  return a->pos + b->pos;
3321+}
3322diff -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
3323--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40570.c        1969-12-31 16:00:00.000000000 -0800
3324+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40570.c     2009-08-05 07:45:15.000000000 -0700
3325@@ -0,0 +1,22 @@
3326+extern void anything(int);
3327+
3328+static int foo(int i);
3329+
3330+static int bar(int i) { foo(i); }
3331+
3332+extern int j;
3333+
3334+static int foo(int i)
3335+{
3336+  if (j)
3337+    anything(j);
3338+  return bar(i);
3339+}
3340+
3341+int baz()
3342+{
3343+  foo(0);
3344+  if (baz())
3345+    return 1;
3346+  return 0;
3347+}
3348diff -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
3349--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40676.c        1969-12-31 16:00:00.000000000 -0800
3350+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40676.c     2009-07-23 10:50:56.000000000 -0700
3351@@ -0,0 +1,33 @@
3352+extern int f1();
3353+extern int f2(void*);
3354+extern void* f3(int);
3355+int xmsih;
3356+typedef unsigned short XWCHAR;
3357+
3358+inline unsigned int xstrlenW( const XWCHAR *str )
3359+{
3360+    const XWCHAR *s = str;
3361+    while (*s) s++;
3362+    return s - str;
3363+}
3364+
3365+
3366+static int msi_dialog_register_class( void )
3367+{
3368+    int cls;
3369+
3370+    if( !f2( &cls ) )
3371+        return 0;
3372+    if( !f2( &cls ) )
3373+        return 0;
3374+    xmsih = f1();
3375+    if( !xmsih )
3376+        return 0;
3377+    return 1;
3378+}
3379+
3380+void *xmsi_dialog_create(const XWCHAR* szDialogName)
3381+{
3382+    msi_dialog_register_class();
3383+    return f3(xstrlenW(szDialogName));
3384+}
3385diff -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
3386--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40692.c        1969-12-31 16:00:00.000000000 -0800
3387+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40692.c     2009-07-23 10:50:56.000000000 -0700
3388@@ -0,0 +1,15 @@
3389+/* PR middle-end/40692 */
3390+
3391+#define M1(x) (((x) & 0x00000002) ? 0x2 : ((x) & 0x1))
3392+#define M2(x) (((x) & 0x0000000c) ? M1 ((x) >> 2) << 2 : M1 (x))
3393+#define M3(x) (((x) & 0x000000f0) ? M2 ((x) >> 4) << 4 : M2 (x))
3394+#define M4(x) (((x) & 0x0000ff00) ? M3 ((x) >> 8) << 8 : M3 (x))
3395+#define M5(x) (((x) & 0xffff0000) ? M4 ((x) >> 16) << 16 : M4 (x))
3396+
3397+struct A { char e; char f; };
3398+
3399+long
3400+foo (void)
3401+{
3402+  return M5 (4096UL - (long) &((struct A *) 0)->f);
3403+}
3404diff -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
3405--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40753.c        1969-12-31 16:00:00.000000000 -0800
3406+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40753.c     2009-07-23 10:50:56.000000000 -0700
3407@@ -0,0 +1,20 @@
3408+typedef struct {
3409+    unsigned nargs;
3410+} ffi_cif;
3411+typedef struct {
3412+    char tramp[24];
3413+    ffi_cif *cif;
3414+} ffi_closure;
3415+extern void *memcpy (void *, const void *, __SIZE_TYPE__);
3416+extern void ffi_closure_LINUX64 (void);
3417+
3418+int
3419+ffi_prep_closure_loc (ffi_closure *closure, ffi_cif *cif)
3420+{
3421+  void **tramp = (void **) &closure->tramp[0];
3422+
3423+  memcpy (tramp, (char *) ffi_closure_LINUX64, 16);
3424+  closure->cif = cif;
3425+
3426+  return 0;
3427+}
3428diff -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
3429--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr40964.c        1969-12-31 16:00:00.000000000 -0800
3430+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr40964.c     2009-08-16 13:23:57.000000000 -0700
3431@@ -0,0 +1,10 @@
3432+struct alloc2 {
3433+    int bla;
3434+    char * __restrict data;
3435+    char * __restrict data2;
3436+};
3437+struct alloc2 b;
3438+void * f (void)
3439+{
3440+  return b.data;
3441+}
3442diff -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
3443--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41006-1.c      1969-12-31 16:00:00.000000000 -0800
3444+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41006-1.c   2009-08-16 13:23:57.000000000 -0700
3445@@ -0,0 +1,17 @@
3446+typedef int (*FARPROC)();
3447+
3448+typedef int (*LPFN_ACCEPTEX)(void*);
3449+static LPFN_ACCEPTEX acceptex_fn;
3450+
3451+int xWSAIoctl(void*);
3452+static void get_fn(FARPROC* fn)
3453+{
3454+    FARPROC func;
3455+    if (!xWSAIoctl( &func))
3456+        *fn = func;
3457+}
3458+
3459+void get_fn_pointers()
3460+{
3461+    get_fn((FARPROC*)&acceptex_fn);
3462+}
3463diff -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
3464--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41006-2.c      1969-12-31 16:00:00.000000000 -0800
3465+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41006-2.c   2009-08-16 13:23:57.000000000 -0700
3466@@ -0,0 +1,15 @@
3467+typedef int *FARPROC;
3468+static int * __restrict__ acceptex_fn;
3469+
3470+int xWSAIoctl(void*);
3471+static void get_fn(FARPROC* fn)
3472+{
3473+  FARPROC func;
3474+  if (!xWSAIoctl( &func))
3475+    *fn = func;
3476+}
3477+
3478+void get_fn_pointers()
3479+{
3480+  get_fn((FARPROC*)&acceptex_fn);
3481+}
3482diff -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
3483--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41016.c        1969-12-31 16:00:00.000000000 -0800
3484+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41016.c     2009-08-09 14:39:19.000000000 -0700
3485@@ -0,0 +1,17 @@
3486+typedef struct _IO_FILE FILE;
3487+void
3488+CompareRNAStructures (FILE * ofp, int start, int L, char *ss_true, char *ss)
3489+{
3490+  int i;
3491+  float agree = 0.;
3492+  float pairs = 0.;
3493+  float pairs_true = 0.;
3494+  for (i = 0; i < L; i++)
3495+    {
3496+      pairs_true += 1.;
3497+      agree += 1.;
3498+    }
3499+  if (((int) pairs % 2 != 0) || ((int) pairs_true % 2 != 0)
3500+      || ((int) agree % 2 != 0))
3501+    Die ("Error in CompareRNAStrutures(); odd number of paired nucleotides\n");
3502+}
3503diff -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
3504--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41163.c        1969-12-31 16:00:00.000000000 -0800
3505+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41163.c     2009-08-29 19:06:32.000000000 -0700
3506@@ -0,0 +1,10 @@
3507+struct option {
3508+    void *value;
3509+};
3510+void parse_options (struct option *);
3511+void cmd_grep(void)
3512+{
3513+  struct option options[] = { { &options } };
3514+  parse_options(options);
3515+}
3516+
3517diff -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
3518--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41181.c        1969-12-31 16:00:00.000000000 -0800
3519+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41181.c     2009-09-10 11:57:46.000000000 -0700
3520@@ -0,0 +1,10 @@
3521+char paths[1024];
3522+static void x264_slicetype_path(char (*best_paths)[250], int n, int length)
3523+{
3524+    __builtin_memcpy (best_paths[n], paths, length);
3525+}
3526+void x264_slicetype_analyse(int n, int length)
3527+{
3528+    char best_paths[250][250];
3529+    x264_slicetype_path (best_paths, n, length);
3530+}
3531diff -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
3532--- gcc-4.4.1.orig/gcc/testsuite/gcc.c-torture/compile/pr41282.c        1969-12-31 16:00:00.000000000 -0800
3533+++ gcc-4.4.1/gcc/testsuite/gcc.c-torture/compile/pr41282.c     2009-09-10 11:57:46.000000000 -0700
3534@@ -0,0 +1,20 @@
3535+struct S
3536+{
3537+  unsigned int iu;
3538+};
3539+
3540+union U
3541+{
3542+  struct S s;
3543+  signed int is;
3544+};
3545+
3546+extern signed int bar ();
3547+
3548+struct S foo (void)
3549+{
3550+  union U u;
3551+
3552+  u.is = bar ();
3553+  return u.s;
3554+}
3555diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20010912-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20010912-1.c
3556--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20010912-1.c    2005-10-15 18:14:19.000000000 -0700
3557+++ gcc-4.4.1/gcc/testsuite/gcc.dg/20010912-1.c 2009-07-27 23:56:49.000000000 -0700
3558@@ -1,6 +1,5 @@
3559 /* { dg-do run { target fpic } } */
3560 /* { dg-options "-O2 -fpic" } */
3561-/* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
3562 
3563 extern void abort (void);
3564 extern void exit (int);
3565diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20021018-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20021018-1.c
3566--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20021018-1.c    2005-10-15 18:14:19.000000000 -0700
3567+++ gcc-4.4.1/gcc/testsuite/gcc.dg/20021018-1.c 2009-07-27 23:56:49.000000000 -0700
3568@@ -1,6 +1,5 @@
3569 /* { dg-do run { target fpic } } */
3570 /* { dg-options "-O2 -fpic" } */
3571-/* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
3572 
3573 extern void abort (void);
3574 extern void exit (int);
3575diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20030213-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20030213-1.c
3576--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20030213-1.c    2005-10-15 18:14:19.000000000 -0700
3577+++ gcc-4.4.1/gcc/testsuite/gcc.dg/20030213-1.c 2009-07-27 23:56:49.000000000 -0700
3578@@ -1,7 +1,6 @@
3579 /* Testcase for http://gcc.gnu.org/ml/gcc-patches/2003-02/msg01017.html */
3580 /* { dg-do link { target fpic } } */
3581 /* { dg-options "-O -fpic" } */
3582-/* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
3583 
3584 int *g;
3585 
3586diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20030225-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20030225-1.c
3587--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20030225-1.c    2005-10-15 18:14:19.000000000 -0700
3588+++ gcc-4.4.1/gcc/testsuite/gcc.dg/20030225-1.c 2009-07-27 23:56:49.000000000 -0700
3589@@ -5,7 +5,6 @@
3590    and Benjamin Herrenschmidt <benh@kernel.crashing.org>.  */
3591 /* { dg-do run { target fpic } } */
3592 /* { dg-options "-O2 -fPIC" } */
3593-/* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
3594 
3595 extern void exit (int);
3596 
3597diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20030708-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20030708-1.c
3598--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20030708-1.c    2005-10-15 18:14:19.000000000 -0700
3599+++ gcc-4.4.1/gcc/testsuite/gcc.dg/20030708-1.c 2009-07-27 23:56:49.000000000 -0700
3600@@ -1,7 +1,6 @@
3601 /* PR c/11420 */
3602 /* { dg-do link { target fpic } } */
3603 /* { dg-options "-O2 -fpic" } */
3604-/* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
3605 
3606 void (* volatile fn) (void);
3607 static void foo (void)
3608diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20050321-2.c gcc-4.4.1/gcc/testsuite/gcc.dg/20050321-2.c
3609--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20050321-2.c    2006-04-13 16:14:25.000000000 -0700
3610+++ gcc-4.4.1/gcc/testsuite/gcc.dg/20050321-2.c 2009-07-27 23:56:49.000000000 -0700
3611@@ -5,7 +5,6 @@
3612    figure out branch to lab is too far.  */
3613 /* { dg-do link { target fpic } } */
3614 /* { dg-options "-g1 -fpic" } */
3615-/* { dg-bogus "\[Uu\]nresolved symbol .(_GLOBAL_OFFSET_TABLE_|\[_.A-Za-z\]\[_.0-9A-Za-z\]*@(PLT|GOT|GOTOFF))" "PIC unsupported" { xfail *-*-netware* } 0 } */
3616 /* { dg-require-effective-target int32plus } */
3617 
3618 #define A(n) \
3619diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20090902-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/20090902-1.c
3620--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/20090902-1.c    1969-12-31 16:00:00.000000000 -0800
3621+++ gcc-4.4.1/gcc/testsuite/gcc.dg/20090902-1.c 2009-09-02 11:47:29.000000000 -0700
3622@@ -0,0 +1,3 @@
3623+/* { dg-do compile } */
3624+#define STRING(x) #x
3625+char buf[] = STRING(L'\x123');
3626diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-15.c gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-15.c
3627--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-15.c     2009-01-25 12:15:44.000000000 -0800
3628+++ gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-15.c  2009-07-27 23:56:49.000000000 -0700
3629@@ -1,6 +1,7 @@
3630 /* { dg-do compile } */
3631 /* Remove pedantic.  Allow the GCC extension to use char for bitfields.  */
3632 /* { dg-options "" } */
3633+/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
3634 
3635 struct t
3636 {
3637diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-16.c gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-16.c
3638--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-16.c     2009-01-22 22:29:54.000000000 -0800
3639+++ gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-16.c  2009-07-27 23:56:49.000000000 -0700
3640@@ -1,5 +1,6 @@
3641 /* { dg-do compile } */
3642 /* { dg-options "-Wno-packed-bitfield-compat" } */
3643+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
3644 
3645 struct t
3646 {
3647diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-17.c gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-17.c
3648--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-17.c     2009-01-25 12:15:44.000000000 -0800
3649+++ gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-17.c  2009-07-27 23:56:49.000000000 -0700
3650@@ -1,5 +1,6 @@
3651 /* { dg-do compile } */
3652 /* { dg-options "" } */
3653+/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
3654 
3655 struct t
3656 {
3657diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-18.c gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-18.c
3658--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/bitfld-18.c     2009-01-22 22:29:54.000000000 -0800
3659+++ gcc-4.4.1/gcc/testsuite/gcc.dg/bitfld-18.c  2009-07-27 23:56:49.000000000 -0700
3660@@ -1,5 +1,6 @@
3661 /* { dg-do compile } */
3662 /* { dg-options "-Wno-packed-bitfield-compat" } */
3663+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
3664 
3665 struct t
3666 {
3667diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/builtins-10.c gcc-4.4.1/gcc/testsuite/gcc.dg/builtins-10.c
3668--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/builtins-10.c   2005-03-09 12:11:48.000000000 -0800
3669+++ gcc-4.4.1/gcc/testsuite/gcc.dg/builtins-10.c        2009-08-24 02:52:03.000000000 -0700
3670@@ -25,7 +25,7 @@
3671     link_error ();
3672 
3673   if (pow(pow(x,4.0),0.25) != x)
3674-    link_error ();
3675+    /* XFAIL.  PR41098.  */;
3676 }
3677 
3678 void test2(double x, double y, double z)
3679@@ -42,7 +42,7 @@
3680   if (pow(sqrt(x),y) != pow(x,y*0.5))
3681     link_error ();
3682 
3683-  if (pow(pow(x,y),z) != pow(x,y*z))
3684+  if (pow(pow(fabs(x),y),z) != pow(fabs(x),y*z))
3685     link_error ();
3686 }
3687 
3688diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/builtins-config.h gcc-4.4.1/gcc/testsuite/gcc.dg/builtins-config.h
3689--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/builtins-config.h       2008-06-18 14:41:13.000000000 -0700
3690+++ gcc-4.4.1/gcc/testsuite/gcc.dg/builtins-config.h    2009-08-30 15:45:18.000000000 -0700
3691@@ -1,4 +1,4 @@
3692-/* Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation.
3693+/* Copyright (C) 2003, 2004, 2005, 2006, 2009 Free Software Foundation.
3694 
3695    Define macros useful in tests for bulitin functions.  */
3696 
3697@@ -15,8 +15,8 @@
3698 /* Irix6 doesn't have the entire C99 runtime.  */
3699 #elif defined(__AVR__)
3700 /* AVR doesn't have the entire C99 runtime.  */
3701-#elif defined(__FreeBSD__) && (__FreeBSD__ < 5)
3702-/* FreeBSD before version 5 doesn't have the entire C99 runtime. */
3703+#elif defined(__FreeBSD__)
3704+/* FreeBSD up to at least version 8 lacks support for cexp and friends.  */
3705 #elif defined(__netware__)
3706 /* NetWare doesn't have the entire C99 runtime.  */
3707 #elif defined(__vxworks)
3708diff -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
3709--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/c90-const-expr-2.c      2008-04-25 01:40:10.000000000 -0700
3710+++ gcc-4.4.1/gcc/testsuite/gcc.dg/c90-const-expr-2.c   2009-09-08 12:10:43.000000000 -0700
3711@@ -14,8 +14,10 @@
3712 int b;
3713 long *c;
3714 
3715-#if defined(_LP64) || defined(_WIN64)
3716+#if defined(_LP64)
3717 #define ZERO 0L
3718+#elif defined(_WIN64)
3719+#define ZERO 0LL
3720 #else
3721 #define ZERO 0
3722 #endif
3723diff -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
3724--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/c99-const-expr-2.c      2008-04-25 01:40:10.000000000 -0700
3725+++ gcc-4.4.1/gcc/testsuite/gcc.dg/c99-const-expr-2.c   2009-09-08 12:10:43.000000000 -0700
3726@@ -14,8 +14,10 @@
3727 int b;
3728 long *c;
3729 
3730-#if defined(_LP64) || defined(_WIN64)
3731+#if defined(_LP64)
3732 #define ZERO 0L
3733+#elif defined(_WIN64)
3734+#define ZERO 0LL
3735 #else
3736 #define ZERO 0
3737 #endif
3738diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/cdce1.c gcc-4.4.1/gcc/testsuite/gcc.dg/cdce1.c
3739--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/cdce1.c 2009-02-05 03:59:20.000000000 -0800
3740+++ gcc-4.4.1/gcc/testsuite/gcc.dg/cdce1.c      2009-07-28 09:11:21.000000000 -0700
3741@@ -1,7 +1,8 @@
3742 /* { dg-do  run  } */
3743 /* { dg-skip-if "doubles are floats" { "avr-*-*" "m32c-*-*" } { "*" } { "" } } */
3744 /* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details  -lm" } */
3745-/* { dg-final { scan-tree-dump  "cdce1.c:16: note: function call is shrink-wrapped into error conditions\."  "cdce" } } */
3746+/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details" { target *-*-netware* } } */
3747+/* { dg-final { scan-tree-dump  "cdce1.c:17: note: function call is shrink-wrapped into error conditions\."  "cdce" } } */
3748 /* { dg-final { cleanup-tree-dump "cdce" } } */
3749 
3750 #include <stdlib.h>
3751diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/cdce2.c gcc-4.4.1/gcc/testsuite/gcc.dg/cdce2.c
3752--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/cdce2.c 2008-06-18 14:41:13.000000000 -0700
3753+++ gcc-4.4.1/gcc/testsuite/gcc.dg/cdce2.c      2009-07-28 09:11:21.000000000 -0700
3754@@ -1,7 +1,8 @@
3755 /* { dg-do  run  } */
3756 /* { dg-skip-if "doubles are floats" { "avr-*-*" } { "*" } { "" } } */
3757 /* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details  -lm" } */
3758-/* { dg-final { scan-tree-dump  "cdce2.c:16: note: function call is shrink-wrapped into error conditions\." "cdce" } }*/
3759+/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details" { target *-*-netware* } } */
3760+/* { dg-final { scan-tree-dump  "cdce2.c:17: note: function call is shrink-wrapped into error conditions\." "cdce" } }*/
3761 /* { dg-final { cleanup-tree-dump "cdce" } } */
3762 
3763 #include <stdlib.h>
3764diff -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
3765--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/debug/20020224-1.c      2002-02-26 11:05:26.000000000 -0800
3766+++ gcc-4.4.1/gcc/testsuite/gcc.dg/debug/20020224-1.c   2009-08-16 02:07:40.000000000 -0700
3767@@ -1,9 +1,13 @@
3768+/* { dg-options "-g3 -O" } */
3769 /* { dg-do compile } */
3770 
3771-/* Here's the deal: f3 is not inlined because it's too big, but f2 and
3772-   f1 are inlined into it.  We used to fail to emit debugging info for
3773-   t1, because it was moved inside the (inlined) block of f1, marked
3774-   as abstract, then we'd crash.  */
3775+/* Here's the deal: f4 is inlined into main, f3 is inlined into f4, f2 is
3776+   inlined into f1. The DIE of main should contain DW_TAG_inlined_subroutines
3777+   children for f4, f3, f2 and f1. Also, there should be a DIE representing
3778+   and out of line instance of f4, aside the DIE representing its abstract
3779+   instance.
3780+   We used to fail to emit debugging info for t1, because it was moved
3781+   inside the (inlined) block of f1, marked as abstract, then we'd crash.  */
3782 
3783 #define UNUSED __attribute__((unused))
3784 #define EXT __extension__
3785@@ -58,3 +62,10 @@
3786 
3787   return;
3788 }
3789+
3790+int
3791+main ()
3792+{
3793+    int foo = 1;
3794+    f4 ();
3795+}
3796diff -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
3797--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/debug/dwarf2/inline2.c  1969-12-31 16:00:00.000000000 -0800
3798+++ gcc-4.4.1/gcc/testsuite/gcc.dg/debug/dwarf2/inline2.c       2009-08-17 03:04:21.000000000 -0700
3799@@ -0,0 +1,70 @@
3800+/* Contributed by Dodji Seketeli <dodji@redhat.com>
3801+   Origin: PR debug/37801
3802+
3803+  Abstract instances (DW_TAG_subroutines having the DW_AT_inline attribute)
3804+  of second and first were having a DW_TAG_lexical_block DIE wrongly
3805+  representing the inlined calls to third (in second) and to
3806+  second (in first). At the same time, main didn't have children
3807+  DW_TAG_inlined_subroutine DIEs representing the inlined calls to
3808+  first, second and third.
3809+
3810+  The ideal goal here is to test that we have no superfluous
3811+  DW_TAG_lexical_block DIE anymore, that abstract instances DIEs have
3812+  no descendant DIE with a DW_AT_abstract_origin attribute, and that main has
3813+  properly nested DW_TAG_inlined_subroutine DIEs for third, second and first.
3814+*/
3815+
3816+/* { dg-options "-O -g3 -dA" } */
3817+/* { dg-do compile } */
3818+
3819+/* There are 6 inlined subroutines:
3820+   - One for each subroutine inlined into main, that's 3.
3821+   - One for earch subroutine inline into the out of line instances
3822+     of third, second and first.  */
3823+/* { dg-final { scan-assembler-times "\\(DIE \\(.*?\\) DW_TAG_inlined_subroutine" 6 } } */
3824+
3825+/* Likewise we should have 6 DW_TAG_lexical_block DIEs:
3826+   - One for each subroutine inlined into main, so that's 3.
3827+   - One for each subroutine inlined in the out of line instances
3828+     of third, second and first, that's 3.
3829+*/
3830+/* { dg-final { scan-assembler-times "\\(DIE \\(.*?\\) DW_TAG_lexical_block" 6 } } */
3831+
3832+
3833+/* There are 3 DW_AT_inline attributes: one per abstract inline instance.
3834+   The value of the attribute must be 0x3, meaning the function was
3835+   actually inlined.  */
3836+/* { dg-final { scan-assembler-times "byte.*?0x3.*? DW_AT_inline" 3 } } */
3837+
3838+
3839+inline void
3840+third (int arg3)
3841+{
3842+  int var3 = arg3;
3843+  int* a = 0;
3844+  a[0] = var3;
3845+}
3846+
3847+inline void
3848+second (int arg2)
3849+{
3850+  int var2 = arg2;
3851+  third (var2+1);
3852+}
3853+
3854+inline void
3855+first (int arg1)
3856+{
3857+  int var1 = arg1;
3858+  second (var1+1);
3859+}
3860+
3861+int
3862+main ()
3863+{
3864+  int some_int = 1;
3865+  first (some_int);
3866+  return 0;
3867+}
3868+
3869+
3870diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/dfp/pr39902.c gcc-4.4.1/gcc/testsuite/gcc.dg/dfp/pr39902.c
3871--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/dfp/pr39902.c   2009-06-29 10:13:33.000000000 -0700
3872+++ gcc-4.4.1/gcc/testsuite/gcc.dg/dfp/pr39902.c        2009-07-30 10:08:09.000000000 -0700
3873@@ -189,7 +189,7 @@
3874   if (COMPARE128 (a128, p128_2_0))
3875     FAILURE
3876 
3877-  a128.d = p128_2_0.d * 1.0DD;
3878+  a128.d = p128_2_0.d * 1.0DL;
3879   if (COMPARE128 (a128, p128_2_0))
3880     FAILURE
3881 
3882@@ -197,7 +197,7 @@
3883   if (COMPARE128 (a128, m128_2_0))
3884     FAILURE
3885 
3886-  a128.d = p128_2_0.d * -1.0DD;
3887+  a128.d = p128_2_0.d * -1.0DL;
3888   if (COMPARE128 (a128, m128_2_0))
3889     FAILURE
3890 
3891@@ -208,7 +208,7 @@
3892   if (! (COMPARE128 (a128, p128_2_0)))
3893     FAILURE
3894 
3895-  a128.d = p128_2_0.d * 1.DD;
3896+  a128.d = p128_2_0.d * 1.DL;
3897   if (! (COMPARE128 (a128, p128_2_0)))
3898     FAILURE
3899 
3900@@ -216,7 +216,7 @@
3901   if (! (COMPARE128 (a128, m128_2_0)))
3902     FAILURE
3903 
3904-  a128.d = p128_2_0.d * -1.DD;
3905+  a128.d = p128_2_0.d * -1.DL;
3906   if (! (COMPARE128 (a128, m128_2_0)))
3907     FAILURE
3908 }
3909diff -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
3910--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/large-size-array-2.c    2008-04-26 12:14:46.000000000 -0700
3911+++ gcc-4.4.1/gcc/testsuite/gcc.dg/large-size-array-2.c 2009-09-08 12:10:43.000000000 -0700
3912@@ -4,4 +4,4 @@
3913 static char * name[] = {
3914     [0x80000000]  = "bar"
3915   };
3916-/* { dg-error "too large" "" { target { { ! lp64 } || x86_64-*-mingw* } }  6 } */
3917+/* { dg-error "too large" "" { target { { ! lp64 } && { ! llp64 } } }  6 } */
3918diff -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
3919--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/large-size-array-4.c    2008-04-26 12:14:46.000000000 -0700
3920+++ gcc-4.4.1/gcc/testsuite/gcc.dg/large-size-array-4.c 2009-09-08 12:10:43.000000000 -0700
3921@@ -4,4 +4,4 @@
3922 static char * name[] = {
3923     [0x80000000]  = "bar"
3924   };
3925-/* { dg-error "too large" "" { target { { ! lp64 } || x86_64-*-mingw* } }  6 } */
3926+/* { dg-error "too large" "" { target { { ! lp64 } && { ! llp64 } } }  6 } */
3927diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr40861.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr40861.c
3928--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr40861.c       1969-12-31 16:00:00.000000000 -0800
3929+++ gcc-4.4.1/gcc/testsuite/gcc.dg/pr40861.c    2009-09-07 13:25:52.000000000 -0700
3930@@ -0,0 +1,7 @@
3931+/* { dg-do compile } */
3932+/* { dg-options "-O" } */
3933+
3934+int foo(int i)
3935+{
3936+  return (1LL >> 128 * i) && i;
3937+}
3938diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr40971.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr40971.c
3939--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr40971.c       1969-12-31 16:00:00.000000000 -0800
3940+++ gcc-4.4.1/gcc/testsuite/gcc.dg/pr40971.c    2009-08-18 04:43:16.000000000 -0700
3941@@ -0,0 +1,23 @@
3942+/* PR target/40971 */
3943+/* { dg-do compile } */
3944+/* { dg-options "-O -fstack-protector -fno-strict-aliasing" } */
3945+/* { dg-require-effective-target fstack_protector } */
3946+
3947+extern void bar (char *);
3948+
3949+void
3950+foo (int f, long a)
3951+{
3952+  {
3953+    char d[32768];
3954+    bar (d);
3955+  }
3956+  double b = f;
3957+  while (a)
3958+    {
3959+      char c[sizeof (double)];
3960+      __builtin_memcpy (c, &b, sizeof (c));
3961+      if (*(double *) c != 2.0)
3962+       break;
3963+    }
3964+}
3965diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr41033.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr41033.c
3966--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr41033.c       1969-12-31 16:00:00.000000000 -0800
3967+++ gcc-4.4.1/gcc/testsuite/gcc.dg/pr41033.c    2009-08-12 23:28:28.000000000 -0700
3968@@ -0,0 +1,24 @@
3969+/* { dg-options "-O1 -fno-strict-aliasing" } */
3970+/* PR rtl-optimization/41033 */
3971+
3972+struct X {
3973+  int i;
3974+  int j;
3975+};
3976+
3977+int foo(struct X *p, struct X *q)
3978+{
3979+  p->j = 1;
3980+  q->i = 0;
3981+  return p->j;
3982+}
3983+
3984+extern void abort (void);
3985+
3986+int main()
3987+{
3988+  struct X x;
3989+  if (foo (&x, (struct X *)&x.j) != 0)
3990+    abort ();
3991+  return 0;
3992+}
3993diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr41123.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr41123.c
3994--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr41123.c       1969-12-31 16:00:00.000000000 -0800
3995+++ gcc-4.4.1/gcc/testsuite/gcc.dg/pr41123.c    2009-08-19 15:52:11.000000000 -0700
3996@@ -0,0 +1,46 @@
3997+/* PR middle-end/41123 */
3998+/* { dg-do compile } */
3999+/* { dg-options "-O2 -fno-strict-aliasing" } */
4000+
4001+struct S { char a, b, c, d, e, f, g, h; };
4002+struct T { int a, b; };
4003+
4004+struct S
4005+f1 (float _Complex x)
4006+{
4007+  return *(struct S *) & x;
4008+}
4009+
4010+int
4011+f2 (float _Complex x)
4012+{
4013+  struct S f = f1 (x);
4014+  return f.b;
4015+}
4016+
4017+struct T
4018+f3 (float _Complex x)
4019+{
4020+  return *(struct T *) & x;
4021+}
4022+
4023+int
4024+f4 (float _Complex x)
4025+{
4026+  struct T f = f3 (x);
4027+  return f.a;
4028+}
4029+
4030+int
4031+f5 (float _Complex x)
4032+{
4033+  struct T f = f3 (x);
4034+  return f.b;
4035+}
4036+
4037+struct T
4038+f6 (float _Complex x)
4039+{
4040+  struct T f = f3 (x);
4041+  return f;
4042+}
4043diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr41232.c gcc-4.4.1/gcc/testsuite/gcc.dg/pr41232.c
4044--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/pr41232.c       1969-12-31 16:00:00.000000000 -0800
4045+++ gcc-4.4.1/gcc/testsuite/gcc.dg/pr41232.c    2009-09-10 11:57:46.000000000 -0700
4046@@ -0,0 +1,14 @@
4047+/* { dg-do compile } */
4048+/* { dg-options "-O1 -g" } */
4049+extern int atoi (const char *);
4050+extern int sprintf (char *, const char *, ...);
4051+void malloc_init() {
4052+  char *cptr;
4053+  char buf[1];
4054+  int tmbd = atoi(cptr);
4055+  if (tmbd > 0)
4056+    tmbd = (tmbd <= 124) ? tmbd : 124;
4057+   else
4058+    tmbd = 0;
4059+   sprintf(buf, "%d\n", tmbd);
4060+}
4061diff -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
4062--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/special/gcsec-1.c       2007-05-07 11:28:41.000000000 -0700
4063+++ gcc-4.4.1/gcc/testsuite/gcc.dg/special/gcsec-1.c    2009-07-25 06:54:21.000000000 -0700
4064@@ -3,10 +3,8 @@
4065 /* { dg-do run { xfail rs6000-*-aix* powerpc*-*-aix* } } */
4066 /* { dg-require-gc-sections "" } */
4067 
4068-/* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections -static" } */
4069-/* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections -static" { target native } } */
4070-/* Solaris 10 does not support static linking; there is no libc.a.  */
4071-/* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections" { target *-*-netware* i?86-*-solaris2.1[0-9] } } */
4072+/* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections" } */
4073+/* { dg-options "-ffunction-sections -fdata-sections -Wl,--gc-sections -static" { target static } } */
4074 
4075 #include <stdlib.h>
4076 
4077diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/ssp-1.c gcc-4.4.1/gcc/testsuite/gcc.dg/ssp-1.c
4078--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/ssp-1.c 2007-03-28 16:08:26.000000000 -0700
4079+++ gcc-4.4.1/gcc/testsuite/gcc.dg/ssp-1.c      2009-08-10 10:35:05.000000000 -0700
4080@@ -4,7 +4,7 @@
4081 
4082 #include <stdlib.h>
4083 
4084-static void
4085+void
4086 __stack_chk_fail (void)
4087 {
4088   exit (0); /* pass */
4089diff -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
4090--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/builtin-power-1.c       2007-09-22 01:25:43.000000000 -0700
4091+++ gcc-4.4.1/gcc/testsuite/gcc.dg/torture/builtin-power-1.c    2009-08-24 02:52:03.000000000 -0700
4092@@ -77,9 +77,9 @@
4093   /* Test pow(pow(x,y),z) -> pow(x,y*z).  */
4094 #define POW_POW \
4095  extern void link_failure_pow_pow(void); \
4096- if (pow(pow(d1, d2), d3) != pow(d1,d2*d3) \
4097-     || powf(powf(f1,f2),f3) != powf(f1,f2*f3) \
4098-     || powl(powl(ld1,ld2),ld3) != powl(ld1,ld2*ld3)) \
4099+ if (pow(pow(fabs(d1), d2), d3) != pow(fabs(d1),d2*d3) \
4100+     || powf(powf(fabs(f1),f2),f3) != powf(fabs(f1),f2*f3) \
4101+     || powl(powl(fabs(ld1),ld2),ld3) != powl(fabs(ld1),ld2*ld3)) \
4102     link_failure_pow_pow()
4103 
4104   POW_POW;
4105diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/pr39074.c gcc-4.4.1/gcc/testsuite/gcc.dg/torture/pr39074.c
4106--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/pr39074.c       2009-02-19 02:12:25.000000000 -0800
4107+++ gcc-4.4.1/gcc/testsuite/gcc.dg/torture/pr39074.c    2009-09-08 12:10:43.000000000 -0700
4108@@ -2,9 +2,11 @@
4109 /* { dg-options "-fdump-tree-alias" } */
4110 /* { dg-skip-if "" { *-*-* } { "-O0" } { "" } } */
4111 
4112+typedef __PTRDIFF_TYPE__ intptr_t;
4113+
4114 int i;
4115 void __attribute__((noinline))
4116-foo(long b, long q)
4117+foo(long b, intptr_t q)
4118 {
4119   int *y;
4120   int **a = &y, **x;
4121diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/pr41094.c gcc-4.4.1/gcc/testsuite/gcc.dg/torture/pr41094.c
4122--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/pr41094.c       1969-12-31 16:00:00.000000000 -0800
4123+++ gcc-4.4.1/gcc/testsuite/gcc.dg/torture/pr41094.c    2009-08-24 02:52:03.000000000 -0700
4124@@ -0,0 +1,19 @@
4125+/* { dg-do run } */
4126+/* { dg-options "-ffast-math" } */
4127+
4128+#include <math.h>
4129+
4130+extern void abort (void);
4131+
4132+double foo(void)
4133+{
4134+  double x = -4.0;
4135+  return pow (x * x, 0.25);
4136+}
4137+
4138+int main()
4139+{
4140+  if (foo() != 2.0)
4141+    abort ();
4142+  return 0;
4143+}
4144diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/pr41261.c gcc-4.4.1/gcc/testsuite/gcc.dg/torture/pr41261.c
4145--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/torture/pr41261.c       1969-12-31 16:00:00.000000000 -0800
4146+++ gcc-4.4.1/gcc/testsuite/gcc.dg/torture/pr41261.c    2009-09-10 11:57:46.000000000 -0700
4147@@ -0,0 +1,8 @@
4148+/* { dg-do compile } */
4149+/* { dg-options "-fprofile-arcs" } */
4150+
4151+extern void relocate_kernel();
4152+void machine_kexec(void *control_page)
4153+{
4154+  __builtin_memcpy(control_page, relocate_kernel, 2048);
4155+}
4156diff -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
4157--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/tree-ssa/pr33920.c      2009-02-05 03:59:20.000000000 -0800
4158+++ gcc-4.4.1/gcc/testsuite/gcc.dg/tree-ssa/pr33920.c   2009-09-08 12:10:43.000000000 -0700
4159@@ -2,6 +2,7 @@
4160 /* { dg-do compile } */
4161 /* { dg-options "-O3" } */
4162 
4163+typedef __PTRDIFF_TYPE__ intptr_t;
4164 typedef union lispunion *object;
4165 struct character
4166 {
4167@@ -22,14 +23,14 @@
4168   object V659;
4169   object _x, _y;
4170   object V643;
4171-  long V648;
4172+  intptr_t V648;
4173   unsigned char V653;
4174   object V651;
4175   object V654;
4176   object V658;
4177 
4178 T1240:
4179-if (V648 >= (long)V651) /* { dg-warning "cast from pointer to integer of different size" "" { target { ! int32plus } } } */
4180+if (V648 >= (intptr_t)V651) /* { dg-warning "cast from pointer to integer of different size" "" { target { ! int32plus } } } */
4181     goto T1243;
4182   V653 = ((char *) V654->v.v_self)[V648];
4183   V659 = (object) V654 + V653;
4184@@ -41,7 +42,7 @@
4185     goto T1249;
4186   goto T1224;
4187 T1249:
4188- V648 = (long) V648 + 1;
4189+  V648 = (intptr_t) V648 + 1;
4190   goto T1240;
4191 T1243:
4192   V643 = (object) & Cnil_body;
4193diff -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
4194--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/tree-ssa/ssa-ccp-27.c   1969-12-31 16:00:00.000000000 -0800
4195+++ gcc-4.4.1/gcc/testsuite/gcc.dg/tree-ssa/ssa-ccp-27.c        2009-08-16 13:23:57.000000000 -0700
4196@@ -0,0 +1,24 @@
4197+/* { dg-do compile } */
4198+/* { dg-options "-O2 -fdump-tree-ccp1" } */
4199+
4200+#include <string.h>
4201+
4202+char c[10];
4203+
4204+void
4205+f1 ()
4206+{
4207+  const char *p = "123456";
4208+  memcpy (c, p, 6);
4209+}
4210+
4211+void
4212+f2 ()
4213+{
4214+  const char *p = "12345678";
4215+  p += 2;
4216+  memcpy (c, p, 6);
4217+}
4218+
4219+/* { dg-final { scan-tree-dump-times "memcpy\[^\n\]*123456" 2 "ccp1" } } */
4220+/* { dg-final { cleanup-tree-dump "ccp1" } } */
4221diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/uninit-6.c gcc-4.4.1/gcc/testsuite/gcc.dg/uninit-6.c
4222--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/uninit-6.c      2008-08-20 15:23:45.000000000 -0700
4223+++ gcc-4.4.1/gcc/testsuite/gcc.dg/uninit-6.c   2009-08-03 12:27:32.000000000 -0700
4224@@ -39,7 +39,7 @@
4225     rv = malloc (sizeof (struct tree));
4226     rv->car = 0;
4227 
4228-    APPEND(rv, field, INTEGER_T, a);  /* { dg-bogus "field" "uninitialized variable warning" } */
4229+    APPEND(rv, field, INTEGER_T, a);  /* { dg-bogus "field" "uninitialized variable warning" { xfail *-*-* } } */
4230     APPEND(rv, field, PTR_T, b);
4231     APPEND(rv, field, INTEGER_T, c);
4232 
4233diff -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
4234--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/uninit-6-O0.c   2008-08-20 15:23:45.000000000 -0700
4235+++ gcc-4.4.1/gcc/testsuite/gcc.dg/uninit-6-O0.c        2009-08-03 12:27:32.000000000 -0700
4236@@ -39,7 +39,7 @@
4237     rv = malloc (sizeof (struct tree));
4238     rv->car = 0;
4239 
4240-    APPEND(rv, field, INTEGER_T, a);  /* { dg-bogus "field" "uninitialized variable warning" } */
4241+    APPEND(rv, field, INTEGER_T, a);  /* { dg-bogus "field" "uninitialized variable warning" { xfail *-*-* } } */
4242     APPEND(rv, field, PTR_T, b);
4243     APPEND(rv, field, INTEGER_T, c);
4244 
4245diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/uninit-pr40943.c gcc-4.4.1/gcc/testsuite/gcc.dg/uninit-pr40943.c
4246--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/uninit-pr40943.c        1969-12-31 16:00:00.000000000 -0800
4247+++ gcc-4.4.1/gcc/testsuite/gcc.dg/uninit-pr40943.c     2009-08-03 12:27:32.000000000 -0700
4248@@ -0,0 +1,10 @@
4249+/* PR middle-end/40943 */
4250+/* { dg-do compile } */
4251+/* { dg-options "-O2 -Wuninitialized" } */
4252+
4253+void
4254+foo (void)
4255+{
4256+  int *p;
4257+  *p = 3;      /* { dg-warning "is used uninitialized" } */
4258+}
4259diff -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
4260--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/no-scevccp-noreassoc-outer-2.c     2007-09-04 06:05:19.000000000 -0700
4261+++ gcc-4.4.1/gcc/testsuite/gcc.dg/vect/no-scevccp-noreassoc-outer-2.c  2009-07-28 09:51:19.000000000 -0700
4262@@ -4,7 +4,7 @@
4263 #include "tree-vect.h"
4264 
4265 #define N 40
4266-int a[200*N];
4267+int a[200*N+N];
4268 
4269 __attribute__ ((noinline)) void
4270 foo (){
4271diff -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
4272--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/O1-pr33854.c       2007-10-22 05:05:36.000000000 -0700
4273+++ gcc-4.4.1/gcc/testsuite/gcc.dg/vect/O1-pr33854.c    2009-09-08 12:10:43.000000000 -0700
4274@@ -1,7 +1,7 @@
4275 /* Testcase by Martin Michlmayr <tbm@cyrius.com> */
4276 /* { dg-do compile } */
4277 
4278-extern void *malloc (long unsigned int __size);
4279+extern void *malloc (__SIZE_TYPE__ __size);
4280 typedef struct VMatrix_ VMatrix;
4281 struct VMatrix_
4282 {
4283diff -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
4284--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/O1-pr41008.c       1969-12-31 16:00:00.000000000 -0800
4285+++ gcc-4.4.1/gcc/testsuite/gcc.dg/vect/O1-pr41008.c    2009-08-16 13:23:57.000000000 -0700
4286@@ -0,0 +1,23 @@
4287+/* { dg-do compile } */
4288+
4289+double heating[2][2];
4290+
4291+void foo (int, int);
4292+
4293+void map_do()
4294+{
4295+  int jsav, ksav, k, j;
4296+
4297+  for(k = 0; k < 2; k++)
4298+    for(j = 0; j < 2; j++)
4299+      if (heating[k][j] > 0.)
4300+        {
4301+          jsav = j;
4302+          ksav = k;
4303+        }
4304+
4305+  foo (jsav, ksav);
4306+}
4307+
4308+/* { dg-final { cleanup-tree-dump "vect" } } */
4309+
4310diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/pr33833.c gcc-4.4.1/gcc/testsuite/gcc.dg/vect/pr33833.c
4311--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/pr33833.c  2007-10-25 09:41:45.000000000 -0700
4312+++ gcc-4.4.1/gcc/testsuite/gcc.dg/vect/pr33833.c       2009-09-08 12:10:43.000000000 -0700
4313@@ -1,6 +1,10 @@
4314 /* Testcase by Martin Michlmayr <tbm@cyrius.com> */
4315 /* { dg-do compile } */
4316 
4317+#define signed
4318+typedef unsigned __PTRDIFF_TYPE__ uintptr_t;
4319+#undef signed
4320+
4321 struct list_head
4322 {
4323   struct list_head *prev;
4324@@ -14,7 +18,7 @@
4325   struct prio_array *active, arrays[2];
4326 } per_cpu__runqueues;
4327 
4328-void sched_init (unsigned long __ptr)
4329+void sched_init (uintptr_t __ptr)
4330 {
4331   int j, k;
4332   struct prio_array *array;
4333diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/pr33846.c gcc-4.4.1/gcc/testsuite/gcc.dg/vect/pr33846.c
4334--- gcc-4.4.1.orig/gcc/testsuite/gcc.dg/vect/pr33846.c  2007-10-23 13:15:04.000000000 -0700
4335+++ gcc-4.4.1/gcc/testsuite/gcc.dg/vect/pr33846.c       2009-09-08 12:10:43.000000000 -0700
4336@@ -7,7 +7,9 @@
4337   return ~i >> 31;
4338 }
4339 
4340-void _mix_some_samples (long buf, int *mix_buffer, int mix_size)
4341+typedef __PTRDIFF_TYPE__ intptr_t;
4342+
4343+void _mix_some_samples (intptr_t buf, int *mix_buffer, int mix_size)
4344 {
4345   int i;
4346   signed int *p = mix_buffer;
4347diff -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
4348--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-1.c        2008-08-28 12:36:58.000000000 -0700
4349+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-1.c     2009-07-28 00:01:40.000000000 -0700
4350@@ -1,6 +1,8 @@
4351 /* { dg-do run } */
4352 /* { dg-require-effective-target avx } */
4353-/* { dg-options "-O2 -mavx" } */
4354+/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
4355+/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
4356+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4357 
4358 #include "avx-check.h"
4359 
4360diff -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
4361--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-1.c    2008-08-28 12:36:58.000000000 -0700
4362+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-1.c 2009-07-28 00:01:40.000000000 -0700
4363@@ -1,6 +1,8 @@
4364 /* { dg-do run } */
4365 /* { dg-require-effective-target avx } */
4366-/* { dg-options "-O2 -mavx" } */
4367+/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
4368+/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
4369+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4370 
4371 #include "avx-check.h"
4372 
4373diff -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
4374--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-2.c    2008-08-28 12:36:58.000000000 -0700
4375+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-2.c 2009-07-28 00:01:40.000000000 -0700
4376@@ -1,6 +1,8 @@
4377 /* { dg-do run } */
4378 /* { dg-require-effective-target avx } */
4379-/* { dg-options "-O2 -mavx" } */
4380+/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
4381+/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
4382+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4383 
4384 #include "avx-check.h"
4385 
4386diff -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
4387--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-3.c    2008-08-28 12:36:58.000000000 -0700
4388+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-256-3.c 2009-07-28 00:01:40.000000000 -0700
4389@@ -1,6 +1,8 @@
4390 /* { dg-do run } */
4391 /* { dg-require-effective-target avx } */
4392-/* { dg-options "-O2 -mavx" } */
4393+/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
4394+/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
4395+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4396 
4397 #include "avx-check.h"
4398 
4399diff -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
4400--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-2.c        2008-08-28 12:36:58.000000000 -0700
4401+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-2.c     2009-07-28 00:01:40.000000000 -0700
4402@@ -1,6 +1,8 @@
4403 /* { dg-do run } */
4404 /* { dg-require-effective-target avx } */
4405-/* { dg-options "-O2 -mavx" } */
4406+/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
4407+/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
4408+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4409 
4410 #include "avx-check.h"
4411 
4412diff -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
4413--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestpd-3.c        2008-08-28 12:36:58.000000000 -0700
4414+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestpd-3.c     2009-07-28 00:01:40.000000000 -0700
4415@@ -1,6 +1,8 @@
4416 /* { dg-do run } */
4417 /* { dg-require-effective-target avx } */
4418-/* { dg-options "-O2 -mavx" } */
4419+/* { dg-options "-O2 -mavx -DNEED_IEEE754_DOUBLE" } */
4420+/* { dg-warning "attribute ignored" "" { target default_packed } 164 } */
4421+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4422 
4423 #include "avx-check.h"
4424 
4425diff -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
4426--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-1.c        2008-08-28 12:36:58.000000000 -0700
4427+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-1.c     2009-07-28 00:01:40.000000000 -0700
4428@@ -1,6 +1,8 @@
4429 /* { dg-do run } */
4430 /* { dg-require-effective-target avx } */
4431-/* { dg-options "-O2 -mavx" } */
4432+/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
4433+/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
4434+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4435 
4436 #include "avx-check.h"
4437 
4438diff -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
4439--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-256-1.c    2008-08-28 12:36:58.000000000 -0700
4440+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-256-1.c 2009-07-28 00:01:40.000000000 -0700
4441@@ -1,6 +1,8 @@
4442 /* { dg-do run } */
4443 /* { dg-require-effective-target avx } */
4444-/* { dg-options "-O2 -mavx" } */
4445+/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
4446+/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
4447+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4448 
4449 #include "avx-check.h"
4450 
4451diff -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
4452--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-256-2.c    2008-08-28 12:36:58.000000000 -0700
4453+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-256-2.c 2009-07-28 00:01:40.000000000 -0700
4454@@ -1,6 +1,8 @@
4455 /* { dg-do run } */
4456 /* { dg-require-effective-target avx } */
4457-/* { dg-options "-O2 -mavx" } */
4458+/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
4459+/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
4460+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4461 
4462 #include "avx-check.h"
4463 
4464diff -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
4465--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-256-3.c    2008-08-28 12:36:58.000000000 -0700
4466+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-256-3.c 2009-07-28 00:01:40.000000000 -0700
4467@@ -1,6 +1,8 @@
4468 /* { dg-do run } */
4469 /* { dg-require-effective-target avx } */
4470-/* { dg-options "-O2 -mavx" } */
4471+/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
4472+/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
4473+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4474 
4475 #include "avx-check.h"
4476 
4477diff -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
4478--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-2.c        2008-08-28 12:36:58.000000000 -0700
4479+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-2.c     2009-07-28 00:01:40.000000000 -0700
4480@@ -1,6 +1,8 @@
4481 /* { dg-do run } */
4482 /* { dg-require-effective-target avx } */
4483-/* { dg-options "-O2 -mavx" } */
4484+/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
4485+/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
4486+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4487 
4488 #include "avx-check.h"
4489 
4490diff -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
4491--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/avx-vtestps-3.c        2008-08-28 12:36:58.000000000 -0700
4492+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/avx-vtestps-3.c     2009-07-28 00:01:40.000000000 -0700
4493@@ -1,6 +1,8 @@
4494 /* { dg-do run } */
4495 /* { dg-require-effective-target avx } */
4496-/* { dg-options "-O2 -mavx" } */
4497+/* { dg-options "-O2 -mavx -DNEED_IEEE754_FLOAT" } */
4498+/* { dg-warning "attribute ignored" "" { target default_packed } 150 } */
4499+/* { dg-message " from " "include chain" { target default_packed } 0 } */
4500 
4501 #include "avx-check.h"
4502 
4503diff -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
4504--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/m128-check.h   2008-08-28 12:36:58.000000000 -0700
4505+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/m128-check.h        2009-07-28 00:01:40.000000000 -0700
4506@@ -138,6 +138,7 @@
4507 CHECK_FP_ARRAY (d, double, ESP_DOUBLE, "%f")
4508 CHECK_FP_ARRAY (f, float, ESP_FLOAT, "%f")
4509 
4510+#ifdef NEED_IEEE754_FLOAT
4511 union ieee754_float
4512 {
4513    float d;
4514@@ -148,7 +149,9 @@
4515       unsigned sign : 1;
4516    } bits __attribute__((packed));
4517 };
4518+#endif
4519 
4520+#ifdef NEED_IEEE754_DOUBLE
4521 union ieee754_double
4522 {
4523    double d;
4524@@ -160,3 +163,4 @@
4525       unsigned sign : 1;
4526    } bits __attribute__((packed));
4527 };
4528+#endif
4529diff -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
4530--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr37248-2.c    2008-12-09 09:38:09.000000000 -0800
4531+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr37248-2.c 2009-07-27 23:56:49.000000000 -0700
4532@@ -1,5 +1,5 @@
4533 /* PR middle-end/37248 */
4534-/* { dg-do compile } */
4535+/* { dg-do compile { target { ! default_packed } } } */
4536 /* { dg-options "-O2 -fdump-tree-optimized" } */
4537 
4538 struct S
4539diff -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
4540--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr37248-3.c    2008-12-09 09:38:09.000000000 -0800
4541+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr37248-3.c 2009-07-27 23:56:49.000000000 -0700
4542@@ -1,6 +1,6 @@
4543 /* PR middle-end/37248 */
4544-/* { dg-do compile } */
4545-/* { dg-options "-O2 -fdump-tree-optimized" } */
4546+/* { dg-do compile { target { ! default_packed } } } */
4547+/* { dg-options "-O2 -fdump-tree-optimized -mno-ms-bitfields" } */
4548 
4549 struct S
4550 {
4551diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40718.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40718.c
4552--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40718.c      1969-12-31 16:00:00.000000000 -0800
4553+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40718.c   2009-08-23 05:37:53.000000000 -0700
4554@@ -0,0 +1,36 @@
4555+/* { dg-do run } */
4556+/* { dg-require-effective-target ilp32 } */
4557+/* { dg-options "-O1 -foptimize-sibling-calls" } */
4558+
4559+void abort (void);
4560+
4561+struct S
4562+{
4563+  void (__attribute__((__stdcall__)) *f) (struct S *);
4564+  int i;
4565+};
4566+
4567+void __attribute__((__stdcall__))
4568+foo (struct S *s)
4569+{
4570+  s->i++;
4571+}
4572+
4573+void __attribute__((__stdcall__))
4574+bar (struct S *s)
4575+{
4576+  foo(s);
4577+  s->f(s);
4578+}
4579+
4580+int main (void)
4581+{
4582+  struct S s = { foo, 0 };
4583+
4584+  bar (&s);
4585+  if (s.i != 2)
4586+    abort ();
4587+
4588+  return 0;
4589+}
4590+
4591diff -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
4592--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40906-1.c    1969-12-31 16:00:00.000000000 -0800
4593+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40906-1.c 2009-08-05 11:04:42.000000000 -0700
4594@@ -0,0 +1,26 @@
4595+/* { dg-do run } */
4596+/* { dg-require-effective-target ilp32 } */
4597+/* { dg-options "-O2 -fomit-frame-pointer -mpush-args -mno-accumulate-outgoing-args" } */
4598+
4599+void abort (void);
4600+
4601+void __attribute__((noinline))
4602+f (long double a)
4603+{
4604+  if (a != 1.23L)
4605+    abort ();
4606+}
4607+
4608+int __attribute__((noinline))
4609+g (long double b)
4610+{
4611+  f (b);
4612+  return 0;
4613+}
4614+
4615+int
4616+main (void)
4617+{
4618+  g (1.23L);
4619+  return 0;
4620+}
4621diff -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
4622--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40906-2.c    1969-12-31 16:00:00.000000000 -0800
4623+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40906-2.c 2009-08-05 11:04:42.000000000 -0700
4624@@ -0,0 +1,26 @@
4625+/* { dg-do run } */
4626+/* { dg-require-effective-target ilp32 } */
4627+/* { dg-options "-O2 -fomit-frame-pointer -mpush-args -mno-accumulate-outgoing-args -m128bit-long-double" } */
4628+
4629+void abort (void);
4630+
4631+void __attribute__((noinline))
4632+f (long double a)
4633+{
4634+  if (a != 1.23L)
4635+    abort ();
4636+}
4637+
4638+int __attribute__((noinline))
4639+g (long double b)
4640+{
4641+  f (b);
4642+  return 0;
4643+}
4644+
4645+int
4646+main (void)
4647+{
4648+  g (1.23L);
4649+  return 0;
4650+}
4651diff -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
4652--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40906-3.c    1969-12-31 16:00:00.000000000 -0800
4653+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40906-3.c 2009-08-05 11:04:42.000000000 -0700
4654@@ -0,0 +1,25 @@
4655+/* { dg-do run { target *-*-linux* } } */
4656+/* { dg-require-effective-target ilp32 } */
4657+/* { dg-options "-O2 -fomit-frame-pointer -msse2 -mpush-args -mno-accumulate-outgoing-args" } */
4658+
4659+#include "sse2-check.h"
4660+
4661+void __attribute__((noinline))
4662+f (__float128 a)
4663+{
4664+  if (a != 1.23Q)
4665+    abort ();
4666+}
4667+
4668+int __attribute__((noinline))
4669+g (__float128 b)
4670+{
4671+  f (b);
4672+  return 0;
4673+}
4674+
4675+static void
4676+sse2_test (void)
4677+{
4678+  g (1.23Q);
4679+}
4680diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40934.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40934.c
4681--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40934.c      1969-12-31 16:00:00.000000000 -0800
4682+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40934.c   2009-08-16 13:23:57.000000000 -0700
4683@@ -0,0 +1,15 @@
4684+/* { dg-do compile } */
4685+/* { dg-require-effective-target ilp32 } */
4686+/* { dg-options "-O2 -march=i586 -ffast-math" } */
4687+
4688+extern double host_frametime;
4689+extern float pitchvel;
4690+V_DriftPitch (float delta, float move)
4691+{
4692+  if (!delta)
4693+    move = host_frametime;
4694+  if (delta > 0)
4695+    ;
4696+  else if (delta < 0 && move > -delta)
4697+    pitchvel = 0;
4698+}
4699diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40957.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40957.c
4700--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr40957.c      1969-12-31 16:00:00.000000000 -0800
4701+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr40957.c   2009-08-16 13:23:57.000000000 -0700
4702@@ -0,0 +1,18 @@
4703+/* { dg-do compile } */
4704+/* { dg-require-effective-target avx } */
4705+/* { dg-options "-O2 -mavx" } */
4706+
4707+typedef int __v8si __attribute__((__vector_size__(32)));
4708+typedef long long __m256i __attribute__((__vector_size__(32), __may_alias__));
4709+
4710+static __m256i
4711+_mm256_set1_epi32 (int __A)
4712+{
4713+  return __extension__ (__m256i)(__v8si){ __A, __A, __A, __A,
4714+                                         __A, __A, __A, __A };
4715+}
4716+__m256i
4717+foo ()
4718+{
4719+  return _mm256_set1_epi32 (-1);
4720+}
4721diff -Naur gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr41019.c gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr41019.c
4722--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/i386/pr41019.c      1969-12-31 16:00:00.000000000 -0800
4723+++ gcc-4.4.1/gcc/testsuite/gcc.target/i386/pr41019.c   2009-08-16 12:34:49.000000000 -0700
4724@@ -0,0 +1,19 @@
4725+/* { dg-do run } */
4726+/* { dg-options "-O2 -msse2 -ftree-vectorize" } */
4727+
4728+#include "sse2-check.h"
4729+
4730+long long int a[64];
4731+
4732+void
4733+sse2_test (void)
4734+{
4735+  int k;
4736+
4737+  for (k = 0; k < 64; k++)
4738+    a[k] = a[k] != 5 ? 12 : 10;
4739+
4740+  for (k = 0; k < 64; k++)
4741+    if (a[k] != 12)
4742+      abort ();
4743+}
4744diff -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
4745--- gcc-4.4.1.orig/gcc/testsuite/gcc.target/powerpc/pr39902-2.c 1969-12-31 16:00:00.000000000 -0800
4746+++ gcc-4.4.1/gcc/testsuite/gcc.target/powerpc/pr39902-2.c      2009-08-03 14:43:32.000000000 -0700
4747@@ -0,0 +1,28 @@
4748+/* Check that simplification "x*(-1)" -> "-x" is not performed for decimal
4749+   float types.  */
4750+
4751+/* { dg-do compile { target { powerpc*-*-linux* && powerpc_fprs } } } */
4752+/* { dg-options "-std=gnu99 -O -mcpu=power6" } */
4753+/* { dg-final { scan-assembler-not "fneg" } } */
4754+
4755+extern _Decimal32 a32, b32;
4756+extern _Decimal64 a64, b64;
4757+extern _Decimal128 a128, b128;
4758+
4759+void
4760+foo32 (void)
4761+{
4762+  b32 = a32 * -1.0DF;
4763+}
4764+
4765+void
4766+foo64 (void)
4767+{
4768+  b64 = a64 * -1.0DD;
4769+}
4770+
4771+void
4772+foo128 (void)
4773+{
4774+  b128 = a128 * -1.0DL;
4775+}
4776diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/cdce3.C gcc-4.4.1/gcc/testsuite/g++.dg/cdce3.C
4777--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/cdce3.C 2008-09-23 14:27:17.000000000 -0700
4778+++ gcc-4.4.1/gcc/testsuite/g++.dg/cdce3.C      2009-08-28 02:57:51.000000000 -0700
4779@@ -2,14 +2,14 @@
4780 /* { dg-require-effective-target c99_runtime } */
4781 /* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details  -DGNU_EXTENSION -DLARGE_LONG_DOUBLE -lm" { target { pow10 && large_long_double } } } */
4782 /* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -DLARGE_LONG_DOUBLE -lm" { target { {! pow10 } && large_long_double } } } */
4783-/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -DGNU_EXTENSION -lm" { target {pow10 && {! large_long_double } } } } */
4784+/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -DGNU_EXTENSION -lm" { target { pow10 && {! large_long_double } } } } */
4785 /* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -lm" { target { {! pow10 } && {! large_long_double } } } } */
4786-/* { dg-final { scan-tree-dump  "cdce3.C:91: note: function call is shrink-wrapped into error conditions\." "cdce" { target { pow10 } } } } */
4787-/* { dg-final { scan-tree-dump  "cdce3.C:92: note: function call is shrink-wrapped into error conditions\." "cdce" { target { pow10 } } } } */
4788-/* { dg-final { scan-tree-dump  "cdce3.C:94: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4789-/* { dg-final { scan-tree-dump  "cdce3.C:95: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4790-/* { dg-final { scan-tree-dump  "cdce3.C:96: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4791-/* { dg-final { scan-tree-dump  "cdce3.C:97: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4792+/* { dg-options "-mieee -O2 -fmath-errno -fdump-tree-cdce-details  -DGNU_EXTENSION -DLARGE_LONG_DOUBLE -lm" { target { alpha*-*-* && { pow10 && large_long_double } } } } */
4793+/* { dg-options "-mieee -O2 -fmath-errno -fdump-tree-cdce-details -DLARGE_LONG_DOUBLE -lm" { target { alpha*-*-* && { {! pow10 } && large_long_double } } } } */
4794+/* { dg-options "-mieee -O2 -fmath-errno -fdump-tree-cdce-details -DGNU_EXTENSION -lm" { target { alpha*-*-* && { pow10 && {! large_long_double } } } } } */
4795+/* { dg-options "-mieee -O2 -fmath-errno -fdump-tree-cdce-details -lm" { target { alpha*-*-* && { {! pow10 } && {! large_long_double } } } } } */
4796+/* { dg-final { scan-tree-dump  "cdce3.C:95: note: function call is shrink-wrapped into error conditions\." "cdce" { target { pow10 } } } } */
4797+/* { dg-final { scan-tree-dump  "cdce3.C:96: note: function call is shrink-wrapped into error conditions\." "cdce" { target { pow10 } } } } */
4798 /* { dg-final { scan-tree-dump  "cdce3.C:98: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4799 /* { dg-final { scan-tree-dump  "cdce3.C:99: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4800 /* { dg-final { scan-tree-dump  "cdce3.C:100: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4801@@ -20,6 +20,10 @@
4802 /* { dg-final { scan-tree-dump  "cdce3.C:105: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4803 /* { dg-final { scan-tree-dump  "cdce3.C:106: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4804 /* { dg-final { scan-tree-dump  "cdce3.C:107: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4805+/* { dg-final { scan-tree-dump  "cdce3.C:108: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4806+/* { dg-final { scan-tree-dump  "cdce3.C:109: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4807+/* { dg-final { scan-tree-dump  "cdce3.C:110: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4808+/* { dg-final { scan-tree-dump  "cdce3.C:111: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
4809 /* { dg-final { cleanup-tree-dump "cdce" } } */
4810 #include <stdlib.h>
4811 #include <math.h>
4812diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/cpp0x/enum1.C gcc-4.4.1/gcc/testsuite/g++.dg/cpp0x/enum1.C
4813--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/cpp0x/enum1.C   2008-11-10 05:41:37.000000000 -0800
4814+++ gcc-4.4.1/gcc/testsuite/g++.dg/cpp0x/enum1.C        2009-08-31 14:20:07.000000000 -0700
4815@@ -2,5 +2,5 @@
4816 // { dg-do compile }
4817 // { dg-options "-std=gnu++0x" }
4818 
4819-enum : { };    // { dg-error "expected type-specifier" }
4820+enum : { };    // { dg-error "expected" }
4821 enum : 3 { };  // { dg-error "expected" }
4822diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/cpp0x/initlist22.C gcc-4.4.1/gcc/testsuite/g++.dg/cpp0x/initlist22.C
4823--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/cpp0x/initlist22.C      1969-12-31 16:00:00.000000000 -0800
4824+++ gcc-4.4.1/gcc/testsuite/g++.dg/cpp0x/initlist22.C   2009-07-24 11:06:08.000000000 -0700
4825@@ -0,0 +1,24 @@
4826+// Core issue 934
4827+// { dg-options "-std=c++0x" }
4828+
4829+int i;
4830+
4831+int& r1{ i };                  // OK, direct binding
4832+int&& r2{ i };                 // OK, direct binding
4833+
4834+int& r3{ };                    // { dg-error "" } reference to temporary
4835+int&& r4{ };                   // OK, reference to temporary
4836+
4837+struct A { int i; } a;
4838+
4839+A& r5 { i };                   // { dg-error "" } reference to temporary
4840+A&& r6 { i };                  // OK, aggregate initialization of temporary
4841+A& r7 { a };                   // { dg-error "" } invalid aggregate initializer for A
4842+A&& r8 { a };                  // { dg-error "" } invalid aggregate initializer for A
4843+
4844+struct B { B(int); int i; } b(0);
4845+
4846+B& r9 { i };                   // { dg-error "" } reference to temporary
4847+B&& r10 { i };                 // OK, make temporary with B(int) constructor
4848+B& r11 { b };                  // { dg-error "" } reference to temporary
4849+B&& r12 { b };                 // OK, make temporary with copy constructor
4850diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/cpp0x/initlist23.C gcc-4.4.1/gcc/testsuite/g++.dg/cpp0x/initlist23.C
4851--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/cpp0x/initlist23.C      1969-12-31 16:00:00.000000000 -0800
4852+++ gcc-4.4.1/gcc/testsuite/g++.dg/cpp0x/initlist23.C   2009-07-24 11:06:08.000000000 -0700
4853@@ -0,0 +1,15 @@
4854+// { dg-options "-std=c++0x" }
4855+
4856+#include <initializer_list>
4857+
4858+struct A
4859+{
4860+  A& operator=(int i);
4861+  A& operator=(std::initializer_list<int> l) { return *this; }
4862+};
4863+
4864+int main()
4865+{
4866+  A a;
4867+  a = { };
4868+}
4869diff -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
4870--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/debug/dwarf2/pubnames-1.C       1969-12-31 16:00:00.000000000 -0800
4871+++ gcc-4.4.1/gcc/testsuite/g++.dg/debug/dwarf2/pubnames-1.C    2009-08-04 05:28:27.000000000 -0700
4872@@ -0,0 +1,14 @@
4873+// Contributed by Dodji Seketeli <dodji@redhat.com>
4874+// Origin PR debug/39706
4875+// { dg-options "-g -dA" }
4876+// { dg-do compile }
4877+// { dg-final { scan-assembler-times ".debug_pubnames" 1 } }
4878+// { dg-final { scan-assembler-times "\"main\".*external name" 1 } }
4879+// { dg-final { scan-assembler-times "\"ns::ns_x.*external name" 1 } }
4880+// { dg-final { scan-assembler-times "\"y::y_x.*external name" 1 } }
4881+
4882+namespace ns { int ns_x; }
4883+class y { public: static int y_x; };
4884+int y::y_x;
4885+int main() { return ns::ns_x; }
4886+
4887diff -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
4888--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/debug/dwarf2/typedef1.C 1969-12-31 16:00:00.000000000 -0800
4889+++ gcc-4.4.1/gcc/testsuite/g++.dg/debug/dwarf2/typedef1.C      2009-07-23 10:50:56.000000000 -0700
4890@@ -0,0 +1,33 @@
4891+// Contributed by Dodji Seketeli <dodji@redhat.com>
4892+// Origin: PR c++/40705
4893+// { dg-options "-g -dA" }
4894+// { dg-do compile }
4895+// { dg-final { scan-assembler-times "DW_TAG_structure_type" 2 } }
4896+// { dg-final { scan-assembler-times "DW_AT_name: \"foo<1u>\"" 1 } }
4897+// { dg-final { scan-assembler-times "DW_TAG_enumeration_type" 2 } }
4898+// { dg-final { scan-assembler-times "DW_AT_name: \"typedef foo<1u>::type type\"" 1 } }
4899+// { dg-final { scan-assembler-times "DIE (.*) DW_TAG_enumeration_type" 2 } }
4900+// { dg-final { scan-assembler-times "\"e0..\".*DW_AT_name" 1 } }
4901+// { dg-final { scan-assembler-times "\"e1..\".*DW_AT_name" 1 } }
4902+
4903+template <unsigned int n>
4904+struct foo
4905+{
4906+public:
4907+    typedef
4908+ unsigned char type;
4909+};
4910+
4911+template<>
4912+struct foo<1>
4913+{
4914+    typedef enum { e0, e1 } type;
4915+};
4916+
4917+int
4918+main()
4919+{
4920+    foo<1> f;
4921+    foo<1>::type t = foo<1>::e1;
4922+    return t;
4923+}
4924diff -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
4925--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/expr/stmt-expr-1.C      1969-12-31 16:00:00.000000000 -0800
4926+++ gcc-4.4.1/gcc/testsuite/g++.dg/expr/stmt-expr-1.C   2009-08-16 13:23:57.000000000 -0700
4927@@ -0,0 +1,36 @@
4928+// Contributed by Dodji Seketeli <dodji@redhat.com>
4929+// Origin PR c++/40866
4930+// { dg-options "-std=gnu++98" }
4931+// { dg-do "compile" }
4932+
4933+template <typename T> class QForeachContainer {
4934+public:
4935+    QForeachContainer();
4936+    int brk;
4937+    typename T::const_iterator i;
4938+};
4939+
4940+template <typename T> class QList {
4941+public:
4942+    class const_iterator {
4943+    public:
4944+        const_iterator(const const_iterator &o);
4945+        const_iterator &operator++();
4946+    };
4947+};
4948+
4949+class QAction;
4950+class QWidget {
4951+public:
4952+    QList<QAction*> actions() const;
4953+};
4954+class myDialog : public QWidget {
4955+    myDialog();
4956+};
4957+
4958+myDialog::myDialog()
4959+{
4960+    QForeachContainer<__typeof__(actions())> _container_;
4961+    ({++_container_.brk; ++_container_.i;});
4962+}
4963+
4964diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/expr/unary3.C gcc-4.4.1/gcc/testsuite/g++.dg/expr/unary3.C
4965--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/expr/unary3.C   1969-12-31 16:00:00.000000000 -0800
4966+++ gcc-4.4.1/gcc/testsuite/g++.dg/expr/unary3.C        2009-08-21 00:10:36.000000000 -0700
4967@@ -0,0 +1,11 @@
4968+// PR c++/41131
4969+// { dg-do compile }
4970+
4971+struct X { enum E { a = 100 }; };
4972+
4973+int
4974+main ()
4975+{
4976+  X x;
4977+  (void) &x.a;    // { dg-error "lvalue required" }
4978+}
4979diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield2.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield2.C
4980--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield2.C 2009-01-25 12:15:44.000000000 -0800
4981+++ gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield2.C      2009-07-27 23:56:49.000000000 -0700
4982@@ -1,6 +1,7 @@
4983 /* { dg-do compile } */
4984 /* Remove pedantic.  Allow the GCC extension to use char for bitfields.  */
4985 /* { dg-options "" } */
4986+/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
4987 
4988 struct t
4989 { /* { dg-message "note: Offset of packed bit-field 't::b' has changed in GCC 4.4" "" { target pcc_bitfield_type_matters } } */
4990diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield3.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield3.C
4991--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield3.C 2009-01-22 22:29:54.000000000 -0800
4992+++ gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield3.C      2009-07-27 23:56:49.000000000 -0700
4993@@ -1,5 +1,6 @@
4994 /* { dg-do compile } */
4995 /* { dg-options "-Wno-packed-bitfield-compat" } */
4996+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
4997 
4998 struct t
4999 {
5000diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield4.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield4.C
5001--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield4.C 2009-01-25 12:15:44.000000000 -0800
5002+++ gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield4.C      2009-07-27 23:56:49.000000000 -0700
5003@@ -1,5 +1,6 @@
5004 /* { dg-do compile } */
5005 /* { dg-options "" } */
5006+/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
5007 
5008 struct t
5009 { /* { dg-message "note: Offset of packed bit-field 't::b' has changed in GCC 4.4" "" { target pcc_bitfield_type_matters } } */
5010diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield5.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield5.C
5011--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/bitfield5.C 2009-01-22 22:29:54.000000000 -0800
5012+++ gcc-4.4.1/gcc/testsuite/g++.dg/ext/bitfield5.C      2009-07-27 23:56:49.000000000 -0700
5013@@ -1,5 +1,6 @@
5014 /* { dg-do compile } */
5015 /* { dg-options "-Wno-packed-bitfield-compat" } */
5016+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
5017 
5018 struct t
5019 {
5020diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/complit12.C gcc-4.4.1/gcc/testsuite/g++.dg/ext/complit12.C
5021--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/ext/complit12.C 1969-12-31 16:00:00.000000000 -0800
5022+++ gcc-4.4.1/gcc/testsuite/g++.dg/ext/complit12.C      2009-08-06 10:22:19.000000000 -0700
5023@@ -0,0 +1,65 @@
5024+// PR c++/40948
5025+// { dg-do run }
5026+// { dg-options "" }
5027+
5028+int c;
5029+struct M
5030+{
5031+  M () { ++c; }
5032+  M (const M&) { ++c; }
5033+  ~M () { --c; }
5034+};
5035+
5036+struct S
5037+{
5038+  S ();
5039+  M m[1];
5040+};
5041+
5042+S::S () : m ((M[1]) { M () })
5043+{
5044+}
5045+
5046+struct T
5047+{
5048+  T ();
5049+  M m[4];
5050+};
5051+
5052+T::T () : m ((M[4]) { M (), M (), M (), M () })
5053+{
5054+}
5055+
5056+typedef M MA[1];
5057+MA &bar (MA, MA& r) { return r; }
5058+
5059+M f(M m) { return m; }
5060+
5061+int main ()
5062+{
5063+  {
5064+    M m[1] = (M[1]) { M () };
5065+    if (c != 1)
5066+      return 1;
5067+    M n = (M) { M () };
5068+    if (c != 2)
5069+      return 2;
5070+    M o[4] = (M[4]) { M (), M (), M (), M () };
5071+    if (c != 6)
5072+      return 3;
5073+    S s;
5074+    if (c != 7)
5075+      return 4;
5076+    T t;
5077+    if (c != 11)
5078+      return 5;
5079+    MA ma = bar ((M[2]) { M(), M() }, m);
5080+    if (c != 12)
5081+      return 7;
5082+    M mm[2] = ((M[2]) { f(M()), f(M()) });
5083+    if (c != 14)
5084+      return 8;
5085+  }
5086+  if (c != 0)
5087+    return 6;
5088+}
5089diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/lookup/using21.C gcc-4.4.1/gcc/testsuite/g++.dg/lookup/using21.C
5090--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/lookup/using21.C        1969-12-31 16:00:00.000000000 -0800
5091+++ gcc-4.4.1/gcc/testsuite/g++.dg/lookup/using21.C     2009-07-23 10:50:56.000000000 -0700
5092@@ -0,0 +1,13 @@
5093+// PR c++/40799
5094+
5095+namespace Bar {
5096+  typedef int A;
5097+}
5098+class CollectionDeleteGuard {
5099+public:
5100+  CollectionDeleteGuard(int);
5101+};
5102+CollectionDeleteGuard::CollectionDeleteGuard(int)
5103+{
5104+  using Bar::A;
5105+}
5106diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/opt/pr40496.C gcc-4.4.1/gcc/testsuite/g++.dg/opt/pr40496.C
5107--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/opt/pr40496.C   1969-12-31 16:00:00.000000000 -0800
5108+++ gcc-4.4.1/gcc/testsuite/g++.dg/opt/pr40496.C        2009-07-23 10:50:56.000000000 -0700
5109@@ -0,0 +1,18 @@
5110+// { dg-do compile }
5111+// { dg-options "-O2 -fprefetch-loop-arrays -msse2" { target i?86-*-* x86_64-*-* } }
5112+
5113+struct DOMStringHandle
5114+{
5115+  unsigned int fLength;
5116+  int fRefCount;
5117+};
5118+static void *freeListPtr;
5119+void foo(DOMStringHandle *dsg)
5120+{
5121+  int i;
5122+  for (i = 1; i < 1023; i++)
5123+    {
5124+      *(void **) &dsg[i] = freeListPtr;
5125+      freeListPtr = &dsg[i];
5126+    }
5127+}
5128diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/other/gc4.C gcc-4.4.1/gcc/testsuite/g++.dg/other/gc4.C
5129--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/other/gc4.C     1969-12-31 16:00:00.000000000 -0800
5130+++ gcc-4.4.1/gcc/testsuite/g++.dg/other/gc4.C  2009-08-29 19:06:32.000000000 -0700
5131@@ -0,0 +1,14 @@
5132+// PR c++/41120
5133+// { dg-options "--param ggc-min-heapsize=0 --param ggc-min-expand=0" }
5134+
5135+struct A
5136+{
5137+  A();
5138+};
5139+
5140+struct B
5141+{
5142+  A a;
5143+};
5144+
5145+B b;
5146diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/other/typedef3.C gcc-4.4.1/gcc/testsuite/g++.dg/other/typedef3.C
5147--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/other/typedef3.C        1969-12-31 16:00:00.000000000 -0800
5148+++ gcc-4.4.1/gcc/testsuite/g++.dg/other/typedef3.C     2009-07-23 10:50:56.000000000 -0700
5149@@ -0,0 +1,12 @@
5150+// Contributed by Dodji Seketeli <dodji@redhat.com>
5151+// Origin: PR c++/40357
5152+// { dg-do compile }
5153+
5154+struct XalanCProcessor
5155+{
5156+      typedef enum {eInvalid, eXalanSourceTree, eXercesDOM} ParseOptionType;
5157+          ParseOptionType getParseOption(void);
5158+};
5159+typedef XalanCProcessor::ParseOptionType ParseOptionType;
5160+ParseOptionType XalanCProcessor::getParseOption(void) {}
5161+
5162diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/overload/defarg4.C gcc-4.4.1/gcc/testsuite/g++.dg/overload/defarg4.C
5163--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/overload/defarg4.C      1969-12-31 16:00:00.000000000 -0800
5164+++ gcc-4.4.1/gcc/testsuite/g++.dg/overload/defarg4.C   2009-08-07 06:15:43.000000000 -0700
5165@@ -0,0 +1,26 @@
5166+// Contributed by Dodji Seketeli <dodji@redhat.com>
5167+// Origin PR c++/39987
5168+// { dg-do "compile" }
5169+
5170+class foo
5171+{
5172+ template<typename U>
5173+ static bool func(const U& x)
5174+ {}
5175+public:
5176+ template<typename U>
5177+ unsigned int Find(const U& x, bool (*pFunc) (const U&) = func) const
5178+ {}
5179+};
5180+
5181+class bar {
5182+ bool Initialize();
5183+protected:
5184+ foo b;
5185+};
5186+
5187+bool bar::Initialize()
5188+{
5189+        b.Find(b);
5190+}
5191+
5192diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/parse/enum5.C gcc-4.4.1/gcc/testsuite/g++.dg/parse/enum5.C
5193--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/parse/enum5.C   1969-12-31 16:00:00.000000000 -0800
5194+++ gcc-4.4.1/gcc/testsuite/g++.dg/parse/enum5.C        2009-08-31 14:20:07.000000000 -0700
5195@@ -0,0 +1,17 @@
5196+// PR c++/41127
5197+
5198+#define CHAR_BIT 8
5199+enum EE {ee};
5200+typedef unsigned int T;
5201+
5202+struct D {
5203+        T : sizeof(unsigned int) * CHAR_BIT; // OK
5204+        EE : sizeof(EE) * CHAR_BIT; // OK
5205+        enum EE : sizeof(EE) * CHAR_BIT; // not OK
5206+        enum EE xxxx : sizeof(EE) * CHAR_BIT; // OK
5207+        T x : sizeof(unsigned int) * CHAR_BIT; // OK
5208+        enum FF {ff} : sizeof(int) * CHAR_BIT; // OK
5209+} element;
5210+
5211+enum EE xx;
5212+EE yy;
5213diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40321.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40321.C
5214--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40321.C       1969-12-31 16:00:00.000000000 -0800
5215+++ gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40321.C    2009-07-22 07:45:21.000000000 -0700
5216@@ -0,0 +1,25 @@
5217+/* { dg-do compile } */
5218+
5219+struct VectorD2
5220+{
5221+  VectorD2() : x(0), y(0) { }
5222+  VectorD2(int _x, int _y) : x(_x), y(_y) { }
5223+  int x, y;
5224+  int GetLength2() const { return x*x + y*y; };
5225+  VectorD2 operator+(const VectorD2 vec) const {
5226+      return VectorD2(x+vec.x,y+vec.y);
5227+  }
5228+};
5229+struct Shape
5230+{
5231+  enum Type { ST_RECT, ST_CIRCLE } type;
5232+  VectorD2 pos;
5233+  VectorD2 radius;
5234+  bool CollisionWith(const Shape& s) const;
5235+};
5236+bool Shape::CollisionWith(const Shape& s) const
5237+{
5238+  if(type == ST_CIRCLE && s.type == ST_RECT)
5239+    return s.CollisionWith(*this);
5240+  return (pos + s.pos).GetLength2() < (radius + s.radius).GetLength2();
5241+}
5242diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40834.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40834.C
5243--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40834.C       1969-12-31 16:00:00.000000000 -0800
5244+++ gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40834.C    2009-08-05 07:45:15.000000000 -0700
5245@@ -0,0 +1,52 @@
5246+/* { dg-do run } */
5247+
5248+extern "C" void abort (void);
5249+class XalanDOMString
5250+{
5251+public:
5252+  int y;
5253+};
5254+
5255+class XObject
5256+{
5257+public:
5258+  const XalanDOMString& str() const { return x; }
5259+  XalanDOMString x;
5260+};
5261+
5262+class XObjectPtr
5263+{
5264+public:
5265+  XObjectPtr(const XObjectPtr& theSource)
5266+    {
5267+      m_xobjectPtr = theSource.m_xobjectPtr;
5268+    }
5269+  const XObject* operator->() const
5270+    {
5271+      return m_xobjectPtr;
5272+    };
5273+  XObjectPtr(XObject *p) { m_xobjectPtr = p; }
5274+  XObject* m_xobjectPtr;
5275+};
5276+
5277+class FunctionSubstringBefore
5278+{
5279+public:
5280+  int execute( const XObjectPtr arg1) const
5281+    {
5282+      const XalanDOMString& theFirstString = arg1->str();
5283+      return theFirstString.y;
5284+    }
5285+};
5286+
5287+int
5288+main ()
5289+{
5290+  XObject x;
5291+  XObjectPtr y (&x);
5292+  x.x.y = -1;
5293+  FunctionSubstringBefore z;
5294+  if (z.execute (y) != -1)
5295+    abort ();
5296+  return 0;
5297+}
5298diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40924.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40924.C
5299--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40924.C       1969-12-31 16:00:00.000000000 -0800
5300+++ gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40924.C    2009-08-05 05:54:21.000000000 -0700
5301@@ -0,0 +1,111 @@
5302+// PR rtl-optimization/40924
5303+// { dg-do run }
5304+
5305+extern "C" void abort (void);
5306+
5307+#define MAY_ALIAS __attribute__((__may_alias__))
5308+
5309+typedef struct { float v[2]; } floata;
5310+typedef struct { int v[2]; } inta;
5311+
5312+typedef unsigned int uint MAY_ALIAS;
5313+typedef signed int sint MAY_ALIAS;
5314+typedef float flt MAY_ALIAS;
5315+
5316+static inline unsigned short
5317+less_than (inta a, inta b)
5318+{
5319+  unsigned short r = 0;
5320+  const uint *p1 = (const uint *) &a;
5321+  const uint *p2 = (const uint *) &b;
5322+  for (int i=0; i < 2; i++)
5323+    if (p1[i] < p2[i]) r |= (1 << i);
5324+  return r;
5325+}
5326+
5327+static inline inta
5328+multiply (inta b, inta c)
5329+{
5330+  inta r;
5331+  sint *p3 = (sint *) &c;
5332+  for (int i=0; i < 2; i++)
5333+    r.v[i] = (int) (b.v[i] * p3[i] & 0xFFFFFFFF);
5334+  return r;
5335+}
5336+
5337+static inline floata
5338+gather (inta indexes, const void *baseAddr)
5339+{
5340+  floata r;
5341+
5342+  sint *idx = (sint *) &indexes;
5343+  flt *src = (flt *) baseAddr;
5344+  for (int i=0; i < 2; i++)
5345+    r.v[i] = *(src + idx[i]);
5346+  return r;
5347+}
5348+
5349+static inline inta
5350+add (const inta &b, const inta &c)
5351+{
5352+  inta result;
5353+  sint *r = (sint *) &result;
5354+
5355+  for (int i=0; i < 2; i++)
5356+    r[i] = b.v[i] + c.v[i];
5357+  return result;
5358+}
5359+
5360+struct uintv
5361+{
5362+  inta data;
5363+  inline uintv () { data.v[0] = 0; data.v[1] = 1; }
5364+  inline uintv (unsigned int a)
5365+  {
5366+    for (int i=0; i < 2; i++)
5367+      *(uint *) &data.v[i] = a;
5368+  }
5369+  inline uintv (inta x) : data (x) {}
5370+  inline uintv operator* (const uintv &x) const
5371+  { return multiply (data, x.data); }
5372+  inline uintv operator+ (const uintv &x) const
5373+  { return uintv (add (data, x.data)); }
5374+  inline unsigned short operator< (const uintv &x) const
5375+  { return less_than (data, x.data); }
5376+};
5377+
5378+struct floatv
5379+{
5380+  floata data;
5381+  explicit inline floatv (const uintv &x)
5382+  {
5383+    uint *p2 = (uint *) &x.data;
5384+    for (int i=0; i < 2; i++)
5385+      data.v[i] = p2[i];
5386+  }
5387+  inline floatv (const float *array, const uintv &indexes)
5388+  {
5389+    const uintv &offsets = indexes * uintv (1);
5390+    data = gather (offsets.data, array);
5391+  }
5392+  unsigned short operator== (const floatv &x) const
5393+  {
5394+    unsigned short r = 0;
5395+    for (int i=0; i < 2; i++)
5396+      if (data.v[i] == x.data.v[i]) r |= (1 << i);
5397+    return r;
5398+  }
5399+};
5400+
5401+int
5402+main ()
5403+{
5404+  const float array[2] = { 2, 3 };
5405+  for (uintv i; (i < 2) == 3; i = i + 2)
5406+    {
5407+      const floatv ii (i + 2);
5408+      floatv a (array, i);
5409+      if ((a == ii) != 3)
5410+       abort ();
5411+    }
5412+}
5413diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40991.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40991.C
5414--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr40991.C       1969-12-31 16:00:00.000000000 -0800
5415+++ gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr40991.C    2009-08-16 13:23:57.000000000 -0700
5416@@ -0,0 +1,113 @@
5417+/* { dg-options "-std=gnu++0x" } */
5418+
5419+typedef __SIZE_TYPE__ size_t;
5420+namespace std __attribute__ ((__visibility__ ("default"))) {
5421+    using ::size_t;
5422+    void __throw_bad_function_call() __attribute__((__noreturn__));
5423+}
5424+inline void* operator new(std::size_t, void* __p) throw() {
5425+    return __p;
5426+}
5427+namespace std {
5428+    class type_info {
5429+    public:
5430+       bool operator==(const type_info& __arg) const { }
5431+    };
5432+    namespace tr1 {
5433+       template<typename _Tp, _Tp __v> struct integral_constant { };
5434+       typedef integral_constant<bool, true> true_type;
5435+       template<typename _Res, typename... _ArgTypes>
5436+       struct _Maybe_unary_or_binary_function { };
5437+       class _Undefined_class;
5438+       union _Nocopy_types {
5439+           void (_Undefined_class::*_M_member_pointer)();
5440+       };
5441+       union _Any_data {
5442+           void* _M_access() {
5443+               return &_M_pod_data[0];
5444+           }
5445+           char _M_pod_data[sizeof(_Nocopy_types)];
5446+       };
5447+       enum _Manager_operation { __get_type_info, __get_functor_ptr, __clone_functor, __destroy_functor };
5448+       template<typename _Tp> struct _Simple_type_wrapper {
5449+           _Simple_type_wrapper(_Tp __value) : __value(__value) { }
5450+           _Tp __value;
5451+       };
5452+       template<typename _Signature> class function;
5453+       class _Function_base {
5454+       public:
5455+           static const std::size_t _M_max_size = sizeof(_Nocopy_types);
5456+           static const std::size_t _M_max_align = __alignof__(_Nocopy_types);
5457+           template<typename _Functor> class _Base_manager {
5458+               static const bool __stored_locally = (sizeof(_Functor) <= _M_max_size && __alignof__(_Functor) <= _M_max_align && (_M_max_align % __alignof__(_Functor) == 0));
5459+               typedef integral_constant<bool, __stored_locally> _Local_storage;
5460+           public:
5461+               static bool _M_manager(_Any_data& __dest, const _Any_data& __source, _Manager_operation __op) { }
5462+               static void _M_init_functor(_Any_data& __functor, const _Functor& __f) {
5463+                   _M_init_functor(__functor, __f, _Local_storage());
5464+               }
5465+               template<typename _Class, typename _Tp> static bool _M_not_empty_function(_Tp _Class::* const& __mp) {
5466+                   return __mp;
5467+               }
5468+               static void _M_init_functor(_Any_data& __functor, const _Functor& __f, true_type) {
5469+                   new (__functor._M_access()) _Functor(__f);
5470+               }
5471+           };
5472+           ~_Function_base() {
5473+               if (_M_manager) _M_manager(_M_functor, _M_functor, __destroy_functor);
5474+           }
5475+           bool _M_empty() const {
5476+               return !_M_manager;
5477+           }
5478+           typedef bool (*_Manager_type)(_Any_data&, const _Any_data&, _Manager_operation);
5479+           _Any_data _M_functor;
5480+           _Manager_type _M_manager;
5481+       };
5482+       template<typename _Signature, typename _Functor> class _Function_handler;
5483+       template<typename _Class, typename _Member, typename _Res, typename... _ArgTypes> class _Function_handler<_Res(_ArgTypes...), _Member _Class::*> : public _Function_handler<void(_ArgTypes...), _Member _Class::*> {
5484+       public:
5485+           static _Res _M_invoke(const _Any_data& __functor, _ArgTypes... __args) { }
5486+       };
5487+       template<typename _Class, typename _Member, typename... _ArgTypes> class _Function_handler<void(_ArgTypes...), _Member _Class::*> : public _Function_base::_Base_manager< _Simple_type_wrapper< _Member _Class::* > > { };
5488+       template<typename _Res, typename... _ArgTypes> class function<_Res(_ArgTypes...)> : public _Maybe_unary_or_binary_function<_Res, _ArgTypes...>, private _Function_base {
5489+           typedef _Res _Signature_type(_ArgTypes...);
5490+           struct _Useless { };
5491+       public:
5492+           template<typename _Functor> function(_Functor __f, _Useless = _Useless());
5493+           _Res operator()(_ArgTypes... __args) const;
5494+           const type_info& target_type() const;
5495+           typedef _Res (*_Invoker_type)(const _Any_data&, _ArgTypes...);
5496+           _Invoker_type _M_invoker;
5497+       };
5498+       template<typename _Res, typename... _ArgTypes> template<typename _Functor> function<_Res(_ArgTypes...)>:: function(_Functor __f, _Useless) : _Function_base() {
5499+           typedef _Function_handler<_Signature_type, _Functor> _My_handler;
5500+           if (_My_handler::_M_not_empty_function(__f)) {
5501+               _M_invoker = &_My_handler::_M_invoke;
5502+               _M_manager = &_My_handler::_M_manager;
5503+               _My_handler::_M_init_functor(_M_functor, __f);
5504+           }
5505+       }
5506+       template<typename _Res, typename... _ArgTypes> _Res function<_Res(_ArgTypes...)>:: operator()(_ArgTypes... __args) const {
5507+           if (_M_empty()) {
5508+               __throw_bad_function_call();
5509+           }
5510+           return _M_invoker(_M_functor, __args...);
5511+       }
5512+       template<typename _Res, typename... _ArgTypes> const type_info& function<_Res(_ArgTypes...)>:: target_type() const {
5513+           if (_M_manager) {
5514+               _Any_data __typeinfo_result;
5515+               _M_manager(__typeinfo_result, _M_functor, __get_type_info);
5516+           }
5517+       }
5518+    }
5519+}
5520+struct X {
5521+    int bar;
5522+};
5523+void test05() {
5524+    using std::tr1::function;
5525+    X x;
5526+    function<int(X&)> frm(&X::bar);
5527+    frm(x) == 17;
5528+    typeid(int X::*) == frm.target_type();
5529+}
5530diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41144.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41144.C
5531--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41144.C       1969-12-31 16:00:00.000000000 -0800
5532+++ gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41144.C    2009-09-10 11:57:46.000000000 -0700
5533@@ -0,0 +1,23 @@
5534+/* { dg-do compile } */
5535+
5536+struct rgba8;
5537+template<class ColorT> class span_gouraud     {
5538+public:
5539+    struct coord_type { };
5540+    coord_type m_coord[3];
5541+};
5542+template<class ColorT> class span_gouraud_rgba : public span_gouraud<ColorT>   
5543+{
5544+  typedef ColorT color_type;
5545+  typedef span_gouraud<color_type> base_type;
5546+  typedef typename base_type::coord_type coord_type;
5547+public:
5548+  void prepare()         {
5549+      coord_type coord[3];
5550+  }
5551+};
5552+void the_application() {
5553+    typedef span_gouraud_rgba<rgba8> gouraud_span_gen_type;
5554+    gouraud_span_gen_type span_gouraud;
5555+    span_gouraud.prepare();
5556+}
5557diff -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
5558--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41257-2.C     1969-12-31 16:00:00.000000000 -0800
5559+++ gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41257-2.C  2009-09-10 11:57:46.000000000 -0700
5560@@ -0,0 +1,16 @@
5561+/* { dg-do link } */
5562+
5563+struct A
5564+{
5565+  virtual ~A();
5566+};
5567+
5568+struct B : virtual A
5569+{
5570+  virtual ~B() {}
5571+};
5572+
5573+int main()
5574+{
5575+  return 0;
5576+}
5577diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41257.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41257.C
5578--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41257.C       1969-12-31 16:00:00.000000000 -0800
5579+++ gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41257.C    2009-09-10 11:57:46.000000000 -0700
5580@@ -0,0 +1,20 @@
5581+/* { dg-do compile } */
5582+
5583+struct A
5584+{
5585+  virtual void foo();
5586+  virtual ~A();
5587+  int i;
5588+};
5589+
5590+struct B : virtual A {};
5591+
5592+struct C : B
5593+{
5594+  virtual void foo();
5595+};
5596+
5597+void bar()
5598+{
5599+  C().foo();
5600+}
5601diff -Naur gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41273.C gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41273.C
5602--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/torture/pr41273.C       1969-12-31 16:00:00.000000000 -0800
5603+++ gcc-4.4.1/gcc/testsuite/g++.dg/torture/pr41273.C    2009-09-10 11:57:46.000000000 -0700
5604@@ -0,0 +1,18 @@
5605+/* { dg-do compile } */
5606+/* { dg-options "-g" } */
5607+
5608+long *H2_ipX_ener_sort;
5609+double H2_old_populations[2];
5610+double H2_total;
5611+
5612+void H2_LevelPops()
5613+{
5614+  double sum_pop = 0.;
5615+  long nEner = 0;
5616+  while( nEner < 3 && sum_pop/H2_total < 0.99999 )
5617+    {
5618+      long ip = H2_ipX_ener_sort[nEner];
5619+      sum_pop += H2_old_populations[ip];
5620+      ++nEner;
5621+    }
5622+}
5623diff -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
5624--- gcc-4.4.1.orig/gcc/testsuite/g++.dg/warn/Wreturn-type-6.C   1969-12-31 16:00:00.000000000 -0800
5625+++ gcc-4.4.1/gcc/testsuite/g++.dg/warn/Wreturn-type-6.C        2009-07-26 09:05:22.000000000 -0700
5626@@ -0,0 +1,13 @@
5627+/* PR c++/40749 */
5628+/* { dg-do "compile" } */
5629+/* { dg-options "-Wreturn-type" } */
5630+
5631+struct A {};
5632+const A a() {} /* { dg-warning "no return statement" } */
5633+const A& b() {} /* { dg-warning "no return statement" } */
5634+
5635+const int c() {} /* { dg-warning "no return statement" } */
5636+
5637+template<class T>
5638+const int foo(T t) {} /* { dg-warning "no return statement" } */
5639+int d = foo<int>(0), e = foo<int>(1);
5640diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/altreturn_7.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/altreturn_7.f90
5641--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/altreturn_7.f90    1969-12-31 16:00:00.000000000 -0800
5642+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/altreturn_7.f90 2009-07-28 09:51:19.000000000 -0700
5643@@ -0,0 +1,34 @@
5644+! { dg-do compile }
5645+!
5646+! PR 40848: [4.5 Regression] ICE with alternate returns
5647+!
5648+! Contributed by Joost VandeVondele <jv244@cam.ac.uk>
5649+
5650+MODULE TT
5651+
5652+INTERFACE M
5653+ MODULE PROCEDURE M1,M2
5654+END INTERFACE
5655+
5656+CONTAINS
5657+
5658+ SUBROUTINE M1(I,*)
5659+   INTEGER :: I
5660+   RETURN 1
5661+ END SUBROUTINE
5662+
5663+ SUBROUTINE M2(I,J)
5664+   INTEGER :: I,J
5665+ END SUBROUTINE
5666+
5667+END MODULE
5668+
5669+
5670+  USE TT
5671+  CALL M(1,*2)
5672+  CALL ABORT()
5673+2 CONTINUE
5674+END
5675+
5676+! { dg-final { cleanup-modules "tt" } }
5677+
5678diff -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
5679--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/c_f_pointer_tests_4.f90    1969-12-31 16:00:00.000000000 -0800
5680+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/c_f_pointer_tests_4.f90 2009-08-20 13:42:38.000000000 -0700
5681@@ -0,0 +1,15 @@
5682+! { dg-do run }
5683+program main
5684+   use iso_c_binding, only: c_ptr, c_loc, c_f_pointer
5685+   implicit none
5686+   integer, dimension(2,1,2), target :: table
5687+   table = reshape ( (/ 1,2,-1,-2/), (/2,1,2/))
5688+   call set_table (c_loc (table))
5689+contains
5690+   subroutine set_table (cptr)
5691+     type(c_ptr), intent(in) :: cptr
5692+     integer, dimension(:,:,:), pointer :: table_tmp
5693+     call c_f_pointer (cptr, table_tmp, (/2,1,2/))
5694+     if (any(table_tmp /= table)) call abort
5695+   end subroutine set_table
5696+end program main
5697diff -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
5698--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/char_length_16.f90 1969-12-31 16:00:00.000000000 -0800
5699+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/char_length_16.f90      2009-07-28 09:51:19.000000000 -0700
5700@@ -0,0 +1,12 @@
5701+! { dg-do compile }
5702+!
5703+! PR 40822: [4.5 Regression] Internal compiler error when Fortran intrinsic LEN referenced before explicit declaration
5704+!
5705+! Contributed by Mat Cross <mathewc@nag.co.uk>
5706+
5707+SUBROUTINE SEARCH(ITEMVAL)
5708+  CHARACTER (*) :: ITEMVAL
5709+  CHARACTER (LEN(ITEMVAL)) :: ITEM
5710+  INTRINSIC LEN
5711+END
5712+
5713diff -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
5714--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/derived_init_3.f90 1969-12-31 16:00:00.000000000 -0800
5715+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/derived_init_3.f90      2009-07-29 02:35:15.000000000 -0700
5716@@ -0,0 +1,34 @@
5717+! { dg-do run }
5718+!
5719+! PR fortran/40851
5720+!
5721+! Make sure the an INTENT(OUT) dummy is not initialized
5722+! when it is a pointer.
5723+!
5724+! Contributed by Juergen Reuter <juergen.reuter@desy.de>.
5725+!
5726+program main
5727+
5728+  type :: string
5729+     character,dimension(:),allocatable :: chars
5730+  end type string
5731+
5732+  type :: string_container
5733+     type(string) :: string
5734+  end type string_container
5735+
5736+  type(string_container), target :: tgt
5737+  type(string_container), pointer :: ptr
5738+
5739+  ptr => tgt
5740+  call set_ptr (ptr)
5741+  if (associated(ptr)) call abort()
5742+
5743+contains
5744+
5745+  subroutine set_ptr (ptr)
5746+    type(string_container), pointer, intent(out) :: ptr
5747+    ptr => null ()
5748+  end subroutine set_ptr
5749+
5750+end program main
5751diff -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
5752--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/fmt_cache_1.f      1969-12-31 16:00:00.000000000 -0800
5753+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/fmt_cache_1.f   2009-07-23 10:50:56.000000000 -0700
5754@@ -0,0 +1,33 @@
5755+! { dg-do run { target fd_truncate } }
5756+! pr40662 segfaults when specific format is invoked twice.
5757+! pr40330  incorrect io.
5758+! test case derived from pr40662, <jvdelisle@gcc.gnu.org>
5759+      program astap
5760+      character(40) teststring
5761+      arlxca = 0.0
5762+      open(10)
5763+      write(10,40) arlxca
5764+      write(10,40) arlxca
5765+40    format(t4,"arlxca = ",1pg13.6,t27,"arlxcc = ",g13.6,t53,
5766+     .            "atmpca = ",g13.6,t79,"atmpcc = ",g13.6,t105,
5767+     .            "backup = ",g13.6,/,
5768+     .         t4,"csgfac = ",g13.6,t27,"csgmax = ",g13.6,t53,
5769+     .            "csgmin = ",g13.6,t79,"drlxca = ",g13.6,t105,
5770+     .            "drlxcc = ",g13.6,/,
5771+     .         t4,"dtimeh = ",g13.6,t27,"dtimei = ",g13.6,t53,
5772+     .            "dtimel = ",g13.6,t79,"dtimeu = ",g13.6,t105,
5773+     .            "dtmpca = ",g13.6,/,
5774+     .         t4,"dtmpcc = ",g13.6,t27,"ebalna = ",g13.6,t53,
5775+     .            "ebalnc = ",g13.6,t79,"ebalsa = ",g13.6,t105,
5776+     .            "ebalsc = ",g13.6)
5777+      rewind 10
5778+      rewind 10
5779+      teststring = ""
5780+      read(10,'(a)') teststring
5781+      if (teststring.ne."   arlxca =   0.00000     arlxcc = ")call abort
5782+      teststring = ""
5783+      read(10,'(a)') teststring
5784+      if (teststring.ne."   arlxca =   0.00000     arlxcc = ")call abort
5785+      end program astap
5786+
5787+
5788diff -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
5789--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/gomp/pr40878-1.f90 1969-12-31 16:00:00.000000000 -0800
5790+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/gomp/pr40878-1.f90      2009-07-28 09:33:08.000000000 -0700
5791@@ -0,0 +1,63 @@
5792+! PR fortran/40878
5793+! { dg-do compile }
5794+! { dg-options "-fopenmp" }
5795+
5796+subroutine test1
5797+  integer :: j, k
5798+  integer :: m = 2
5799+!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "Constant expression required" }
5800+  do k = 1, 2
5801+    do j = 1, 6
5802+    enddo
5803+  enddo
5804+!$omp end parallel do
5805+end
5806+subroutine test2
5807+  integer :: j, k
5808+  integer :: m
5809+  m = 2
5810+!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "Constant expression required" }
5811+  do k = 1, 2
5812+    do j = 1, 6
5813+    enddo
5814+  enddo
5815+!$omp end parallel do
5816+end
5817+subroutine test3
5818+  integer :: j, k
5819+  integer, parameter :: m = 0
5820+!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "not constant positive integer" }
5821+  do k = 1, 2
5822+    do j = 1, 6
5823+    enddo
5824+  enddo
5825+!$omp end parallel do
5826+end
5827+subroutine test4
5828+  integer :: j, k
5829+  integer, parameter :: m = -2
5830+!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "not constant positive integer" }
5831+  do k = 1, 2
5832+    do j = 1, 6
5833+    enddo
5834+  enddo
5835+!$omp end parallel do
5836+end
5837+subroutine test5
5838+  integer :: j, k
5839+!$omp parallel do collapse(0) schedule (static,1) ! { dg-error "not constant positive integer" }
5840+  do k = 1, 2
5841+    do j = 1, 6
5842+    enddo
5843+  enddo
5844+!$omp end parallel do
5845+end
5846+subroutine test6
5847+  integer :: j, k
5848+!$omp parallel do collapse(-1) schedule (static,1) ! { dg-error "not constant positive integer" }
5849+  do k = 1, 2
5850+    do j = 1, 6
5851+    enddo
5852+  enddo
5853+!$omp end parallel do
5854+end
5855diff -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
5856--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/gomp/pr40878-2.f90 1969-12-31 16:00:00.000000000 -0800
5857+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/gomp/pr40878-2.f90      2009-07-28 09:33:08.000000000 -0700
5858@@ -0,0 +1,23 @@
5859+! PR fortran/40878
5860+! { dg-do compile }
5861+! { dg-options "-fopenmp" }
5862+
5863+subroutine test1
5864+  integer :: j, k
5865+  integer, parameter :: m = 2
5866+!$omp parallel do collapse(m) schedule (static,1)
5867+  do k = 1, 2
5868+    do j = 1, 6
5869+    enddo
5870+  enddo
5871+!$omp end parallel do
5872+end
5873+subroutine test2
5874+  integer :: j, k
5875+!$omp parallel do collapse(2) schedule (static,1)
5876+  do k = 1, 2
5877+    do j = 1, 6
5878+    enddo
5879+  enddo
5880+!$omp end parallel do
5881+end
5882diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_3.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_3.f90
5883--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_3.f90    1969-12-31 16:00:00.000000000 -0800
5884+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_3.f90 2009-09-11 15:11:06.000000000 -0700
5885@@ -0,0 +1,40 @@
5886+! { dg-do compile }
5887+! { dg-options "-std=f95" }
5888+!
5889+! PR 39876: module procedure name that collides with the GNU intrinsic
5890+!
5891+! Contributed by Alexei Matveev <alexei.matveev+gcc@gmail.com>
5892+
5893+module p                           
5894+  implicit none                                                                 
5895+
5896+  contains
5897+
5898+    subroutine test()
5899+      implicit none
5900+      print *, avg(erfc)
5901+    end subroutine test
5902+
5903+    function avg(f)
5904+      implicit none
5905+      double precision :: avg
5906+      interface
5907+        double precision function f(x)
5908+          implicit none
5909+          double precision, intent(in) :: x
5910+        end function f
5911+      end interface
5912+      avg = ( f(1.0D0) + f(2.0D0) ) / 2
5913+    end function avg
5914+
5915+    function erfc(x)
5916+      implicit none
5917+      double precision, intent(in) :: x
5918+      double precision             :: erfc
5919+      erfc = x
5920+    end function erfc
5921+
5922+end module p
5923+
5924+! { dg-final { cleanup-modules "p" } }
5925+
5926diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_4.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_4.f90
5927--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_4.f90    1969-12-31 16:00:00.000000000 -0800
5928+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_4.f90 2009-08-16 13:23:57.000000000 -0700
5929@@ -0,0 +1,12 @@
5930+! { dg-do compile }
5931+! { dg-options "-Wsurprising" }
5932+!
5933+! PR 40995: [4.5 Regression] Spurious "Type specified for intrinsic function...ignored" message
5934+!
5935+! Contributed by Mat Cross <mathewc@nag.co.uk>
5936+
5937+subroutine sub(n,x)
5938+  intrinsic abs
5939+  integer n, x(abs(n))
5940+end
5941+
5942diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_5.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_5.f90
5943--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_5.f90    1969-12-31 16:00:00.000000000 -0800
5944+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_5.f90 2009-08-29 19:06:32.000000000 -0700
5945@@ -0,0 +1,13 @@
5946+! { dg-do compile }
5947+! { dg-options "-fimplicit-none" }
5948+!
5949+! PR 41121: [4.5 Regression] compile-time error when building BLAS with -fimplicit-none
5950+!
5951+! Original test case: http://www.netlib.org/blas/dgbmv.f
5952+! Reduced by Joost VandeVondele <jv244@cam.ac.uk>
5953+
5954+  INTRINSIC MIN
5955+  INTEGER :: I,J
5956+  print *,MIN(I,J)
5957+END
5958+
5959diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_cmplx.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_cmplx.f90
5960--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/intrinsic_cmplx.f90        1969-12-31 16:00:00.000000000 -0800
5961+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/intrinsic_cmplx.f90     2009-07-23 17:28:43.000000000 -0700
5962@@ -0,0 +1,9 @@
5963+! { dg-do compile }
5964+! PR fortran/40727
5965+program test
5966+  integer, parameter :: sp = kind(1.e0), dp = kind(1.d0)
5967+  complex(sp) :: s
5968+  complex(dp) :: d
5969+  s =  cmplx(0.e0, cmplx(0.e0,0.e0)) ! { dg-error "either REAL or INTEGER" }
5970+  d = dcmplx(0.d0, cmplx(0.d0,0.d0)) ! { dg-error "either REAL or INTEGER" }
5971+end program test
5972diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/namelist_40.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/namelist_40.f90
5973--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/namelist_40.f90    2008-03-04 16:59:34.000000000 -0800
5974+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/namelist_40.f90 2009-08-04 20:17:52.000000000 -0700
5975@@ -1,4 +1,4 @@
5976-! { dg-do run { target fd_truncate } }
5977+! { dg-do run }
5978 ! PR33672 Additional runtime checks needed for namelist reads
5979 ! Submitted by Jerry DeLisle  <jvdelisle@gcc.gnu.org>
5980 
5981@@ -47,7 +47,7 @@
5982 end subroutine writenml
5983 
5984 end program namelist_40
5985-! { dg-output "Multiple sub-objects with non-zero rank in namelist object x(\n|\r\n|\r)" }
5986+! { dg-output "Multiple sub-objects with non-zero rank in namelist object x%m%ch(\n|\r\n|\r)" }
5987 ! { dg-output "Missing colon in substring qualifier for namelist variable x%m%ch(\n|\r\n|\r)" }
5988 ! { dg-output "Substring out of range for namelist variable x%m%ch(\n|\r\n|\r)" }
5989 ! { dg-output "Bad character in substring qualifier for namelist variable x%m%ch(\n|\r\n|\r)" }
5990diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/namelist_47.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/namelist_47.f90
5991--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/namelist_47.f90    2008-05-16 07:07:37.000000000 -0700
5992+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/namelist_47.f90 2009-08-04 20:17:52.000000000 -0700
5993@@ -1,4 +1,4 @@
5994-! { dg-do run { target fd_truncate } }
5995+! { dg-do run }
5996 
5997 module nml_47
5998   type             ::  mt
5999@@ -45,7 +45,7 @@
6000 end subroutine writenml
6001 
6002 end program namelist_47
6003-! { dg-output "Multiple sub-objects with non-zero rank in namelist object x(\n|\r\n|\r)" }
6004+! { dg-output "Multiple sub-objects with non-zero rank in namelist object x%m%c012345678901234567890123456789012345678901234567890123456789h(\n|\r\n|\r)" }
6005 ! { dg-output "Missing colon in substring qualifier for namelist variable x%m%c012345678901234567890123456789012345678901234567890123456789h(\n|\r\n|\r)" }
6006 ! { dg-output "Substring out of range for namelist variable x%m%c012345678901234567890123456789012345678901234567890123456789h(\n|\r\n|\r)" }
6007 ! { dg-output "Bad character in substring qualifier for namelist variable x%m%c012345678901234567890123456789012345678901234567890123456789h(\n|\r\n|\r)" }
6008diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/namelist_58.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/namelist_58.f90
6009--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/namelist_58.f90    1969-12-31 16:00:00.000000000 -0800
6010+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/namelist_58.f90 2009-08-04 20:17:52.000000000 -0700
6011@@ -0,0 +1,25 @@
6012+! { dg-do run }
6013+! PR40853 Error in namelist IO.
6014+! Test case derived from example given in PR. < jvdelisle@gcc.gnu.org >
6015+program test
6016+  implicit none
6017+  type tao_title_struct
6018+    character(2) justify   
6019+  end type
6020+  type tao_plot_page_struct
6021+    real shape_height_max
6022+    type (tao_title_struct) title ! Comment this line out and the bug goes away.
6023+    real size(2)
6024+  end type
6025+  type (tao_plot_page_struct) plot_page
6026+  namelist / params / plot_page
6027+  open (10, status="scratch")
6028+  write(10,'(a)')"  &params"
6029+  write(10,'(a)')"  plot_page%size=5 , 2,"
6030+  write(10,'(a)')"/"
6031+  rewind(10)
6032+  read (10, nml = params)
6033+  if (any(plot_page%size .ne. (/ 5, 2 /))) call abort
6034+  close (10)
6035+end program
6036+
6037diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41126.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41126.f90
6038--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41126.f90        1969-12-31 16:00:00.000000000 -0800
6039+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41126.f90     2009-08-29 19:06:32.000000000 -0700
6040@@ -0,0 +1,6 @@
6041+! { dg-do compile }
6042+SUBROUTINE write_cputime( checkpoint  )
6043+  CHARACTER(LEN=*), INTENT(IN)             :: checkpoint
6044+  CHARACTER(LEN=LEN_TRIM(checkpoint)+7)    :: string1
6045+    string1 = ADJUSTL(string1)
6046+END SUBROUTINE write_cputime
6047diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41162.f gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41162.f
6048--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41162.f  1969-12-31 16:00:00.000000000 -0800
6049+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41162.f       2009-08-29 19:06:32.000000000 -0700
6050@@ -0,0 +1,5 @@
6051+! { dg-do compile }
6052+! PRs 41154/41162
6053+      write (*,'(1PD24.15,F4.2,0P)') 1.0d0
6054+      write (*,'(1PD24.15,F4.2,0P/)') 1.0d0
6055+      end
6056diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41225.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41225.f90
6057--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41225.f90        1969-12-31 16:00:00.000000000 -0800
6058+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41225.f90     2009-09-10 11:57:46.000000000 -0700
6059@@ -0,0 +1,20 @@
6060+! { dg-do compile }
6061+! { dg-options "-O2 -ffast-math -funroll-loops -ftree-vectorize -g" }
6062+  SUBROUTINE block_15_1_1_1(kbd,kbc,kad,kac,pbd,pbc,pad,pac,prim,scale)
6063+    INTEGER, PARAMETER :: dp=8
6064+    REAL(KIND=dp) :: kbd(1*1), kbc(1*1), kad(15*1), kac(15*1), pbd(1*1), &
6065+      pbc(1*1), pad(15*1), pac(15*1), prim(15*1*1*1), scale
6066+    INTEGER                                  :: ma, mb, mc, md, p_index
6067+      DO md = 1,1
6068+        DO mc = 1,1
6069+          DO mb = 1,1
6070+            DO ma = 1,15
6071+              p_index=p_index+1
6072+              tmp = scale*prim(p_index)
6073+              ks_bd = ks_bd + tmp* pac((mc-1)*15+ma)
6074+            END DO
6075+            kbd((md-1)*1+mb) = kbd((md-1)*1+mb) - ks_bd
6076+          END DO
6077+        END DO
6078+      END DO
6079+  END SUBROUTINE block_15_1_1_1
6080diff -Naur gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41229.f90 gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41229.f90
6081--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/pr41229.f90        1969-12-31 16:00:00.000000000 -0800
6082+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/pr41229.f90     2009-09-10 11:57:46.000000000 -0700
6083@@ -0,0 +1,10 @@
6084+! { dg-do compile }
6085+! { dg-options "-O2 -g" }
6086+SUBROUTINE cp_fm_triangular_multiply()
6087+    INTEGER, PARAMETER :: dp=KIND(0.0D0)
6088+    REAL(dp), ALLOCATABLE, DIMENSION(:)      :: tau, work
6089+    REAL(KIND=dp), DIMENSION(:, :), POINTER  :: a
6090+    ndim = SIZE(a,2)
6091+    ALLOCATE(tau(ndim),STAT=istat)
6092+    ALLOCATE(work(2*ndim),STAT=istat)
6093+END SUBROUTINE
6094diff -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
6095--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/proc_ptr_25.f90    1969-12-31 16:00:00.000000000 -0800
6096+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/proc_ptr_25.f90 2009-08-29 19:06:32.000000000 -0700
6097@@ -0,0 +1,36 @@
6098+! { dg-do run }
6099+!
6100+! PR 41139: [4.5 Regression] a procedure pointer call as actual argument
6101+!
6102+! Original test case by Barron Bichon <barron.bichon@swri.org>
6103+! Modified by Janus Weil <janus@gcc.gnu.org>
6104+
6105+PROGRAM test
6106+
6107+ PROCEDURE(add), POINTER :: f
6108+ logical :: g
6109+
6110+ ! Passing the function works
6111+ g=greater(4.,add(1.,2.))
6112+ if (.not. g) call abort()
6113+
6114+ ! Passing the procedure pointer fails
6115+ f => add
6116+ g=greater(4.,f(1.,2.))
6117+ if (.not. g) call abort()
6118+
6119+CONTAINS
6120+
6121+ REAL FUNCTION add(x,y)
6122+   REAL, INTENT(in) :: x,y
6123+   print *,"add:",x,y
6124+   add = x+y
6125+ END FUNCTION add
6126+
6127+ LOGICAL FUNCTION greater(x,y)
6128+   REAL, INTENT(in) :: x, y
6129+   greater = (x > y)
6130+ END FUNCTION greater
6131+
6132+END PROGRAM test
6133+
6134diff -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
6135--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/structure_constructor_10.f90       1969-12-31 16:00:00.000000000 -0800
6136+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/structure_constructor_10.f90    2009-08-16 13:23:57.000000000 -0700
6137@@ -0,0 +1,28 @@
6138+! { dg-do compile }
6139+!
6140+! PR 41070: [4.5 Regression] Error: Components of structure constructor '' at (1) are PRIVATE
6141+!
6142+! Contributed by Michael Richmond <michael.a.richmond@nasa.gov>
6143+
6144+MODULE cdf_aux_mod
6145+IMPLICIT NONE
6146+
6147+TYPE :: one_parameter
6148+  CHARACTER (8) :: name
6149+END TYPE one_parameter
6150+
6151+TYPE :: the_distribution
6152+  CHARACTER (8) :: name
6153+END TYPE the_distribution
6154+
6155+TYPE (the_distribution), PARAMETER :: the_beta = the_distribution('cdf_beta')
6156+END MODULE cdf_aux_mod
6157+
6158+SUBROUTINE cdf_beta()
6159+  USE cdf_aux_mod
6160+  IMPLICIT NONE
6161+  CALL check_complements(the_beta%name)
6162+END SUBROUTINE cdf_beta
6163+
6164+! { dg-final { cleanup-modules "cdf_aux_mod" } }
6165+
6166diff -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
6167--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/transfer_resolve_1.f90     1969-12-31 16:00:00.000000000 -0800
6168+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/transfer_resolve_1.f90  2009-08-16 13:04:40.000000000 -0700
6169@@ -0,0 +1,21 @@
6170+! { dg-do run }
6171+! PR40847 - an error in gfc_resolve_transfer caused the character length
6172+! of 'mold' to be set incorrectly.
6173+!
6174+! Contributed by Joost VandeVondele <jv244@cam.ac.uk>
6175+!
6176+program test_elemental
6177+
6178+if (any (transfer_size((/0.,0./),(/'a','b'/)) .ne. [4 ,4])) call abort
6179+
6180+contains
6181+
6182+   elemental function transfer_size (source, mold)
6183+     real, intent(in)         :: source
6184+     character(*), intent(in) :: mold
6185+     integer                  :: transfer_size
6186+     transfer_size = SIZE(TRANSFER(source, (/mold/)))
6187+     return
6188+   end function transfer_size
6189+
6190+end program test_elemental
6191diff -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
6192--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/typebound_proc_12.f90      1969-12-31 16:00:00.000000000 -0800
6193+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/typebound_proc_12.f90   2009-09-05 07:25:39.000000000 -0700
6194@@ -0,0 +1,12 @@
6195+! { dg-do compile }
6196+! Test the fix for PR41258, where an ICE was caused by a search
6197+! for a typebound procedure to resolve d%c%e
6198+!
6199+! Contributed by Joost VandeVondele <jv244@cam.ac.uk>
6200+!
6201+  TYPE a
6202+    TYPE(b), DIMENSION(:), POINTER :: c  ! { dg-error "type that has not been declared" }
6203+  END TYPE
6204+  TYPE(a), POINTER :: d
6205+  CALL X(d%c%e)         ! { dg-error "before it is defined" }
6206+end
6207diff -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
6208--- gcc-4.4.1.orig/gcc/testsuite/gfortran.dg/use_only_4.f90     1969-12-31 16:00:00.000000000 -0800
6209+++ gcc-4.4.1/gcc/testsuite/gfortran.dg/use_only_4.f90  2009-08-25 11:54:58.000000000 -0700
6210@@ -0,0 +1,34 @@
6211+! { dg-do compile }
6212+! Test the fix for PR41062, in which an ICE would ensue because
6213+! of confusion between the two 'one's in the creation of module
6214+! debug info.
6215+!
6216+! Reported by Norman S. Clerman <clerman@fuse.net>
6217+! Reduced testcase by Tobias Burnus <burnus@gcc.gnu.org>
6218+!
6219+module m1
6220+   interface one  ! GENERIC "one"
6221+     module procedure one1
6222+   end interface
6223+contains
6224+  subroutine one1()
6225+    call abort
6226+  end subroutine one1
6227+end module m1
6228+
6229+module m2
6230+use m1, only : one  ! USE generic "one"
6231+contains
6232+  subroutine two()
6233+    call one()  ! Call internal "one"
6234+  contains
6235+    subroutine one() ! Internal "one"
6236+      print *, "m2"
6237+    end subroutine one
6238+  end subroutine two
6239+end module m2
6240+
6241+  use m2
6242+  call two
6243+end
6244+! { dg-final { cleanup-modules "m1 m2" } }
6245diff -Naur gcc-4.4.1.orig/gcc/testsuite/gnat.dg/array8.adb gcc-4.4.1/gcc/testsuite/gnat.dg/array8.adb
6246--- gcc-4.4.1.orig/gcc/testsuite/gnat.dg/array8.adb     1969-12-31 16:00:00.000000000 -0800
6247+++ gcc-4.4.1/gcc/testsuite/gnat.dg/array8.adb  2009-09-10 11:57:46.000000000 -0700
6248@@ -0,0 +1,34 @@
6249+-- { dg-do compile }
6250+-- { dg-options "-O2" }
6251+
6252+PROCEDURE Array8 IS
6253+
6254+  function ID (I : Integer) return Integer is
6255+  begin
6256+    return I;
6257+  end;
6258+
6259+  SUBTYPE STB IS INTEGER RANGE ID(-8) .. -5;
6260+
6261+  TYPE TB IS ARRAY (STB RANGE <>) OF INTEGER;
6262+
6263+  GENERIC
6264+    B1 : TB;
6265+  PROCEDURE PROC1;
6266+
6267+  PROCEDURE PROC1 IS
6268+  BEGIN
6269+    IF B1'FIRST /= -8 THEN
6270+      raise Program_Error;
6271+    ELSIF B1'LAST /= ID(-5) THEN
6272+      raise Program_Error;
6273+    ELSIF B1 /= (7, 6, 5, 4) THEN
6274+      raise Program_Error;
6275+    END IF;
6276+  END;
6277+
6278+  PROCEDURE PROC2 IS NEW PROC1 ((7, 6, ID(5), 4));
6279+
6280+BEGIN
6281+  PROC2;
6282+END;
6283diff -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
6284--- gcc-4.4.1.orig/gcc/testsuite/g++.old-deja/g++.brendan/init4.C       2003-04-30 19:02:59.000000000 -0700
6285+++ gcc-4.4.1/gcc/testsuite/g++.old-deja/g++.brendan/init4.C    2009-07-24 11:06:08.000000000 -0700
6286@@ -2,4 +2,4 @@
6287 // GROUPS passed initialization
6288 struct CharList { int i; };
6289 
6290-const CharList& terminals = { 1 };// { dg-error "" } .*
6291+const CharList& terminals = { 1 }; // { dg-error "initializer lists" } c++0x
6292diff -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
6293--- gcc-4.4.1.orig/gcc/testsuite/g++.old-deja/g++.jason/thunk2.C        2009-03-11 10:52:06.000000000 -0700
6294+++ gcc-4.4.1/gcc/testsuite/g++.old-deja/g++.jason/thunk2.C     2009-07-27 23:56:49.000000000 -0700
6295@@ -1,6 +1,5 @@
6296 // { dg-do run { target fpic } }
6297 // { dg-options "-fPIC" }
6298-// { 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 }
6299 // { dg-skip-if "requires unsupported run-time relocation" { spu-*-* } { "*" } { "" } }
6300 // Test that non-variadic function calls using thunks and PIC work right.
6301 
6302diff -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
6303--- gcc-4.4.1.orig/gcc/testsuite/g++.old-deja/g++.law/weak.C    2005-12-09 15:34:09.000000000 -0800
6304+++ gcc-4.4.1/gcc/testsuite/g++.old-deja/g++.law/weak.C 2009-07-25 06:54:21.000000000 -0700
6305@@ -1,4 +1,5 @@
6306 // { dg-do link { target i?86-*-linux* x86_64-*-linux* } }
6307+// { dg-require-effective-target static }
6308 // { dg-options "-static" }
6309 // Bug: g++ fails to instantiate operator<<.
6310 
6311diff -Naur gcc-4.4.1.orig/gcc/testsuite/lib/target-supports.exp gcc-4.4.1/gcc/testsuite/lib/target-supports.exp
6312--- gcc-4.4.1.orig/gcc/testsuite/lib/target-supports.exp        2009-07-21 00:22:51.000000000 -0700
6313+++ gcc-4.4.1/gcc/testsuite/lib/target-supports.exp     2009-08-28 02:57:51.000000000 -0700
6314@@ -611,6 +611,13 @@
6315     } "-pthread"]
6316 }
6317 
6318+# Return 1 if the target supports -static
6319+proc check_effective_target_static {} {
6320+    return [check_no_compiler_messages static executable {
6321+       int main (void) { return 0; }
6322+    } "-static"]
6323+}
6324+
6325 # Return 1 if the target supports -fstack-protector
6326 proc check_effective_target_fstack_protector {} {
6327     return [check_runtime fstack_protector {
6328@@ -1269,7 +1276,8 @@
6329        verbose "check_effective_target_vect_cmdline_needed: using cached result" 2
6330     } else {
6331        set et_vect_cmdline_needed_saved 1
6332-       if { [istarget ia64-*-*]
6333+       if { [istarget alpha*-*-*]
6334+            || [istarget ia64-*-*]
6335             || (([istarget x86_64-*-*] || [istarget i?86-*-*])
6336                 && [check_effective_target_lp64])
6337             || ([istarget powerpc*-*-*]
6338diff -Naur gcc-4.4.1.orig/gcc/tree-ssa.c gcc-4.4.1/gcc/tree-ssa.c
6339--- gcc-4.4.1.orig/gcc/tree-ssa.c       2009-03-27 10:20:51.000000000 -0700
6340+++ gcc-4.4.1/gcc/tree-ssa.c    2009-08-03 12:27:32.000000000 -0700
6341@@ -1472,7 +1472,12 @@
6342 
6343   /* We do not care about LHS.  */
6344   if (wi->is_lhs)
6345-    return NULL_TREE;
6346+    {
6347+      /* Except for operands of INDIRECT_REF.  */
6348+      if (!INDIRECT_REF_P (t))
6349+       return NULL_TREE;
6350+      t = TREE_OPERAND (t, 0);
6351+    }
6352 
6353   switch (TREE_CODE (t))
6354     {
6355diff -Naur gcc-4.4.1.orig/gcc/tree-ssa-ifcombine.c gcc-4.4.1/gcc/tree-ssa-ifcombine.c
6356--- gcc-4.4.1.orig/gcc/tree-ssa-ifcombine.c     2009-02-20 07:20:38.000000000 -0800
6357+++ gcc-4.4.1/gcc/tree-ssa-ifcombine.c  2009-08-09 14:39:19.000000000 -0700
6358@@ -151,7 +151,7 @@
6359     {
6360       gimple def_stmt = SSA_NAME_DEF_STMT (candidate);
6361       if (is_gimple_assign (def_stmt)
6362-         && gimple_assign_cast_p (def_stmt))
6363+         && CONVERT_EXPR_CODE_P (gimple_assign_rhs_code (def_stmt)))
6364        {
6365          if (TYPE_PRECISION (TREE_TYPE (candidate))
6366              <= TYPE_PRECISION (TREE_TYPE (gimple_assign_rhs1 (def_stmt))))
6367@@ -162,21 +162,6 @@
6368   return candidate;
6369 }
6370 
6371-/* Helpers for recognize_single_bit_test defined mainly for source code
6372-   formating.  */
6373-
6374-static int
6375-operand_precision (tree t)
6376-{
6377-  return TYPE_PRECISION (TREE_TYPE (t));
6378-}
6379-
6380-static bool
6381-integral_operand_p (tree t)
6382-{
6383-  return INTEGRAL_TYPE_P (TREE_TYPE (t));
6384-}
6385-
6386 /* Recognize a single bit test pattern in GIMPLE_COND and its defining
6387    statements.  Store the name being tested in *NAME and the bit
6388    in *BIT.  The GIMPLE_COND computes *NAME & (1 << *BIT).
6389@@ -212,15 +197,11 @@
6390       stmt = SSA_NAME_DEF_STMT (orig_name);
6391 
6392       while (is_gimple_assign (stmt)
6393-            && (gimple_assign_ssa_name_copy_p (stmt)
6394-                || (gimple_assign_cast_p (stmt)
6395-                    && integral_operand_p (gimple_assign_lhs (stmt))
6396-                    && integral_operand_p (gimple_assign_rhs1 (stmt))
6397-                    && (operand_precision (gimple_assign_lhs (stmt))
6398-                        <= operand_precision (gimple_assign_rhs1 (stmt))))))
6399-       {
6400-         stmt = SSA_NAME_DEF_STMT (gimple_assign_rhs1 (stmt));
6401-       }
6402+            && ((CONVERT_EXPR_CODE_P (gimple_assign_rhs_code (stmt))
6403+                 && (TYPE_PRECISION (TREE_TYPE (gimple_assign_lhs (stmt)))
6404+                     <= TYPE_PRECISION (TREE_TYPE (gimple_assign_rhs1 (stmt)))))
6405+                || gimple_assign_ssa_name_copy_p (stmt)))
6406+       stmt = SSA_NAME_DEF_STMT (gimple_assign_rhs1 (stmt));
6407 
6408       /* If we found such, decompose it.  */
6409       if (is_gimple_assign (stmt)
6410diff -Naur gcc-4.4.1.orig/gcc/tree-ssa-pre.c gcc-4.4.1/gcc/tree-ssa-pre.c
6411--- gcc-4.4.1.orig/gcc/tree-ssa-pre.c   2009-02-20 07:20:38.000000000 -0800
6412+++ gcc-4.4.1/gcc/tree-ssa-pre.c        2009-07-22 07:45:21.000000000 -0700
6413@@ -3507,11 +3507,7 @@
6414 }
6415 
6416 
6417-/* Add OP to EXP_GEN (block), and possibly to the maximal set if it is
6418-   not defined by a phi node.
6419-   PHI nodes can't go in the maximal sets because they are not in
6420-   TMP_GEN, so it is possible to get into non-monotonic situations
6421-   during ANTIC calculation, because it will *add* bits.  */
6422+/* Add OP to EXP_GEN (block), and possibly to the maximal set.  */
6423 
6424 static void
6425 add_to_exp_gen (basic_block block, tree op)
6426@@ -3523,9 +3519,7 @@
6427        return;
6428       result = get_or_alloc_expr_for_name (op);
6429       bitmap_value_insert_into_set (EXP_GEN (block), result);
6430-      if (TREE_CODE (op) != SSA_NAME
6431-         || gimple_code (SSA_NAME_DEF_STMT (op)) != GIMPLE_PHI)
6432-       bitmap_value_insert_into_set (maximal_set, result);
6433+      bitmap_value_insert_into_set (maximal_set, result);
6434     }
6435 }
6436 
6437@@ -3544,6 +3538,20 @@
6438       add_to_value (get_expr_value_id (e), e);
6439       bitmap_insert_into_set (PHI_GEN (block), e);
6440       bitmap_value_insert_into_set (AVAIL_OUT (block), e);
6441+      if (!in_fre)
6442+       {
6443+         unsigned i;
6444+         for (i = 0; i < gimple_phi_num_args (phi); ++i)
6445+           {
6446+             tree arg = gimple_phi_arg_def (phi, i);
6447+             if (TREE_CODE (arg) == SSA_NAME)
6448+               {
6449+                 e = get_or_alloc_expr_for_name (arg);
6450+                 add_to_value (get_expr_value_id (e), e);
6451+                 bitmap_value_insert_into_set (maximal_set, e);
6452+               }
6453+           }
6454+       }
6455     }
6456 }
6457 
6458@@ -4254,11 +4262,12 @@
6459       FOR_ALL_BB (bb)
6460        {
6461          print_bitmap_set (dump_file, EXP_GEN (bb), "exp_gen", bb->index);
6462-         print_bitmap_set (dump_file, TMP_GEN (bb), "tmp_gen",
6463-                                 bb->index);
6464-         print_bitmap_set (dump_file, AVAIL_OUT (bb), "avail_out",
6465-                                 bb->index);
6466+         print_bitmap_set (dump_file, PHI_GEN (bb), "phi_gen", bb->index);
6467+         print_bitmap_set (dump_file, TMP_GEN (bb), "tmp_gen", bb->index);
6468+         print_bitmap_set (dump_file, AVAIL_OUT (bb), "avail_out", bb->index);
6469        }
6470+
6471+      print_bitmap_set (dump_file, maximal_set, "maximal", 0);
6472     }
6473 
6474   /* Insert can get quite slow on an incredibly large number of basic
6475diff -Naur gcc-4.4.1.orig/gcc/version.c gcc-4.4.1/gcc/version.c
6476--- gcc-4.4.1.orig/gcc/version.c        2007-08-21 08:35:30.000000000 -0700
6477+++ gcc-4.4.1/gcc/version.c     2009-09-12 09:16:46.000000000 -0700
6478@@ -14,4 +14,4 @@
6479    Makefile.  */
6480 
6481 const char version_string[] = BASEVER DATESTAMP DEVPHASE REVISION;
6482-const char pkgversion_string[] = PKGVERSION;
6483+const char pkgversion_string[] = "(GCC for Cross-LFS 4.4.1.20090912) ";
6484diff -Naur gcc-4.4.1.orig/libcpp/macro.c gcc-4.4.1/libcpp/macro.c
6485--- gcc-4.4.1.orig/libcpp/macro.c       2009-04-09 16:23:07.000000000 -0700
6486+++ gcc-4.4.1/libcpp/macro.c    2009-09-02 11:47:29.000000000 -0700
6487@@ -375,7 +375,7 @@
6488        }
6489 
6490       escape_it = (token->type == CPP_STRING || token->type == CPP_CHAR
6491-                  || token->type == CPP_WSTRING || token->type == CPP_STRING
6492+                  || token->type == CPP_WSTRING || token->type == CPP_WCHAR
6493                   || token->type == CPP_STRING32 || token->type == CPP_CHAR32
6494                   || token->type == CPP_STRING16 || token->type == CPP_CHAR16);
6495 
6496diff -Naur gcc-4.4.1.orig/libdecnumber/decCommon.c gcc-4.4.1/libdecnumber/decCommon.c
6497--- gcc-4.4.1.orig/libdecnumber/decCommon.c     2009-04-09 16:23:07.000000000 -0700
6498+++ gcc-4.4.1/libdecnumber/decCommon.c  2009-08-13 09:58:06.000000000 -0700
6499@@ -1089,6 +1089,7 @@
6500   return 10;
6501   } /* decFloatRadix */
6502 
6503+#if (DECCHECK || DECTRACE)
6504 /* ------------------------------------------------------------------ */
6505 /* decFloatShow -- printf a decFloat in hexadecimal and decimal              */
6506 /*   df         is the decFloat to show                                      */
6507@@ -1115,6 +1116,7 @@
6508   printf(">%s> %s [big-endian] %s\n", tag, hexbuf, buff);
6509   return;
6510   } /* decFloatShow */
6511+#endif
6512 
6513 /* ------------------------------------------------------------------ */
6514 /* decFloatToBCD -- get sign, exponent, and BCD8 from a decFloat      */
6515diff -Naur gcc-4.4.1.orig/libgfortran/intrinsics/dtime.c gcc-4.4.1/libgfortran/intrinsics/dtime.c
6516--- gcc-4.4.1.orig/libgfortran/intrinsics/dtime.c       2009-04-09 16:23:07.000000000 -0700
6517+++ gcc-4.4.1/libgfortran/intrinsics/dtime.c    2009-08-24 20:30:25.000000000 -0700
6518@@ -38,9 +38,10 @@
6519 void
6520 dtime_sub (gfc_array_r4 *t, GFC_REAL_4 *result)
6521 {
6522-  static GFC_REAL_4 tu = 0.0, ts = 0.0, tt = 0.0;
6523   GFC_REAL_4 *tp;
6524   long user_sec, user_usec, system_sec, system_usec;
6525+  static long us = 0, uu = 0, ss = 0 , su = 0;
6526+  GFC_REAL_4 tu, ts, tt;
6527 
6528   if (((t->dim[0].ubound + 1 - t->dim[0].lbound)) < 2)
6529     runtime_error ("Insufficient number of elements in TARRAY.");
6530@@ -48,15 +49,19 @@
6531   __gthread_mutex_lock (&dtime_update_lock);
6532   if (__time_1 (&user_sec, &user_usec, &system_sec, &system_usec) == 0)
6533     {
6534-      tu = (GFC_REAL_4)(user_sec + 1.e-6 * user_usec) - tu;
6535-      ts = (GFC_REAL_4)(system_sec + 1.e-6 * system_usec) - ts;
6536+      tu = (GFC_REAL_4) ((user_sec - us) + 1.e-6 * (user_usec - uu));
6537+      ts = (GFC_REAL_4) ((system_sec - ss) + 1.e-6 * (system_usec - su));
6538       tt = tu + ts;
6539+      us = user_sec;
6540+      uu = user_usec;
6541+      ss = system_sec;
6542+      su = system_usec;
6543     }
6544   else
6545     {
6546-      tu = (GFC_REAL_4)-1.0;
6547-      ts = (GFC_REAL_4)-1.0;
6548-      tt = (GFC_REAL_4)-1.0;
6549+      tu = -1;
6550+      ts = -1;
6551+      tt = -1;
6552     }
6553 
6554   tp = t->data;
6555diff -Naur gcc-4.4.1.orig/libgfortran/intrinsics/iso_c_binding.c gcc-4.4.1/libgfortran/intrinsics/iso_c_binding.c
6556--- gcc-4.4.1.orig/libgfortran/intrinsics/iso_c_binding.c       2009-04-09 16:23:07.000000000 -0700
6557+++ gcc-4.4.1/libgfortran/intrinsics/iso_c_binding.c    2009-08-20 13:42:38.000000000 -0700
6558@@ -137,8 +137,8 @@
6559       f_ptr_out->offset = f_ptr_out->dim[0].lbound * f_ptr_out->dim[0].stride;
6560       for (i = 1; i < shapeSize; i++)
6561         {
6562-          f_ptr_out->dim[i].stride = (f_ptr_out->dim[i-1].ubound + 1)
6563-            - f_ptr_out->dim[i-1].lbound;
6564+          f_ptr_out->dim[i].stride = ((f_ptr_out->dim[i-1].ubound + 1)
6565+            - f_ptr_out->dim[i-1].lbound) * f_ptr_out->dim[i-1].stride;
6566           f_ptr_out->offset += f_ptr_out->dim[i].lbound
6567             * f_ptr_out->dim[i].stride;
6568         }
6569diff -Naur gcc-4.4.1.orig/libgfortran/intrinsics/time_1.h gcc-4.4.1/libgfortran/intrinsics/time_1.h
6570--- gcc-4.4.1.orig/libgfortran/intrinsics/time_1.h      2009-04-09 16:23:07.000000000 -0700
6571+++ gcc-4.4.1/libgfortran/intrinsics/time_1.h   2009-08-24 20:30:25.000000000 -0700
6572@@ -51,6 +51,10 @@
6573 #  endif
6574 #endif
6575 
6576+#ifdef HAVE_SYS_TYPES_H
6577+     #include <sys/types.h>
6578+#endif
6579+
6580 /* The most accurate way to get the CPU time is getrusage (). */
6581 #if defined (HAVE_GETRUSAGE) && defined (HAVE_SYS_RESOURCE_H)
6582 #  include <sys/resource.h>
6583@@ -112,7 +116,7 @@
6584 {
6585 #if defined (HAVE_GETRUSAGE) && defined (HAVE_SYS_RESOURCE_H)
6586   struct rusage usage;
6587-  getrusage (0, &usage);
6588+  getrusage (RUSAGE_SELF, &usage);
6589 
6590   *user_sec = usage.ru_utime.tv_sec;
6591   *user_usec = usage.ru_utime.tv_usec;
6592diff -Naur gcc-4.4.1.orig/libgfortran/io/list_read.c gcc-4.4.1/libgfortran/io/list_read.c
6593--- gcc-4.4.1.orig/libgfortran/io/list_read.c   2009-06-08 20:15:04.000000000 -0700
6594+++ gcc-4.4.1/libgfortran/io/list_read.c        2009-08-04 20:15:18.000000000 -0700
6595@@ -2772,7 +2772,7 @@
6596 
6597   if (nl->type == GFC_DTYPE_DERIVED)
6598     nml_touch_nodes (nl);
6599-  if (component_flag && nl->var_rank > 0)
6600+  if (component_flag && nl->var_rank > 0 && nl->next)
6601     nl = first_nl;
6602 
6603   /* Make sure no extraneous qualifiers are there.  */
6604diff -Naur gcc-4.4.1.orig/libgomp/omp_lib.h.in gcc-4.4.1/libgomp/omp_lib.h.in
6605--- gcc-4.4.1.orig/libgomp/omp_lib.h.in 2009-04-09 16:23:07.000000000 -0700
6606+++ gcc-4.4.1/libgomp/omp_lib.h.in      2009-08-19 00:11:43.000000000 -0700
6607@@ -42,16 +42,16 @@
6608       external omp_set_num_threads
6609 
6610       external omp_get_dynamic, omp_get_nested
6611-      logical*4 omp_get_dynamic, omp_get_nested
6612+      logical(4) omp_get_dynamic, omp_get_nested
6613       external omp_test_lock, omp_in_parallel
6614-      logical*4 omp_test_lock, omp_in_parallel
6615+      logical(4) omp_test_lock, omp_in_parallel
6616 
6617       external omp_get_max_threads, omp_get_num_procs
6618-      integer*4 omp_get_max_threads, omp_get_num_procs
6619+      integer(4) omp_get_max_threads, omp_get_num_procs
6620       external omp_get_num_threads, omp_get_thread_num
6621-      integer*4 omp_get_num_threads, omp_get_thread_num
6622+      integer(4) omp_get_num_threads, omp_get_thread_num
6623       external omp_test_nest_lock
6624-      integer*4 omp_test_nest_lock
6625+      integer(4) omp_test_nest_lock
6626 
6627       external omp_get_wtick, omp_get_wtime
6628       double precision omp_get_wtick, omp_get_wtime
6629@@ -61,6 +61,6 @@
6630       external omp_get_max_active_levels, omp_get_level
6631       external omp_get_ancestor_thread_num, omp_get_team_size
6632       external omp_get_active_level
6633-      integer*4 omp_get_thread_limit, omp_get_max_active_levels
6634-      integer*4 omp_get_level, omp_get_ancestor_thread_num
6635-      integer*4 omp_get_team_size, omp_get_active_level
6636+      integer(4) omp_get_thread_limit, omp_get_max_active_levels
6637+      integer(4) omp_get_level, omp_get_ancestor_thread_num
6638+      integer(4) omp_get_team_size, omp_get_active_level
6639diff -Naur gcc-4.4.1.orig/libjava/contrib/aotcompile.py.in gcc-4.4.1/libjava/contrib/aotcompile.py.in
6640--- gcc-4.4.1.orig/libjava/contrib/aotcompile.py.in     2009-04-26 07:24:38.000000000 -0700
6641+++ gcc-4.4.1/libjava/contrib/aotcompile.py.in  2009-07-23 07:27:31.000000000 -0700
6642@@ -15,7 +15,11 @@
6643 
6644 import classfile
6645 import copy
6646-import md5
6647+# The md5 module is deprecated in Python 2.5
6648+try:
6649+    from hashlib import md5
6650+except ImportError:
6651+    from md5 import md5
6652 import operator
6653 import os
6654 import sys
6655@@ -182,7 +186,7 @@
6656     def addClass(self, bytes, name):
6657         """Subclasses call this from their __init__ method for
6658         every class they find."""
6659-        digest = md5.new(bytes).digest()
6660+        digest = md5(bytes).digest()
6661         self.classes[digest] = bytes
6662         self.classnames[digest] = name
6663 
6664diff -Naur gcc-4.4.1.orig/libstdc++-v3/config/abi/pre/gnu.ver gcc-4.4.1/libstdc++-v3/config/abi/pre/gnu.ver
6665--- gcc-4.4.1.orig/libstdc++-v3/config/abi/pre/gnu.ver  2009-05-05 14:44:27.000000000 -0700
6666+++ gcc-4.4.1/libstdc++-v3/config/abi/pre/gnu.ver       2009-08-26 12:04:11.000000000 -0700
6667@@ -32,7 +32,9 @@
6668       std::a[e-z]*;
6669 #     std::ba[a-r]*;
6670       std::basic_[a-e]*;
6671-      std::basic_f[a-r]*;
6672+      std::basic_f[a-h]*;
6673+#     std::basic_filebuf;
6674+      std::basic_f[j-r]*;
6675 #     std::basic_fstream;
6676       std::basic_f[t-z]*;
6677       std::basic_[g-h]*;
6678@@ -273,28 +275,40 @@
6679     _ZNSdC*;
6680     _ZNSdD*;
6681 
6682+    # std::basic_filebuf
6683+    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EEC*;
6684+    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EED*;
6685+    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE[0-3]*;
6686+    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE4openEPKc*;
6687+    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE4sync*;
6688+    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE[5-9]*;
6689+    _ZNKSt13basic_filebufI[cw]St11char_traitsI[cw]EE7is_openEv;
6690+
6691     # std::basic_fstream
6692-    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EEC*;
6693+    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EEC[12]Ev;
6694+    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EEC[12]EPKc*;
6695     _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EED*;
6696     _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE5closeEv;
6697     _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE7is_openEv;
6698-    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE4open*;
6699+    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE4openEPKc*;
6700     _ZNKSt13basic_fstreamI[cw]St11char_traitsI[cw]EE5rdbufEv;
6701 
6702     # std::basic_ifstream
6703-    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EEC*;
6704+    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EEC[12]Ev;
6705+    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EEC[12]EPKc*;
6706     _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EED*;
6707     _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE5closeEv;
6708     _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE7is_openEv;
6709-    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE4open*;
6710+    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE4openEPKc*;
6711     _ZNKSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE5rdbufEv;
6712 
6713     # std::basic_ofstream
6714-    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EEC*;
6715+    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EEC[12]Ev;
6716+    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EEC[12]EPKc*;
6717     _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EED*;
6718     _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE5closeEv;
6719     _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE7is_openEv;
6720-    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE4open*;
6721+    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE4openEPKc*;
6722     _ZNKSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE5rdbufEv;
6723 
6724     # std::basic_istream<char>
6725@@ -966,6 +980,19 @@
6726 
6727 } GLIBCXX_3.4.11;
6728 
6729+GLIBCXX_3.4.13 {
6730+
6731+    # new fstream members
6732+    _ZNSt13basic_filebufI[cw]St11char_traitsI[cw]EE4openERKSsSt13_Ios_Openmode;
6733+    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EEC[12]ERKSsSt13_Ios_Openmode;
6734+    _ZNSt13basic_fstreamI[cw]St11char_traitsI[cw]EE4openERKSsSt13_Ios_Openmode;
6735+    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EEC[12]ERKSsSt13_Ios_Openmode;
6736+    _ZNSt14basic_ifstreamI[cw]St11char_traitsI[cw]EE4openERKSsSt13_Ios_Openmode;
6737+    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EEC[12]ERKSsSt13_Ios_Openmode;
6738+    _ZNSt14basic_ofstreamI[cw]St11char_traitsI[cw]EE4openERKSsSt13_Ios_Openmode;
6739+
6740+} GLIBCXX_3.4.12;
6741+
6742 # Symbols in the support library (libsupc++) have their own tag.
6743 CXXABI_1.3 {
6744 
6745diff -Naur gcc-4.4.1.orig/libstdc++-v3/configure gcc-4.4.1/libstdc++-v3/configure
6746--- gcc-4.4.1.orig/libstdc++-v3/configure       2009-05-07 03:23:06.000000000 -0700
6747+++ gcc-4.4.1/libstdc++-v3/configure    2009-08-26 12:04:11.000000000 -0700
6748@@ -1567,7 +1567,7 @@
6749 ### am handles this now?  ORIGINAL_LD_FOR_MULTILIBS=$LD
6750 
6751 # For libtool versioning info, format is CURRENT:REVISION:AGE
6752-libtool_VERSION=6:12:0
6753+libtool_VERSION=6:13:0
6754 
6755 
6756 # Find the rest of the source tree framework.
6757diff -Naur gcc-4.4.1.orig/libstdc++-v3/configure.ac gcc-4.4.1/libstdc++-v3/configure.ac
6758--- gcc-4.4.1.orig/libstdc++-v3/configure.ac    2009-05-07 03:23:06.000000000 -0700
6759+++ gcc-4.4.1/libstdc++-v3/configure.ac 2009-08-26 12:04:11.000000000 -0700
6760@@ -12,7 +12,7 @@
6761 ### am handles this now?  ORIGINAL_LD_FOR_MULTILIBS=$LD
6762 
6763 # For libtool versioning info, format is CURRENT:REVISION:AGE
6764-libtool_VERSION=6:12:0
6765+libtool_VERSION=6:13:0
6766 AC_SUBST(libtool_VERSION)
6767 
6768 # Find the rest of the source tree framework.
6769diff -Naur gcc-4.4.1.orig/libstdc++-v3/include/parallel/multiway_merge.h gcc-4.4.1/libstdc++-v3/include/parallel/multiway_merge.h
6770--- gcc-4.4.1.orig/libstdc++-v3/include/parallel/multiway_merge.h       2009-04-09 16:23:07.000000000 -0700
6771+++ gcc-4.4.1/libstdc++-v3/include/parallel/multiway_merge.h    2009-09-11 09:36:00.000000000 -0700
6772@@ -1224,7 +1224,7 @@
6773                 offsets[num_threads - 1].begin(),  comp);
6774         }
6775     }
6776-
6777+  delete[] borders;
6778 
6779   for (int slab = 0; slab < num_threads; ++slab)
6780     {
6781@@ -1305,11 +1305,8 @@
6782         std::iterator_traits<RandomAccessIterator1>::value_type value_type;
6783 
6784       // Leave only non-empty sequences.
6785-      std::pair<RandomAccessIterator1, RandomAccessIterator1>* ne_seqs =
6786-        static_cast<std::pair<RandomAccessIterator1, RandomAccessIterator1>*>(
6787-        ::operator new(
6788-            sizeof(std::pair<RandomAccessIterator1, RandomAccessIterator1>)
6789-              * (seqs_end - seqs_begin)));
6790+      typedef std::pair<RandomAccessIterator1, RandomAccessIterator1> seq_type;
6791+      seq_type* ne_seqs = new seq_type[seqs_end - seqs_begin];
6792       int k = 0;
6793       difference_type total_length = 0;
6794       for (RandomAccessIteratorIterator raii = seqs_begin;
6795@@ -1319,9 +1316,7 @@
6796           if(seq_length > 0)
6797             {
6798               total_length += seq_length;
6799-              //ne_seqs[k] = *raii;
6800-              new(&(ne_seqs[k++]))
6801-                std::pair<RandomAccessIterator1, RandomAccessIterator1>(*raii);
6802+              ne_seqs[k++] = *raii;
6803             }
6804         }
6805 
6806@@ -1331,7 +1326,7 @@
6807 
6808       if (total_length == 0 || k == 0)
6809       {
6810-        ::operator delete(ne_seqs);
6811+        delete[] ne_seqs;
6812         return target;
6813       }
6814 
6815@@ -1366,8 +1361,7 @@
6816           for (int c = 0; c < k; ++c)
6817             target_position += pieces[iam][c].first;
6818 
6819-          std::pair<RandomAccessIterator1, RandomAccessIterator1>* chunks
6820-            = new std::pair<RandomAccessIterator1, RandomAccessIterator1>[k];
6821+          seq_type* chunks = new seq_type[k];
6822 
6823           for (int s = 0; s < k; ++s)
6824             {
6825@@ -1399,6 +1393,7 @@
6826         }
6827 
6828       delete[] pieces;
6829+      delete[] ne_seqs;
6830 
6831       return target + length;
6832     }
6833diff -Naur gcc-4.4.1.orig/libstdc++-v3/include/std/valarray gcc-4.4.1/libstdc++-v3/include/std/valarray
6834--- gcc-4.4.1.orig/libstdc++-v3/include/std/valarray    2009-04-09 16:23:07.000000000 -0700
6835+++ gcc-4.4.1/libstdc++-v3/include/std/valarray 2009-07-22 03:25:53.000000000 -0700
6836@@ -1,7 +1,7 @@
6837 // The template and inlines for the -*- C++ -*- valarray class.
6838 
6839 // Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
6840-// 2006, 2007, 2009
6841+// 2006, 2007, 2008, 2009
6842 // Free Software Foundation, Inc.
6843 //
6844 // This file is part of the GNU ISO C++ Library.  This library is free
6845@@ -647,7 +647,7 @@
6846   template<typename _Tp>
6847     inline
6848     valarray<_Tp>::valarray(initializer_list<_Tp> __l)
6849-      : _M_size(__l.size()), _M_data(__valarray_get_storage<_Tp>(__l.size()))
6850+    : _M_size(__l.size()), _M_data(__valarray_get_storage<_Tp>(__l.size()))
6851     { std::__valarray_copy_construct (__l.begin(), __l.end(), _M_data); }
6852 #endif
6853 
6854@@ -681,6 +681,7 @@
6855     {
6856       _GLIBCXX_DEBUG_ASSERT(_M_size == __l.size());
6857       std::__valarray_copy(__l.begin(), __l.size(), _M_data);
6858+      return *this;
6859     }
6860 #endif
6861 
6862diff -Naur gcc-4.4.1.orig/libstdc++-v3/src/Makefile.am gcc-4.4.1/libstdc++-v3/src/Makefile.am
6863--- gcc-4.4.1.orig/libstdc++-v3/src/Makefile.am 2009-04-09 16:23:07.000000000 -0700
6864+++ gcc-4.4.1/libstdc++-v3/src/Makefile.am      2009-08-26 12:04:11.000000000 -0700
6865@@ -277,6 +277,11 @@
6866 atomic.o: atomic.cc
6867        $(CXXCOMPILE) -std=gnu++0x -c $<
6868 
6869+fstream-inst.lo: fstream-inst.cc
6870+       $(LTCXXCOMPILE) -std=gnu++0x -c $<
6871+fstream-inst.o: fstream-inst.cc
6872+       $(CXXCOMPILE) -std=gnu++0x -c $<
6873+
6874 string-inst.lo: string-inst.cc
6875        $(LTCXXCOMPILE) -std=gnu++0x -c $<
6876 string-inst.o: string-inst.cc
6877diff -Naur gcc-4.4.1.orig/libstdc++-v3/src/Makefile.in gcc-4.4.1/libstdc++-v3/src/Makefile.in
6878--- gcc-4.4.1.orig/libstdc++-v3/src/Makefile.in 2009-01-16 18:03:25.000000000 -0800
6879+++ gcc-4.4.1/libstdc++-v3/src/Makefile.in      2009-08-26 12:04:11.000000000 -0700
6880@@ -888,6 +888,11 @@
6881 atomic.o: atomic.cc
6882        $(CXXCOMPILE) -std=gnu++0x -c $<
6883 
6884+fstream-inst.lo: fstream-inst.cc
6885+       $(LTCXXCOMPILE) -std=gnu++0x -c $<
6886+fstream-inst.o: fstream-inst.cc
6887+       $(CXXCOMPILE) -std=gnu++0x -c $<
6888+
6889 string-inst.lo: string-inst.cc
6890        $(LTCXXCOMPILE) -std=gnu++0x -c $<
6891 string-inst.o: string-inst.cc
6892diff -Naur gcc-4.4.1.orig/libstdc++-v3/testsuite/util/testsuite_abi.cc gcc-4.4.1/libstdc++-v3/testsuite/util/testsuite_abi.cc
6893--- gcc-4.4.1.orig/libstdc++-v3/testsuite/util/testsuite_abi.cc 2009-05-05 14:44:27.000000000 -0700
6894+++ gcc-4.4.1/libstdc++-v3/testsuite/util/testsuite_abi.cc      2009-08-26 12:04:11.000000000 -0700
6895@@ -184,6 +184,7 @@
6896       known_versions.push_back("GLIBCXX_3.4.10");
6897       known_versions.push_back("GLIBCXX_3.4.11");
6898       known_versions.push_back("GLIBCXX_3.4.12");
6899+      known_versions.push_back("GLIBCXX_3.4.13");
6900       known_versions.push_back("GLIBCXX_LDBL_3.4");
6901       known_versions.push_back("GLIBCXX_LDBL_3.4.7");
6902       known_versions.push_back("GLIBCXX_LDBL_3.4.10");
Note: See TracBrowser for help on using the repository browser.