]> git.pld-linux.org Git - packages/crossppc-gcc.git/blob - gcc-branch.diff
f2bee90732c275fc910a90e9f9a8913471a821b4
[packages/crossppc-gcc.git] / gcc-branch.diff
1 Index: gcc-4_2-branch/libgomp/configure
2 ===================================================================
3 --- gcc-4_2-branch/libgomp/configure    (revision 123014)
4 +++ gcc-4_2-branch/libgomp/configure    (revision 124164)
5 @@ -9315,7 +9315,7 @@
6    # does some of this, but throws away the result.
7  
8    ldver=`$LD --version 2>/dev/null | head -1 | \
9 -         sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
10 +         sed -e 's/GNU ld \(version \)\{0,1\}\(([^)]*) \)\{0,1\}\([0-9.][0-9.]*\).*/\3/'`
11  
12    libgomp_gnu_ld_version=`echo $ldver | \
13           $AWK -F. '{ if (NF<3) $3=0; print ($1*100+$2)*100+$3 }'`
14 Index: gcc-4_2-branch/libgomp/ChangeLog
15 ===================================================================
16 --- gcc-4_2-branch/libgomp/ChangeLog    (revision 123014)
17 +++ gcc-4_2-branch/libgomp/ChangeLog    (revision 124164)
18 @@ -1,3 +1,9 @@
19 +2007-03-18  Andreas Schwab  <schwab@suse.de>
20 +
21 +       * acinclude.m4: Adjust regular expression for ld version
22 +       extraction.
23 +       * configure: Regenerate.
24 +
25  2007-02-07  Jakub Jelinek  <jakub@redhat.com>
26  
27         PR c++/30703
28 Index: gcc-4_2-branch/libgomp/acinclude.m4
29 ===================================================================
30 --- gcc-4_2-branch/libgomp/acinclude.m4 (revision 123014)
31 +++ gcc-4_2-branch/libgomp/acinclude.m4 (revision 124164)
32 @@ -148,7 +148,7 @@
33    # does some of this, but throws away the result.
34    changequote(,)
35    ldver=`$LD --version 2>/dev/null | head -1 | \
36 -         sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
37 +         sed -e 's/GNU ld \(version \)\{0,1\}\(([^)]*) \)\{0,1\}\([0-9.][0-9.]*\).*/\3/'`
38    changequote([,])
39    libgomp_gnu_ld_version=`echo $ldver | \
40           $AWK -F. '{ if (NF<3) [$]3=0; print ([$]1*100+[$]2)*100+[$]3 }'`
41 Index: gcc-4_2-branch/gcc/tree-vrp.c
42 ===================================================================
43 --- gcc-4_2-branch/gcc/tree-vrp.c       (revision 123014)
44 +++ gcc-4_2-branch/gcc/tree-vrp.c       (revision 124164)
45 @@ -266,6 +266,10 @@
46  
47        cmp = compare_values (min, max);
48        gcc_assert (cmp == 0 || cmp == -1 || cmp == -2);
49 +
50 +      if (needs_overflow_infinity (TREE_TYPE (min)))
51 +       gcc_assert (!is_overflow_infinity (min)
52 +                   || !is_overflow_infinity (max));
53      }
54  
55    if (t == VR_UNDEFINED || t == VR_VARYING)
56 @@ -314,6 +318,23 @@
57      bitmap_clear (vr->equiv);
58  }
59  
60 +/* Set value range VR to a single value.  This function is only called
61 +   with values we get from statements, and exists to clear the
62 +   TREE_OVERFLOW flag so that we don't think we have an overflow
63 +   infinity when we shouldn't.  */
64 +
65 +static inline void
66 +set_value_range_to_value (value_range_t *vr, tree val)
67 +{
68 +  gcc_assert (is_gimple_min_invariant (val));
69 +  if (is_overflow_infinity (val))
70 +    {
71 +      val = copy_node (val);
72 +      TREE_OVERFLOW (val) = 0;
73 +    }
74 +  set_value_range (vr, VR_RANGE, val, val, NULL);
75 +}
76 +
77  /* Set value range VR to a non-negative range of type TYPE.
78     OVERFLOW_INFINITY indicates whether to use a overflow infinity
79     rather than TYPE_MAX_VALUE; this should be true if we determine
80 @@ -1565,7 +1586,7 @@
81    if (TREE_CODE (op0) == SSA_NAME)
82      vr0 = *(get_value_range (op0));
83    else if (is_gimple_min_invariant (op0))
84 -    set_value_range (&vr0, VR_RANGE, op0, op0, NULL);
85 +    set_value_range_to_value (&vr0, op0);
86    else
87      set_value_range_to_varying (&vr0);
88  
89 @@ -1573,7 +1594,7 @@
90    if (TREE_CODE (op1) == SSA_NAME)
91      vr1 = *(get_value_range (op1));
92    else if (is_gimple_min_invariant (op1))
93 -    set_value_range (&vr1, VR_RANGE, op1, op1, NULL);
94 +    set_value_range_to_value (&vr1, op1);
95    else
96      set_value_range_to_varying (&vr1);
97  
98 @@ -1892,10 +1913,18 @@
99        return;
100      }
101  
102 +  /* We punt if:
103 +     1) [-INF, +INF]
104 +     2) [-INF, +-INF(OVF)]
105 +     3) [+-INF(OVF), +INF]
106 +     4) [+-INF(OVF), +-INF(OVF)]
107 +     We learn nothing when we have INF and INF(OVF) on both sides.
108 +     Note that we do accept [-INF, -INF] and [+INF, +INF] without
109 +     overflow.  */
110    if ((min == TYPE_MIN_VALUE (TREE_TYPE (min))
111 -       || is_negative_overflow_infinity (min))
112 +       || is_overflow_infinity (min))
113        && (max == TYPE_MAX_VALUE (TREE_TYPE (max))
114 -         || is_positive_overflow_infinity (max)))
115 +         || is_overflow_infinity (max)))
116      {
117        set_value_range_to_varying (vr);
118        return;
119 @@ -1946,7 +1975,7 @@
120    if (TREE_CODE (op0) == SSA_NAME)
121      vr0 = *(get_value_range (op0));
122    else if (is_gimple_min_invariant (op0))
123 -    set_value_range (&vr0, VR_RANGE, op0, op0, NULL);
124 +    set_value_range_to_value (&vr0, op0);
125    else
126      set_value_range_to_varying (&vr0);
127  
128 @@ -2078,7 +2107,9 @@
129         min = fold_unary_to_constant (code, TREE_TYPE (expr), vr0.max);
130        else if (needs_overflow_infinity (TREE_TYPE (expr)))
131         {
132 -         if (supports_overflow_infinity (TREE_TYPE (expr)))
133 +         if (supports_overflow_infinity (TREE_TYPE (expr))
134 +             && !is_overflow_infinity (vr0.min)
135 +             && vr0.min != TYPE_MIN_VALUE (TREE_TYPE (expr)))
136             min = positive_overflow_infinity (TREE_TYPE (expr));
137           else
138             {
139 @@ -2254,6 +2285,18 @@
140        if (needs_overflow_infinity (TREE_TYPE (expr)))
141         {
142           gcc_assert (code != NEGATE_EXPR && code != ABS_EXPR);
143 +
144 +         /* If both sides have overflowed, we don't know
145 +            anything.  */
146 +         if ((is_overflow_infinity (vr0.min)
147 +              || TREE_OVERFLOW (min))
148 +             && (is_overflow_infinity (vr0.max)
149 +                 || TREE_OVERFLOW (max)))
150 +           {
151 +             set_value_range_to_varying (vr);
152 +             return;
153 +           }
154 +
155           if (is_overflow_infinity (vr0.min))
156             min = vr0.min;
157           else if (TREE_OVERFLOW (min))
158 @@ -2350,7 +2393,7 @@
159    else if (TREE_CODE_CLASS (code) == tcc_comparison)
160      extract_range_from_comparison (vr, expr);
161    else if (is_gimple_min_invariant (expr))
162 -    set_value_range (vr, VR_RANGE, expr, expr, NULL);
163 +    set_value_range_to_value (vr, expr);
164    else
165      set_value_range_to_varying (vr);
166  
167 @@ -4514,6 +4557,17 @@
168               return;
169             }
170  
171 +         /* Check for useless ranges.  */
172 +         if (INTEGRAL_TYPE_P (TREE_TYPE (min))
173 +             && ((min == TYPE_MIN_VALUE (TREE_TYPE (min))
174 +                  || is_overflow_infinity (min))
175 +                 && (max == TYPE_MAX_VALUE (TREE_TYPE (max))
176 +                     || is_overflow_infinity (max))))
177 +           {
178 +             set_value_range_to_varying (vr0);
179 +             return;
180 +           }
181 +
182           /* The resulting set of equivalences is the intersection of
183              the two sets.  */
184           if (vr0->equiv && vr1->equiv && vr0->equiv != vr1->equiv)
185 @@ -4639,6 +4693,12 @@
186             vr_arg = *(get_value_range (arg));
187           else
188             {
189 +             if (is_overflow_infinity (arg))
190 +               {
191 +                 arg = copy_node (arg);
192 +                 TREE_OVERFLOW (arg) = 0;
193 +               }
194 +
195               vr_arg.type = VR_RANGE;
196               vr_arg.min = arg;
197               vr_arg.max = arg;
198 Index: gcc-4_2-branch/gcc/doc/invoke.texi
199 ===================================================================
200 --- gcc-4_2-branch/gcc/doc/invoke.texi  (revision 123014)
201 +++ gcc-4_2-branch/gcc/doc/invoke.texi  (revision 124164)
202 @@ -695,9 +695,11 @@
203  -mwarn-framesize  -mwarn-dynamicstack  -mstack-size -mstack-guard}
204  
205  @emph{Score Options}
206 -@gccoptlist{-mel -mel @gol
207 +@gccoptlist{-meb -mel @gol
208 +-mnhwloop @gol
209 +-muls @gol
210  -mmac @gol
211 --mscore5u -mscore7}
212 +-mscore5 -mscore5u -mscore7 -mscore7d}
213   
214  @emph{SH Options}
215  @gccoptlist{-m1  -m2  -m2e  -m3  -m3e @gol
216 @@ -2834,7 +2836,7 @@
217  
218  @item -Wstrict-overflow
219  @item -Wstrict-overflow=@var{n}
220 -@opindex -Wstrict-overflow
221 +@opindex Wstrict-overflow
222  This option is only active when @option{-fstrict-overflow} is active.
223  It warns about cases where the compiler optimizes based on the
224  assumption that signed overflow does not occur.  Note that it does not
225 @@ -2847,7 +2849,10 @@
226  overflow never does, in fact, occur.  Therefore this warning can
227  easily give a false positive: a warning about code which is not
228  actually a problem.  To help focus on important issues, several
229 -warning levels are defined.
230 +warning levels are defined.  No warnings are issued for the use of
231 +undefined signed overflow when estimating how many iterations a loop
232 +will require, in particular when determining whether a loop will be
233 +executed at all.
234  
235  @table @option
236  @item -Wstrict-overflow=1
237 @@ -4673,7 +4678,7 @@
238  arithmetic on them.  This produces better code by making all memory
239  references potential common subexpressions.  When they are not common
240  subexpressions, instruction combination should eliminate the separate
241 -register-load. This option is now a nop and will be removed in 4.2.
242 +register-load. This option is now a nop and will be removed in 4.3.
243  
244  @item -fforce-addr
245  @opindex fforce-addr
246 @@ -5298,7 +5303,7 @@
247  @option{-funroll-loops},
248  
249  @item -fsplit-ivs-in-unroller
250 -@opindex -fsplit-ivs-in-unroller
251 +@opindex fsplit-ivs-in-unroller
252  Enables expressing of values of induction variables in later iterations
253  of the unrolled loop using the value in the first iteration.  This breaks
254  long dependency chains, thus improving efficiency of the scheduling passes.
255 @@ -5311,7 +5316,7 @@
256  This optimization is enabled by default.
257  
258  @item -fvariable-expansion-in-unroller
259 -@opindex -fvariable-expansion-in-unroller
260 +@opindex fvariable-expansion-in-unroller
261  With this option, the compiler will create multiple copies of some
262  local variables when unrolling a loop which can result in superior code.
263  
264 @@ -8161,13 +8166,13 @@
265  @samp{"PrivateHeaders"} or @samp{"Headers"} directory.
266  
267  @item -gused
268 -@opindex -gused
269 +@opindex gused
270  Emit debugging information for symbols that are used.  For STABS
271  debugging format, this enables @option{-feliminate-unused-debug-symbols}.
272  This is by default ON@.
273  
274  @item -gfull
275 -@opindex -gfull
276 +@opindex gfull
277  Emit debugging information for all symbols and types.
278  
279  @item -mmacosx-version-min=@var{version}
280 @@ -8189,7 +8194,7 @@
281  @option{-mlong-branch} for PowerPC targets.
282  
283  @item -mone-byte-bool
284 -@opindex -mone-byte-bool
285 +@opindex mone-byte-bool
286  Override the defaults for @samp{bool} so that @samp{sizeof(bool)==1}.
287  By default @samp{sizeof(bool)} is @samp{4} when compiling for
288  Darwin/PowerPC and @samp{1} when compiling for Darwin/x86, so this
289 @@ -8238,12 +8243,12 @@
290  output file being linked.  See man ld(1) for more information.
291  
292  @item -dynamiclib
293 -@opindex -dynamiclib
294 +@opindex dynamiclib
295  When passed this option, GCC will produce a dynamic library instead of
296  an executable when linking, using the Darwin @file{libtool} command.
297  
298  @item -force_cpusubtype_ALL
299 -@opindex -force_cpusubtype_ALL
300 +@opindex force_cpusubtype_ALL
301  This causes GCC's output file to have the @var{ALL} subtype, instead of
302  one controlled by the @option{-mcpu} or @option{-march} option.
303  
304 @@ -9759,7 +9764,9 @@
305  The 32-bit environment sets int, long and pointer to 32 bits and
306  generates code that runs on any i386 system.
307  The 64-bit environment sets int to 32 bits and long and pointer
308 -to 64 bits and generates code for AMD's x86-64 architecture.
309 +to 64 bits and generates code for AMD's x86-64 architecture. For
310 +darwin only the -m64 option turns off the @option{-fno-pic} and
311 +@option{-mdynamic-no-pic} options.
312  
313  @item -mno-red-zone
314  @opindex no-red-zone
315 @@ -9947,8 +9954,8 @@
316  
317  @item -mno-sched-br-data-spec
318  @itemx -msched-br-data-spec
319 -@opindex -mno-sched-br-data-spec
320 -@opindex -msched-br-data-spec
321 +@opindex mno-sched-br-data-spec
322 +@opindex msched-br-data-spec
323  (Dis/En)able data speculative scheduling before reload.
324  This will result in generation of the ld.a instructions and
325  the corresponding check instructions (ld.c / chk.a).
326 @@ -9956,8 +9963,8 @@
327  
328  @item -msched-ar-data-spec
329  @itemx -mno-sched-ar-data-spec
330 -@opindex -msched-ar-data-spec
331 -@opindex -mno-sched-ar-data-spec
332 +@opindex msched-ar-data-spec
333 +@opindex mno-sched-ar-data-spec
334  (En/Dis)able data speculative scheduling after reload.
335  This will result in generation of the ld.a instructions and
336  the corresponding check instructions (ld.c / chk.a).
337 @@ -9965,8 +9972,8 @@
338  
339  @item -mno-sched-control-spec
340  @itemx -msched-control-spec
341 -@opindex -mno-sched-control-spec
342 -@opindex -msched-control-spec
343 +@opindex mno-sched-control-spec
344 +@opindex msched-control-spec
345  (Dis/En)able control speculative scheduling.  This feature is
346  available only during region scheduling (i.e. before reload).
347  This will result in generation of the ld.s instructions and
348 @@ -9975,8 +9982,8 @@
349  
350  @item -msched-br-in-data-spec
351  @itemx -mno-sched-br-in-data-spec
352 -@opindex -msched-br-in-data-spec
353 -@opindex -mno-sched-br-in-data-spec
354 +@opindex msched-br-in-data-spec
355 +@opindex mno-sched-br-in-data-spec
356  (En/Dis)able speculative scheduling of the instructions that
357  are dependent on the data speculative loads before reload.
358  This is effective only with @option{-msched-br-data-spec} enabled.
359 @@ -9984,8 +9991,8 @@
360  
361  @item -msched-ar-in-data-spec
362  @itemx -mno-sched-ar-in-data-spec
363 -@opindex -msched-ar-in-data-spec
364 -@opindex -mno-sched-ar-in-data-spec
365 +@opindex msched-ar-in-data-spec
366 +@opindex mno-sched-ar-in-data-spec
367  (En/Dis)able speculative scheduling of the instructions that
368  are dependent on the data speculative loads after reload.
369  This is effective only with @option{-msched-ar-data-spec} enabled.
370 @@ -9993,8 +10000,8 @@
371  
372  @item -msched-in-control-spec
373  @itemx -mno-sched-in-control-spec
374 -@opindex -msched-in-control-spec
375 -@opindex -mno-sched-in-control-spec
376 +@opindex msched-in-control-spec
377 +@opindex mno-sched-in-control-spec
378  (En/Dis)able speculative scheduling of the instructions that
379  are dependent on the control speculative loads.
380  This is effective only with @option{-msched-control-spec} enabled.
381 @@ -10002,8 +10009,8 @@
382  
383  @item -msched-ldc
384  @itemx -mno-sched-ldc
385 -@opindex -msched-ldc
386 -@opindex -mno-sched-ldc
387 +@opindex msched-ldc
388 +@opindex mno-sched-ldc
389  (En/Dis)able use of simple data speculation checks ld.c .
390  If disabled, only chk.a instructions will be emitted to check
391  data speculative loads.
392 @@ -10011,8 +10018,8 @@
393  
394  @item -mno-sched-control-ldc
395  @itemx -msched-control-ldc
396 -@opindex -mno-sched-control-ldc
397 -@opindex -msched-control-ldc 
398 +@opindex mno-sched-control-ldc
399 +@opindex msched-control-ldc 
400  (Dis/En)able use of ld.c instructions to check control speculative loads.
401  If enabled, in case of control speculative load with no speculatively
402  scheduled dependent instructions this load will be emitted as ld.sa and
403 @@ -10021,14 +10028,14 @@
404  
405  @item -mno-sched-spec-verbose
406  @itemx -msched-spec-verbose
407 -@opindex -mno-sched-spec-verbose
408 -@opindex -msched-spec-verbose
409 +@opindex mno-sched-spec-verbose
410 +@opindex msched-spec-verbose
411  (Dis/En)able printing of the information about speculative motions.
412  
413  @item -mno-sched-prefer-non-data-spec-insns
414  @itemx -msched-prefer-non-data-spec-insns
415 -@opindex -mno-sched-prefer-non-data-spec-insns
416 -@opindex -msched-prefer-non-data-spec-insns
417 +@opindex mno-sched-prefer-non-data-spec-insns
418 +@opindex msched-prefer-non-data-spec-insns
419  If enabled, data speculative instructions will be chosen for schedule
420  only if there are no other choices at the moment.  This will make
421  the use of the data speculation much more conservative.
422 @@ -10036,8 +10043,8 @@
423  
424  @item -mno-sched-prefer-non-control-spec-insns
425  @itemx -msched-prefer-non-control-spec-insns
426 -@opindex -mno-sched-prefer-non-control-spec-insns
427 -@opindex -msched-prefer-non-control-spec-insns
428 +@opindex mno-sched-prefer-non-control-spec-insns
429 +@opindex msched-prefer-non-control-spec-insns
430  If enabled, control speculative instructions will be chosen for schedule
431  only if there are no other choices at the moment.  This will make
432  the use of the control speculation much more conservative.
433 @@ -10045,8 +10052,8 @@
434  
435  @item -mno-sched-count-spec-in-critical-path
436  @itemx -msched-count-spec-in-critical-path
437 -@opindex -mno-sched-count-spec-in-critical-path
438 -@opindex -msched-count-spec-in-critical-path
439 +@opindex mno-sched-count-spec-in-critical-path
440 +@opindex msched-count-spec-in-critical-path
441  If enabled, speculative dependencies will be considered during
442  computation of the instructions priorities.  This will make the use of the
443  speculation a bit more conservative.
444 @@ -12273,25 +12280,41 @@
445  These options are defined for Score implementations:
446  
447  @table @gcctabopt
448 -@item -mel
449 -@opindex -mel
450 -Compile code for little endian mode. 
451 -
452  @item -meb
453  @opindex meb
454  Compile code for big endian mode.  This is the default.
455  
456 +@item -mel
457 +@opindex mel
458 +Compile code for little endian mode. 
459 +
460 +@item -mnhwloop
461 +@opindex mnhwloop
462 +Disable generate bcnz instruction.
463 +
464 +@item -muls
465 +@opindex muls
466 +Enable generate unaligned load and store instruction.
467 +
468  @item -mmac
469  @opindex mmac
470  Enable the use of multiply-accumulate instructions. Disabled by default. 
471  
472 +@item -mscore5
473 +@opindex mscore5
474 +Specify the SCORE5 as the target architecture.
475 +
476  @item -mscore5u
477  @opindex mscore5u
478  Specify the SCORE5U of the target architecture.
479  
480  @item -mscore7
481  @opindex mscore7
482 -Specify the SCORE7 of the target architecture. This is the default.
483 +Specify the SCORE7 as the target architecture. This is the default.
484 +
485 +@item -mscore7d
486 +@opindex mscore7d
487 +Specify the SCORE7D as the target architecture.
488  @end table
489  
490  @node SH Options
491 Index: gcc-4_2-branch/gcc/doc/md.texi
492 ===================================================================
493 --- gcc-4_2-branch/gcc/doc/md.texi      (revision 123014)
494 +++ gcc-4_2-branch/gcc/doc/md.texi      (revision 124164)
495 @@ -2814,7 +2814,7 @@
496  cp1 + cp2 + cp3 registers.
497  
498  @item I
499 -Unsigned 15 bit integer (in the range 0 to 32767).
500 +High 16-bit constant (32-bit constant with 16 LSBs zero).
501  
502  @item J
503  Unsigned 5 bit integer (in the range 0 to 31).
504 @@ -2831,18 +2831,6 @@
505  @item N
506  Signed 14 bit integer (in the range @minus{}8192 to 8191).
507  
508 -@item O
509 -Signed 15 bit integer (in the range @minus{}16384 to 16383).
510 -
511 -@item P
512 -Signed 12 bit integer (in the range @minus{}2048 to 2047).
513 -
514 -@item J
515 -An integer constant with exactly a single bit set.
516 -
517 -@item Q
518 -An integer constant.
519 -
520  @item Z
521  Any SYMBOL_REF.
522  @end table
523 Index: gcc-4_2-branch/gcc/DATESTAMP
524 ===================================================================
525 --- gcc-4_2-branch/gcc/DATESTAMP        (revision 123014)
526 +++ gcc-4_2-branch/gcc/DATESTAMP        (revision 124164)
527 @@ -1 +1 @@
528 -20070317
529 +20070425
530 Index: gcc-4_2-branch/gcc/tree-ssa-loop-ch.c
531 ===================================================================
532 --- gcc-4_2-branch/gcc/tree-ssa-loop-ch.c       (revision 123014)
533 +++ gcc-4_2-branch/gcc/tree-ssa-loop-ch.c       (revision 124164)
534 @@ -1,5 +1,5 @@
535  /* Loop header copying on trees.
536 -   Copyright (C) 2004, 2005 Free Software Foundation, Inc.
537 +   Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
538     
539  This file is part of GCC.
540     
541 @@ -204,6 +204,27 @@
542           continue;
543         }
544  
545 +      /* If the loop has the form "for (i = j; i < j + 10; i++)" then
546 +        this copying can introduce a case where we rely on undefined
547 +        signed overflow to eliminate the preheader condition, because
548 +        we assume that "j < j + 10" is true.  We don't want to warn
549 +        about that case for -Wstrict-overflow, because in general we
550 +        don't warn about overflow involving loops.  Prevent the
551 +        warning by setting TREE_NO_WARNING.  */
552 +      if (warn_strict_overflow > 0)
553 +       {
554 +         unsigned int i;
555 +
556 +         for (i = 0; i < n_bbs; ++i)
557 +           {
558 +             tree last;
559 +
560 +             last = last_stmt (copied_bbs[i]);
561 +             if (TREE_CODE (last) == COND_EXPR)
562 +               TREE_NO_WARNING (last) = 1;
563 +           }
564 +       }
565 +
566        /* Ensure that the latch and the preheader is simple (we know that they
567          are not now, since there was the loop exit condition.  */
568        loop_split_edge_with (loop_preheader_edge (loop), NULL);
569 Index: gcc-4_2-branch/gcc/reload.c
570 ===================================================================
571 --- gcc-4_2-branch/gcc/reload.c (revision 123014)
572 +++ gcc-4_2-branch/gcc/reload.c (revision 124164)
573 @@ -1853,7 +1853,12 @@
574                     ||  ! (TEST_HARD_REG_BIT
575                            (reg_class_contents[(int) rld[secondary_out].class],
576                             REGNO (XEXP (note, 0)))))))
577 -       && ! fixed_regs[REGNO (XEXP (note, 0))])
578 +       && ! fixed_regs[REGNO (XEXP (note, 0))]
579 +       /* Check that we don't use a hardreg for an uninitialized
580 +          pseudo.  See also find_dummy_reload().  */
581 +       && (ORIGINAL_REGNO (XEXP (note, 0)) < FIRST_PSEUDO_REGISTER
582 +           || ! bitmap_bit_p (ENTRY_BLOCK_PTR->il.rtl->global_live_at_end,
583 +                              ORIGINAL_REGNO (XEXP (note, 0)))))
584        {
585         rld[output_reload].reg_rtx
586           = gen_rtx_REG (rld[output_reload].outmode,
587 Index: gcc-4_2-branch/gcc/builtins.c
588 ===================================================================
589 --- gcc-4_2-branch/gcc/builtins.c       (revision 123014)
590 +++ gcc-4_2-branch/gcc/builtins.c       (revision 124164)
591 @@ -5492,14 +5492,19 @@
592                                rtx target, bool ignore)
593  {
594    rtx val, mem;
595 +  enum machine_mode old_mode;
596  
597    /* Expand the operands.  */
598    mem = get_builtin_sync_mem (TREE_VALUE (arglist), mode);
599  
600    arglist = TREE_CHAIN (arglist);
601    val = expand_expr (TREE_VALUE (arglist), NULL, mode, EXPAND_NORMAL);
602 -  /* If VAL is promoted to a wider mode, convert it back to MODE.  */
603 -  val = convert_to_mode (mode, val, 1);
604 +  /* If VAL is promoted to a wider mode, convert it back to MODE.  Take care
605 +     of CONST_INTs, where we know the old_mode only from the call argument.  */
606 +  old_mode = GET_MODE (val);
607 +  if (old_mode == VOIDmode)
608 +    old_mode = TYPE_MODE (TREE_TYPE (TREE_VALUE (arglist)));
609 +  val = convert_modes (mode, old_mode, val, 1);
610  
611    if (ignore)
612      return expand_sync_operation (mem, val, code);
613 @@ -5517,19 +5522,28 @@
614                                  bool is_bool, rtx target)
615  {
616    rtx old_val, new_val, mem;
617 +  enum machine_mode old_mode;
618  
619    /* Expand the operands.  */
620    mem = get_builtin_sync_mem (TREE_VALUE (arglist), mode);
621  
622    arglist = TREE_CHAIN (arglist);
623    old_val = expand_expr (TREE_VALUE (arglist), NULL, mode, EXPAND_NORMAL);
624 -  /* If OLD_VAL is promoted to a wider mode, convert it back to MODE.  */
625 -  old_val = convert_to_mode (mode, old_val, 1);
626 +  /* If VAL is promoted to a wider mode, convert it back to MODE.  Take care
627 +     of CONST_INTs, where we know the old_mode only from the call argument.  */
628 +  old_mode = GET_MODE (old_val);
629 +  if (old_mode == VOIDmode)
630 +    old_mode = TYPE_MODE (TREE_TYPE (TREE_VALUE (arglist)));
631 +  old_val = convert_modes (mode, old_mode, old_val, 1);
632  
633    arglist = TREE_CHAIN (arglist);
634    new_val = expand_expr (TREE_VALUE (arglist), NULL, mode, EXPAND_NORMAL);
635 -  /* If NEW_VAL is promoted to a wider mode, convert it back to MODE.  */
636 -  new_val = convert_to_mode (mode, new_val, 1);
637 +  /* If VAL is promoted to a wider mode, convert it back to MODE.  Take care
638 +     of CONST_INTs, where we know the old_mode only from the call argument.  */
639 +  old_mode = GET_MODE (new_val);
640 +  if (old_mode == VOIDmode)
641 +    old_mode = TYPE_MODE (TREE_TYPE (TREE_VALUE (arglist)));
642 +  new_val = convert_modes (mode, old_mode, new_val, 1);
643  
644    if (is_bool)
645      return expand_bool_compare_and_swap (mem, old_val, new_val, target);
646 @@ -5548,14 +5562,19 @@
647                                   rtx target)
648  {
649    rtx val, mem;
650 +  enum machine_mode old_mode;
651  
652    /* Expand the operands.  */
653    mem = get_builtin_sync_mem (TREE_VALUE (arglist), mode);
654  
655    arglist = TREE_CHAIN (arglist);
656    val = expand_expr (TREE_VALUE (arglist), NULL, mode, EXPAND_NORMAL);
657 -  /* If VAL is promoted to a wider mode, convert it back to MODE.  */
658 -  val = convert_to_mode (mode, val, 1);
659 +  /* If VAL is promoted to a wider mode, convert it back to MODE.  Take care
660 +     of CONST_INTs, where we know the old_mode only from the call argument.  */
661 +  old_mode = GET_MODE (val);
662 +  if (old_mode == VOIDmode)
663 +    old_mode = TYPE_MODE (TREE_TYPE (TREE_VALUE (arglist)));
664 +  val = convert_modes (mode, old_mode, val, 1);
665  
666    return expand_sync_lock_test_and_set (mem, val, target);
667  }
668 Index: gcc-4_2-branch/gcc/fold-const.c
669 ===================================================================
670 --- gcc-4_2-branch/gcc/fold-const.c     (revision 123014)
671 +++ gcc-4_2-branch/gcc/fold-const.c     (revision 124164)
672 @@ -7052,7 +7052,7 @@
673  {
674    tree type = TREE_TYPE (expr);
675    int total_bytes = GET_MODE_SIZE (TYPE_MODE (type));
676 -  int byte, offset, word, words;
677 +  int byte, offset, word, words, bitpos;
678    unsigned char value;
679  
680    /* There are always 32 bits in each long, no matter the size of
681 @@ -7062,19 +7062,20 @@
682  
683    if (total_bytes > len)
684      return 0;
685 -  words = total_bytes / UNITS_PER_WORD;
686 +  words = 32 / UNITS_PER_WORD;
687  
688    real_to_target (tmp, TREE_REAL_CST_PTR (expr), TYPE_MODE (type));
689  
690 -  for (byte = 0; byte < total_bytes; byte++)
691 +  for (bitpos = 0; bitpos < total_bytes * BITS_PER_UNIT;
692 +       bitpos += BITS_PER_UNIT)
693      {
694 -      int bitpos = byte * BITS_PER_UNIT;
695 +      byte = (bitpos / BITS_PER_UNIT) & 3;
696        value = (unsigned char) (tmp[bitpos / 32] >> (bitpos & 31));
697  
698 -      if (total_bytes > UNITS_PER_WORD)
699 +      if (UNITS_PER_WORD < 4)
700         {
701           word = byte / UNITS_PER_WORD;
702 -         if (FLOAT_WORDS_BIG_ENDIAN)
703 +         if (WORDS_BIG_ENDIAN)
704             word = (words - 1) - word;
705           offset = word * UNITS_PER_WORD;
706           if (BYTES_BIG_ENDIAN)
707 @@ -7083,8 +7084,8 @@
708             offset += byte % UNITS_PER_WORD;
709         }
710        else
711 -       offset = BYTES_BIG_ENDIAN ? (total_bytes - 1) - byte : byte;
712 -      ptr[offset] = value;
713 +       offset = BYTES_BIG_ENDIAN ? 3 - byte : byte;
714 +      ptr[offset + ((bitpos / BITS_PER_UNIT) & ~3)] = value;
715      }
716    return total_bytes;
717  }
718 @@ -7241,7 +7242,7 @@
719  {
720    enum machine_mode mode = TYPE_MODE (type);
721    int total_bytes = GET_MODE_SIZE (mode);
722 -  int byte, offset, word, words;
723 +  int byte, offset, word, words, bitpos;
724    unsigned char value;
725    /* There are always 32 bits in each long, no matter the size of
726       the hosts long.  We handle floating point representations with
727 @@ -7252,16 +7253,17 @@
728    total_bytes = GET_MODE_SIZE (TYPE_MODE (type));
729    if (total_bytes > len || total_bytes > 24)
730      return NULL_TREE;
731 -  words = total_bytes / UNITS_PER_WORD;
732 +  words = 32 / UNITS_PER_WORD;
733  
734    memset (tmp, 0, sizeof (tmp));
735 -  for (byte = 0; byte < total_bytes; byte++)
736 +  for (bitpos = 0; bitpos < total_bytes * BITS_PER_UNIT;
737 +       bitpos += BITS_PER_UNIT)
738      {
739 -      int bitpos = byte * BITS_PER_UNIT;
740 -      if (total_bytes > UNITS_PER_WORD)
741 +      byte = (bitpos / BITS_PER_UNIT) & 3;
742 +      if (UNITS_PER_WORD < 4)
743         {
744           word = byte / UNITS_PER_WORD;
745 -         if (FLOAT_WORDS_BIG_ENDIAN)
746 +         if (WORDS_BIG_ENDIAN)
747             word = (words - 1) - word;
748           offset = word * UNITS_PER_WORD;
749           if (BYTES_BIG_ENDIAN)
750 @@ -7270,8 +7272,8 @@
751             offset += byte % UNITS_PER_WORD;
752         }
753        else
754 -       offset = BYTES_BIG_ENDIAN ? (total_bytes - 1) - byte : byte;
755 -      value = ptr[offset];
756 +       offset = BYTES_BIG_ENDIAN ? 3 - byte : byte;
757 +      value = ptr[offset + ((bitpos / BITS_PER_UNIT) & ~3)];
758  
759        tmp[bitpos / 32] |= (unsigned long)value << (bitpos & 31);
760      }
761 @@ -7732,7 +7734,7 @@
762             return fold_build1 (BIT_NOT_EXPR, type, fold_convert (type, tem));
763         }
764  
765 -      tem = fold_convert_const (code, type, arg0);
766 +      tem = fold_convert_const (code, type, op0);
767        return tem ? tem : NULL_TREE;
768  
769      case VIEW_CONVERT_EXPR:
770 @@ -11126,13 +11128,13 @@
771                   return omit_one_operand (type, integer_zero_node, arg0);
772  
773                 case GE_EXPR:
774 -                 return fold_build2 (EQ_EXPR, type, arg0, arg1);
775 +                 return fold_build2 (EQ_EXPR, type, op0, op1);
776  
777                 case LE_EXPR:
778                   return omit_one_operand (type, integer_one_node, arg0);
779  
780                 case LT_EXPR:
781 -                 return fold_build2 (NE_EXPR, type, arg0, arg1);
782 +                 return fold_build2 (NE_EXPR, type, op0, op1);
783  
784                 /* The GE_EXPR and LT_EXPR cases above are not normally
785                    reached because of previous transformations.  */
786 @@ -11147,10 +11149,14 @@
787                 {
788                 case GT_EXPR:
789                   arg1 = const_binop (PLUS_EXPR, arg1, integer_one_node, 0);
790 -                 return fold_build2 (EQ_EXPR, type, arg0, arg1);
791 +                 return fold_build2 (EQ_EXPR, type,
792 +                                     fold_convert (TREE_TYPE (arg1), arg0),
793 +                                     arg1);
794                 case LE_EXPR:
795                   arg1 = const_binop (PLUS_EXPR, arg1, integer_one_node, 0);
796 -                 return fold_build2 (NE_EXPR, type, arg0, arg1);
797 +                 return fold_build2 (NE_EXPR, type,
798 +                                     fold_convert (TREE_TYPE (arg1), arg0),
799 +                                     arg1);
800                 default:
801                   break;
802                 }
803 @@ -11163,7 +11169,7 @@
804                   return omit_one_operand (type, integer_zero_node, arg0);
805  
806                 case LE_EXPR:
807 -                 return fold_build2 (EQ_EXPR, type, arg0, arg1);
808 +                 return fold_build2 (EQ_EXPR, type, op0, op1);
809  
810                 case GE_EXPR:
811                   return omit_one_operand (type, integer_one_node, arg0);
812 @@ -11181,10 +11187,14 @@
813                 {
814                 case GE_EXPR:
815                   arg1 = const_binop (MINUS_EXPR, arg1, integer_one_node, 0);
816 -                 return fold_build2 (NE_EXPR, type, arg0, arg1);
817 +                 return fold_build2 (NE_EXPR, type,
818 +                                     fold_convert (TREE_TYPE (arg1), arg0),
819 +                                     arg1);
820                 case LT_EXPR:
821                   arg1 = const_binop (MINUS_EXPR, arg1, integer_one_node, 0);
822 -                 return fold_build2 (EQ_EXPR, type, arg0, arg1);
823 +                 return fold_build2 (EQ_EXPR, type,
824 +                                     fold_convert (TREE_TYPE (arg1), arg0),
825 +                                     arg1);
826                 default:
827                   break;
828                 }
829 @@ -11200,12 +11210,11 @@
830                    and X >= signed_max+1 because previous transformations.  */
831                 if (code == LE_EXPR || code == GT_EXPR)
832                   {
833 -                   tree st0, st1;
834 -                   st0 = lang_hooks.types.signed_type (TREE_TYPE (arg0));
835 -                   st1 = lang_hooks.types.signed_type (TREE_TYPE (arg1));
836 -                   return fold_build2 (code == LE_EXPR ? GE_EXPR: LT_EXPR,
837 -                                       type, fold_convert (st0, arg0),
838 -                                       build_int_cst (st1, 0));
839 +                   tree st;
840 +                   st = lang_hooks.types.signed_type (TREE_TYPE (arg1));
841 +                   return fold_build2 (code == LE_EXPR ? GE_EXPR : LT_EXPR,
842 +                                       type, fold_convert (st, arg0),
843 +                                       build_int_cst (st, 0));
844                   }
845               }
846           }
847 Index: gcc-4_2-branch/gcc/omp-low.c
848 ===================================================================
849 --- gcc-4_2-branch/gcc/omp-low.c        (revision 123014)
850 +++ gcc-4_2-branch/gcc/omp-low.c        (revision 124164)
851 @@ -2421,6 +2421,7 @@
852    block_stmt_iterator si;
853    tree entry_stmt;
854    edge e;
855 +  bool do_cleanup_cfg = false;
856  
857    entry_stmt = last_stmt (region->entry);
858    child_fn = OMP_PARALLEL_FN (entry_stmt);
859 @@ -2456,6 +2457,7 @@
860           exit_succ_e = single_succ_edge (exit_bb);
861           make_edge (new_bb, exit_succ_e->dest, EDGE_FALLTHRU);
862         }
863 +      do_cleanup_cfg = true;
864      }
865    else
866      {
867 @@ -2546,6 +2548,14 @@
868  
869    /* Emit a library call to launch the children threads.  */
870    expand_parallel_call (region, new_bb, entry_stmt, ws_args);
871 +
872 +  if (do_cleanup_cfg)
873 +    {
874 +      /* Clean up the unreachable sub-graph we created above.  */
875 +      free_dominance_info (CDI_DOMINATORS);
876 +      free_dominance_info (CDI_POST_DOMINATORS);
877 +      cleanup_tree_cfg ();
878 +    }
879  }
880  
881  
882 Index: gcc-4_2-branch/gcc/objc/objc-act.c
883 ===================================================================
884 --- gcc-4_2-branch/gcc/objc/objc-act.c  (revision 123014)
885 +++ gcc-4_2-branch/gcc/objc/objc-act.c  (revision 124164)
886 @@ -3632,7 +3632,7 @@
887  
888         {
889           struct _objc_exception_data _stack;
890 -         id volatile _rethrow = 0;
891 +         id _rethrow = 0;
892           try
893             {
894               objc_exception_try_enter (&_stack);
895 @@ -3676,7 +3676,6 @@
896  
897    rethrow_decl = objc_create_temporary_var (objc_object_type);
898    cur_try_context->rethrow_decl = rethrow_decl;
899 -  TREE_THIS_VOLATILE (rethrow_decl) = 1;
900    TREE_CHAIN (rethrow_decl) = stack_decl;
901  
902    /* Build the outermost variable binding level.  */
903 Index: gcc-4_2-branch/gcc/ChangeLog
904 ===================================================================
905 --- gcc-4_2-branch/gcc/ChangeLog        (revision 123014)
906 +++ gcc-4_2-branch/gcc/ChangeLog        (revision 124164)
907 @@ -1,3 +1,334 @@
908 +2007-04-25  Anatoly Sokolov <aesok@post.ru>
909 +
910 +       PR target/18989
911 +       * config/avr/avr.h (ASM_OUTPUT_ALIGN): Redefine.
912 +
913 +2007-04-24  Andrew Pinski  <andrew_pinski@playstation.sony.com>
914 +            Roger Sayle  <roger@eyesopen.com>
915 +
916 +       PR middle-end/30222
917 +       * expmed.c (make_tree): Use the correct type, i.e. the inner
918 +       type, when constructing the individual elements of a CONST_VECTOR.
919 +
920 +2007-04-24  Ian Lance Taylor  <iant@google.com>
921 +
922 +       PR tree-optimization/31605
923 +       * tree-vrp.c (set_value_range): Check that min and max are not
924 +       both overflow infinities.
925 +       (set_value_range_to_value): New static function.
926 +       (extract_range_from_binary_expr): Call set_value_range_to_value.
927 +       (extract_range_from_expr): Likewise.
928 +       (extract_range_from_unary_expr): Likewise.  Don't create a range
929 +       which overflows on both sides.
930 +       (vrp_meet): Check for a useless range.
931 +       (vrp_visit_phi_node): If we see a constant which looks like an
932 +       overflow infinity, turn off the TREE_OVERFLOW flag.
933 +
934 +2007-04-24  Ian Lance Taylor  <iant@google.com>
935 +
936 +       PR tree-optimization/31602
937 +       * tree-ssa-loop-ch.c (copy_loop_headers): Set TREE_NO_WARNING for
938 +       conditionals in the copied loop header.
939 +       * tree-cfg.c (fold_cond_expr_cond): Don't issue undefined overflow
940 +       warnings if TREE_NO_WARNING is set.
941 +       * doc/invoke.texi (Warning Options): Clarify that
942 +       -Wstrict-overflow does not warn about loops.
943 +
944 +2007-04-24  Andreas Krebbel  <krebbel1@de.ibm.com>
945 +
946 +       PR target/31641
947 +       * config/s390/s390.c (s390_expand_setmem): Don't ICE for constant length
948 +       argument of 0 for memset.
949 +       (s390_expand_movmem, s390_expand_setmem, s390_expand_cmpmem): Use
950 +       unsigned shift instead of the signed variant.
951 +
952 +2007-04-24  Daniel Franke  <franke.daniel@gmail.com>
953 +
954 +       * doc/invoke.texi: Removed leading '-' from option index entries.
955 +
956 +2007-04-22  Andrew Pinski  <andrew_pinski@playstation.sony.com>
957 +
958 +       PR middle-end/31448
959 +       * expr.c (reduce_to_bit_field_precision): Handle
960 +       CONST_INT rtx's.
961 +
962 +2007-04-20  Richard Henderson  <rth@redhat.com>
963 +
964 +       PR target/28623
965 +       * config/alpha/alpha.c (get_unaligned_address): Remove extra_offset
966 +       argument; update all callers.
967 +       (get_unaligned_offset): New.
968 +       * config/alpha/alpha.md (extendqidi2, extendhidi2): Don't use
969 +       get_unaligned_address, just pass on the address directly.
970 +       (unaligned_extendqidi): Use gen_lowpart instead of open-coding
971 +       the subreg in the helper patterns.
972 +       (unaligned_extendqidi_le): Use get_unaligned_offset.
973 +       (unaligned_extendqidi_be, unaligned_extendhidi_le): Likewise.
974 +       (unaligned_extendhidi_be): Likewise.
975 +       (unaligned_extendhidi): Tidy.
976 +       * config/alpha/alpha-protos.h: Update.
977 +
978 +2007-04-21  Richard Guenther  <rguenther@suse.de>
979 +
980 +       PR middle-end/31136
981 +       * fold-const.c (fold_unary): Call fold_convert_const on the
982 +       original tree.
983 +
984 +2007-04-20  Richard Henderson  <rth@redhat.com>
985 +
986 +       * config/alpha/linux.h (CPP_SPEC): Undef before redefine.
987 +
988 +2007-04-20  Bernd Schmidt  <bernd.schmidt@analog.com>
989 +
990 +       * reload.c (combine_reloads): When trying to use a dying register,
991 +       check whether it's uninitialized and don't use if so.
992 +
993 +2007-04-20  Jakub Jelinek  <jakub@redhat.com>
994 +
995 +       * config/i386/i386.c (bdesc_2arg): Use ORDERED rather than UNORDERED
996 +       for __builtin_ia32_cmpordss.
997 +
998 +       PR tree-optimization/31632
999 +       * fold-const.c (fold_binary): Use op0 and op1 instead of arg0
1000 +       and arg1 for optimizations of comparison against min/max values.
1001 +       Fold arg0 to arg1's type for optimizations of comparison against
1002 +       min+1 and max-1 values.
1003 +
1004 +2007-04-19  Eric Botcazou  <ebotcazou@libertysurf.fr>
1005 +
1006 +       PR rtl-optimization/29841
1007 +       * cfgbuild.c (control_flow_insn_p): Return TRUE for unconditional
1008 +       trap instructions.
1009 +       * sched-deps.c (sched_analyze_insn): Prevent all non-jump instructions
1010 +       that may cause control flow transfer from being moved.
1011 +
1012 +2007-04-18  Anatoly Sokolov <aesok@post.ru>
1013 +
1014 +       * config/avr/avr.c (ptrreg_to_str): Replace error() with
1015 +       output_operand_lossage().
1016 +
1017 +2007-04-17  Anatoly Sokolov <aesok@post.ru>
1018 +
1019 +       PR target/30483
1020 +       * config/avr/avr.c (ptrreg_to_str): Replace gcc_unreachable() with
1021 +       error().
1022 +
1023 +2007-04-17  Jan Hubicka  <jh@suse.cz>
1024 +
1025 +       PR middle-end/30700
1026 +       * dwarf2out.c (reference_to_unused): Ask cgraph for functions
1027 +       availablility; add more sanity checking; ask varpool only about
1028 +       VAR_DECL.
1029 +
1030 +2007-04-17  H.J. Lu  <hongjiu.lu@intel.com>
1031 +
1032 +       * Backport from mainline:
1033 +       2007-04-17  H.J. Lu  <hongjiu.lu@intel.com>
1034 +
1035 +       * config/i386/sse.md (sse_vmaddv4sf3): Use register_operand
1036 +       on "0".
1037 +       (sse_vmmulv4sf3): Likewise.
1038 +       (sse2_vmaddv2df3): Likewise.
1039 +       (sse2_vmmulv2df3): Likewise.
1040 +
1041 +2007-04-16  Matthias Klose  <doko@debian.org>
1042 +
1043 +       * config/alpha/linux.h (CPP_SPEC): Define.
1044 +       * config/arm/linux-gas.h (SUBTARGET_CPP_SPEC): Extend.
1045 +
1046 +2007-04-16  Anatoly Sokolov <aesok@post.ru>
1047 +
1048 +       * config/avr/avr.c (avr_arch_types): Rearranging  array.
1049 +       (enum avr_arch): Add.
1050 +       (avr_mcu_types): Use avr_arch enumeration constants instead of 
1051 +       numbers.
1052 +       * config/avr/avr.h (LINK_SPEC): Simplify.
1053 +
1054 +2007-04-16  Jan Hubicka  <jh@suse.cz>
1055 +
1056 +       PR target/27869
1057 +       * config/i386/sse.md
1058 +       (sse_vmaddv4sf3, sse_vmmulv4sf3): Remove '%' modifier.
1059 +       (sse_vmsmaxv4sf3_finite, sse_vmsminv4sf3_finite): Remove.
1060 +       (sse2_vmaddv2df3, sse2_vmmulv2df3): Remove '%' modifier.
1061 +       (sse2_vmsmaxv2df3_finite, sse2_vmsminv2df3_finite): Remove.
1062 +
1063 +2007-04-16  H.J. Lu  <hongjiu.lu@intel.com>
1064 +
1065 +       * Backport from mainline:
1066 +       2007-04-16  H.J. Lu  <hongjiu.lu@intel.com>
1067 +
1068 +       PR target/31582
1069 +       * config/i386/i386.c (ix86_expand_vec_set_builtin): Make a
1070 +       copy of source, pass it to ix86_expand_vector_set and return
1071 +       it as target.
1072 +
1073 +2007-04-14  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1074 +
1075 +       PR c/31520
1076 +       * c-decl.c (finish_decl): Grab the type of the decl after the call
1077 +       to store_init_value.
1078 +
1079 +2007-04-14  Jakub Jelinek  <jakub@redhat.com>
1080 +
1081 +       PR c++/25874
1082 +       * omp-low.c (expand_omp_parallel): If child_cfun->cfg, free dominators,
1083 +       post dominators and cleanup cfg before returning.
1084 +
1085 +2007-04-11  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1086 +
1087 +       * pa.c (pa_som_asm_init_sections): Ensure that cfun->machine is not
1088 +       null before emitting a .nsubspa directive.
1089 +
1090 +2007-04-08  Anatoly Sokolov <aesok@post.ru>
1091 +
1092 +       PR target/29932
1093 +       * config/avr/predicates.md (io_address_operand): Delete predicate.
1094 +       (low_io_address_operand): Don't use 'mode' argument.
1095 +       (higth_io_address_operand): Rename ...
1096 +       (high_io_address_operand): ... to this. Don't use 'mode' argument.
1097 +       * config/avr/avr.md (*sbix_branch_tmp, *sbix_branch_tmp_bit7): Adjust
1098 +       for above change.
1099 +
1100 +2007-04-07  Anatoly Sokolov <aesok@post.ru>
1101 +
1102 +       PR target/30289
1103 +       * config/avr/avr.md (*clrmemqi, *clrmemhi): Mark operand 4 as 
1104 +       earlyclobber.
1105 +
1106 +2007-04-05  Anatoly Sokolov <aesok@post.ru>
1107 +
1108 +       PR target/25448
1109 +       * config/avr/avr.c (avr_handle_fndecl_attribute): Use the 
1110 +       DECL_ASSEMBLER_NAME, not the DECL_NAME.
1111 +
1112 +2007-04-04  Richard Henderson  <rth@redhat.com>
1113 +
1114 +       PR target/31361
1115 +       * config/i386/i386.c (ix86_init_mmx_sse_builtins): Remove
1116 +       v8hi_ftype_v8hi_v2di, v4si_ftype_v4si_v2di.  Use like-types for
1117 +       the variable shift builtins.
1118 +       (ix86_expand_builtin): Properly expand the variable shift builtins.
1119 +       * config/i386/sse.md (ashr<mode>3, lshr<mode>3, ashl<mode>3): Make
1120 +       operand 2 be TImode.
1121 +       * config/i386/emmintrin.h (_mm_slli_epi16, _mm_slli_epi32,
1122 +       _mm_slli_epi64, _mm_srai_epi16, _mm_srai_epi32, _mm_srli_epi16,
1123 +       _mm_srli_epi32, _mm_srli_epi64): Turn into macros.
1124 +       (_mm_srli_si128, _mm_srli_si128): Fix disabled inline versions.
1125 +       (_mm_sll_epi16, _mm_sll_epi32, _mm_sll_epi64, _mm_sra_epi16,
1126 +       _mm_sra_epi32, _mm_srl_epi16, _mm_srl_epi32, _mm_srl_epi64): Use
1127 +       two-vector shift builtins.
1128 +
1129 +2007-04-04  Chen liqin  <liqin@sunnorth.com.cn>
1130 +
1131 +       * config/score/crti.asm: Change _bss_start to __bss_start.
1132 +       * config/score/score.h (CONDITIONAL_REGISTER_USAGE): Added.
1133 +       (OUTGOING_REG_PARM_STACK_SPACE) update.
1134 +       * config/score/score.opt: add options to make backend support
1135 +       score5, score5u, score7 and score7d.
1136 +       * config/score/score.md: Likewise.
1137 +       * config/score/misc.md: Likewise.
1138 +       * config/score/mac.md: Likewise.
1139 +       * doc/invoke.texi: Likewise.
1140 +       * doc/md.texi: update constraints define.
1141 +
1142 +2007-04-03  Stuart Hastings  <stuart@apple.com>
1143 +
1144 +       PR 31281
1145 +       * objc/objc-act.c (next_sjlj_build_catch_list): Delete volatile from rethrow decl.
1146 +       * cse.c (record_jump_equiv): Bail out on CCmode comparisons.
1147 +
1148 +2007-04-03  Jakub Jelinek  <jakub@redhat.com>
1149 +
1150 +       PR middle-end/30704
1151 +       * fold-const.c (native_encode_real): Encode real.c provided longs
1152 +       as a series of 32-bit native integers.
1153 +       (native_interpret_real): Interpret buffer as a series of 32-bit
1154 +       native integers.
1155 +
1156 +2007-04-02  Eric Christopher  <echristo@apple.com>
1157 +
1158 +       * doc/invoke.texi (i386 and x86-64 Options): Document -m64
1159 +       limitations on darwin.
1160 +
1161 +2007-04-02  Anatoly Sokolov <aesok@post.ru>
1162 +
1163 +       PR target/31137
1164 +       * config/avr/avr.c (avr_rtx_costs): Add missing 'break' statements.
1165 +
1166 +2007-04-02  H.J. Lu  <hongjiu.lu@intel.com>
1167 +
1168 +       * Backport from mainline:
1169 +       2007-03-28  Grigory Zagorodnev <grigory_zagorodnev@linux.intel.com>
1170 +
1171 +       PR target/31380
1172 +       * config/i386/sse.md (uminv16qi3): Use UMIN instead of UMAX.
1173 +
1174 +2007-03-30  Anatoly Sokolov <aesok@post.ru>
1175 +
1176 +       * config/avr/avr.c (avr_override_options): Clear
1177 +       'flag_delete_null_pointer_checks'.
1178 +
1179 +2007-03-29  Michael Matz  <matz@suse.de>
1180 +
1181 +       * builtins.c (expand_builtin_sync_operation,
1182 +       expand_builtin_compare_and_swap,
1183 +       expand_builtin_lock_test_and_set): Care for extending CONST_INTs
1184 +       correctly.
1185 +
1186 +       * config/i386/sync.md (sync_double_compare_and_swapdi_pic,
1187 +       sync_double_compare_and_swap_ccdi_pic): Use "SD" as constraint
1188 +       for operand 3.
1189 +
1190 +2007-03-28  Mike Stump  <mrs@apple.com>
1191 +
1192 +       * config/darwin9.h (ASM_OUTPUT_ALIGNED_COMMON): Add.
1193 +       * config/darwin.h (MAX_OFILE_ALIGNMENT): Fix.
1194 +       * config/rs6000/darwin.h (ASM_OUTPUT_ALIGNED_COMMON): Removed #undef.
1195 +
1196 +2007-03-27  Anatoly Sokolov <aesok@post.ru>
1197 +
1198 +       * config/avr/avr.c (avr_mcu_types): Move at90usb82 device to 'avr4'
1199 +       architecture.
1200 +
1201 +2007-03-26  Ian Lance Taylor  <iant@google.com>
1202 +
1203 +       PR tree-optimization/31345
1204 +       * tree-vrp.c (extract_range_from_binary_expr): Turn ranges like
1205 +       [+INF, +INF(OVF)] into VARYING.
1206 +
1207 +2007-03-23  Martin Michlmayr  <tbm@cyrius.com>
1208 +
1209 +       * doc/invoke.texi (-fforce-mem): Update documentation to reflect
1210 +       that this option will be removed in 4.3 rather than 4.2.
1211 +       * opts.c (common_handle_option): Likewise.
1212 +
1213 +2007-03-21  Mike Stump  <mrs@apple.com>
1214 +
1215 +       * c.opt: Fixup for Objective-C/C++.
1216 +
1217 +2007-03-21  Richard Henderson  <rth@redhat.com>
1218 +
1219 +       PR target/31245
1220 +       * config/i386/emmintrin.h (__m128i, __m128d): Mark may_alias.
1221 +       * config/i386/mmintrin.h (__m64): Likewise.
1222 +       * config/i386/xmmintrin.h (__m128): Likewise.
1223 +
1224 +2007-03-20  Jakub Jelinek  <jakub@redhat.com>
1225 +
1226 +       PR c/30762
1227 +       * c-typeck.c (convert_for_assignment): Call comptypes for
1228 +       RECORD_TYPE or UNION_TYPE.
1229 +
1230 +       PR inline-asm/30505
1231 +       * reload1.c (reload): Do invalid ASM checking after
1232 +       cleanup_subreg_operands.
1233 +
1234 +2007-03-19  Jeff Law  <law@redhat.com>
1235 +
1236 +       * tree-cfg.c (find_taken_edge): Tighten conditions for
1237 +       optimizing computed gotos.
1238 +
1239  2007-03-16  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1240  
1241         * pa.c (attr_length_call): Partially revert change of 2007-03-09.
1242 @@ -24,7 +355,7 @@
1243         PR target/31123
1244         * pa.md (vdepi_ior): Don't allow zero length deposit.  Likewise for
1245         two unamed patterns.
1246 -       
1247 +
1248  2007-03-12  Brooks Moses  <brooks.moses@codesourcery.com>
1249  
1250         * doc/extend.texi: Edit "gnu_inline" documentation.
1251 @@ -37,7 +368,7 @@
1252         * doc/passes.texi: Fix gcc.info cross-reference.
1253  
1254  2007-03-12  Daniel Berlin  <dberlin@dberlin.org>
1255 -       
1256 +
1257         Fix PR tree-optimization/28544
1258         * tree-ssa-operands.c (add_virtual_operand):
1259         Move assert triggering on aliasing violations into
1260 @@ -119,7 +450,7 @@
1261         (thread_across_edge): Likewise.
1262         * tree-flow.h (vrp_evaluate_conditional): Update declaration.
1263         (thread_across_edge): Likewise.
1264 -       * gcc/Makefile.in (tree-vrp.o): Depend upon toplev.h and intl.h.
1265 +       * Makefile.in (tree-vrp.o): Depend upon toplev.h and intl.h.
1266  
1267         2007-03-05  Ian Lance Taylor  <iant@google.com>
1268  
1269 @@ -415,7 +746,7 @@
1270  2007-03-09  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1271  
1272         PR tree-opt/28624
1273 -       * tree-ssa-dom.c (eliminate_degenerate_phis): Use a temporary 
1274 +       * tree-ssa-dom.c (eliminate_degenerate_phis): Use a temporary
1275         bitmap for EXECUTE_IF_SET_IN_BITMAP.
1276  
1277  2006-03-09  Mark Shinwell  <shinwell@codesourcery.com>
1278 @@ -436,7 +767,7 @@
1279         * builtins.def (lceil, lceilf, lceill, lfloor, lfloorf, lfloorl,
1280         llceil, llceilf, llceill, llfloor, llfloorf, llfloorl): Mark with
1281         ATTR_CONST_NOTHROW_LIST.
1282 -       
1283 +
1284         * fold-const.c (tree_expr_nonnegative_p): Handle FIX_TRUNC_EXPR.
1285  
1286  2007-03-08 Andrew Pinski <andrew_pinski@playstation.sony.com>
1287 @@ -484,11 +815,11 @@
1288         * doc/invoke.texi (Warning Options): Replace -Werror- with
1289         -Werror=.
1290         * opts.c (common_handle_option): Likewise.
1291 -       
1292 +
1293  2007-03-06  Anatoly Sokolov <aesok@post.ru>
1294  
1295         * config/avr/avr.c (avr_mcu_types): Add support for ATmega325P,
1296 -       ATmega3250P, ATmega329P, ATmega3290P, AT90USB82 and AT90USB162 
1297 +       ATmega3250P, ATmega329P, ATmega3290P, AT90USB82 and AT90USB162
1298         devices.
1299         * config/avr/avr.h (LINK_SPEC, CRT_BINUTILS_SPECS): (Ditto.).
1300         * config/avr/t-avr (MULTILIB_MATCHES): (Ditto.).
1301 @@ -509,7 +840,7 @@
1302         in soft-float DFmode pattern.
1303         (movdf): Fail if operand1 is a CONST_DOUBLE and operand0 is a hard
1304         floating register.
1305 -       (movsf): Likewise. 
1306 +       (movsf): Likewise.
1307  
1308  2007-03-05  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
1309  
1310 @@ -618,7 +949,7 @@
1311  2007-03-01  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
1312  
1313         * doc/invoke.texi (Wextra): Delete outdated paragraph.
1314 -       
1315 +
1316  2007-02-27  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1317  
1318         * pa/predicates.md (move_src_operand): Allow zero for mode.
1319 @@ -706,7 +1037,7 @@
1320  2007-02-18 Ira Rosen  <irar@il.ibm.com>
1321  
1322         * tree-ssa-alias.c (may_aliases_intersect): New function.
1323 -       * tree-data-ref.c (ptr_ptr_may_alias_p): Call may_aliases_intersect 
1324 +       * tree-data-ref.c (ptr_ptr_may_alias_p): Call may_aliases_intersect
1325         for different tags.
1326         * tree-flow.h (may_aliases_intersect): Add function declaration.
1327  
1328 @@ -764,7 +1095,7 @@
1329  
1330  2007-02-06  Rask Ingemann Lamberisen  <rask@sygehus.dk>
1331  
1332 -       PR 30370 
1333 +       PR 30370
1334         * config/rs6000/t-ppccomm: Correct Makefile typo.
1335  
1336  2007-02-06  Roger Sayle  <roger@eyesopen.com>
1337 @@ -788,7 +1119,7 @@
1338  2007-02-05  Bob Wilson  <bob.wilson@acm.org>
1339  
1340         * config/xtensa/xtensa.c (constantpool_mem_p): Skip over SUBREGs.
1341 -       
1342 +
1343  2007-02-02  Maxim Kuvyrkov  <mkuvyrkov@ispras.ru>
1344  
1345         PR target/29682
1346 @@ -817,7 +1148,7 @@
1347  
1348         Revert for x86 darwin:
1349         2005-06-19  Uros Bizjak  <uros@kss-loka.si>
1350 -       
1351 +
1352         * config/i386/i386.c (ix86_function_arg_regno_p): Put back the
1353         code before the following patch under TARGET_MACHO.
1354         (ix86_function_value_regno_p): Likewise.
1355 Index: gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/pr31448.c
1356 ===================================================================
1357 --- gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/pr31448.c        (revision 0)
1358 +++ gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/pr31448.c        (revision 124164)
1359 @@ -0,0 +1,36 @@
1360 +/* PR middle-end/31448, this used to ICE during expand because
1361 +   reduce_to_bit_field_precision was not ready to handle constants. */
1362 +
1363 +typedef struct _st {
1364 +    int iIndex : 24;
1365 +    int iIndex1 : 24;
1366 +} st;
1367 +st *next;
1368 +void g(void)
1369 +{
1370 +    st *next = 0;
1371 +    int nIndx;
1372 +    const static int constreg[] = { 0,};
1373 +    nIndx = 0;
1374 +    next->iIndex = constreg[nIndx];
1375 +}
1376 +void f(void)
1377 +{
1378 +    int nIndx;
1379 +    const static int constreg[] = { 0xFEFEFEFE,};
1380 +    nIndx = 0;
1381 +    next->iIndex = constreg[nIndx];
1382 +    next->iIndex1 = constreg[nIndx];
1383 +}
1384 +int main(void)
1385 +{
1386 +  st a;
1387 +  next = &a;
1388 +  f();
1389 +  if (next->iIndex != 0xFFFEFEFE)
1390 +    __builtin_abort ();
1391 +  if (next->iIndex1 != 0xFFFEFEFE)
1392 +    __builtin_abort ();
1393 +  return 0;
1394 +}
1395 +
1396 Index: gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/pr31136.c
1397 ===================================================================
1398 --- gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/pr31136.c        (revision 0)
1399 +++ gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/pr31136.c        (revision 124164)
1400 @@ -0,0 +1,17 @@
1401 +extern void abort (void);
1402 +
1403 +struct S {
1404 +  unsigned b4:4;
1405 +  unsigned b6:6;
1406 +} s;
1407 +
1408 +int main()
1409 +{
1410 +  s.b6 = 31;
1411 +  s.b4 = s.b6;
1412 +  s.b6 = s.b4;
1413 +  if (s.b6 != 15)
1414 +    abort ();
1415 +  return 0;
1416 +}
1417 +
1418 Index: gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/ieee/pr30704.c
1419 ===================================================================
1420 --- gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/ieee/pr30704.c   (revision 0)
1421 +++ gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/ieee/pr30704.c   (revision 124164)
1422 @@ -0,0 +1,57 @@
1423 +/* PR middle-end/30704 */
1424 +
1425 +typedef __SIZE_TYPE__ size_t;
1426 +extern void abort (void);
1427 +extern int memcmp (const void *, const void *, size_t);
1428 +extern void *memcpy (void *, const void *, size_t);
1429 +
1430 +long long
1431 +__attribute__((noinline))
1432 +f1 (void)
1433 +{
1434 +  long long t;
1435 +  double d = 0x0.fffffffffffff000p-1022;
1436 +  memcpy (&t, &d, sizeof (long long));
1437 +  return t;
1438 +}
1439 +
1440 +double
1441 +__attribute__((noinline))
1442 +f2 (void)
1443 +{
1444 +  long long t = 0x000fedcba9876543LL;
1445 +  double d;
1446 +  memcpy (&d, &t, sizeof (long long));
1447 +  return d;
1448 +}
1449 +
1450 +int
1451 +main ()
1452 +{
1453 +  union
1454 +  {
1455 +    long long ll;
1456 +    double d;
1457 +  } u;
1458 +
1459 +  if (sizeof (long long) != sizeof (double) || __DBL_MIN_EXP__ != -1021)
1460 +    return 0;
1461 +
1462 +  u.ll = f1 ();
1463 +  if (u.d != 0x0.fffffffffffff000p-1022)
1464 +    abort ();
1465 +
1466 +  u.d = f2 ();
1467 +  if (u.ll != 0x000fedcba9876543LL)
1468 +    abort ();
1469 +
1470 +  double b = 234.0;
1471 +  long long c;
1472 +  double d = b;
1473 +  memcpy (&c, &b, sizeof (double));
1474 +  long long e = c;
1475 +  if (memcmp (&e, &d, sizeof (double)) != 0)
1476 +    abort ();
1477 +
1478 +  return 0;
1479 +}
1480 Index: gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/pr31605.c
1481 ===================================================================
1482 --- gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/pr31605.c        (revision 0)
1483 +++ gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/pr31605.c        (revision 124164)
1484 @@ -0,0 +1,13 @@
1485 +void put_field (unsigned int start, unsigned int len)
1486 +{
1487 +  int cur_bitshift = ((start + len) % 8) - 8;
1488 +  if (cur_bitshift > -8)
1489 +    exit (0);
1490 +}
1491 +
1492 +int
1493 +main ()
1494 +{
1495 +  put_field (0, 1);
1496 +  abort ();
1497 +}
1498 Index: gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/mayalias-2.x
1499 ===================================================================
1500 --- gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/mayalias-2.x     (revision 0)
1501 +++ gcc-4_2-branch/gcc/testsuite/gcc.c-torture/execute/mayalias-2.x     (revision 124164)
1502 @@ -0,0 +1,10 @@
1503 +set torture_eval_before_compile {
1504 +    set compiler_conditional_xfail_data {
1505 +        "PR 28834" \
1506 +        { "*-*-*" } \
1507 +        { "-O3 -g" } \
1508 +        { "" }
1509 +    }
1510 +}
1511 +
1512 +return 0
1513 Index: gcc-4_2-branch/gcc/testsuite/gcc.c-torture/compile/pr31345-1.c
1514 ===================================================================
1515 --- gcc-4_2-branch/gcc/testsuite/gcc.c-torture/compile/pr31345-1.c      (revision 0)
1516 +++ gcc-4_2-branch/gcc/testsuite/gcc.c-torture/compile/pr31345-1.c      (revision 124164)
1517 @@ -0,0 +1,24 @@
1518 +/* PR tree-optimization/31345
1519 +   This caused a crash in VRP when dealing with overflow infinities.  */
1520 +
1521 +void
1522 +dpsnaffle (const char *kbuf)
1523 +{
1524 +  int hash, thash, head[2], off;
1525 +    {
1526 +      int _DP_i;
1527 +      (hash) = 19780211;
1528 +        {
1529 +          (hash) = (hash) + (kbuf)[_DP_i];
1530 +        }
1531 +      (hash) = ((hash) * 43321879) & 0x7FFFFFFF;
1532 +    }
1533 +  while (off != 0)
1534 +    {
1535 +      if (hash > thash) {}
1536 +      else if (hash < thash)
1537 +        {
1538 +          off = head[2];
1539 +        }
1540 +    }
1541 +}
1542 Index: gcc-4_2-branch/gcc/testsuite/gcc.c-torture/compile/pr30984.c
1543 ===================================================================
1544 --- gcc-4_2-branch/gcc/testsuite/gcc.c-torture/compile/pr30984.c        (revision 0)
1545 +++ gcc-4_2-branch/gcc/testsuite/gcc.c-torture/compile/pr30984.c        (revision 124164)
1546 @@ -0,0 +1,7 @@
1547 +int fs_exec(int ino)
1548 +{
1549 + void *src = 0;
1550 + if (ino)
1551 +   src = (void*)0xe000;
1552 + goto *src;
1553 +}
1554 Index: gcc-4_2-branch/gcc/testsuite/gcc.c-torture/compile/20070419-1.c
1555 ===================================================================
1556 --- gcc-4_2-branch/gcc/testsuite/gcc.c-torture/compile/20070419-1.c     (revision 0)
1557 +++ gcc-4_2-branch/gcc/testsuite/gcc.c-torture/compile/20070419-1.c     (revision 124164)
1558 @@ -0,0 +1,17 @@
1559 +/* PR tree-optimization/31632 */
1560 +
1561 +struct S
1562 +{
1563 +  long int l;
1564 +  void *m;
1565 +};
1566 +
1567 +int
1568 +foo (struct S *x)
1569 +{
1570 +  unsigned long a;
1571 +  a = x->l;
1572 +  if (a <= ((void *) 0))
1573 +    x->m = 0;
1574 +  return 0;
1575 +}
1576 Index: gcc-4_2-branch/gcc/testsuite/gcc.target/arm/register-variables.c
1577 ===================================================================
1578 --- gcc-4_2-branch/gcc/testsuite/gcc.target/arm/register-variables.c    (revision 0)
1579 +++ gcc-4_2-branch/gcc/testsuite/gcc.target/arm/register-variables.c    (revision 124164)
1580 @@ -0,0 +1,21 @@
1581 +/* { dg-do run } */
1582 +/* { dg-options "-O" } */
1583 +
1584 +#include <stdlib.h>
1585 +
1586 +void __attribute__((noinline)) 
1587 +bar(int a, int b)
1588 +{
1589 +  if (a != 43 || b != 42)
1590 +    abort();
1591 +}
1592 +
1593 +int main(void)
1594 +{
1595 +    register int r0 asm("r0") = 42;
1596 +    register int r1 asm("r1") = 43;
1597 +    asm volatile("": "+r" (r0), "+r" (r1));
1598 +    bar(r1, r0);
1599 +    return 0;
1600 +}
1601 +
1602 Index: gcc-4_2-branch/gcc/testsuite/gcc.target/i386/ordcmp-1.c
1603 ===================================================================
1604 --- gcc-4_2-branch/gcc/testsuite/gcc.target/i386/ordcmp-1.c     (revision 0)
1605 +++ gcc-4_2-branch/gcc/testsuite/gcc.target/i386/ordcmp-1.c     (revision 124164)
1606 @@ -0,0 +1,36 @@
1607 +/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
1608 +/* { dg-options "-O2 -msse2" } */
1609 +/* { dg-final { scan-assembler "cmpordss" } } */
1610 +/* { dg-final { scan-assembler "cmpordps" } } */
1611 +/* { dg-final { scan-assembler "cmpordsd" } } */
1612 +/* { dg-final { scan-assembler "cmpordpd" } } */
1613 +/* { dg-final { scan-assembler-not "cmpunordss" } } */
1614 +/* { dg-final { scan-assembler-not "cmpunordps" } } */
1615 +/* { dg-final { scan-assembler-not "cmpunordsd" } } */
1616 +/* { dg-final { scan-assembler-not "cmpunordpd" } } */
1617 +
1618 +#include <emmintrin.h>
1619 +
1620 +__m128
1621 +f1 (__m128 x, __m128 y)
1622 +{
1623 +  return _mm_cmpord_ss (x, y);
1624 +}
1625 +
1626 +__m128
1627 +f2 (__m128 x, __m128 y)
1628 +{
1629 +  return _mm_cmpord_ps (x, y);
1630 +}
1631 +
1632 +__m128d
1633 +f3 (__m128d x, __m128d y)
1634 +{
1635 +  return _mm_cmpord_sd (x, y);
1636 +}
1637 +
1638 +__m128d
1639 +f4 (__m128d x, __m128d y)
1640 +{
1641 +  return _mm_cmpord_pd (x, y);
1642 +}
1643 Index: gcc-4_2-branch/gcc/testsuite/gcc.target/i386/unordcmp-1.c
1644 ===================================================================
1645 --- gcc-4_2-branch/gcc/testsuite/gcc.target/i386/unordcmp-1.c   (revision 0)
1646 +++ gcc-4_2-branch/gcc/testsuite/gcc.target/i386/unordcmp-1.c   (revision 124164)
1647 @@ -0,0 +1,36 @@
1648 +/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
1649 +/* { dg-options "-O2 -msse2" } */
1650 +/* { dg-final { scan-assembler "cmpunordss" } } */
1651 +/* { dg-final { scan-assembler "cmpunordps" } } */
1652 +/* { dg-final { scan-assembler "cmpunordsd" } } */
1653 +/* { dg-final { scan-assembler "cmpunordpd" } } */
1654 +/* { dg-final { scan-assembler-not "cmpordss" } } */
1655 +/* { dg-final { scan-assembler-not "cmpordps" } } */
1656 +/* { dg-final { scan-assembler-not "cmpordsd" } } */
1657 +/* { dg-final { scan-assembler-not "cmpordpd" } } */
1658 +
1659 +#include <emmintrin.h>
1660 +
1661 +__m128
1662 +f1 (__m128 x, __m128 y)
1663 +{
1664 +  return _mm_cmpunord_ss (x, y);
1665 +}
1666 +
1667 +__m128
1668 +f2 (__m128 x, __m128 y)
1669 +{
1670 +  return _mm_cmpunord_ps (x, y);
1671 +}
1672 +
1673 +__m128d
1674 +f3 (__m128d x, __m128d y)
1675 +{
1676 +  return _mm_cmpunord_sd (x, y);
1677 +}
1678 +
1679 +__m128d
1680 +f4 (__m128d x, __m128d y)
1681 +{
1682 +  return _mm_cmpunord_pd (x, y);
1683 +}
1684 Index: gcc-4_2-branch/gcc/testsuite/gcc.target/i386/pr30505.c
1685 ===================================================================
1686 --- gcc-4_2-branch/gcc/testsuite/gcc.target/i386/pr30505.c      (revision 0)
1687 +++ gcc-4_2-branch/gcc/testsuite/gcc.target/i386/pr30505.c      (revision 124164)
1688 @@ -0,0 +1,19 @@
1689 +/* PR inline-asm/30505 */
1690 +/* { dg-do compile { target ilp32 } } */
1691 +/* { dg-options "-O2" } */
1692 +
1693 +unsigned long long a, c;
1694 +unsigned int b, d;
1695 +
1696 +void
1697 +test ()
1698 +{
1699 +  unsigned int e, f;
1700 +
1701 +  __asm__ ("divl %5;movl %1, %0;movl %4, %1;divl %5"
1702 +          : "=&rm" (e), "=a" (f), "=d" (d)
1703 +          : "1" ((unsigned int) (a >> 32)), "g" ((unsigned int) a),
1704 +            "rm" (b), "2" (0)
1705 +          : "cc");
1706 +  c = (unsigned long long) e << 32 | f;
1707 +}
1708 Index: gcc-4_2-branch/gcc/testsuite/gcc.dg/gomp/pr25874.c
1709 ===================================================================
1710 --- gcc-4_2-branch/gcc/testsuite/gcc.dg/gomp/pr25874.c  (revision 123014)
1711 +++ gcc-4_2-branch/gcc/testsuite/gcc.dg/gomp/pr25874.c  (revision 124164)
1712 @@ -1,3 +1,5 @@
1713 +/* { dg-options "-O -fopenmp" } */
1714 +
1715  void foo();
1716  
1717  inline void bar()
1718 Index: gcc-4_2-branch/gcc/testsuite/gcc.dg/pr30762-2.c
1719 ===================================================================
1720 --- gcc-4_2-branch/gcc/testsuite/gcc.dg/pr30762-2.c     (revision 0)
1721 +++ gcc-4_2-branch/gcc/testsuite/gcc.dg/pr30762-2.c     (revision 124164)
1722 @@ -0,0 +1,9 @@
1723 +/* PR c/30762 */
1724 +/* { dg-do compile } */
1725 +
1726 +typedef struct { int i; } D;
1727 +
1728 +void
1729 +foo (D x)
1730 +{
1731 +}
1732 Index: gcc-4_2-branch/gcc/testsuite/gcc.dg/tree-ssa/loadpre1.c
1733 ===================================================================
1734 --- gcc-4_2-branch/gcc/testsuite/gcc.dg/tree-ssa/loadpre1.c     (revision 123014)
1735 +++ gcc-4_2-branch/gcc/testsuite/gcc.dg/tree-ssa/loadpre1.c     (revision 124164)
1736 @@ -14,5 +14,5 @@
1737    e = *a;
1738    return d + e;
1739  }
1740 -/* { dg-final { scan-tree-dump-times "Eliminated: 1" 1 "pre"} } */
1741 +/* { dg-final { scan-tree-dump-times "Eliminated: 1" 1 "pre" { xfail *-*-* } } } */
1742  /* { dg-final { cleanup-tree-dump "pre" } } */
1743 Index: gcc-4_2-branch/gcc/testsuite/gcc.dg/tree-ssa/loadpre14.c
1744 ===================================================================
1745 --- gcc-4_2-branch/gcc/testsuite/gcc.dg/tree-ssa/loadpre14.c    (revision 123014)
1746 +++ gcc-4_2-branch/gcc/testsuite/gcc.dg/tree-ssa/loadpre14.c    (revision 124164)
1747 @@ -15,5 +15,5 @@
1748    e = (*a)[0];
1749    return d + e;
1750  }
1751 -/* { dg-final { scan-tree-dump-times "Eliminated: 1" 1 "pre"} } */
1752 +/* { dg-final { scan-tree-dump-times "Eliminated: 1" 1 "pre" { xfail *-*-* } } } */
1753  /* { dg-final { cleanup-tree-dump "pre" } } */
1754 Index: gcc-4_2-branch/gcc/testsuite/gcc.dg/tree-ssa/loadpre15.c
1755 ===================================================================
1756 --- gcc-4_2-branch/gcc/testsuite/gcc.dg/tree-ssa/loadpre15.c    (revision 123014)
1757 +++ gcc-4_2-branch/gcc/testsuite/gcc.dg/tree-ssa/loadpre15.c    (revision 124164)
1758 @@ -15,5 +15,5 @@
1759    e = (*a)[t];
1760    return d + e;
1761  }
1762 -/* { dg-final { scan-tree-dump-times "Eliminated: 1" 1 "pre"} } */
1763 +/* { dg-final { scan-tree-dump-times "Eliminated: 1" 1 "pre" { xfail *-*-* } } } */
1764  /* { dg-final { cleanup-tree-dump "pre" } } */
1765 Index: gcc-4_2-branch/gcc/testsuite/gcc.dg/invalid-call-1.c
1766 ===================================================================
1767 --- gcc-4_2-branch/gcc/testsuite/gcc.dg/invalid-call-1.c        (revision 0)
1768 +++ gcc-4_2-branch/gcc/testsuite/gcc.dg/invalid-call-1.c        (revision 124164)
1769 @@ -0,0 +1,17 @@
1770 +/* PR rtl-optimization/29841 */
1771 +/* Testcase by Khem Raj <raj.khem@gmail.com> */
1772 +
1773 +/* { dg-do compile } */
1774 +/* { dg-options "-O2" } */
1775 +/* { dg-options "-O2 -mtune=i586" { target i?86-*-* } } */
1776 +
1777 +typedef void (*fp)(void);
1778 +extern char* bar(void* a1, int a2);
1779 +extern char* mar(int n);
1780 +char* cptr;
1781 +
1782 +void foo()
1783 +{
1784 +  cptr = mar(6);
1785 +  ((char *(*)(void *,int (*)(void *,unsigned char **),char**))((fp)bar))(0,0,(void*)(0)); /* { dg-warning "" "non-compatible type" } */
1786 +}
1787 Index: gcc-4_2-branch/gcc/testsuite/gcc.dg/gnu89-init-4.c
1788 ===================================================================
1789 --- gcc-4_2-branch/gcc/testsuite/gcc.dg/gnu89-init-4.c  (revision 0)
1790 +++ gcc-4_2-branch/gcc/testsuite/gcc.dg/gnu89-init-4.c  (revision 124164)
1791 @@ -0,0 +1,12 @@
1792 +/* Test for GNU extensions to compound literals are giving the correct array bounds */
1793 +/* { dg-do compile } */
1794 +/* { dg-options "-std=gnu89 -W -Wall -O2" } */
1795 +
1796 +int a[] = (int[4]){1, 1, 2};
1797 +int f(void)
1798 +{
1799 +  int sum = 0; int i;
1800 +  for(i = 0;i<4;i++)
1801 +    sum = a[i];
1802 +  return sum;
1803 +}
1804 Index: gcc-4_2-branch/gcc/testsuite/gcc.dg/darwin-comm.c
1805 ===================================================================
1806 --- gcc-4_2-branch/gcc/testsuite/gcc.dg/darwin-comm.c   (revision 0)
1807 +++ gcc-4_2-branch/gcc/testsuite/gcc.dg/darwin-comm.c   (revision 124164)
1808 @@ -0,0 +1,4 @@
1809 +/* { dg-do compile { target *-*-darwin9* } } */
1810 +/* { dg-final { scan-assembler ".comm _foo,1,15" } } */
1811 +
1812 +char foo __attribute__ ((aligned(32768)));
1813 Index: gcc-4_2-branch/gcc/testsuite/gcc.dg/pr30762-1.c
1814 ===================================================================
1815 --- gcc-4_2-branch/gcc/testsuite/gcc.dg/pr30762-1.c     (revision 0)
1816 +++ gcc-4_2-branch/gcc/testsuite/gcc.dg/pr30762-1.c     (revision 124164)
1817 @@ -0,0 +1,15 @@
1818 +/* PR c/30762 */
1819 +/* { dg-do compile } */
1820 +/* { dg-options "--combine -O3" } */
1821 +/* { dg-additional-sources pr30762-2.c } */
1822 +
1823 +typedef struct { int i; } D;
1824 +extern void foo (D);
1825 +
1826 +void
1827 +bar (void)
1828 +{
1829 +  D d;
1830 +  d.i = 1;
1831 +  foo (d);
1832 +}
1833 Index: gcc-4_2-branch/gcc/testsuite/ChangeLog
1834 ===================================================================
1835 --- gcc-4_2-branch/gcc/testsuite/ChangeLog      (revision 123014)
1836 +++ gcc-4_2-branch/gcc/testsuite/ChangeLog      (revision 124164)
1837 @@ -1,3 +1,164 @@
1838 +2007-04-24  Paolo Carlini  <pcarlini@suse.de>
1839 +
1840 +       PR c++/30500
1841 +       * g++.dg/warn/pragma-system_header3.C: New test.
1842 +       * g++.dg/warn/pragma-system_header3.h. New.
1843 +
1844 +2007-04-24  Ian Lance Taylor  <iant@google.com>
1845 +
1846 +       PR tree-optimization/31605
1847 +       * gcc.c-torture/execute/pr31605.c: New test.
1848 +
1849 +2007-04-24  Andreas Krebbel  <krebbel1@de.ibm.com>
1850 +
1851 +       PR target/31641
1852 +       * gcc.c-torture/compile/pr31641.c: New testcase.
1853 +
1854 +2007-04-22  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1855 +
1856 +       PR middle-end/31448
1857 +       * gcc.c-torture/execute/pr31448.c: New testcase.
1858 +
1859 +2007-04-21  Richard Guenther  <rguenther@suse.de>
1860 +
1861 +       PR middle-end/31136
1862 +       * gcc.c-torture/execute/pr31136.c: New testcase.
1863 +
1864 +2007-04-20  Jakub Jelinek  <jakub@redhat.com>
1865 +
1866 +       * gcc.target/i386/ordcmp-1.c: New test.
1867 +       * gcc.target/i386/unordcmp-1.c: New test.
1868 +
1869 +       PR tree-optimization/31632
1870 +       * gcc.c-torture/compile/20070419-1.c: New test.
1871 +
1872 +2007-04-19  Eric Botcazou  <ebotcazou@libertysurf.fr>
1873 +
1874 +       * gcc.dg/invalid-call-1.c: New test.
1875 +
1876 +2007-04-17  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1877 +
1878 +       PR libgfortran/31366
1879 +       * gfortran.dg/direct_io_6.f90: New test.
1880 +
1881 +2007-04-17  Simon Martin  <simartin@users.sourceforge.net>
1882 +
1883 +       PR c++/31517
1884 +       * g++.dg/template/init7.C: New test.
1885 +
1886 +2007-04-16  Mark Mitchell  <mark@codesourcery.com>
1887 +
1888 +       PR c++/31513
1889 +       * g++.dg/expr/bitfield8.C: New test.
1890 +
1891 +2007-04-14  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1892 +
1893 +       PR testsuite/31578
1894 +       * gcc.dg/gnu89-init-4.c: Change to a compile only test.
1895 +
1896 +2007-04-14  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1897 +
1898 +       PR C/31520
1899 +       * gcc.dg/gnu89-init-4.c: New testcase.
1900 +
1901 +2007-04-14  Jakub Jelinek  <jakub@redhat.com>
1902 +
1903 +       PR c++/25874
1904 +       * gcc.dg/gomp/pr25874.c: Add dg-options.
1905 +       * g++.dg/gomp/pr25874.C: Add dg-options.
1906 +
1907 +2007-04-13  Jason Merrill  <jason@redhat.com>
1908 +
1909 +       PR c++/31074
1910 +       * conv3.C: New test.
1911 +
1912 +2007-04-13  Joseph Myers  <joseph@codesourcery.com>
1913 +
1914 +       PR tree-optimization/29598
1915 +       * gcc.dg/tree-ssa/loadpre1.c, gcc.dg/tree-ssa/loadpre14.c,
1916 +       gcc.dg/tree-ssa/loadpre15.c: XFAIL.
1917 +
1918 +2007-04-10  Mike Stump  <mrs@apple.com>
1919 +
1920 +       * g++.dg/tree-ssa/pr29585.C: Don't die on an expected warning.
1921 +
1922 +2007-04-09  Mark Mitchell  <mark@codesourcery.com>
1923 +
1924 +       PR c++/31449
1925 +       * g++.dg/init/const5.C: New test.
1926 +
1927 +2007-04-03  Eric Christopher  <echristo@apple.com>
1928 +
1929 +       * g++.dg/tree-ssa/pr29902.C: Require ilp32.
1930 +
1931 +2007-04-03  Stuart Hastings  <stuart@apple.com>
1932 +
1933 +       PR 31281
1934 +       * testsuite/objc/execute/exceptions/pr31281.m: New.
1935 +
1936 +2007-04-03  Jakub Jelinek  <jakub@redhat.com>
1937 +
1938 +       PR c++/30847
1939 +       * g++.dg/parse/cond3.C: New test.
1940 +
1941 +       PR middle-end/30704
1942 +       * gcc.c-torture/execute/ieee/pr30704.c: New test.
1943 +
1944 +2007-04-02  Jason Merrill  <jason@redhat.com>
1945 +
1946 +       PR c++/31187
1947 +       * g++.dg/ext/visibility/anon3.C: New test.
1948 +
1949 +2007-03-31  Diego Novillo  <dnovillo@redhat.com>
1950 +
1951 +       PR 29585
1952 +       * g++.dg/tree-ssa/pr29585.C: New test.
1953 +
1954 +2007-03-30  Kazu Hirata  <kazu@codesourcery.com>
1955 +
1956 +       * gcc.c-torture/execute/mayalias-2.x: New.
1957 +
1958 +2007-03-28  Mike Stump  <mrs@apple.com>
1959 +
1960 +       * gcc.dg/darwin-comm.c: Add.
1961 +
1962 +2007-03-26  Ian Lance Taylor  <iant@google.com>
1963 +
1964 +       PR tree-optimization/31345
1965 +       * gcc.c-torture/compile/pr31345-1.c: New test.
1966 +
1967 +2007-03-22  Mark Mitchell  <mark@codesourcery.com>
1968 +
1969 +       PR c++/30863
1970 +       * g++.dg/template/error24.C: New test.
1971 +       * g++.dg/parse/tmpl-outside1.C: Tweak error markers.
1972 +
1973 +       PR c++/31273
1974 +       * g++.dg/expr/bitfield7.C: New test.
1975 +
1976 +2007-03-20  Seongbae Park <seongbae.park@gmail.com>
1977 +
1978 +       PR tree-optimization/30590
1979 +       * g++.dg/opt/pr30590.C: New testcase.
1980 +
1981 +2007-03-20  Jakub Jelinek  <jakub@redhat.com>
1982 +
1983 +       PR c/30762
1984 +       * gcc.dg/pr30762-1.c: New test.
1985 +       * gcc.dg/pr30762-2.c: New test.
1986 +
1987 +       PR inline-asm/30505
1988 +       * gcc.target/i386/pr30505.c: New test.
1989 +
1990 +2007-03-19  Mark Shinwell  <shinwell@codesourcery.com>
1991 +
1992 +       * gcc.target/arm/register-variables.c: New.
1993 +
1994 +2007-03-19  Jeff Law  <law@redhat.com>
1995 +
1996 +       * PR tree-optimization/30984
1997 +       * gcc.c-torture/pr30984.c: New test.
1998 +
1999  2007-03-16  Alexandre Oliva  <aoliva@redhat.com>
2000  
2001         PR debug/29906
2002 @@ -123,12 +284,12 @@
2003         PR rtl-optimization/30643
2004         * gcc.dg/pr30643.c: New.
2005  
2006 -2007-03-09  Andrew Pinski  <andrew_pinski@playstation.sony.com> 
2007 +2007-03-09  Andrew Pinski  <andrew_pinski@playstation.sony.com>
2008  
2009         PR tree-opt/30045
2010         * gcc.dg/pr30045.c: New test.
2011  
2012 -2007-03-09  Andrew Pinski  <andrew_pinski@playstation.sony.com> 
2013 +2007-03-09  Andrew Pinski  <andrew_pinski@playstation.sony.com>
2014  
2015         PR middle-end/30729
2016         * gcc.dg/Wunused-value-2.c: New testcase.
2017 @@ -163,7 +324,7 @@
2018  2007-03-08  Brooks Moses  <brooks.moses@codesourcery.com>
2019  
2020         Backport from trunk.
2021 -       * gfortran.dg/gomp/reduction1.f90: Add -fmax-errors=100 to 
2022 +       * gfortran.dg/gomp/reduction1.f90: Add -fmax-errors=100 to
2023         dg-options.
2024  
2025  2007-03-08  Paul Thomas  <pault@gcc.gnu.org>
2026 @@ -216,7 +377,7 @@
2027         * gcc.dg/Wstring-literal-comparison-4.c: Likewise.
2028         * g++.dg/warn/Wstring-literal-comparison-1.C: Likewise.
2029         * g++.dg/warn/Wstring-literal-comparison-4.c: Likewise.
2030 -       
2031 +
2032  2007-03-06  Roger Sayle  <roger@eyesopen.com>
2033  
2034         PR middle-end/30744
2035 @@ -315,7 +476,7 @@
2036  
2037  2007-02-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2038  
2039 -       PR libgfortran/30910    
2040 +       PR libgfortran/30910
2041         * gfortran.dg/fmt_zero_precision.f90: Update test.
2042  
2043  2007-02-23  Tobias Burnus  <burnus@net-b.de>
2044 @@ -404,7 +565,7 @@
2045  2007-02-16  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2046  
2047         PR fortran/30611
2048 -       * gcc/testsuite/gfortran.dg/repeat_1.f90: New test.
2049 +       * gfortran.dg/repeat_1.f90: New test.
2050  
2051  2007-02-16  Thomas Koenig  <Thomas.Koenig@online.de>
2052  
2053 @@ -480,7 +641,7 @@
2054  
2055  2007-02-07  Hans-Peter Nilsson  <hp@axis.com>
2056  
2057 -       * lib/target-supports.exp (check_effective_target_simulator): New. 
2058 +       * lib/target-supports.exp (check_effective_target_simulator): New.
2059  
2060  2007-02-05  Alexandre Oliva  <aoliva@redhat.com>
2061  
2062 @@ -614,7 +775,7 @@
2063  
2064         PR fortran/30532
2065         * gfortran.dg/ctrl-z.f90:  New test.
2066 -       
2067 +
2068  2007-01-26  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2069  
2070         PR fortran/30481
2071 @@ -1319,7 +1480,7 @@
2072  2006-11-13  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2073  
2074         PR libfortran/27895
2075 -       * gcc/testsuite/gfortran.dg/zero_sized_1.f90: Uncomment checks
2076 +       * gfortran.dg/zero_sized_1.f90: Uncomment checks
2077         for RESHAPE.
2078  
2079  2006-11-13  Mark Mitchell  <mark@codesourcery.com>
2080 @@ -1753,16 +1914,16 @@
2081  2006-10-13  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2082  
2083         PR fortran/21435
2084 -       * gcc/testsuite/gfortran.dg/io_constraints_3.f90: New test.
2085 -       * gcc/testsuite/gfortran.dg/open_access_append_1.f90: Add checks
2086 +       * gfortran.dg/io_constraints_3.f90: New test.
2087 +       * gfortran.dg/open_access_append_1.f90: Add checks
2088         for compile-time warnings.
2089 -       * gcc/testsuite/gfortran.dg/pr20163-2.f: Likewise.
2090 -       * gcc/testsuite/gfortran.dg/iostat_2.f90: Likewise.
2091 -       * gcc/testsuite/gfortran.dg/label_4.f90: Delete the temporary
2092 +       * gfortran.dg/pr20163-2.f: Likewise.
2093 +       * gfortran.dg/iostat_2.f90: Likewise.
2094 +       * gfortran.dg/label_4.f90: Delete the temporary
2095         file.
2096 -       * gcc/testsuite/gfortran.dg/direct_io_2.f90: Add a FILE=
2097 +       * gfortran.dg/direct_io_2.f90: Add a FILE=
2098         specifier.
2099 -       * gcc/testsuite/gfortran.dg/iomsg_1.f90: Add check for
2100 +       * gfortran.dg/iomsg_1.f90: Add check for
2101         compile-time warning.
2102  
2103  2006-10-12  Jan Hubicka  <jh@suse.cz>
2104 @@ -1899,12 +2060,12 @@
2105  
2106         PR fortran/16580
2107         PR fortran/29288
2108 -       * gcc/testsuite/gfortran.fortran-torture/execute/specifics.f90:
2109 +       * gfortran.fortran-torture/execute/specifics.f90:
2110         Add tests for using all possible intrinsics as actual arguments.
2111 -       * gcc/testsuite/gfortran.dg/specifics_1.f90: Add tests for using
2112 +       * gfortran.dg/specifics_1.f90: Add tests for using
2113         all possible intrinsics as actual arguments.
2114 -       * gcc/testsuite/gfortran.dg/specifics_2.f90: New file.
2115 -       * gcc/testsuite/gfortran.dg/specifics_3.f90: New file.
2116 +       * gfortran.dg/specifics_2.f90: New file.
2117 +       * gfortran.dg/specifics_3.f90: New file.
2118  
2119  2006-10-07  Richard Sandiford  <richard@codesourcery.com>
2120  
2121 @@ -4158,7 +4319,7 @@
2122  2006-06-08  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2123  
2124         PR fortran/27958
2125 -       * gcc/testsuite/gfortran.dg/substr_2.f: New test.
2126 +       * gfortran.dg/substr_2.f: New test.
2127  
2128  2006-06-08  Asher Langton  <langton2@llnl.gov>
2129  
2130 @@ -6195,7 +6356,7 @@
2131  
2132  2006-03-03  Paul Brook  <paul@codesourcery.com>
2133  
2134 -       * gcc/testsuite/lib/target-supports.exp (check_profiling_available):
2135 +       * lib/target-supports.exp (check_profiling_available):
2136         Add m68k-*-elf.
2137  
2138  2006-03-03  Thomas Koenig  <Thomas.Koenig@online.de>
2139 @@ -9951,11 +10112,11 @@
2140  2005-11-04  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2141  
2142         PR libfortran/22298
2143 -       * gcc/testsuite/lib/target-supports.exp
2144 +       * lib/target-supports.exp
2145         (check_effective_target_static_libgfortran): New
2146         static_libgfortran effective target.
2147 -       * gcc/testsuite/gfortran.dg/static_linking_1.f: New test.
2148 -       * gcc/testsuite/gfortran.dg/static_linking_1.c: New file.
2149 +       * gfortran.dg/static_linking_1.f: New test.
2150 +       * gfortran.dg/static_linking_1.c: New file.
2151  
2152  2005-11-04  Hans-Peter Nilsson  <hp@axis.com>
2153  
2154 @@ -17467,7 +17628,7 @@
2155  2005-02-11  Jakub Jelinek  <jakub@redhat.com>
2156  
2157         PR c++/19666
2158 -       * gcc/testsuite/g++.dg/other/ptrmem6.C: New test.
2159 +       * g++.dg/other/ptrmem6.C: New test.
2160  
2161         PR middle-end/19858
2162         * gcc.c-torture/compile/20050210-1.c: New test.
2163 @@ -33085,33 +33246,33 @@
2164  
2165  2003-01-16  Mark Mitchell  <mark@codesourcery.com>
2166  
2167 -       * gcc/testsuite/g++.dg/ext/typename1.C: Add typename keyword.
2168 -       * gcc/testsuite/g++.dg/template/crash1.C: Update error messages.
2169 -       * gcc/testsuite/g++.dg/template/crash2.C: Remove error message.
2170 -       * gcc/testsuite/g++.dg/parse/typename2.C: New test.
2171 -       * gcc/testsuite/g++.dg/template/typename2.C: Change implicit
2172 +       * g++.dg/ext/typename1.C: Add typename keyword.
2173 +       * g++.dg/template/crash1.C: Update error messages.
2174 +       * g++.dg/template/crash2.C: Remove error message.
2175 +       * g++.dg/parse/typename2.C: New test.
2176 +       * g++.dg/template/typename2.C: Change implicit
2177         typename warning into error.
2178 -       * gcc/testsuite/g++.old-deja/g++.benjamin/tem03.C: Issue more
2179 +       * g++.old-deja/g++.benjamin/tem03.C: Issue more
2180         error messages.
2181 -       * gcc/testsuite/g++.old-deja/g++.benjamin/tem04.C: Fix typos.
2182 -       * gcc/testsuite/g++.old-deja/g++.brendan/crash56.C: Add this->.
2183 -       * gcc/testsuite/g++.old-deja/g++.law/visibility13.C: Remove error
2184 +       * g++.old-deja/g++.benjamin/tem04.C: Fix typos.
2185 +       * g++.old-deja/g++.brendan/crash56.C: Add this->.
2186 +       * g++.old-deja/g++.law/visibility13.C: Remove error
2187         messages.
2188 -       * gcc/testsuite/g++.old-deja/g++.ns/template17.C: Reorder code to
2189 +       * g++.old-deja/g++.ns/template17.C: Reorder code to
2190         make declaration visible in template.
2191 -       * gcc/testsuite/g++.old-deja/g++.pt/crash3.C: Fix typos.
2192 -       * gcc/testsuite/g++.old-deja/g++.pt/crash36.C: Issue more error
2193 +       * g++.old-deja/g++.pt/crash3.C: Fix typos.
2194 +       * g++.old-deja/g++.pt/crash36.C: Issue more error
2195         messages.
2196 -       * gcc/testsuite/g++.old-deja/g++.pt/crash5.C: Improve error
2197 +       * g++.old-deja/g++.pt/crash5.C: Improve error
2198         message.
2199 -       * gcc/testsuite/g++.old-deja/g++.pt/crash67.C: Remove warning.
2200 -       * gcc/testsuite/g++.old-deja/g++.pt/inherit1.C: Add this->.
2201 -       * gcc/testsuite/g++.old-deja/g++.pt/niklas01a.C: Add error message.
2202 -       * gcc/testsuite/g++.old-deja/g++.pt/typename16.C: Replace implicit
2203 +       * g++.old-deja/g++.pt/crash67.C: Remove warning.
2204 +       * g++.old-deja/g++.pt/inherit1.C: Add this->.
2205 +       * g++.old-deja/g++.pt/niklas01a.C: Add error message.
2206 +       * g++.old-deja/g++.pt/typename16.C: Replace implicit
2207         typename warning with error message.
2208 -       * gcc/testsuite/g++.old-deja/g++.pt/typename19.C: Remove warning.
2209 -       * gcc/testsuite/g++.old-deja/g++.robertl/eb112.C: Fix typo.
2210 -       * gcc/testsuite/g++.old-deja/g++.robertl/eb24.C: Use this->.
2211 +       * g++.old-deja/g++.pt/typename19.C: Remove warning.
2212 +       * g++.old-deja/g++.robertl/eb112.C: Fix typo.
2213 +       * g++.old-deja/g++.robertl/eb24.C: Use this->.
2214  
2215  2003-01-16  Nathan Sidwell  <nathan@codesourcery.com>
2216  
2217 @@ -34702,9 +34863,9 @@
2218  
2219  2002-09-25  Mark Mitchell  <mark@codesourcery.com>
2220  
2221 -       * gcc/testsuite/g++.dg/abi/empty5.C: New test.
2222 -       * gcc/testsuite/g++.dg/abi/empty6.C: New test.
2223 -       * gcc/testsuite/g++.dg/abi/vbase12.C: New test.
2224 +       * g++.dg/abi/empty5.C: New test.
2225 +       * g++.dg/abi/empty6.C: New test.
2226 +       * g++.dg/abi/vbase12.C: New test.
2227  
2228  2002-09-25  Richard Henderson  <rth@redhat.com>
2229  
2230 @@ -35726,7 +35887,7 @@
2231  
2232  2002-05-23  Mark Mitchell  <mark@codesourcery.com>
2233  
2234 -       * gcc/testsuite/gcc.dg/weak-8.c: New test.
2235 +       * gcc.dg/weak-8.c: New test.
2236  
2237  2002-05-23  J"orn Rennecke <joern.rennecke@superh.com>
2238  
2239 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/tree-ssa/pr29585.C
2240 ===================================================================
2241 --- gcc-4_2-branch/gcc/testsuite/g++.dg/tree-ssa/pr29585.C      (revision 0)
2242 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/tree-ssa/pr29585.C      (revision 124164)
2243 @@ -0,0 +1,15 @@
2244 +/* { dg-do compile } */
2245 +/* { dg-options "-O2 -w" } */
2246 +
2247 +class ios_base{};
2248 +struct basic_ostream : virtual ios_base{};
2249 +namespace
2250 +{
2251 +  struct Nullostream : basic_ostream{};
2252 +}
2253 +class  In
2254 +{
2255 +  In ();
2256 +  Nullostream  nullout;
2257 +};
2258 +In::In (){}
2259 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/tree-ssa/pr29902.C
2260 ===================================================================
2261 --- gcc-4_2-branch/gcc/testsuite/g++.dg/tree-ssa/pr29902.C      (revision 123014)
2262 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/tree-ssa/pr29902.C      (revision 124164)
2263 @@ -1,5 +1,6 @@
2264  /* { dg-do compile { target i?86-*-* } } */
2265  /* { dg-options "-O1 -fprefetch-loop-arrays -march=athlon" } */
2266 +/* { dg-require-effective-target ilp32 } */
2267  
2268  int length1();
2269  int g(int);
2270 @@ -16,4 +17,3 @@
2271        for (int i = 1; i < capacity_; i++){old_storage[i] = 0;}
2272    }
2273  }
2274 -
2275 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/ext/visibility/anon3.C
2276 ===================================================================
2277 --- gcc-4_2-branch/gcc/testsuite/g++.dg/ext/visibility/anon3.C  (revision 0)
2278 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/ext/visibility/anon3.C  (revision 124164)
2279 @@ -0,0 +1,16 @@
2280 +// PR c++/31187
2281 +// Bug: the repeated declaration was confusing the compiler into
2282 +// thinking that foo1 had language internal linkage.
2283 +
2284 +class foo { };
2285 +
2286 +namespace
2287 +{
2288 +  extern foo foo1;
2289 +  foo foo1;
2290 +}
2291 +
2292 +template< foo * >
2293 +class bar { };
2294 +
2295 +bar< &foo1 > bar1;
2296 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/inherit/conv3.C
2297 ===================================================================
2298 --- gcc-4_2-branch/gcc/testsuite/g++.dg/inherit/conv3.C (revision 0)
2299 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/inherit/conv3.C (revision 124164)
2300 @@ -0,0 +1,31 @@
2301 +// PR 31074
2302 +// Bug: The reference cast wasn't finding the desired static_cast followed by
2303 +// const_cast interpretation.
2304 +
2305 +struct Shape
2306 +{
2307 +  Shape() {}
2308 +  virtual ~Shape() {}
2309 +};
2310 +
2311 +struct Loop
2312 +{
2313 +  Loop() {}
2314 +  virtual ~Loop() {}
2315 +  virtual void func() {}
2316 +};
2317 +
2318 +struct Rect :
2319 +  public Shape,
2320 +  public Loop
2321 +{
2322 +  Rect() {}
2323 +  virtual ~Rect() {}
2324 +};
2325 +
2326 +int main ()
2327 +{
2328 +  const Rect* rect = new Rect();
2329 +  Loop &l = ((Loop&)(*rect));
2330 +  return (&l != (const Loop *)rect);
2331 +}
2332 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/gomp/pr25874.C
2333 ===================================================================
2334 --- gcc-4_2-branch/gcc/testsuite/g++.dg/gomp/pr25874.C  (revision 123014)
2335 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/gomp/pr25874.C  (revision 124164)
2336 @@ -1,3 +1,5 @@
2337 +// { dg-options "-O -fopenmp" }
2338 +
2339  int foo();
2340  
2341  struct wigner_d
2342 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/opt/pr30590.C
2343 ===================================================================
2344 --- gcc-4_2-branch/gcc/testsuite/g++.dg/opt/pr30590.C   (revision 0)
2345 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/opt/pr30590.C   (revision 124164)
2346 @@ -0,0 +1,40 @@
2347 +/* { dg-do run } */
2348 +/* { dg-options "-O" } */
2349 +struct test
2350 +{
2351 +  int type;
2352 +  char buffer[4242]; /* should trigger pass-by-reference */
2353 +};
2354 +
2355 +int flag = 0;
2356 +
2357 +struct test
2358 +reset (void)
2359 +{
2360 +  struct test retval;
2361 +  retval.type = 1;
2362 +  return retval;
2363 +}
2364 +
2365 +struct test
2366 +test (void)
2367 +{
2368 +  struct test result;
2369 +  result.type = 0;
2370 +
2371 +  for (int i = 0; i < 2; ++i)
2372 +    {
2373 +      struct test candidate = reset ();
2374 +      if (flag)
2375 +        result = candidate;
2376 +    }
2377 +
2378 +  return result;
2379 +}
2380 +
2381 +int
2382 +main (void)
2383 +{
2384 +  struct test result = test ();
2385 +  return result.type;
2386 +}
2387 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/init/const5.C
2388 ===================================================================
2389 --- gcc-4_2-branch/gcc/testsuite/g++.dg/init/const5.C   (revision 0)
2390 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/init/const5.C   (revision 124164)
2391 @@ -0,0 +1,11 @@
2392 +// PR c++/31449
2393 +
2394 +class Foo {};
2395 +class Bar : public Foo {};
2396 +static const Foo *foo = 0;
2397 +
2398 +static Bar *bar = static_cast<const Bar*>(foo); // { dg-error "conversion" }
2399 +
2400 +void func(const Foo *foo) {
2401 +  Bar *bar = static_cast<const Bar*>(foo);  // { dg-error "conversion" }
2402 +}
2403 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/warn/pragma-system_header3.C
2404 ===================================================================
2405 --- gcc-4_2-branch/gcc/testsuite/g++.dg/warn/pragma-system_header3.C    (revision 0)
2406 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/warn/pragma-system_header3.C    (revision 124164)
2407 @@ -0,0 +1,10 @@
2408 +// PR c++/30500
2409 +// { dg-options "-Wcast-align" }
2410 +
2411 +#include "pragma-system_header3.h"
2412 +
2413 +void f()
2414 +{
2415 +  g<int>();
2416 +  h<int>();
2417 +}
2418 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/warn/pragma-system_header3.h
2419 ===================================================================
2420 --- gcc-4_2-branch/gcc/testsuite/g++.dg/warn/pragma-system_header3.h    (revision 0)
2421 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/warn/pragma-system_header3.h    (revision 124164)
2422 @@ -0,0 +1,7 @@
2423 +#pragma GCC system_header
2424 +
2425 +template <typename T>
2426 +  int* g() { static char c; return reinterpret_cast<int*>(&c); }
2427 +
2428 +template <typename T>
2429 +  T* h() { static char c; return reinterpret_cast<T*>(&c); }
2430 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/parse/cond3.C
2431 ===================================================================
2432 --- gcc-4_2-branch/gcc/testsuite/g++.dg/parse/cond3.C   (revision 0)
2433 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/parse/cond3.C   (revision 124164)
2434 @@ -0,0 +1,15 @@
2435 +// PR c++/30847
2436 +// { dg-do compile }
2437 +// { dg-options "" }
2438 +
2439 +int j, k, l;
2440 +extern void baz ();
2441 +
2442 +void
2443 +foo (int i)
2444 +{
2445 +  (i ? j : k) = ({ l++; (void) l; });  // { dg-error "void value not ignored" }
2446 +  (i ? j : k) += ({ l++; (void) l; }); // { dg-error "void value not ignored" }
2447 +  (i ? j : k) = baz ();                        // { dg-error "void value not ignored" }
2448 +  (i ? j : k) *= baz ();               // { dg-error "void value not ignored" }
2449 +}
2450 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/parse/tmpl-outside1.C
2451 ===================================================================
2452 --- gcc-4_2-branch/gcc/testsuite/g++.dg/parse/tmpl-outside1.C   (revision 123014)
2453 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/parse/tmpl-outside1.C   (revision 124164)
2454 @@ -7,5 +7,4 @@
2455     template <int i> struct Y {};
2456  };
2457  
2458 -typedef X::template Y<0> y; // { dg-error "template" }
2459 -// { dg-bogus "with no type" "" { xfail *-*-* } 10 }
2460 +typedef X::template Y<0> y; // { dg-error "template|invalid" }
2461 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/template/error24.C
2462 ===================================================================
2463 --- gcc-4_2-branch/gcc/testsuite/g++.dg/template/error24.C      (revision 0)
2464 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/template/error24.C      (revision 124164)
2465 @@ -0,0 +1,8 @@
2466 +// PR c++/30863
2467 +
2468 +template <typename T>
2469 +struct s {};
2470 +
2471 +void f() {
2472 +  unsigned s<int> x; // { dg-error "invalid" }
2473 +}
2474 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/template/init7.C
2475 ===================================================================
2476 --- gcc-4_2-branch/gcc/testsuite/g++.dg/template/init7.C        (revision 0)
2477 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/template/init7.C        (revision 124164)
2478 @@ -0,0 +1,9 @@
2479 +/* PR c++/31517. This used to ICE.  */
2480 +/* { dg-do "compile" } */
2481 +
2482 +template<typename> struct A
2483 +{
2484 +  static const int i=0;
2485 +};
2486 +
2487 +template<typename T> const int A<T>::i = 0=0; /* { dg-error "duplicate initialization" } */
2488 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/expr/bitfield7.C
2489 ===================================================================
2490 --- gcc-4_2-branch/gcc/testsuite/g++.dg/expr/bitfield7.C        (revision 0)
2491 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/expr/bitfield7.C        (revision 124164)
2492 @@ -0,0 +1,8 @@
2493 +// PR c++/31273
2494 +
2495 +enum E { e };
2496 +struct S {
2497 +  E v:5;
2498 +};
2499 +S s;
2500 +int main() { if (!s.v) return 0; }
2501 Index: gcc-4_2-branch/gcc/testsuite/g++.dg/expr/bitfield8.C
2502 ===================================================================
2503 --- gcc-4_2-branch/gcc/testsuite/g++.dg/expr/bitfield8.C        (revision 0)
2504 +++ gcc-4_2-branch/gcc/testsuite/g++.dg/expr/bitfield8.C        (revision 124164)
2505 @@ -0,0 +1,24 @@
2506 +// PR c++/31513
2507 +// { dg-do run }
2508 +
2509 +extern "C" void abort();
2510 +
2511 +struct tree_type {
2512 +  unsigned int precision : 9;
2513 +};
2514 +
2515 +void bork(unsigned int i) {
2516 +  if (i != 7)
2517 +    abort();
2518 +}
2519 +
2520 +void foo(struct tree_type *t)
2521 +{
2522 +  bork(t->precision);
2523 +}
2524 +
2525 +int main() {
2526 +  tree_type t;
2527 +  t.precision = 7;
2528 +  foo(&t);
2529 +}
2530 Index: gcc-4_2-branch/gcc/testsuite/gfortran.dg/direct_io_6.f90
2531 ===================================================================
2532 --- gcc-4_2-branch/gcc/testsuite/gfortran.dg/direct_io_6.f90    (revision 0)
2533 +++ gcc-4_2-branch/gcc/testsuite/gfortran.dg/direct_io_6.f90    (revision 124164)
2534 @@ -0,0 +1,16 @@
2535 +! { dg-do run }
2536 +! pr31366 last record truncated for read after short write, direct access file.
2537 +! test case derived from pr, submitted by jerry delisle  <jvdelisle@gcc.gnu.org
2538 +      program test
2539 +      character(len=8) :: as_written, as_read
2540 +      character(1) :: byte
2541 +      as_written = "12345678"
2542 +      open (76, access="direct", recl=12, status="scratch")
2543 +      write(76, rec=1) as_written
2544 +      write(76, rec=2) as_written
2545 +      read(76, rec=1) as_read, byte, byte, byte, byte
2546 +      read(76, rec=2, err=3) as_read, byte, byte, byte, byte
2547 +      stop
2548 +  3   call abort()
2549 +      end program test
2550 +
2551 Index: gcc-4_2-branch/gcc/testsuite/objc/execute/exceptions/pr31281.m
2552 ===================================================================
2553 --- gcc-4_2-branch/gcc/testsuite/objc/execute/exceptions/pr31281.m      (revision 0)
2554 +++ gcc-4_2-branch/gcc/testsuite/objc/execute/exceptions/pr31281.m      (revision 124164)
2555 @@ -0,0 +1,27 @@
2556 +/* From PR31281.  */
2557 +extern void abort (void);
2558 +int __attribute__((noinline))
2559 +f(unsigned int i)
2560 +{
2561 +  int j, k;
2562 +  @try { } @catch(id) { return 13; }
2563 +  for (j=0; j<i; j++)
2564 +    for (k=0; k<i; k++)
2565 +      {
2566 +        @try {
2567 +          if (i)
2568 +            break;
2569 +        } @catch(id) { }
2570 +        return 9;
2571 +      }
2572 +  return 0;
2573 +}
2574 +
2575 +
2576 +int
2577 +main()
2578 +{
2579 +  if (f(1))
2580 +    abort ();
2581 +  return 0 ;
2582 +}
2583 Index: gcc-4_2-branch/gcc/cp/typeck.c
2584 ===================================================================
2585 --- gcc-4_2-branch/gcc/cp/typeck.c      (revision 123014)
2586 +++ gcc-4_2-branch/gcc/cp/typeck.c      (revision 124164)
2587 @@ -5614,6 +5614,12 @@
2588         tree cond;
2589         tree preeval = NULL_TREE;
2590  
2591 +       if (VOID_TYPE_P (TREE_TYPE (rhs)))
2592 +         {
2593 +           error ("void value not ignored as it ought to be");
2594 +           return error_mark_node;
2595 +         }
2596 +
2597         rhs = stabilize_expr (rhs, &preeval);
2598  
2599         /* Check this here to avoid odd errors when trying to convert
2600 @@ -6795,6 +6801,16 @@
2601    return TYPE_QUALS (type);
2602  }
2603  
2604 +/* Returns nonzero if the TYPE is const from a C++ perspective: look inside
2605 +   arrays.  */
2606 +
2607 +bool
2608 +cp_type_readonly (tree type)
2609 +{
2610 +  type = strip_array_types (type);
2611 +  return TYPE_READONLY (type);
2612 +}
2613 +
2614  /* Returns nonzero if the TYPE contains a mutable member.  */
2615  
2616  bool
2617 Index: gcc-4_2-branch/gcc/cp/class.c
2618 ===================================================================
2619 --- gcc-4_2-branch/gcc/cp/class.c       (revision 123014)
2620 +++ gcc-4_2-branch/gcc/cp/class.c       (revision 124164)
2621 @@ -302,7 +302,18 @@
2622          field, because other parts of the compiler know that such
2623          expressions are always non-NULL.  */
2624        if (!virtual_access && integer_zerop (offset))
2625 -       return build_nop (build_pointer_type (target_type), expr);
2626 +       {
2627 +         tree class_type;
2628 +         /* TARGET_TYPE has been extracted from BINFO, and, is
2629 +            therefore always cv-unqualified.  Extract the
2630 +            cv-qualifiers from EXPR so that the expression returned
2631 +            matches the input.  */
2632 +         class_type = TREE_TYPE (TREE_TYPE (expr));
2633 +         target_type
2634 +           = cp_build_qualified_type (target_type,
2635 +                                      cp_type_quals (class_type));
2636 +         return build_nop (build_pointer_type (target_type), expr);
2637 +       }
2638        null_test = error_mark_node;
2639      }
2640  
2641 @@ -7101,7 +7112,13 @@
2642  
2643        /* Figure out the position to which the VPTR should point.  */
2644        vtbl = TREE_PURPOSE (l);
2645 -      vtbl = build1 (ADDR_EXPR, vtbl_ptr_type_node, vtbl);
2646 +      vtbl = build_address (vtbl);
2647 +      /* ??? We should call fold_convert to convert the address to
2648 +        vtbl_ptr_type_node, which is the type of elements in the
2649 +        vtable.  However, the resulting NOP_EXPRs confuse other parts
2650 +        of the C++ front end.  */
2651 +      gcc_assert (TREE_CODE (vtbl) == ADDR_EXPR);
2652 +      TREE_TYPE (vtbl) = vtbl_ptr_type_node;
2653        index = size_binop (PLUS_EXPR,
2654                           size_int (non_fn_entries),
2655                           size_int (list_length (TREE_VALUE (l))));
2656 Index: gcc-4_2-branch/gcc/cp/decl.c
2657 ===================================================================
2658 --- gcc-4_2-branch/gcc/cp/decl.c        (revision 123014)
2659 +++ gcc-4_2-branch/gcc/cp/decl.c        (revision 124164)
2660 @@ -3815,6 +3815,7 @@
2661    tree decl;
2662    tree type, tem;
2663    tree context;
2664 +  bool was_public;
2665  
2666    *pushed_scope_p = NULL_TREE;
2667  
2668 @@ -3969,6 +3970,8 @@
2669                  decl);
2670      }
2671  
2672 +  was_public = TREE_PUBLIC (decl);
2673 +
2674    /* Enter this declaration into the symbol table.  */
2675    tem = maybe_push_decl (decl);
2676  
2677 @@ -3989,6 +3992,17 @@
2678        && !have_global_bss_p ())
2679      DECL_COMMON (tem) = 1;
2680  
2681 +  if (TREE_CODE (tem) == VAR_DECL
2682 +      && DECL_NAMESPACE_SCOPE_P (tem) && !TREE_PUBLIC (tem) && !was_public
2683 +      && !DECL_THIS_STATIC (tem) && !DECL_ARTIFICIAL (tem))
2684 +    {
2685 +      /* This is a const variable with implicit 'static'.  Set
2686 +        DECL_THIS_STATIC so we can tell it from variables that are
2687 +        !TREE_PUBLIC because of the anonymous namespace.  */
2688 +      gcc_assert (cp_type_readonly (TREE_TYPE (tem)));
2689 +      DECL_THIS_STATIC (tem) = 1;
2690 +    }
2691 +
2692    if (!processing_template_decl && TREE_CODE (tem) == VAR_DECL)
2693      start_decl_1 (tem, initialized);
2694  
2695 @@ -5301,14 +5315,6 @@
2696         {
2697           layout_var_decl (decl);
2698           maybe_commonize_var (decl);
2699 -         if (DECL_NAMESPACE_SCOPE_P (decl) && !TREE_PUBLIC (decl)
2700 -             && !DECL_THIS_STATIC (decl) && !DECL_ARTIFICIAL (decl))
2701 -           {
2702 -             /* This is a const variable with implicit 'static'.  Set
2703 -                DECL_THIS_STATIC so we can tell it from variables that are
2704 -                !TREE_PUBLIC because of the anonymous namespace.  */
2705 -             DECL_THIS_STATIC (decl) = 1;
2706 -           }
2707         }
2708  
2709        make_rtl_for_nonlocal_decl (decl, init, asmspec);
2710 Index: gcc-4_2-branch/gcc/cp/call.c
2711 ===================================================================
2712 --- gcc-4_2-branch/gcc/cp/call.c        (revision 123014)
2713 +++ gcc-4_2-branch/gcc/cp/call.c        (revision 124164)
2714 @@ -171,7 +171,7 @@
2715         (struct z_candidate **, tree, tree, tree, tree, tree, int);
2716  static conversion *implicit_conversion (tree, tree, tree, bool, int);
2717  static conversion *standard_conversion (tree, tree, tree, bool, int);
2718 -static conversion *reference_binding (tree, tree, tree, int);
2719 +static conversion *reference_binding (tree, tree, tree, bool, int);
2720  static conversion *build_conv (conversion_kind, tree, conversion *);
2721  static bool is_subseq (conversion *, conversion *);
2722  static tree maybe_handle_ref_bind (conversion **);
2723 @@ -613,18 +613,12 @@
2724    tcode = TREE_CODE (to);
2725  
2726    conv = build_identity_conv (from, expr);
2727 -  if (fcode == FUNCTION_TYPE)
2728 +  if (fcode == FUNCTION_TYPE || fcode == ARRAY_TYPE)
2729      {
2730 -      from = build_pointer_type (from);
2731 +      from = type_decays_to (from);
2732        fcode = TREE_CODE (from);
2733        conv = build_conv (ck_lvalue, from, conv);
2734      }
2735 -  else if (fcode == ARRAY_TYPE)
2736 -    {
2737 -      from = build_pointer_type (TREE_TYPE (from));
2738 -      fcode = TREE_CODE (from);
2739 -      conv = build_conv (ck_lvalue, from, conv);
2740 -    }
2741    else if (fromref || (expr && lvalue_p (expr)))
2742      {
2743        if (expr)
2744 @@ -632,7 +626,10 @@
2745           tree bitfield_type;
2746           bitfield_type = is_bitfield_expr_with_lowered_type (expr);
2747           if (bitfield_type)
2748 -           from = strip_top_quals (bitfield_type);
2749 +           {
2750 +             from = strip_top_quals (bitfield_type);
2751 +             fcode = TREE_CODE (from);
2752 +           }
2753         }
2754        conv = build_conv (ck_rvalue, from, conv);
2755      }
2756 @@ -1085,10 +1082,11 @@
2757     purposes of reference binding.  For lvalue binding, either pass a
2758     reference type to FROM or an lvalue expression to EXPR.  If the
2759     reference will be bound to a temporary, NEED_TEMPORARY_P is set for
2760 -   the conversion returned.  */
2761 +   the conversion returned.  If C_CAST_P is true, this
2762 +   conversion is coming from a C-style cast.  */
2763  
2764  static conversion *
2765 -reference_binding (tree rto, tree rfrom, tree expr, int flags)
2766 +reference_binding (tree rto, tree rfrom, tree expr, bool c_cast_p, int flags)
2767  {
2768    conversion *conv = NULL;
2769    tree to = TREE_TYPE (rto);
2770 @@ -1118,6 +1116,11 @@
2771       reference compatible.  We have do do this after stripping
2772       references from FROM.  */
2773    related_p = reference_related_p (to, from);
2774 +  /* If this is a C cast, first convert to an appropriately qualified
2775 +     type, so that we can later do a const_cast to the desired type.  */
2776 +  if (related_p && c_cast_p
2777 +      && !at_least_as_qualified_p (to, from))
2778 +    to = build_qualified_type (to, cp_type_quals (from));
2779    compatible_p = reference_compatible_p (to, from);
2780  
2781    if (lvalue_p && compatible_p)
2782 @@ -1227,7 +1230,7 @@
2783    if (related_p && !at_least_as_qualified_p (to, from))
2784      return NULL;
2785  
2786 -  conv = implicit_conversion (to, from, expr, /*c_cast_p=*/false,
2787 +  conv = implicit_conversion (to, from, expr, c_cast_p,
2788                               flags);
2789    if (!conv)
2790      return NULL;
2791 @@ -1257,7 +1260,7 @@
2792      return NULL;
2793  
2794    if (TREE_CODE (to) == REFERENCE_TYPE)
2795 -    conv = reference_binding (to, from, expr, flags);
2796 +    conv = reference_binding (to, from, expr, c_cast_p, flags);
2797    else
2798      conv = standard_conversion (to, from, expr, c_cast_p, flags);
2799  
2800 @@ -4655,6 +4658,7 @@
2801  tree
2802  convert_for_arg_passing (tree type, tree val)
2803  {
2804 +  val = convert_bitfield_to_declared_type (val);
2805    if (val == error_mark_node)
2806      ;
2807    /* Pass classes with copy ctors by invisible reference.  */
2808 @@ -6564,7 +6568,8 @@
2809    /* Get the high-water mark for the CONVERSION_OBSTACK.  */
2810    p = conversion_obstack_alloc (0);
2811  
2812 -  conv = reference_binding (type, TREE_TYPE (expr), expr, LOOKUP_NORMAL);
2813 +  conv = reference_binding (type, TREE_TYPE (expr), expr, /*c_cast_p=*/false,
2814 +                           LOOKUP_NORMAL);
2815    if (!conv || conv->bad_p)
2816      {
2817        if (!(TYPE_QUALS (TREE_TYPE (type)) & TYPE_QUAL_CONST)
2818 Index: gcc-4_2-branch/gcc/cp/cp-tree.h
2819 ===================================================================
2820 --- gcc-4_2-branch/gcc/cp/cp-tree.h     (revision 123014)
2821 +++ gcc-4_2-branch/gcc/cp/cp-tree.h     (revision 124164)
2822 @@ -4471,6 +4471,7 @@
2823  extern int ptr_reasonably_similar              (tree, tree);
2824  extern tree build_ptrmemfunc                   (tree, tree, int, bool);
2825  extern int cp_type_quals                       (tree);
2826 +extern bool cp_type_readonly                   (tree);
2827  extern bool cp_has_mutable_p                   (tree);
2828  extern bool at_least_as_qualified_p            (tree, tree);
2829  extern void cp_apply_type_quals_to_decl                (int, tree);
2830 Index: gcc-4_2-branch/gcc/cp/ChangeLog
2831 ===================================================================
2832 --- gcc-4_2-branch/gcc/cp/ChangeLog     (revision 123014)
2833 +++ gcc-4_2-branch/gcc/cp/ChangeLog     (revision 124164)
2834 @@ -1,3 +1,70 @@
2835 +2007-04-24  Paolo Carlini  <pcarlini@suse.de>
2836 +
2837 +       PR c++/30500
2838 +       * pt.c (instantiate_decl): Set in_system_header.
2839 +
2840 +2007-04-17  Simon Martin  <simartin@users.sourceforge.net>
2841 +
2842 +       PR c++/31517
2843 +       * pt.c (value_dependent_expression_p): Handle MODOP_EXPRs.
2844 +
2845 +2007-04-16  Mark Mitchell  <mark@codesourcery.com>
2846 +
2847 +       PR c++/31513
2848 +       * call.c (convert_for_arg_passing): Convert bitfields to their
2849 +       declared types.
2850 +
2851 +2007-04-13  Jason Merrill  <jason@redhat.com>
2852 +
2853 +       PR c++/31074
2854 +       * call.c (reference_binding): Add c_cast_p parm.  If true,
2855 +       add quals to TO as needed to make it reference-compatible.
2856 +
2857 +2007-04-10  Mike Stump  <mrs@apple.com>
2858 +
2859 +       * class.c (dfs_accumulate_vtbl_inits): Slam the vtbl type back to
2860 +       vtbl_ptr_type_node to ensure the mode is correct.
2861 +
2862 +2007-04-09  Mark Mitchell  <mark@codesourcery.com>
2863 +
2864 +       PR c++/31449
2865 +       * class.c (build_base_path): Ensure that the converted pointer has
2866 +       the same cv-qualification as the input.
2867 +
2868 +2007-04-03  Jakub Jelinek  <jakub@redhat.com>
2869 +
2870 +       PR c++/30847
2871 +       * typeck.c (build_modify_expr): For COND_EXPR on LHS, if RHS has void
2872 +       type issue error and return early.
2873 +
2874 +2007-03-30  Jason Merrill  <jason@redhat.com>
2875 +
2876 +       PR c++/31187
2877 +       * typeck.c (cp_type_readonly): New fn.
2878 +       * cp-tree.h: Declare it.
2879 +       * decl.c (start_decl): Set implicit DECL_THIS_STATIC here.
2880 +       (cp_finish_decl): Not here.
2881 +
2882 +2007-03-31  Diego Novillo  <dnovillo@redhat.com>
2883 +           Mark Mitchell  <mark@codesourcery.com>
2884 +
2885 +       PR 29585
2886 +       * class.c (dfs_accumulate_vtbl_inits): Use build_address
2887 +       to build the vtbl entry.
2888 +
2889 +2007-03-22  Mark Mitchell  <mark@codesourcery.com>
2890 +
2891 +       PR c++/30863
2892 +       * parser.c (cp_parser_parse_and_diagnose_invalid_type_name): Do
2893 +       not consume tokens when failing.
2894 +
2895 +2007-03-22  Jim Wilson  <wilson@specifix.com>
2896 +           Mark Mitchell  <mark@codesourcery.com>
2897 +
2898 +       PR c++/31273
2899 +       * call.c (standard_conversion): Use type_decays_to.  Keep FCODE
2900 +       consistent with FROM.
2901 +
2902  2007-03-14  Andrew Pinski  <andrew_pinski@playstation.sony.com>
2903  
2904         PR c++/31165
2905 Index: gcc-4_2-branch/gcc/cp/pt.c
2906 ===================================================================
2907 --- gcc-4_2-branch/gcc/cp/pt.c  (revision 123014)
2908 +++ gcc-4_2-branch/gcc/cp/pt.c  (revision 124164)
2909 @@ -12034,6 +12034,7 @@
2910    bool pattern_defined;
2911    int need_push;
2912    location_t saved_loc = input_location;
2913 +  int saved_in_system_header = in_system_header;
2914    bool external_p;
2915  
2916    /* This function should only be used to instantiate templates for
2917 @@ -12116,6 +12117,7 @@
2918      mark_definable (d);
2919  
2920    input_location = DECL_SOURCE_LOCATION (d);
2921 +  in_system_header = DECL_IN_SYSTEM_HEADER (d);
2922  
2923    /* If D is a member of an explicitly instantiated class template,
2924       and no definition is available, treat it like an implicit
2925 @@ -12349,6 +12351,7 @@
2926  
2927  out:
2928    input_location = saved_loc;
2929 +  in_system_header = saved_in_system_header;
2930    pop_deferring_access_checks ();
2931    pop_tinst_level ();
2932  
2933 @@ -12924,6 +12927,10 @@
2934          such calls are value-dependent.  */
2935        return true;
2936  
2937 +    case MODOP_EXPR:
2938 +      return ((value_dependent_expression_p (TREE_OPERAND (expression, 0)))
2939 +             || (value_dependent_expression_p (TREE_OPERAND (expression, 2))));
2940 +
2941      default:
2942        /* A constant expression is value-dependent if any subexpression is
2943          value-dependent.  */
2944 Index: gcc-4_2-branch/gcc/cp/parser.c
2945 ===================================================================
2946 --- gcc-4_2-branch/gcc/cp/parser.c      (revision 123014)
2947 +++ gcc-4_2-branch/gcc/cp/parser.c      (revision 124164)
2948 @@ -2281,12 +2281,13 @@
2949       the scope is dependent, we cannot do much.  */
2950    if (!cp_lexer_next_token_is (parser->lexer, CPP_NAME)
2951        || (parser->scope && TYPE_P (parser->scope)
2952 -         && dependent_type_p (parser->scope)))
2953 +         && dependent_type_p (parser->scope))
2954 +      || TREE_CODE (id) == TYPE_DECL)
2955      {
2956        cp_parser_abort_tentative_parse (parser);
2957        return false;
2958      }
2959 -  if (!cp_parser_parse_definitely (parser) || TREE_CODE (id) == TYPE_DECL)
2960 +  if (!cp_parser_parse_definitely (parser))
2961      return false;
2962  
2963    /* Emit a diagnostic for the invalid type.  */
2964 Index: gcc-4_2-branch/gcc/cse.c
2965 ===================================================================
2966 --- gcc-4_2-branch/gcc/cse.c    (revision 123014)
2967 +++ gcc-4_2-branch/gcc/cse.c    (revision 124164)
2968 @@ -4542,6 +4542,14 @@
2969    op1 = fold_rtx (XEXP (XEXP (SET_SRC (set), 0), 1), insn);
2970  
2971    code = find_comparison_args (code, &op0, &op1, &mode0, &mode1);
2972 +
2973 +  /* If the mode is a MODE_CC mode, we don't know what kinds of things
2974 +     are being compared, so we can't do anything with this
2975 +     comparison.  */
2976 +
2977 +  if (GET_MODE_CLASS (mode0) == MODE_CC)
2978 +    return;
2979 +
2980    if (! cond_known_true)
2981      {
2982        code = reversed_comparison_code_parts (code, op0, op1, insn);
2983 Index: gcc-4_2-branch/gcc/dwarf2out.c
2984 ===================================================================
2985 --- gcc-4_2-branch/gcc/dwarf2out.c      (revision 123014)
2986 +++ gcc-4_2-branch/gcc/dwarf2out.c      (revision 124164)
2987 @@ -10003,12 +10003,24 @@
2988    if (DECL_P (*tp) && ! TREE_PUBLIC (*tp) && ! TREE_USED (*tp)
2989        && ! TREE_ASM_WRITTEN (*tp))
2990      return *tp;
2991 -  else if (DECL_P (*tp) && TREE_CODE (*tp) != FUNCTION_DECL)
2992 +  else if (!flag_unit_at_a_time)
2993 +    return NULL_TREE;
2994 +  else if (!cgraph_global_info_ready
2995 +          && (TREE_CODE (*tp) == VAR_DECL || TREE_CODE (*tp) == FUNCTION_DECL))
2996 +    gcc_unreachable ();
2997 +  else if (DECL_P (*tp) && TREE_CODE (*tp) == VAR_DECL)
2998      {
2999        struct cgraph_varpool_node *node = cgraph_varpool_node (*tp);
3000        if (!node->needed)
3001         return *tp;
3002      }
3003 +   else if (DECL_P (*tp) && TREE_CODE (*tp) == FUNCTION_DECL
3004 +           && (!DECL_EXTERNAL (*tp) || DECL_DECLARED_INLINE_P (*tp)))
3005 +    {
3006 +      struct cgraph_node *node = cgraph_node (*tp);
3007 +      if (!node->output)
3008 +        return *tp;
3009 +    }
3010  
3011    return NULL_TREE;
3012  }
3013 Index: gcc-4_2-branch/gcc/expr.c
3014 ===================================================================
3015 --- gcc-4_2-branch/gcc/expr.c   (revision 123014)
3016 +++ gcc-4_2-branch/gcc/expr.c   (revision 124164)
3017 @@ -8786,8 +8786,15 @@
3018    HOST_WIDE_INT prec = TYPE_PRECISION (type);
3019    if (target && GET_MODE (target) != GET_MODE (exp))
3020      target = 0;
3021 -  if (TYPE_UNSIGNED (type))
3022 +  /* For constant values, reduce using build_int_cst_type. */
3023 +  if (GET_CODE (exp) == CONST_INT)
3024      {
3025 +      HOST_WIDE_INT value = INTVAL (exp);
3026 +      tree t = build_int_cst_type (type, value);
3027 +      return expand_expr (t, target, VOIDmode, EXPAND_NORMAL);
3028 +    }
3029 +  else if (TYPE_UNSIGNED (type))
3030 +    {
3031        rtx mask;
3032        if (prec < HOST_BITS_PER_WIDE_INT)
3033         mask = immed_double_const (((unsigned HOST_WIDE_INT) 1 << prec) - 1, 0,
3034 Index: gcc-4_2-branch/gcc/cfgbuild.c
3035 ===================================================================
3036 --- gcc-4_2-branch/gcc/cfgbuild.c       (revision 123014)
3037 +++ gcc-4_2-branch/gcc/cfgbuild.c       (revision 124164)
3038 @@ -120,6 +120,11 @@
3039               || can_throw_internal (insn));
3040  
3041      case INSN:
3042 +      /* Treat trap instructions like noreturn calls (same provision).  */
3043 +      if (GET_CODE (PATTERN (insn)) == TRAP_IF
3044 +         && XEXP (PATTERN (insn), 0) == const1_rtx)
3045 +       return true;
3046 +
3047        return (flag_non_call_exceptions && can_throw_internal (insn));
3048  
3049      case BARRIER:
3050 Index: gcc-4_2-branch/gcc/opts.c
3051 ===================================================================
3052 --- gcc-4_2-branch/gcc/opts.c   (revision 123014)
3053 +++ gcc-4_2-branch/gcc/opts.c   (revision 124164)
3054 @@ -1010,7 +1010,7 @@
3055        break;
3056  
3057      case OPT_fforce_mem:
3058 -      warning (0, "-f[no-]force-mem is nop and option will be removed in 4.2");
3059 +      warning (0, "-f[no-]force-mem is nop and option will be removed in 4.3");
3060        break;
3061  
3062      case OPT_floop_optimize:
3063 Index: gcc-4_2-branch/gcc/c-decl.c
3064 ===================================================================
3065 --- gcc-4_2-branch/gcc/c-decl.c (revision 123014)
3066 +++ gcc-4_2-branch/gcc/c-decl.c (revision 124164)
3067 @@ -3337,7 +3337,7 @@
3068  void
3069  finish_decl (tree decl, tree init, tree asmspec_tree)
3070  {
3071 -  tree type = TREE_TYPE (decl);
3072 +  tree type;
3073    int was_incomplete = (DECL_SIZE (decl) == 0);
3074    const char *asmspec = 0;
3075  
3076 @@ -3364,6 +3364,8 @@
3077                             || TREE_CODE (decl) == FIELD_DECL))
3078      objc_check_decl (decl);
3079  
3080 +  type = TREE_TYPE (decl);
3081 +
3082    /* Deduce size of array from initialization, if not already known.  */
3083    if (TREE_CODE (type) == ARRAY_TYPE
3084        && TYPE_DOMAIN (type) == 0
3085 Index: gcc-4_2-branch/gcc/fortran/ChangeLog
3086 ===================================================================
3087 --- gcc-4_2-branch/gcc/fortran/ChangeLog        (revision 123014)
3088 +++ gcc-4_2-branch/gcc/fortran/ChangeLog        (revision 124164)
3089 @@ -1,3 +1,20 @@
3090 +2007-04-12  Daniel Franke  <franke.daniel@gmail.com>
3091 +
3092 +       PR fortran/31234
3093 +       * intrinsic.texi (RANDOM_SEED, RANDOM_NUMBER): New.
3094 +
3095 +2007-03-23  Brooks Moses  <brooks.moses@codesourcery.com>
3096 +
3097 +       * invoke.texi: Misc. small typo fixes.
3098 +       (-Wcharacter-truncation): Add.
3099 +       (-Wnonstd-intrinsics): Correct spelling.
3100 +       (-std=): Edit.
3101 +
3102 +2007-03-17  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3103 +
3104 +       PR fortran/31184
3105 +       * invoke.texi: Fix typo.
3106 +
3107  2007-03-14  Jakub Jelinek  <jakub@redhat.com>
3108  
3109         * module.c (mio_typespec): Don't look at ts->cl if not BT_CHARACTER.
3110 Index: gcc-4_2-branch/gcc/fortran/invoke.texi
3111 ===================================================================
3112 --- gcc-4_2-branch/gcc/fortran/invoke.texi      (revision 123014)
3113 +++ gcc-4_2-branch/gcc/fortran/invoke.texi      (revision 124164)
3114 @@ -128,9 +128,9 @@
3115  and Warnings}.
3116  @gccoptlist{-fmax-errors=@var{n} @gol
3117  -fsyntax-only  -pedantic  -pedantic-errors @gol
3118 --w  -Wall  -Waliasing  -Wampersand  -Wconversion  -Wimplicit-interface @gol
3119 --Wtabs -Wnonstd-intrinsics -Wsurprising -Wunderflow @gol
3120 --Wline-truncation -W}
3121 +-w  -Wall  -Waliasing  -Wampersand  -Wcharacter-truncation  -Wconversion @gol
3122 +-Wimplicit-interface  -Wline-truncation  -Wnonstd-intrinsics  -Wsurprising @gol
3123 +-Wno-tabs  -Wunderflow  -W}
3124  
3125  @item Debugging Options
3126  @xref{Debugging Options,,Options for Debugging Your Program or GCC}.
3127 @@ -138,11 +138,12 @@
3128  
3129  @item Directory Options
3130  @xref{Directory Options,,Options for Directory Search}.
3131 -@gccoptlist{-I@var{dir}  -M@var{dir}}
3132 +@gccoptlist{-I@var{dir}  -J@var{dir}  -M@var{dir}}
3133  
3134  @item Runtime Options
3135  @xref{Runtime Options,,Options for influencing runtime behavior}.
3136 -@gccoptlist{-fconvert=@var{conversion} -frecord-marker=@var{length}}
3137 +@gccoptlist{-fconvert=@var{conversion}  -frecord-marker=@var{length} @gol
3138 +-fmax-subrecord-length=@var{length}}
3139  
3140  @item Code Generation Options
3141  @xref{Code Gen Options,,Options for Code Generation Conventions}.
3142 @@ -198,7 +199,7 @@
3143  @command{gfortran} will ignore @option{-Wnonstd-intrinsics}.
3144  
3145  @item -fd-lines-as-code
3146 -@item -fd-lines-as-comment
3147 +@item -fd-lines-as-comments
3148  @cindex @code{-fd-lines-as-code}, option
3149  @cindex option, @code{-fd-lines-as-code}
3150  @cindex @code{-fd-lines-as-comments}, option
3151 @@ -325,12 +326,19 @@
3152  @item -std=@var{std}
3153  @cindex @code{-std=}@var{std} option
3154  @cindex option, @code{-std=}@var{std}
3155 -Conform to the specified standard.  The default value for @var{std} is
3156 -@samp{gnu}; a superset of the Fortran 95 standard which includes all
3157 -of the GNU extensions recommended for use in new code.  The @samp{legacy}
3158 -value also includes obsolete extensions that may be required for old 
3159 -non-standard programs.  Strict conformance to the Fortran 95 and Fortran 2003
3160 -standards is specified by @samp{f95} and @samp{f2003}, respectively.
3161 +Specify the standard to which the program is expected to conform, which
3162 +may be one of @samp{f95}, @samp{f2003}, @samp{gnu}, or @samp{legacy}.
3163 +The default value for @var{std} is @samp{gnu}, which specifies a
3164 +superset of the Fortran 95 standard that includes all of the extensions
3165 +supported by GNU Fortran, although warnings will be given for obsolete
3166 +extensions not recommended for use in new code.  The @samp{legacy} value
3167 +is equivalent but without the warnings for obsolete extensions, and may
3168 +be useful for old non-standard programs.  The @samp{f95} and
3169 +@samp{f2003} values specify strict conformance to the Fortran 95 and
3170 +Fortran 2003 standards, respectively; errors are given for all
3171 +extensions beyond the relevant language standard, and warnings are given
3172 +for the Fortran 77 features that are permitted but obsolescent in later
3173 +standards.
3174  
3175  @end table
3176  
3177 @@ -420,7 +428,7 @@
3178  Enables commonly used warning options pertaining to usage that
3179  we recommend avoiding and that we believe are easy to avoid.
3180  This currently includes @option{-Waliasing},
3181 -@option{-Wampersand}, @option{-Wsurprising}, @option{-Wnonstd-intrinsic},
3182 +@option{-Wampersand}, @option{-Wsurprising}, @option{-Wnonstd-intrinsics},
3183  @option{-Wno-tabs}, and @option{-Wline-truncation}.
3184  
3185  @item -Waliasing
3186 @@ -455,6 +463,11 @@
3187  constant, GNU Fortran assumes continuation at the first non-comment,
3188  non-whitespace character after the ampersand that initiated the continuation.
3189  
3190 +@item -Wcharacter-truncation
3191 +@cindex @code{-Wcharacter-truncation} option
3192 +@cindex option, @code{-Wcharacter-truncation}
3193 +Warn when a character assignment will truncate the assigned string.
3194 +
3195  @item -Wconversion
3196  @cindex @code{-Wconversion} option
3197  @cindex option, @code{-Wconversion}
3198 @@ -468,11 +481,11 @@
3199  Note this only checks that an explicit interface is present.  It does not
3200  check that the declared interfaces are consistent across program units.
3201  
3202 -@item -Wnonstd-intrinsic
3203 -@cindex @code{-Wnonstd-intrinsic} option
3204 -@cindex option, @code{-Wnonstd-intrinsic}
3205 +@item -Wnonstd-intrinsics
3206 +@cindex @code{-Wnonstd-intrinsics} option
3207 +@cindex option, @code{-Wnonstd-intrinsics}
3208  Warn if the user tries to use an intrinsic that does not belong to the 
3209 -standard the user has chosen via the -std option.
3210 +standard the user has chosen via the @option{-std} option.
3211  
3212  @item -Wsurprising
3213  @cindex @code{-Wsurprising} option
3214 @@ -608,9 +621,11 @@
3215  @item -M@var{dir}
3216  @item -J@var{dir}
3217  @cindex @code{-M}@var{dir} option
3218 -@cindex option, -@code{-M}@var{dir}
3219 +@cindex option, @code{-M}@var{dir}
3220  @cindex @code{-J}@var{dir} option
3221 -@cindex option, -@code{-J}@var{dir}
3222 +@cindex option, @code{-J}@var{dir}
3223 +@cindex paths, search
3224 +@cindex module search path
3225  This option specifies where to put @file{.mod} files for compiled modules.
3226  It is also added to the list of directories to searched by an @code{USE}
3227  statement.
3228 Index: gcc-4_2-branch/gcc/fortran/intrinsic.texi
3229 ===================================================================
3230 --- gcc-4_2-branch/gcc/fortran/intrinsic.texi   (revision 123014)
3231 +++ gcc-4_2-branch/gcc/fortran/intrinsic.texi   (revision 124164)
3232 @@ -7614,10 +7614,11 @@
3233  @cindex @code{RANDOM_NUMBER} intrinsic
3234  @cindex random numbers
3235  
3236 -Intrinsic implemented, documentation pending.
3237 -
3238  @table @asis
3239  @item @emph{Description}:
3240 +Returns a single pseudorandom number or an array of pseudorandom numbers
3241 +from the uniform distribution over the range @math{ 0 \leq x < 1}.
3242 +
3243  @item @emph{Standard}:
3244  F95 and later
3245  
3246 @@ -7625,9 +7626,31 @@
3247  Elemental subroutine
3248  
3249  @item @emph{Syntax}:
3250 +@code{RANDOM_NUMBER(HARVEST)}
3251 +
3252  @item @emph{Arguments}:
3253 -@item @emph{Return value}:
3254 +@multitable @columnfractions .15 .70
3255 +@item @var{HARVEST} @tab Shall be a scalar or an array of type @code{REAL(*)}.
3256 +@end multitable
3257 +
3258  @item @emph{Example}:
3259 +@smallexample
3260 +program test_random_number
3261 +  REAL :: r(5,5)
3262 +  CALL init_random_seed()         ! see example of RANDOM_SEED
3263 +  CALL RANDOM_NUMBER(r)
3264 +end program
3265 +@end smallexample
3266 +
3267 +@item @emph{Note}:
3268 +The implemented random number generator is thread safe if used within
3269 +OpenMP directives, i. e. its state will be consistent while called from
3270 +multiple threads. Please note that the currently implemented KISS generator 
3271 +does not create random numbers in parallel from multiple sources, but in
3272 +sequence from a single source. If your OpenMP-enabled application heavily
3273 +relies on random numbers, you should consider employing a dedicated parallel
3274 +random number generator instead.
3275 +
3276  @item @emph{See also}:
3277  @ref{RANDOM_SEED}
3278  @end table
3279 @@ -7639,10 +7662,15 @@
3280  @cindex @code{RANDOM_SEED} intrinsic
3281  @cindex random numbers
3282  
3283 -Intrinsic implemented, documentation pending.
3284 -
3285  @table @asis
3286  @item @emph{Description}:
3287 +Restarts or queries the state of the pseudorandom number generator used by 
3288 +@code{RANDOM_NUMBER}.
3289 +
3290 +If @code{RANDOM_SEED} is called without arguments, it is initialized to
3291 +a default state. The example below shows how to initialize the random 
3292 +seed based on the system's time.
3293 +
3294  @item @emph{Standard}:
3295  F95 and later
3296  
3297 @@ -7650,9 +7678,41 @@
3298  Subroutine
3299  
3300  @item @emph{Syntax}:
3301 +@code{CALL RANDOM_SEED(SIZE, PUT, GET)}
3302 +
3303  @item @emph{Arguments}:
3304 -@item @emph{Return value}:
3305 +@multitable @columnfractions .15 .70
3306 +@item @var{SIZE} @tab (Optional) Shall be a scalar and of type default 
3307 +@code{INTEGER}, with @code{INTENT(OUT)}. It specifies the minimum size 
3308 +of the arrays used with the @var{PUT} and @var{GET} arguments.
3309 +@item @var{PUT}  @tab (Optional) Shall be an array of type default 
3310 +@code{INTEGER} and rank one. It is @code{INTENT(IN)} and the size of 
3311 +the array must be larger than or equal to the number returned by the 
3312 +@var{SIZE} argument.
3313 +@item @var{GET}  @tab (Optional) Shall be an array of type default 
3314 +@code{INTEGER} and rank one. It is @code{INTENT(OUT)} and the size 
3315 +of the array must be larger than or equal to the number returned by 
3316 +the @var{SIZE} argument.
3317 +@end multitable
3318 +
3319  @item @emph{Example}:
3320 +@smallexample
3321 +SUBROUTINE init_random_seed()
3322 +  INTEGER :: i, n, clock
3323 +  INTEGER, DIMENSION(:), ALLOCATABLE :: seed
3324 +
3325 +  CALL RANDOM_SEED(size = n)
3326 +  ALLOCATE(seed(n))
3327 +
3328 +  CALL SYSTEM_CLOCK(COUNT=clock)
3329 +
3330 +  seed = clock + 37 * (/ (i - 1, i = 1, n) /)
3331 +  CALL RANDOM_SEED(PUT = seed)
3332 +
3333 +  DEALLOCATE(seed)
3334 +END SUBROUTINE
3335 +@end smallexample
3336 +
3337  @item @emph{See also}:
3338  @ref{RANDOM_NUMBER}
3339  @end table
3340 Index: gcc-4_2-branch/gcc/c.opt
3341 ===================================================================
3342 --- gcc-4_2-branch/gcc/c.opt    (revision 123014)
3343 +++ gcc-4_2-branch/gcc/c.opt    (revision 124164)
3344 @@ -133,7 +133,7 @@
3345  Warn about casting functions to incompatible types
3346  
3347  Wc++-compat
3348 -C Var(warn_cxx_compat)
3349 +C ObjC Var(warn_cxx_compat)
3350  Warn about C constructs that are not in the common subset of C and C++
3351  
3352  
3353 @@ -170,7 +170,7 @@
3354  Warn about deprecated compiler features
3355  
3356  Wdiv-by-zero
3357 -C ObjC C++ Var(warn_div_by_zero) Init(1)
3358 +C ObjC C++ ObjC++ Var(warn_div_by_zero) Init(1)
3359  Warn about compile-time integer division by zero
3360  
3361  Weffc++
3362 @@ -532,7 +532,7 @@
3363  Generate code for GNU runtime environment
3364  
3365  fgnu89-inline
3366 -C Var(flag_gnu89_inline) Init(-1)
3367 +C ObjC Var(flag_gnu89_inline) Init(-1)
3368  Use traditional GNU semantics for inline functions
3369  
3370  fguiding-decls
3371 @@ -565,7 +565,7 @@
3372  Emit implicit instantiations of templates
3373  
3374  ffriend-injection
3375 -C++ Var(flag_friend_injection)
3376 +C++ ObjC++ Var(flag_friend_injection)
3377  Inject friend functions into enclosing namespace
3378  
3379  flabels-ok
3380 Index: gcc-4_2-branch/gcc/c-typeck.c
3381 ===================================================================
3382 --- gcc-4_2-branch/gcc/c-typeck.c       (revision 123014)
3383 +++ gcc-4_2-branch/gcc/c-typeck.c       (revision 124164)
3384 @@ -3940,10 +3940,16 @@
3385                || coder == BOOLEAN_TYPE))
3386      return convert_and_check (type, rhs);
3387  
3388 +  /* Aggregates in different TUs might need conversion.  */
3389 +  if ((codel == RECORD_TYPE || codel == UNION_TYPE)
3390 +      && codel == coder
3391 +      && comptypes (type, rhstype))
3392 +    return convert_and_check (type, rhs);
3393 +
3394    /* Conversion to a transparent union from its member types.
3395       This applies only to function arguments.  */
3396 -  else if (codel == UNION_TYPE && TYPE_TRANSPARENT_UNION (type)
3397 -          && (errtype == ic_argpass || errtype == ic_argpass_nonproto))
3398 +  if (codel == UNION_TYPE && TYPE_TRANSPARENT_UNION (type)
3399 +      && (errtype == ic_argpass || errtype == ic_argpass_nonproto))
3400      {
3401        tree memb, marginal_memb = NULL_TREE;
3402  
3403 Index: gcc-4_2-branch/gcc/expmed.c
3404 ===================================================================
3405 --- gcc-4_2-branch/gcc/expmed.c (revision 123014)
3406 +++ gcc-4_2-branch/gcc/expmed.c (revision 124164)
3407 @@ -4976,17 +4976,17 @@
3408  
3409      case CONST_VECTOR:
3410        {
3411 -       int i, units;
3412 -       rtx elt;
3413 +       int units = CONST_VECTOR_NUNITS (x);
3414 +       tree itype = TREE_TYPE (type);
3415         tree t = NULL_TREE;
3416 +       int i;
3417  
3418 -       units = CONST_VECTOR_NUNITS (x);
3419  
3420         /* Build a tree with vector elements.  */
3421         for (i = units - 1; i >= 0; --i)
3422           {
3423 -           elt = CONST_VECTOR_ELT (x, i);
3424 -           t = tree_cons (NULL_TREE, make_tree (type, elt), t);
3425 +           rtx elt = CONST_VECTOR_ELT (x, i);
3426 +           t = tree_cons (NULL_TREE, make_tree (itype, elt), t);
3427           }
3428  
3429         return build_vector (type, t);
3430 Index: gcc-4_2-branch/gcc/po/ChangeLog
3431 ===================================================================
3432 --- gcc-4_2-branch/gcc/po/ChangeLog     (revision 123014)
3433 +++ gcc-4_2-branch/gcc/po/ChangeLog     (revision 124164)
3434 @@ -1,3 +1,7 @@
3435 +2007-04-21  Joseph S. Myers  <joseph@codesourcery.com>
3436 +
3437 +       * sv.po: Update.
3438 +
3439  2007-03-08  Joseph S. Myers  <joseph@codesourcery.com>
3440  
3441         * sr.po: New.
3442 Index: gcc-4_2-branch/gcc/po/sv.po
3443 ===================================================================
3444 --- gcc-4_2-branch/gcc/po/sv.po (revision 123014)
3445 +++ gcc-4_2-branch/gcc/po/sv.po (revision 124164)
3446 @@ -1,7 +1,7 @@
3447  # Swedish messages for GCC.
3448 -# Copyright Â© 2000, 2005, 2006 Free Software Foundation, Inc.
3449 +# Copyright Â© 2000, 2005, 2006, 2007 Free Software Foundation, Inc.
3450  # Dennis Björklund <db@zigo.dhs.org>, 2000, 2001, 2002.
3451 -# Göran Uddeborg <goeran@uddeborg.se>, 2005, 2006.
3452 +# Göran Uddeborg <goeran@uddeborg.se>, 2005, 2006, 2007.
3453  #
3454  # Remember: GCC team does not want RCS keywords in the header!
3455  #
3456 @@ -10,7 +10,7 @@
3457  "Project-Id-Version: gcc 4.1.1\n"
3458  "Report-Msgid-Bugs-To: http://gcc.gnu.org/bugs.html\n"
3459  "POT-Creation-Date: 2006-05-24 16:19-0700\n"
3460 -"PO-Revision-Date: 2006-12-13 22:05+0100\n"
3461 +"PO-Revision-Date: 2007-04-03 09:58+0200\n"
3462  "Last-Translator: Göran Uddeborg <goeran@uddeborg.se>\n"
3463  "Language-Team: Swedish <tp-sv@listor.tp-sv.se>\n"
3464  "MIME-Version: 1.0\n"
3465 @@ -364,7 +364,7 @@
3466  
3467  #: c-typeck.c:5209
3468  msgid "braces around scalar initializer"
3469 -msgstr "klamrar funt skalär initierare"
3470 +msgstr "klamrar runt skalär initierare"
3471  
3472  #: c-typeck.c:5266
3473  msgid "initialization of flexible array member in a nested context"
3474 @@ -9266,19 +9266,19 @@
3475  
3476  #: java/lang.opt:66
3477  msgid "Warn if a deprecated compiler feature, class, method, or field is used"
3478 -msgstr "Varna om en kompilatorfunktion, klass, metod eller fält som avrÃ¥des ifrÃ¥n används"
3479 +msgstr "Varna för en kompilatorfunktion, klass, metod eller fält som bör undvikas används"
3480  
3481  #: java/lang.opt:70
3482  msgid "Warn if deprecated empty statements are found"
3483 -msgstr "Varna om förÃ¥ldrade tomma satser finns"
3484 +msgstr "Varna för tomma satser som bör undvikas finns"
3485  
3486  #: java/lang.opt:74
3487  msgid "Warn if .class files are out of date"
3488 -msgstr "Varna om .class-filer Ã¤r inaktuella"
3489 +msgstr "Varna för .class-filer Ã¤r inaktuella"
3490  
3491  #: java/lang.opt:78
3492  msgid "Warn if modifiers are specified when not necessary"
3493 -msgstr "Varna om modifierare anges när de inte behövs"
3494 +msgstr "Varna för modifierare anges när de inte behövs"
3495  
3496  #: java/lang.opt:82
3497  msgid "Deprecated; use --classpath instead"
3498 @@ -9370,23 +9370,23 @@
3499  
3500  #: fortran/lang.opt:42
3501  msgid "Warn about possible aliasing of dummy arguments"
3502 -msgstr "Varna om eventuell aliasning av atrappargument"
3503 +msgstr "Varna för eventuell aliasning av atrappargument"
3504  
3505  #: fortran/lang.opt:46
3506  msgid "Warn about missing ampersand in continued character literals"
3507 -msgstr "Varna om saknade ampersander i fortsatta teckenliteraler"
3508 +msgstr "Varna för saknade ampersander i fortsatta teckenliteraler"
3509  
3510  #: fortran/lang.opt:50
3511  msgid "Warn about implicit conversion"
3512 -msgstr "Varna om implicita konverteringar"
3513 +msgstr "Varna för implicita konverteringar"
3514  
3515  #: fortran/lang.opt:54
3516  msgid "Warn about calls with implicit interface"
3517 -msgstr "Varna om anrop med implicit gränssnitt"
3518 +msgstr "Varna för anrop med implicit gränssnitt"
3519  
3520  #: fortran/lang.opt:58
3521  msgid "Warn about truncated source lines"
3522 -msgstr "Varna om avhuggna källkodsrader"
3523 +msgstr "Varna för avhuggna källkodsrader"
3524  
3525  #: fortran/lang.opt:62
3526  msgid "Warn about usage of non-standard intrinsics"
3527 @@ -9394,11 +9394,11 @@
3528  
3529  #: fortran/lang.opt:66
3530  msgid "Warn about \"suspicious\" constructs"
3531 -msgstr "Varna om \"misstänkta\" konstruktioner"
3532 +msgstr "Varna för \"misstänkta\" konstruktioner"
3533  
3534  #: fortran/lang.opt:70
3535  msgid "Warn about underflow of numerical constant expressions"
3536 -msgstr "Varna om underspill i numeriska konstantuttryck"
3537 +msgstr "Varna för underspill i numeriska konstantuttryck"
3538  
3539  #: fortran/lang.opt:74 common.opt:162
3540  msgid "Warn when a label is unused"
3541 @@ -9936,11 +9936,11 @@
3542  
3543  #: config/s390/s390.opt:92
3544  msgid "Warn if a function uses alloca or creates an array with dynamic size"
3545 -msgstr "Varna om en funktion använder alloca eller skapar en vektor med dynamisk storlek"
3546 +msgstr "Varna för en funktion använder alloca eller skapar en vektor med dynamisk storlek"
3547  
3548  #: config/s390/s390.opt:96
3549  msgid "Warn if a single function's framesize exceeds the given framesize"
3550 -msgstr "Varna om en enskild funktions ramstorlek Ã¶verskrider den angivna ramstorleken"
3551 +msgstr "Varna för en enskild funktions ramstorlek Ã¶verskrider den angivna ramstorleken"
3552  
3553  #: config/s390/s390.opt:100
3554  msgid "z/Architecture"
3555 @@ -10690,7 +10690,7 @@
3556  
3557  #: config/rs6000/rs6000.opt:215
3558  msgid "Warn about deprecated 'vector long ...' AltiVec type usage"
3559 -msgstr "Varna för användning av AltiVec-typen \"vector long ...\" som avrÃ¥des frÃ¥n"
3560 +msgstr "Varna för användning av AltiVec-typen \"vector long ...\" som bör undvikas"
3561  
3562  #: config/rs6000/rs6000.opt:219
3563  msgid "Select GPR floating point method"
3564 @@ -12214,7 +12214,7 @@
3565  
3566  #: c.opt:117
3567  msgid "Warn about things that will change when compiling with an ABI-compliant compiler"
3568 -msgstr "Varna om saker som skulle Ã¤ndras vid kompilering med en kompilator som följer ABI"
3569 +msgstr "Varna för saker som skulle Ã¤ndras vid kompilering med en kompilator som följer ABI"
3570  
3571  #: c.opt:121
3572  msgid "Enable most warning messages"
3573 @@ -12226,23 +12226,23 @@
3574  
3575  #: c.opt:129
3576  msgid "Warn about casting functions to incompatible types"
3577 -msgstr "Varna om typkonvertering av funktioner till inkompatibla typer"
3578 +msgstr "Varna för typkonvertering av funktioner till inkompatibla typer"
3579  
3580  #: c.opt:133
3581  msgid "Warn about C constructs that are not in the common subset of C and C++"
3582 -msgstr "Varna om C-konstruktioner som inte Ã¤r i den gemensamma delmängden av C och C++"
3583 +msgstr "Varna för C-konstruktioner som inte Ã¤r i den gemensamma delmängden av C och C++"
3584  
3585  #: c.opt:138
3586  msgid "Warn about casts which discard qualifiers"
3587 -msgstr "Varna om typkonvertering som slänger kvalificerare"
3588 +msgstr "Varna för typkonvertering som slänger kvalificerare"
3589  
3590  #: c.opt:142
3591  msgid "Warn about subscripts whose type is \"char\""
3592 -msgstr "Varna om index vars typ Ã¤r \"char\""
3593 +msgstr "Varna för index vars typ Ã¤r \"char\""
3594  
3595  #: c.opt:146
3596  msgid "Warn about possibly nested block comments, and C++ comments spanning more than one physical line"
3597 -msgstr "Varna om möjliga nästade blockkommentarer, och C++-kommentarer som spänner Ã¶ver mer Ã¤n en fysisk rad"
3598 +msgstr "Varna för möjliga nästade blockkommentarer, och C++-kommentarer som spänner Ã¶ver mer Ã¤n en fysisk rad"
3599  
3600  #: c.opt:150
3601  msgid "Synonym for -Wcomment"
3602 @@ -12250,7 +12250,7 @@
3603  
3604  #: c.opt:154
3605  msgid "Warn about possibly confusing type conversions"
3606 -msgstr "Varna om eventuellt förvirrande typkonverteringar"
3607 +msgstr "Varna för eventuellt förvirrande typkonverteringar"
3608  
3609  #: c.opt:158
3610  msgid "Warn when all constructors and destructors are private"
3611 @@ -12262,19 +12262,19 @@
3612  
3613  #: c.opt:166
3614  msgid "Warn about deprecated compiler features"
3615 -msgstr "Varna om kompilatorfunktioner som undanbedes"
3616 +msgstr "Varna för kompilatorfunktioner bör undvikas"
3617  
3618  #: c.opt:170
3619  msgid "Warn about compile-time integer division by zero"
3620 -msgstr "Varna om heltalsdivision med noll vid kompileringstillfället"
3621 +msgstr "Varna för heltalsdivision med noll vid kompileringstillfället"
3622  
3623  #: c.opt:174
3624  msgid "Warn about violations of Effective C++ style rules"
3625 -msgstr "Varna om brott mot Effective C++ stilregler"
3626 +msgstr "Varna för brott mot stilreglerna i Effective C++"
3627  
3628  #: c.opt:178
3629  msgid "Warn about stray tokens after #elif and #endif"
3630 -msgstr "Varna om vilsekomna symboler efter #elif och #endif"
3631 +msgstr "Varna för vilsekomna symboler efter #elif och #endif"
3632  
3633  #: c.opt:186
3634  msgid "Make implicit function declarations an error"
3635 @@ -12286,35 +12286,35 @@
3636  
3637  #: c.opt:194
3638  msgid "Warn about printf/scanf/strftime/strfmon format string anomalies"
3639 -msgstr "Varna om anomalier i formatsträngar till printf/scanf/strftime/strfmon"
3640 +msgstr "Varna för anomalier i formatsträngar till printf/scanf/strftime/strfmon"
3641  
3642  #: c.opt:198
3643  msgid "Warn if passing too many arguments to a function for its format string"
3644 -msgstr "Varna om för mÃ¥nga argument argument till en funktion för dess formatsträng"
3645 +msgstr "Varna för för mÃ¥nga argument argument till en funktion för dess formatsträng"
3646  
3647  #: c.opt:202
3648  msgid "Warn about format strings that are not literals"
3649 -msgstr "Varna om formatsträngar som inte Ã¤r literaler"
3650 +msgstr "Varna för formatsträngar som inte Ã¤r literaler"
3651  
3652  #: c.opt:206
3653  msgid "Warn about possible security problems with format functions"
3654 -msgstr "Varna om möjliga säkerhetsproblem med formatfunktioner"
3655 +msgstr "Varna för möjliga säkerhetsproblem med formatfunktioner"
3656  
3657  #: c.opt:210
3658  msgid "Warn about strftime formats yielding 2-digit years"
3659 -msgstr "Varna om format till strftime som ger 2-siffrigt Ã¥rtal"
3660 +msgstr "Varna för format till strftime som ger 2-siffrigt Ã¥rtal"
3661  
3662  #: c.opt:214
3663  msgid "Warn about zero-length formats"
3664 -msgstr "Varna om format med längden noll"
3665 +msgstr "Varna för format med längden noll"
3666  
3667  #: c.opt:221
3668  msgid "Warn about variables which are initialized to themselves"
3669 -msgstr "Varna om variabler som intieras till sig själva"
3670 +msgstr "Varna för variabler som intieras till sig själva"
3671  
3672  #: c.opt:228
3673  msgid "Warn about implicit function declarations"
3674 -msgstr "Varna om implicita funktionsdeklarationer"
3675 +msgstr "Varna för implicita funktionsdeklarationer"
3676  
3677  #: c.opt:232
3678  msgid "Warn when a declaration does not specify a type"
3679 @@ -12326,15 +12326,15 @@
3680  
3681  #: c.opt:240
3682  msgid "Warn when there is a cast to a pointer from an integer of a different size"
3683 -msgstr "Varna om typkonverteringar till pekare frÃ¥n ett heltal med annan storlek"
3684 +msgstr "Varna för typkonverteringar till pekare frÃ¥n ett heltal med annan storlek"
3685  
3686  #: c.opt:244
3687  msgid "Warn about invalid uses of the \"offsetof\" macro"
3688 -msgstr "Varna om ogiltiga användningar av makrot \"offsetof\""
3689 +msgstr "Varna för ogiltiga användningar av makrot \"offsetof\""
3690  
3691  #: c.opt:248
3692  msgid "Warn about PCH files that are found but not used"
3693 -msgstr "Varna om PCH-filer som hittas men inte används"
3694 +msgstr "Varna för PCH-filer som hittas men inte används"
3695  
3696  #: c.opt:252
3697  msgid "Do not warn about using \"long long\" when -pedantic"
3698 @@ -12342,31 +12342,31 @@
3699  
3700  #: c.opt:256
3701  msgid "Warn about suspicious declarations of \"main\""
3702 -msgstr "Varna om tveksamma deklarationer av \"main\""
3703 +msgstr "Varna för tveksamma deklarationer av \"main\""
3704  
3705  #: c.opt:260
3706  msgid "Warn about possibly missing braces around initializers"
3707 -msgstr "Varna om eventuellt saknade klamrar runt initierare"
3708 +msgstr "Varna för eventuellt saknade klamrar runt initierare"
3709  
3710  #: c.opt:264
3711  msgid "Warn about global functions without previous declarations"
3712 -msgstr "Varna om globala globala funktioner utan tidigare deklaration"
3713 +msgstr "Varna för globala globala funktioner utan tidigare deklaration"
3714  
3715  #: c.opt:268
3716  msgid "Warn about missing fields in struct initializers"
3717 -msgstr "Varna om saknade fält i postinitierare"
3718 +msgstr "Varna för saknade fält i postinitierare"
3719  
3720  #: c.opt:272
3721  msgid "Warn about functions which might be candidates for format attributes"
3722 -msgstr "Varna om funktioner som kan vara kandidater för formatattribut"
3723 +msgstr "Varna för funktioner som kan vara kandidater för formatattribut"
3724  
3725  #: c.opt:276
3726  msgid "Warn about user-specified include directories that do not exist"
3727 -msgstr "Varna om användarangivna inkluderingskataloger som inte finns"
3728 +msgstr "Varna för användarangivna inkluderingskataloger som inte finns"
3729  
3730  #: c.opt:280
3731  msgid "Warn about global functions without prototypes"
3732 -msgstr "Varna om globala funktioner utan prototyper"
3733 +msgstr "Varna för globala funktioner utan prototyper"
3734  
3735  #: c.opt:284
3736  msgid "Warn about use of multi-character character constants"
3737 @@ -12374,7 +12374,7 @@
3738  
3739  #: c.opt:288
3740  msgid "Warn about \"extern\" declarations not at file scope"
3741 -msgstr "Varna om \"extern\"-deklaration som inte Ã¤r pÃ¥ filnivÃ¥"
3742 +msgstr "Varna för \"extern\"-deklaration som inte Ã¤r pÃ¥ filnivÃ¥"
3743  
3744  #: c.opt:292
3745  msgid "Warn when non-templatized friend functions are declared within a template"
3746 @@ -12382,31 +12382,31 @@
3747  
3748  #: c.opt:296
3749  msgid "Warn about non-virtual destructors"
3750 -msgstr "Varna om ickevirtuella destruerare"
3751 +msgstr "Varna för ickevirtuella destruerare"
3752  
3753  #: c.opt:300
3754  msgid "Warn about NULL being passed to argument slots marked as requiring non-NULL"
3755 -msgstr "Varna om NULL skickas som argument till fack markerde att de kräver icke-NULL"
3756 +msgstr "Varna om NULL skickas som argument som Ã¤r markerade att de kräver icke-NULL"
3757  
3758  #: c.opt:304
3759  msgid "Warn about non-normalised Unicode strings"
3760 -msgstr "Varna om icke normaliserade Unicodesträngar"
3761 +msgstr "Varna för icke normaliserade Unicodesträngar"
3762  
3763  #: c.opt:308
3764  msgid "Warn if a C-style cast is used in a program"
3765 -msgstr "Varna om en typkonvertering i C-stil används i ett program"
3766 +msgstr "Varna för en typkonvertering i C-stil används i ett program"
3767  
3768  #: c.opt:312
3769  msgid "Warn if an old-style parameter definition is used"
3770 -msgstr "Varna om en gammaldags parameterdefinition används"
3771 +msgstr "Varna för en gammaldags parameterdefinition används"
3772  
3773  #: c.opt:316
3774  msgid "Warn about overloaded virtual function names"
3775 -msgstr "Varna om Ã¶verlastade virtuella funktionsnamn"
3776 +msgstr "Varna för Ã¶verlagrade virtuella funktionsnamn"
3777  
3778  #: c.opt:320
3779  msgid "Warn about possibly missing parentheses"
3780 -msgstr "Varna om eventuellt saknade parenteser"
3781 +msgstr "Varna för eventuellt saknade parenteser"
3782  
3783  #: c.opt:324
3784  msgid "Warn when converting the type of pointers to member functions"
3785 @@ -12414,7 +12414,7 @@
3786  
3787  #: c.opt:328
3788  msgid "Warn about function pointer arithmetic"
3789 -msgstr "Varna om aritmetik med funktionspekare"
3790 +msgstr "Varna för aritmetik med funktionspekare"
3791  
3792  #: c.opt:332
3793  msgid "Warn when a pointer is cast to an integer of a different size"
3794 @@ -12422,15 +12422,15 @@
3795  
3796  #: c.opt:336
3797  msgid "Warn about misuses of pragmas"
3798 -msgstr "Varna om missbruk av pragman"
3799 +msgstr "Varna för missbruk av pragman"
3800  
3801  #: c.opt:340
3802  msgid "Warn if inherited methods are unimplemented"
3803 -msgstr "Varna om Ã¤rvda metoder Ã¤r oimplementerade"
3804 +msgstr "Varna för Ã¤rvda metoder Ã¤r oimplementerade"
3805  
3806  #: c.opt:344
3807  msgid "Warn about multiple declarations of the same object"
3808 -msgstr "Varna om multipla deklarationer av samma objekt"
3809 +msgstr "Varna för multipla deklarationer av samma objekt"
3810  
3811  #: c.opt:348
3812  msgid "Warn when the compiler reorders code"
3813 @@ -12442,31 +12442,31 @@
3814  
3815  #: c.opt:356
3816  msgid "Warn if a selector has multiple methods"
3817 -msgstr "Varna om en väljare har multipla metoder"
3818 +msgstr "Varna för en väljare har multipla metoder"
3819  
3820  #: c.opt:360
3821  msgid "Warn about possible violations of sequence point rules"
3822 -msgstr "Varna om möjliga brott mot sekvenspunktregler"
3823 +msgstr "Varna för möjliga brott mot sekvenspunktregler"
3824  
3825  #: c.opt:364
3826  msgid "Warn about signed-unsigned comparisons"
3827 -msgstr "Varna om jämförelser mellan signed/unsigned"
3828 +msgstr "Varna för jämförelser mellan signed/unsigned"
3829  
3830  #: c.opt:368
3831  msgid "Warn when overload promotes from unsigned to signed"
3832 -msgstr "Varna när Ã¶verlastning anpassar frÃ¥n teckenlöst till med tecken"
3833 +msgstr "Varna när Ã¶verlagring anpassar frÃ¥n teckenlöst till med tecken"
3834  
3835  #: c.opt:372
3836  msgid "Warn about uncasted NULL used as sentinel"
3837 -msgstr "Varna om ej typkonverterad NULL används som vaktpost"
3838 +msgstr "Varna för ej typkonverterad NULL används som vaktpost"
3839  
3840  #: c.opt:376
3841  msgid "Warn about unprototyped function declarations"
3842 -msgstr "Varna om funktionsdeklarationer utan prototyp"
3843 +msgstr "Varna för funktionsdeklarationer utan prototyp"
3844  
3845  #: c.opt:380
3846  msgid "Warn if type signatures of candidate methods do not match exactly"
3847 -msgstr "Varna om typsignaturer till kandidatmetoder inte stämmer exakt"
3848 +msgstr "Varna för typsignaturer till kandidatmetoder inte stämmer exakt"
3849  
3850  #: c.opt:384
3851  msgid "Warn when synthesis behavior differs from Cfront"
3852 @@ -12478,27 +12478,27 @@
3853  
3854  #: c.opt:392
3855  msgid "Warn about features not present in traditional C"
3856 -msgstr "Varna om funktioner som inte finns i traditionell C"
3857 +msgstr "Varna för funktioner som inte finns i traditionell C"
3858  
3859  #: c.opt:396
3860  msgid "Warn if trigraphs are encountered that might affect the meaning of the program"
3861 -msgstr "Varna om trigrafer upptäcks som kan pÃ¥verka betydelsen av programmet"
3862 +msgstr "Varna för trigrafer upptäcks som kan pÃ¥verka betydelsen av programmet"
3863  
3864  #: c.opt:400
3865  msgid "Warn about @selector()s without previously declared methods"
3866 -msgstr "Varna om @selector()er utan tidigare deklarerade metoder"
3867 +msgstr "Varna för @selector()er utan tidigare deklarerade metoder"
3868  
3869  #: c.opt:404
3870  msgid "Warn if an undefined macro is used in an #if directive"
3871 -msgstr "Varna om ett odefinierat makro används i ett #if-direktiv"
3872 +msgstr "Varna för ett odefinierat makro används i ett #if-direktiv"
3873  
3874  #: c.opt:408
3875  msgid "Warn about unrecognized pragmas"
3876 -msgstr "Varna om okända pragman"
3877 +msgstr "Varna för okända pragman"
3878  
3879  #: c.opt:412
3880  msgid "Warn about macros defined in the main file that are not used"
3881 -msgstr "Varna om makron definierade i huvudfilen som inte används"
3882 +msgstr "Varna för makron definierade i huvudfilen som inte används"
3883  
3884  #: c.opt:416
3885  msgid "Do not warn about using variadic macros when -pedantic"
3886 @@ -12886,23 +12886,23 @@
3887  
3888  #: common.opt:54
3889  msgid "This switch is deprecated; use -Wextra instead"
3890 -msgstr "Denna flagga avrÃ¥des ifrÃ¥n, använd -Wextra istället"
3891 +msgstr "Denna flagga bör undvikas, använd -Wextra istället"
3892  
3893  #: common.opt:58
3894  msgid "Warn about returning structures, unions or arrays"
3895 -msgstr "Varna om retur av poster, unioner eller vektorer"
3896 +msgstr "Varna för retur av poster, unioner eller vektorer"
3897  
3898  #: common.opt:62
3899  msgid "Warn about inappropriate attribute usage"
3900 -msgstr "Varna om felaktig användning av attribut"
3901 +msgstr "Varna för felaktig användning av attribut"
3902  
3903  #: common.opt:66
3904  msgid "Warn about pointer casts which increase alignment"
3905 -msgstr "Varna om typkonvertering av pekare som Ã¶kar justeringen"
3906 +msgstr "Varna för typkonvertering av pekare som Ã¶kar justeringen"
3907  
3908  #: common.opt:70
3909  msgid "Warn about uses of __attribute__((deprecated)) declarations"
3910 -msgstr "Varna om användning av __attribute__((deprecated))-deklarationer"
3911 +msgstr "Varna för användning av __attribute__((deprecated))-deklarationer"
3912  
3913  #: common.opt:74
3914  msgid "Warn when an optimization pass is disabled"
3915 @@ -12926,15 +12926,15 @@
3916  
3917  #: common.opt:94
3918  msgid "Warn if an object is larger than <number> bytes"
3919 -msgstr "Varna om ett objekt Ã¤r större Ã¤n <antal> byte"
3920 +msgstr "Varna för ett objekt Ã¤r större Ã¤n <antal> byte"
3921  
3922  #: common.opt:98
3923  msgid "Warn if the loop cannot be optimized due to nontrivial assumptions."
3924 -msgstr "Varna om slingan inte kan optimeras pÃ¥ grund av icketriviala antaganden."
3925 +msgstr "Varna för slingan inte kan optimeras pÃ¥ grund av icketriviala antaganden."
3926  
3927  #: common.opt:102
3928  msgid "Warn about functions which might be candidates for __attribute__((noreturn))"
3929 -msgstr "Varna om funktioner som Ã¤r möjliga kandidater för __attribute__((noreturn))"
3930 +msgstr "Varna för funktioner som Ã¤r möjliga kandidater för __attribute__((noreturn))"
3931  
3932  #: common.opt:106
3933  msgid "Warn when the packed attribute has no effect on struct layout"
3934 @@ -12950,31 +12950,31 @@
3935  
3936  #: common.opt:118
3937  msgid "Warn when not issuing stack smashing protection for some reason"
3938 -msgstr "Varna när stacksprängningsskydd inte läggs ut av nÃ¥gon anledning"
3939 +msgstr "Varna när stacköverskrivningsskydd inte läggs ut av nÃ¥gon anledning"
3940  
3941  #: common.opt:122 common.opt:126
3942  msgid "Warn about code which might break strict aliasing rules"
3943 -msgstr "Varna om kod som kan bryta strikta aliasregler"
3944 +msgstr "Varna för kod som kan bryta strikta aliasregler"
3945  
3946  #: common.opt:130
3947  msgid "Warn about enumerated switches, with no default, missing a case"
3948 -msgstr "Varna om uppräkningshopptabeller, utan standardfall, saknar ett fall"
3949 +msgstr "Varna när hopptabeller för uppräkningstyper inte har standardfall och saknar ett fall"
3950  
3951  #: common.opt:134
3952  msgid "Warn about enumerated switches missing a \"default:\" statement"
3953 -msgstr "Varna om uppräkningshopptabeller saknar en \"default:\"-sats"
3954 +msgstr "Varna för uppräkningshopptabeller saknar en \"default:\"-sats"
3955  
3956  #: common.opt:138
3957  msgid "Warn about all enumerated switches missing a specific case"
3958 -msgstr "Varna om alla uppräkningshopptabeller som saknar ett specifikt fall"
3959 +msgstr "Varna för alla uppräkningshopptabeller som saknar ett specifikt fall"
3960  
3961  #: common.opt:146
3962  msgid "Warn about uninitialized automatic variables"
3963 -msgstr "Varna om oinitierade automatiska variabler"
3964 +msgstr "Varna för oinitierade automatiska variabler"
3965  
3966  #: common.opt:150
3967  msgid "Warn about code that will never be executed"
3968 -msgstr "Varna om kod som aldrig kommer köras"
3969 +msgstr "Varna för kod som aldrig kommer köras"
3970  
3971  #: common.opt:154
3972  msgid "Enable all -Wunused- warnings"
3973 @@ -13106,7 +13106,7 @@
3974  
3975  #: common.opt:334
3976  msgid "Place data items into their own section"
3977 -msgstr "Placera dataföremÃ¥l i sin egen sektion"
3978 +msgstr "Placera dataobjekt i sin egen sektion"
3979  
3980  #: common.opt:340
3981  msgid "Defer popping functions args from stack until later"
3982 @@ -13118,7 +13118,7 @@
3983  
3984  #: common.opt:348
3985  msgid "Delete useless null pointer checks"
3986 -msgstr "Tag bort oanvändbara nollpekarkontroller"
3987 +msgstr "Tag bort onödiga nollpekarkontroller"
3988  
3989  #: common.opt:352
3990  msgid "How often to emit source location at the beginning of line-wrapped diagnostics"
3991 @@ -13214,7 +13214,7 @@
3992  
3993  #: common.opt:464
3994  msgid "Perform conversion of conditional jumps to branchless equivalents"
3995 -msgstr "Utvör konvertering av villkorliga hopp till grenlösa motsvarigheter"
3996 +msgstr "Utför konvertering av villkorliga hopp till grenlösa motsvarigheter"
3997  
3998  #: common.opt:468
3999  msgid "Perform conversion of conditional jumps to conditional execution"
4000 @@ -13730,15 +13730,15 @@
4001  
4002  #: common.opt:1034
4003  msgid "Construct webs and split unrelated uses of single variable"
4004 -msgstr "Kostruera nät och dela orelaterade användningar av en enskild variabel"
4005 +msgstr "Konstruera nät och dela orelaterade användningar av en enskild variabel"
4006  
4007  #: common.opt:1038
4008  msgid "Perform whole program optimizations"
4009 -msgstr "Utför optimeringav hela program"
4010 +msgstr "Utför optimering av hela program"
4011  
4012  #: common.opt:1042
4013  msgid "Assume signed arithmetic overflow wraps around"
4014 -msgstr "Anta spill vid teckenaritmetik slÃ¥r runt"
4015 +msgstr "Anta att spill vid teckenaritmetik slÃ¥r runt"
4016  
4017  #: common.opt:1046
4018  msgid "Put zero initialized data in the bss section"
4019 @@ -14044,7 +14044,7 @@
4020  #: c-common.c:975
4021  #, gcc-internal-format
4022  msgid "type-punning to incomplete type might break strict-aliasing rules"
4023 -msgstr "typstampning till ofullständiga typ kan bryta strikta aliasregler"
4024 +msgstr "typstampning till ofullständig typ kan bryta strikta aliasregler"
4025  
4026  #: c-common.c:983
4027  #, gcc-internal-format
4028 @@ -14059,7 +14059,7 @@
4029  #: c-common.c:1049
4030  #, gcc-internal-format
4031  msgid "overflow in implicit constant conversion"
4032 -msgstr "spill i implicit constant konvertering"
4033 +msgstr "spill i implicit konstant konvertering"
4034  
4035  #: c-common.c:1185
4036  #, gcc-internal-format
4037 @@ -14129,12 +14129,12 @@
4038  #: c-common.c:2288
4039  #, gcc-internal-format
4040  msgid "pointer to a function used in arithmetic"
4041 -msgstr "pekare till funktion använd med aritmetik"
4042 +msgstr "pekare till funktion använd i aritmetik"
4043  
4044  #: c-common.c:2294
4045  #, gcc-internal-format
4046  msgid "pointer to member function used in arithmetic"
4047 -msgstr "pekare till medlemsfunktion använd med aritmetik"
4048 +msgstr "pekare till medlemsfunktion använd i aritmetik"
4049  
4050  #. Common Ada/Pascal programmer's mistake.  We always warn
4051  #. about this since it is so bad.
4052 @@ -14196,7 +14196,7 @@
4053  #: c-common.c:3724
4054  #, gcc-internal-format
4055  msgid "duplicate (or overlapping) case value"
4056 -msgstr "dubbla (eller Ã¶verlappand) case-värden"
4057 +msgstr "dubbla (eller Ã¶verlappande) case-värden"
4058  
4059  #: c-common.c:3725
4060  #, gcc-internal-format
4061 @@ -14236,7 +14236,7 @@
4062  #: c-common.c:3844
4063  #, gcc-internal-format
4064  msgid "%Hswitch missing default case"
4065 -msgstr "%Hswitch saknare default-fall"
4066 +msgstr "%Hswitch saknar default-fall"
4067  
4068  #. Warn if there are enumerators that don't correspond to
4069  #. case expressions.
4070 @@ -14279,7 +14279,7 @@
4071  #: c-common.c:4540
4072  #, gcc-internal-format
4073  msgid "specifying vector types with __attribute__ ((mode)) is deprecated"
4074 -msgstr "det avrÃ¥des frÃ¥n att ange vektortyper med __attribute__ ((sätt))"
4075 +msgstr "att ange vektortyper med __attribute__ ((sätt)) bör unvikas"
4076  
4077  #: c-common.c:4543
4078  #, gcc-internal-format
4079 @@ -14339,7 +14339,7 @@
4080  #: c-common.c:4708
4081  #, gcc-internal-format
4082  msgid "requested alignment is not a power of 2"
4083 -msgstr "efterrÃ¥gad minnesjustering Ã¤r inte en potens av 2"
4084 +msgstr "efterfÃ¥gad minnesjustering Ã¤r inte en potens av 2"
4085  
4086  #: c-common.c:4713
4087  #, gcc-internal-format
4088 @@ -19077,7 +19077,7 @@
4089  #: stmt.c:910
4090  #, gcc-internal-format
4091  msgid "use of memory input without lvalue in asm operand %d is deprecated"
4092 -msgstr "användning av minnesindata utan lvärde i asm-operand %d undanbedes"
4093 +msgstr "användning av minnesindata utan lvärde i asm-operand %d bör undvikas"
4094  
4095  #: stmt.c:1057
4096  #, gcc-internal-format
4097 @@ -19234,22 +19234,22 @@
4098  #: toplev.c:892 toplev.c:916
4099  #, gcc-internal-format
4100  msgid "%qs is deprecated (declared at %s:%d)"
4101 -msgstr "%qs undanbedes (deklarerad vid %s:%d)"
4102 +msgstr "%qs bör undvikas (deklarerad vid %s:%d)"
4103  
4104  #: toplev.c:920
4105  #, gcc-internal-format
4106  msgid "type is deprecated (declared at %s:%d)"
4107 -msgstr "typen undanbedes (deklarerad vid %s:%d)"
4108 +msgstr "typen bör undvikas (deklarerad vid %s:%d)"
4109  
4110  #: toplev.c:926
4111  #, gcc-internal-format
4112  msgid "%qs is deprecated"
4113 -msgstr "%qs undanbedes"
4114 +msgstr "%qs bör undvikas"
4115  
4116  #: toplev.c:928
4117  #, gcc-internal-format
4118  msgid "type is deprecated"
4119 -msgstr "type undanbedes"
4120 +msgstr "typen bör undvikas"
4121  
4122  #: toplev.c:1095
4123  #, gcc-internal-format
4124 @@ -21694,7 +21694,7 @@
4125  #: config/rs6000/rs6000.c:7259
4126  #, gcc-internal-format
4127  msgid "unresolved overload for Altivec builtin %qF"
4128 -msgstr "ej upplöst Ã¶verlastning för inbyggd Altivec %qF"
4129 +msgstr "ej upplöst Ã¶verlagring för inbyggd Altivec %qF"
4130  
4131  #: config/rs6000/rs6000.c:7341
4132  #, gcc-internal-format
4133 @@ -21729,7 +21729,7 @@
4134  #: config/rs6000/rs6000.c:17299
4135  #, gcc-internal-format
4136  msgid "use of %<long%> in AltiVec types is deprecated; use %<int%>"
4137 -msgstr "användning av %<long%> i AltiVec-typer undanbedes, använd %<int%>"
4138 +msgstr "användning av %<long%> i AltiVec-typer bör undvikas, använd %<int%>"
4139  
4140  #: config/rs6000/rs6000.c:17303
4141  #, gcc-internal-format
4142 @@ -22307,7 +22307,7 @@
4143  #: cp/call.c:2800 cp/call.c:2858
4144  #, gcc-internal-format
4145  msgid "call of overloaded %<%D(%A)%> is ambiguous"
4146 -msgstr "anrop av Ã¶verlastad %<%D(%A)%> Ã¤r tvetydigt"
4147 +msgstr "anrop av Ã¶verlagrad %<%D(%A)%> Ã¤r tvetydigt"
4148  
4149  #. It's no good looking for an overloaded operator() on a
4150  #. pointer-to-member-function.
4151 @@ -22522,7 +22522,7 @@
4152  #: cp/call.c:5404
4153  #, gcc-internal-format
4154  msgid "call of overloaded %<%s(%A)%> is ambiguous"
4155 -msgstr "anrop av Ã¶verlastad %<%s(%A)%> Ã¤r tvetydigt"
4156 +msgstr "anrop av Ã¶verlagrad %<%s(%A)%> Ã¤r tvetydigt"
4157  
4158  #: cp/call.c:5428
4159  #, gcc-internal-format
4160 @@ -22602,7 +22602,7 @@
4161  #: cp/class.c:1061
4162  #, gcc-internal-format
4163  msgid "%q+#D cannot be overloaded"
4164 -msgstr "%q+#D kan inte Ã¶verlastas"
4165 +msgstr "%q+#D kan inte Ã¶verlagras"
4166  
4167  #: cp/class.c:1062
4168  #, gcc-internal-format
4169 @@ -22880,7 +22880,7 @@
4170  #: cp/class.c:5714
4171  #, gcc-internal-format
4172  msgid "cannot resolve overloaded function %qD based on conversion to type %qT"
4173 -msgstr "det gÃ¥r inte att lösa upp  Ã¶verlastad funktion %qD baserat pÃ¥ konvertering till typ %qT"
4174 +msgstr "det gÃ¥r inte att lösa upp Ã¶verlagrad funktion %qD baserat pÃ¥ konvertering till typ %qT"
4175  
4176  #: cp/class.c:5841
4177  #, gcc-internal-format
4178 @@ -22890,7 +22890,7 @@
4179  #: cp/class.c:5864
4180  #, gcc-internal-format
4181  msgid "converting overloaded function %qD to type %q#T is ambiguous"
4182 -msgstr "konvertering av Ã¶verlastad funktion %qD till typ %q#T Ã¤r tvetydig"
4183 +msgstr "konvertering av Ã¶verlagrad funktion %qD till typ %q#T Ã¤r tvetydig"
4184  
4185  #: cp/class.c:5890
4186  #, gcc-internal-format
4187 @@ -23022,7 +23022,7 @@
4188  #: cp/cvt.c:902
4189  #, gcc-internal-format
4190  msgid "%s cannot resolve address of overloaded function"
4191 -msgstr "%s kan inte lösa upp adress till Ã¶verlastad funktion"
4192 +msgstr "%s kan inte lösa upp adress till Ã¶verlagrad funktion"
4193  
4194  #. Only warn when there is no &.
4195  #: cp/cvt.c:908
4196 @@ -23565,7 +23565,7 @@
4197  #: cp/decl.c:4387
4198  #, gcc-internal-format
4199  msgid "braces around scalar initializer for type %qT"
4200 -msgstr "klamrar funt skalär initierare för typen %qT"
4201 +msgstr "klamrar runt skalär initierare för typen %qT"
4202  
4203  #: cp/decl.c:4465
4204  #, gcc-internal-format
4205 @@ -24427,7 +24427,7 @@
4206  #: cp/decl.c:9012
4207  #, gcc-internal-format
4208  msgid "ISO C++ prohibits overloading operator ?:"
4209 -msgstr "ISO C++ förhindrar Ã¶verlastning av operatorn ?:"
4210 +msgstr "ISO C++ förhindrar Ã¶verlagring av operatorn ?:"
4211  
4212  #: cp/decl.c:9015
4213  #, gcc-internal-format
4214 @@ -24848,7 +24848,7 @@
4215  #: cp/except.c:631 cp/init.c:1929
4216  #, gcc-internal-format
4217  msgid "%qD should never be overloaded"
4218 -msgstr "%qD skall aldrig Ã¶verlastas"
4219 +msgstr "%qD skall aldrig Ã¶verlagras"
4220  
4221  #: cp/except.c:698
4222  #, gcc-internal-format
4223 @@ -25242,7 +25242,7 @@
4224  #: cp/lex.c:651
4225  #, gcc-internal-format
4226  msgid "(if you use %<-fpermissive%>, G++ will accept your code, but allowing the use of an undeclared name is deprecated)"
4227 -msgstr "(om du använder %<-fpermissive%>, kommer G++ acceptera din kod, men det avrÃ¥des frÃ¥n att tillÃ¥ta användning av ett odeklarerat namn)"
4228 +msgstr "(om du använder %<-fpermissive%>, kommer G++ acceptera din kod, men man bör undvika att tillÃ¥ta användning av ett odeklarerat namn)"
4229  
4230  #: cp/mangle.c:2139
4231  #, gcc-internal-format
4232 @@ -25562,7 +25562,7 @@
4233  #: cp/parser.c:1875
4234  #, gcc-internal-format
4235  msgid "minimum/maximum operators are deprecated"
4236 -msgstr "minimum-/maximumoperatorer undanbedes"
4237 +msgstr "minimum-/maximumoperatorer bör undvikas"
4238  
4239  #: cp/parser.c:1895
4240  #, gcc-internal-format
4241 @@ -25905,7 +25905,7 @@
4242  #: cp/parser.c:12370
4243  #, gcc-internal-format
4244  msgid "deprecated use of default argument for parameter of non-function"
4245 -msgstr "undanbedd användning av standardargument för parametrar till annat Ã¤n funktioner"
4246 +msgstr "användning av standardargument för parametrar till annat Ã¤n funktioner bör undvikas"
4247  
4248  #: cp/parser.c:12373
4249  #, gcc-internal-format
4250 @@ -26728,7 +26728,7 @@
4251  #: cp/search.c:1847
4252  #, gcc-internal-format
4253  msgid "deprecated covariant return type for %q+#D"
4254 -msgstr "undanbedd kovariant returtyp för %q+#D"
4255 +msgstr "kovariant returtyp för %q+#D bör undvikas"
4256  
4257  #: cp/search.c:1849 cp/search.c:1864 cp/search.c:1869
4258  #, gcc-internal-format
4259 @@ -27013,7 +27013,7 @@
4260  #: cp/typeck.c:1502
4261  #, gcc-internal-format
4262  msgid "deprecated conversion from string constant to %qT'"
4263 -msgstr "undanbedd konvertering frÃ¥n strängkonstant till %qT'"
4264 +msgstr "konvertering frÃ¥n strängkonstant till %qT' bör undvikas"
4265  
4266  #: cp/typeck.c:1613 cp/typeck.c:1961
4267  #, gcc-internal-format
4268 @@ -27155,7 +27155,7 @@
4269  #: cp/typeck.c:2885 cp/typeck.c:2895
4270  #, gcc-internal-format
4271  msgid "assuming cast to type %qT from overloaded function"
4272 -msgstr "antar typkonvertering till %qT frÃ¥n Ã¶verlastad funktion"
4273 +msgstr "antar typkonvertering till %qT frÃ¥n Ã¶verlagrad funktion"
4274  
4275  #: cp/typeck.c:2963
4276  #, gcc-internal-format
4277 Index: gcc-4_2-branch/gcc/sched-deps.c
4278 ===================================================================
4279 --- gcc-4_2-branch/gcc/sched-deps.c     (revision 123014)
4280 +++ gcc-4_2-branch/gcc/sched-deps.c     (revision 124164)
4281 @@ -1238,8 +1238,12 @@
4282  
4283    /* If this instruction can throw an exception, then moving it changes
4284       where block boundaries fall.  This is mighty confusing elsewhere.
4285 -     Therefore, prevent such an instruction from being moved.  */
4286 -  if (can_throw_internal (insn))
4287 +     Therefore, prevent such an instruction from being moved.  Same for
4288 +     non-jump instructions that define block boundaries.
4289 +     ??? Unclear whether this is still necessary in EBB mode.  If not,
4290 +     add_branch_dependences should be adjusted for RGN mode instead.  */
4291 +  if (((CALL_P (insn) || JUMP_P (insn)) && can_throw_internal (insn))
4292 +      || (NONJUMP_INSN_P (insn) && control_flow_insn_p (insn)))
4293      reg_pending_barrier = MOVE_BARRIER;
4294  
4295    /* Add dependencies if a scheduling barrier was found.  */
4296 Index: gcc-4_2-branch/gcc/tree-cfg.c
4297 ===================================================================
4298 --- gcc-4_2-branch/gcc/tree-cfg.c       (revision 123014)
4299 +++ gcc-4_2-branch/gcc/tree-cfg.c       (revision 124164)
4300 @@ -439,7 +439,9 @@
4301           cond = fold (COND_EXPR_COND (stmt));
4302           zerop = integer_zerop (cond);
4303           onep = integer_onep (cond);
4304 -         fold_undefer_overflow_warnings (zerop || onep, stmt,
4305 +         fold_undefer_overflow_warnings (((zerop || onep)
4306 +                                          && !TREE_NO_WARNING (stmt)),
4307 +                                         stmt,
4308                                           WARN_STRICT_OVERFLOW_CONDITIONAL);
4309           if (zerop)
4310             COND_EXPR_COND (stmt) = boolean_false_node;
4311 @@ -2121,8 +2123,19 @@
4312      return find_taken_edge_switch_expr (bb, val);
4313  
4314    if (computed_goto_p (stmt))
4315 -    return find_taken_edge_computed_goto (bb, TREE_OPERAND( val, 0));
4316 +    {
4317 +      /* Only optimize if the argument is a label, if the argument is
4318 +        not a label then we can not construct a proper CFG.
4319  
4320 +         It may be the case that we only need to allow the LABEL_REF to
4321 +         appear inside an ADDR_EXPR, but we also allow the LABEL_REF to
4322 +         appear inside a LABEL_EXPR just to be safe.  */
4323 +      if ((TREE_CODE (val) == ADDR_EXPR || TREE_CODE (val) == LABEL_EXPR)
4324 +         && TREE_CODE (TREE_OPERAND (val, 0)) == LABEL_DECL)
4325 +       return find_taken_edge_computed_goto (bb, TREE_OPERAND (val, 0));
4326 +      return NULL;
4327 +    }
4328 +
4329    gcc_unreachable ();
4330  }
4331  
4332 Index: gcc-4_2-branch/gcc/config/alpha/linux.h
4333 ===================================================================
4334 --- gcc-4_2-branch/gcc/config/alpha/linux.h     (revision 123014)
4335 +++ gcc-4_2-branch/gcc/config/alpha/linux.h     (revision 124164)
4336 @@ -44,6 +44,9 @@
4337     %{shared:-lc} \
4338     %{!shared: %{profile:-lc_p}%{!profile:-lc}}"
4339  
4340 +#undef CPP_SPEC
4341 +#define CPP_SPEC "%{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}"
4342 +
4343  /* Show that we need a GP when profiling.  */
4344  #undef TARGET_PROFILING_NEEDS_GP
4345  #define TARGET_PROFILING_NEEDS_GP 1
4346 Index: gcc-4_2-branch/gcc/config/alpha/alpha.c
4347 ===================================================================
4348 --- gcc-4_2-branch/gcc/config/alpha/alpha.c     (revision 123014)
4349 +++ gcc-4_2-branch/gcc/config/alpha/alpha.c     (revision 124164)
4350 @@ -1549,7 +1549,7 @@
4351     Add EXTRA_OFFSET to the address we return.  */
4352  
4353  rtx
4354 -get_unaligned_address (rtx ref, int extra_offset)
4355 +get_unaligned_address (rtx ref)
4356  {
4357    rtx base;
4358    HOST_WIDE_INT offset = 0;
4359 @@ -1569,9 +1569,25 @@
4360    if (GET_CODE (base) == PLUS)
4361      offset += INTVAL (XEXP (base, 1)), base = XEXP (base, 0);
4362  
4363 -  return plus_constant (base, offset + extra_offset);
4364 +  return plus_constant (base, offset);
4365  }
4366  
4367 +/* Compute a value X, such that X & 7 == (ADDR + OFS) & 7.
4368 +   X is always returned in a register.  */
4369 +
4370 +rtx
4371 +get_unaligned_offset (rtx addr, HOST_WIDE_INT ofs)
4372 +{
4373 +  if (GET_CODE (addr) == PLUS)
4374 +    {
4375 +      ofs += INTVAL (XEXP (addr, 1));
4376 +      addr = XEXP (addr, 0);
4377 +    }
4378 +
4379 +  return expand_simple_binop (Pmode, PLUS, addr, GEN_INT (ofs & 7),
4380 +                             NULL_RTX, 1, OPTAB_LIB_WIDEN);
4381 +}
4382 +
4383  /* On the Alpha, all (non-symbolic) constants except zero go into
4384     a floating-point register via memory.  Note that we cannot
4385     return anything that is not a subset of CLASS, and that some
4386 @@ -2318,7 +2334,7 @@
4387           seq = ((mode == QImode
4388                   ? gen_unaligned_loadqi
4389                   : gen_unaligned_loadhi)
4390 -                (subtarget, get_unaligned_address (operands[1], 0),
4391 +                (subtarget, get_unaligned_address (operands[1]),
4392                   temp1, temp2));
4393           alpha_set_memflags (seq, operands[1]);
4394           emit_insn (seq);
4395 @@ -2357,7 +2373,7 @@
4396           rtx seq = ((mode == QImode
4397                       ? gen_unaligned_storeqi
4398                       : gen_unaligned_storehi)
4399 -                    (get_unaligned_address (operands[0], 0),
4400 +                    (get_unaligned_address (operands[0]),
4401                       operands[1], temp1, temp2, temp3));
4402  
4403           alpha_set_memflags (seq, operands[0]);
4404 Index: gcc-4_2-branch/gcc/config/alpha/alpha.md
4405 ===================================================================
4406 --- gcc-4_2-branch/gcc/config/alpha/alpha.md    (revision 123014)
4407 +++ gcc-4_2-branch/gcc/config/alpha/alpha.md    (revision 124164)
4408 @@ -1607,10 +1607,7 @@
4409  
4410    if (unaligned_memory_operand (operands[1], QImode))
4411      {
4412 -      rtx seq
4413 -       = gen_unaligned_extendqidi (operands[0],
4414 -                                   get_unaligned_address (operands[1], 1));
4415 -
4416 +      rtx seq = gen_unaligned_extendqidi (operands[0], XEXP (operands[1], 0));
4417        alpha_set_memflags (seq, operands[1]);
4418        emit_insn (seq);
4419        DONE;
4420 @@ -1670,9 +1667,7 @@
4421  
4422    if (unaligned_memory_operand (operands[1], HImode))
4423      {
4424 -      rtx seq
4425 -       = gen_unaligned_extendhidi (operands[0],
4426 -                                   get_unaligned_address (operands[1], 2));
4427 +      rtx seq = gen_unaligned_extendhidi (operands[0], XEXP (operands[1], 0));
4428  
4429        alpha_set_memflags (seq, operands[1]);
4430        emit_insn (seq);
4431 @@ -1687,12 +1682,13 @@
4432  ;; as a pattern saves one instruction.  The code is similar to that for
4433  ;; the unaligned loads (see below).
4434  ;;
4435 -;; Operand 1 is the address + 1 (+2 for HI), operand 0 is the result.
4436 +;; Operand 1 is the address, operand 0 is the result.
4437  (define_expand "unaligned_extendqidi"
4438    [(use (match_operand:QI 0 "register_operand" ""))
4439     (use (match_operand:DI 1 "address_operand" ""))]
4440    ""
4441  {
4442 +  operands[0] = gen_lowpart (DImode, operands[0]);
4443    if (WORDS_BIG_ENDIAN)
4444      emit_insn (gen_unaligned_extendqidi_be (operands[0], operands[1]));
4445    else
4446 @@ -1701,48 +1697,40 @@
4447  })
4448  
4449  (define_expand "unaligned_extendqidi_le"
4450 -  [(set (match_dup 2) (match_operand:DI 1 "address_operand" ""))
4451 -   (set (match_dup 3)
4452 -       (mem:DI (and:DI (plus:DI (match_dup 2) (const_int -1))
4453 -                       (const_int -8))))
4454 +  [(set (match_dup 3)
4455 +       (mem:DI (and:DI (match_operand:DI 1 "" "") (const_int -8))))
4456     (set (match_dup 4)
4457         (ashift:DI (match_dup 3)
4458                    (minus:DI (const_int 64)
4459                              (ashift:DI
4460                               (and:DI (match_dup 2) (const_int 7))
4461                               (const_int 3)))))
4462 -   (set (subreg:DI (match_operand:QI 0 "register_operand" "") 0)
4463 +   (set (match_operand:DI 0 "register_operand" "")
4464         (ashiftrt:DI (match_dup 4) (const_int 56)))]
4465    "! WORDS_BIG_ENDIAN"
4466  {
4467 -  operands[2] = gen_reg_rtx (DImode);
4468 +  operands[2] = get_unaligned_offset (operands[1], 1);
4469    operands[3] = gen_reg_rtx (DImode);
4470    operands[4] = gen_reg_rtx (DImode);
4471  })
4472  
4473  (define_expand "unaligned_extendqidi_be"
4474 -  [(set (match_dup 2) (match_operand:DI 1 "address_operand" ""))
4475 -   (set (match_dup 3) (plus:DI (match_dup 2) (const_int -1)))
4476 +  [(set (match_dup 3)
4477 +       (mem:DI (and:DI (match_operand:DI 1 "" "") (const_int -8))))
4478     (set (match_dup 4)
4479 -       (mem:DI (and:DI (match_dup 3)
4480 -                       (const_int -8))))
4481 -   (set (match_dup 5) (plus:DI (match_dup 2) (const_int -2)))
4482 -   (set (match_dup 6)
4483 -       (ashift:DI (match_dup 4)
4484 +       (ashift:DI (match_dup 3)
4485                    (ashift:DI
4486                      (and:DI
4487 -                      (plus:DI (match_dup 5) (const_int 1))
4488 +                      (plus:DI (match_dup 2) (const_int 1))
4489                        (const_int 7))
4490                      (const_int 3))))
4491 -   (set (subreg:DI (match_operand:QI 0 "register_operand" "") 0)
4492 -       (ashiftrt:DI (match_dup 6) (const_int 56)))]
4493 +   (set (match_operand:DI 0 "register_operand" "")
4494 +       (ashiftrt:DI (match_dup 4) (const_int 56)))]
4495    "WORDS_BIG_ENDIAN"
4496  {
4497 -  operands[2] = gen_reg_rtx (DImode);
4498 +  operands[2] = get_unaligned_offset (operands[1], -1);
4499    operands[3] = gen_reg_rtx (DImode);
4500    operands[4] = gen_reg_rtx (DImode);
4501 -  operands[5] = gen_reg_rtx (DImode);
4502 -  operands[6] = gen_reg_rtx (DImode);
4503  })
4504  
4505  (define_expand "unaligned_extendhidi"
4506 @@ -1751,17 +1739,16 @@
4507    ""
4508  {
4509    operands[0] = gen_lowpart (DImode, operands[0]);
4510 -  emit_insn ((WORDS_BIG_ENDIAN
4511 -             ? gen_unaligned_extendhidi_be
4512 -             : gen_unaligned_extendhidi_le) (operands[0], operands[1]));
4513 +  if (WORDS_BIG_ENDIAN)
4514 +    emit_insn (gen_unaligned_extendhidi_be (operands[0], operands[1]));
4515 +  else
4516 +    emit_insn (gen_unaligned_extendhidi_le (operands[0], operands[1]));
4517    DONE;
4518  })
4519  
4520  (define_expand "unaligned_extendhidi_le"
4521 -  [(set (match_dup 2) (match_operand:DI 1 "address_operand" ""))
4522 -   (set (match_dup 3)
4523 -       (mem:DI (and:DI (plus:DI (match_dup 2) (const_int -2))
4524 -                       (const_int -8))))
4525 +  [(set (match_dup 3)
4526 +       (mem:DI (and:DI (match_operand:DI 1 "" "") (const_int -8))))
4527     (set (match_dup 4)
4528         (ashift:DI (match_dup 3)
4529                    (minus:DI (const_int 64)
4530 @@ -1772,34 +1759,28 @@
4531         (ashiftrt:DI (match_dup 4) (const_int 48)))]
4532    "! WORDS_BIG_ENDIAN"
4533  {
4534 -  operands[2] = gen_reg_rtx (DImode);
4535 +  operands[2] = get_unaligned_offset (operands[1], 2);
4536    operands[3] = gen_reg_rtx (DImode);
4537    operands[4] = gen_reg_rtx (DImode);
4538  })
4539  
4540  (define_expand "unaligned_extendhidi_be"
4541 -  [(set (match_dup 2) (match_operand:DI 1 "address_operand" ""))
4542 -   (set (match_dup 3) (plus:DI (match_dup 2) (const_int -2)))
4543 +  [(set (match_dup 3)
4544 +       (mem:DI (and:DI (match_operand:DI 1 "" "") (const_int -8))))
4545     (set (match_dup 4)
4546 -       (mem:DI (and:DI (match_dup 3)
4547 -                       (const_int -8))))
4548 -   (set (match_dup 5) (plus:DI (match_dup 2) (const_int -3)))
4549 -   (set (match_dup 6)
4550 -       (ashift:DI (match_dup 4)
4551 +       (ashift:DI (match_dup 3)
4552                    (ashift:DI
4553                      (and:DI
4554 -                      (plus:DI (match_dup 5) (const_int 1))
4555 +                      (plus:DI (match_dup 2) (const_int 1))
4556                        (const_int 7))
4557                      (const_int 3))))
4558     (set (match_operand:DI 0 "register_operand" "")
4559 -       (ashiftrt:DI (match_dup 6) (const_int 48)))]
4560 +       (ashiftrt:DI (match_dup 4) (const_int 48)))]
4561    "WORDS_BIG_ENDIAN"
4562  {
4563 -  operands[2] = gen_reg_rtx (DImode);
4564 +  operands[2] = get_unaligned_offset (operands[1], -1);
4565    operands[3] = gen_reg_rtx (DImode);
4566    operands[4] = gen_reg_rtx (DImode);
4567 -  operands[5] = gen_reg_rtx (DImode);
4568 -  operands[6] = gen_reg_rtx (DImode);
4569  })
4570  
4571  (define_insn "*extxl_const"
4572 @@ -6065,7 +6046,7 @@
4573        else
4574         scratch = gen_rtx_REG (DImode, REGNO (operands[2]));
4575  
4576 -      addr = get_unaligned_address (operands[1], 0);
4577 +      addr = get_unaligned_address (operands[1]);
4578        operands[0] = gen_rtx_REG (DImode, REGNO (operands[0]));
4579        seq = gen_unaligned_loadqi (operands[0], addr, scratch, operands[0]);
4580        alpha_set_memflags (seq, operands[1]);
4581 @@ -6099,7 +6080,7 @@
4582        else
4583         scratch = gen_rtx_REG (DImode, REGNO (operands[2]));
4584  
4585 -      addr = get_unaligned_address (operands[1], 0);
4586 +      addr = get_unaligned_address (operands[1]);
4587        operands[0] = gen_rtx_REG (DImode, REGNO (operands[0]));
4588        seq = gen_unaligned_loadhi (operands[0], addr, scratch, operands[0]);
4589        alpha_set_memflags (seq, operands[1]);
4590 @@ -6123,7 +6104,7 @@
4591      }
4592    else
4593      {
4594 -      rtx addr = get_unaligned_address (operands[0], 0);
4595 +      rtx addr = get_unaligned_address (operands[0]);
4596        rtx scratch1 = gen_rtx_REG (DImode, REGNO (operands[2]));
4597        rtx scratch2 = gen_rtx_REG (DImode, REGNO (operands[2]) + 1);
4598        rtx scratch3 = scratch1;
4599 @@ -6155,7 +6136,7 @@
4600      }
4601    else
4602      {
4603 -      rtx addr = get_unaligned_address (operands[0], 0);
4604 +      rtx addr = get_unaligned_address (operands[0]);
4605        rtx scratch1 = gen_rtx_REG (DImode, REGNO (operands[2]));
4606        rtx scratch2 = gen_rtx_REG (DImode, REGNO (operands[2]) + 1);
4607        rtx scratch3 = scratch1;
4608 Index: gcc-4_2-branch/gcc/config/alpha/alpha-protos.h
4609 ===================================================================
4610 --- gcc-4_2-branch/gcc/config/alpha/alpha-protos.h      (revision 123014)
4611 +++ gcc-4_2-branch/gcc/config/alpha/alpha-protos.h      (revision 124164)
4612 @@ -51,7 +51,8 @@
4613  extern rtx split_small_symbolic_operand (rtx);
4614  
4615  extern void get_aligned_mem (rtx, rtx *, rtx *);
4616 -extern rtx get_unaligned_address (rtx, int);
4617 +extern rtx get_unaligned_address (rtx);
4618 +extern rtx get_unaligned_offset (rtx, HOST_WIDE_INT);
4619  extern enum reg_class alpha_preferred_reload_class (rtx, enum reg_class);
4620  extern enum reg_class alpha_secondary_reload_class (enum reg_class,
4621                                                     enum machine_mode, rtx,
4622 Index: gcc-4_2-branch/gcc/config/s390/s390.c
4623 ===================================================================
4624 --- gcc-4_2-branch/gcc/config/s390/s390.c       (revision 123014)
4625 +++ gcc-4_2-branch/gcc/config/s390/s390.c       (revision 124164)
4626 @@ -3555,7 +3555,7 @@
4627        if (temp != count)
4628          emit_move_insn (count, temp);
4629  
4630 -      temp = expand_binop (mode, ashr_optab, count, GEN_INT (8), blocks, 1, 0);
4631 +      temp = expand_binop (mode, lshr_optab, count, GEN_INT (8), blocks, 1, 0);
4632        if (temp != blocks)
4633          emit_move_insn (blocks, temp);
4634  
4635 @@ -3592,10 +3592,12 @@
4636  void
4637  s390_expand_setmem (rtx dst, rtx len, rtx val)
4638  {
4639 -  gcc_assert (GET_CODE (len) != CONST_INT || INTVAL (len) > 0);
4640 +  if (GET_CODE (len) == CONST_INT && INTVAL (len) == 0)
4641 +    return;
4642 +
4643    gcc_assert (GET_CODE (val) == CONST_INT || GET_MODE (val) == QImode);
4644    
4645 -  if (GET_CODE (len) == CONST_INT && INTVAL (len) <= 257)
4646 +  if (GET_CODE (len) == CONST_INT && INTVAL (len) > 0 && INTVAL (len) <= 257)
4647      {
4648        if (val == const0_rtx && INTVAL (len) <= 256)
4649          emit_insn (gen_clrmem_short (dst, GEN_INT (INTVAL (len) - 1)));
4650 @@ -3669,7 +3671,7 @@
4651        if (temp != count)
4652          emit_move_insn (count, temp);
4653  
4654 -      temp = expand_binop (mode, ashr_optab, count, GEN_INT (8), blocks, 1, 0);
4655 +      temp = expand_binop (mode, lshr_optab, count, GEN_INT (8), blocks, 1, 0);
4656        if (temp != blocks)
4657          emit_move_insn (blocks, temp);
4658  
4659 @@ -3761,7 +3763,7 @@
4660        if (temp != count)
4661          emit_move_insn (count, temp);
4662  
4663 -      temp = expand_binop (mode, ashr_optab, count, GEN_INT (8), blocks, 1, 0);
4664 +      temp = expand_binop (mode, lshr_optab, count, GEN_INT (8), blocks, 1, 0);
4665        if (temp != blocks)
4666          emit_move_insn (blocks, temp);
4667  
4668 Index: gcc-4_2-branch/gcc/config/i386/mmintrin.h
4669 ===================================================================
4670 --- gcc-4_2-branch/gcc/config/i386/mmintrin.h   (revision 123014)
4671 +++ gcc-4_2-branch/gcc/config/i386/mmintrin.h   (revision 124164)
4672 @@ -1,4 +1,4 @@
4673 -/* Copyright (C) 2002, 2003, 2004, 2005, 2006
4674 +/* Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007
4675     Free Software Foundation, Inc.
4676  
4677     This file is part of GCC.
4678 @@ -34,8 +34,9 @@
4679  #ifndef __MMX__
4680  # error "MMX instruction set not enabled"
4681  #else
4682 -/* The data type intended for user use.  */
4683 -typedef int __m64 __attribute__ ((__vector_size__ (8)));
4684 +/* The Intel API is flexible enough that we must allow aliasing with other
4685 +   vector types, and their scalar components.  */
4686 +typedef int __m64 __attribute__ ((__vector_size__ (8), __may_alias__));
4687  
4688  /* Internal data types for implementing the intrinsics.  */
4689  typedef int __v2si __attribute__ ((__vector_size__ (8)));
4690 Index: gcc-4_2-branch/gcc/config/i386/xmmintrin.h
4691 ===================================================================
4692 --- gcc-4_2-branch/gcc/config/i386/xmmintrin.h  (revision 123014)
4693 +++ gcc-4_2-branch/gcc/config/i386/xmmintrin.h  (revision 124164)
4694 @@ -1,4 +1,4 @@
4695 -/* Copyright (C) 2002, 2003, 2004, 2005, 2006
4696 +/* Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007
4697     Free Software Foundation, Inc.
4698  
4699     This file is part of GCC.
4700 @@ -41,8 +41,9 @@
4701  /* Get _mm_malloc () and _mm_free ().  */
4702  #include <mm_malloc.h>
4703  
4704 -/* The data type intended for user use.  */
4705 -typedef float __m128 __attribute__ ((__vector_size__ (16)));
4706 +/* The Intel API is flexible enough that we must allow aliasing with other
4707 +   vector types, and their scalar components.  */
4708 +typedef float __m128 __attribute__ ((__vector_size__ (16), __may_alias__));
4709  
4710  /* Internal data types for implementing the intrinsics.  */
4711  typedef float __v4sf __attribute__ ((__vector_size__ (16)));
4712 Index: gcc-4_2-branch/gcc/config/i386/sse.md
4713 ===================================================================
4714 --- gcc-4_2-branch/gcc/config/i386/sse.md       (revision 123014)
4715 +++ gcc-4_2-branch/gcc/config/i386/sse.md       (revision 124164)
4716 @@ -304,7 +304,7 @@
4717  (define_insn "sse_vmaddv4sf3"
4718    [(set (match_operand:V4SF 0 "register_operand" "=x")
4719         (vec_merge:V4SF
4720 -         (plus:V4SF (match_operand:V4SF 1 "nonimmediate_operand" "%0")
4721 +         (plus:V4SF (match_operand:V4SF 1 "register_operand" "0")
4722                      (match_operand:V4SF 2 "nonimmediate_operand" "xm"))
4723           (match_dup 1)
4724           (const_int 1)))]
4725 @@ -360,7 +360,7 @@
4726  (define_insn "sse_vmmulv4sf3"
4727    [(set (match_operand:V4SF 0 "register_operand" "=x")
4728         (vec_merge:V4SF
4729 -         (mult:V4SF (match_operand:V4SF 1 "nonimmediate_operand" "%0")
4730 +         (mult:V4SF (match_operand:V4SF 1 "register_operand" "0")
4731                      (match_operand:V4SF 2 "nonimmediate_operand" "xm"))
4732           (match_dup 1)
4733           (const_int 1)))]
4734 @@ -492,19 +492,6 @@
4735    [(set_attr "type" "sse")
4736     (set_attr "mode" "V4SF")])
4737  
4738 -(define_insn "*sse_vmsmaxv4sf3_finite"
4739 -  [(set (match_operand:V4SF 0 "register_operand" "=x")
4740 -       (vec_merge:V4SF
4741 -        (smax:V4SF (match_operand:V4SF 1 "nonimmediate_operand" "%0")
4742 -                   (match_operand:V4SF 2 "nonimmediate_operand" "xm"))
4743 -        (match_dup 1)
4744 -        (const_int 1)))]
4745 -  "TARGET_SSE && flag_finite_math_only
4746 -   && ix86_binary_operator_ok (SMAX, V4SFmode, operands)"
4747 -  "maxss\t{%2, %0|%0, %2}"
4748 -  [(set_attr "type" "sse")
4749 -   (set_attr "mode" "SF")])
4750 -
4751  (define_insn "sse_vmsmaxv4sf3"
4752    [(set (match_operand:V4SF 0 "register_operand" "=x")
4753         (vec_merge:V4SF
4754 @@ -547,19 +534,6 @@
4755    [(set_attr "type" "sse")
4756     (set_attr "mode" "V4SF")])
4757  
4758 -(define_insn "*sse_vmsminv4sf3_finite"
4759 -  [(set (match_operand:V4SF 0 "register_operand" "=x")
4760 -       (vec_merge:V4SF
4761 -        (smin:V4SF (match_operand:V4SF 1 "nonimmediate_operand" "%0")
4762 -                   (match_operand:V4SF 2 "nonimmediate_operand" "xm"))
4763 -        (match_dup 1)
4764 -        (const_int 1)))]
4765 -  "TARGET_SSE && flag_finite_math_only
4766 -   && ix86_binary_operator_ok (SMIN, V4SFmode, operands)"
4767 -  "minss\t{%2, %0|%0, %2}"
4768 -  [(set_attr "type" "sse")
4769 -   (set_attr "mode" "SF")])
4770 -
4771  (define_insn "sse_vmsminv4sf3"
4772    [(set (match_operand:V4SF 0 "register_operand" "=x")
4773         (vec_merge:V4SF
4774 @@ -1398,7 +1372,7 @@
4775  (define_insn "sse2_vmaddv2df3"
4776    [(set (match_operand:V2DF 0 "register_operand" "=x")
4777         (vec_merge:V2DF
4778 -         (plus:V2DF (match_operand:V2DF 1 "nonimmediate_operand" "%0")
4779 +         (plus:V2DF (match_operand:V2DF 1 "register_operand" "0")
4780                      (match_operand:V2DF 2 "nonimmediate_operand" "xm"))
4781           (match_dup 1)
4782           (const_int 1)))]
4783 @@ -1454,7 +1428,7 @@
4784  (define_insn "sse2_vmmulv2df3"
4785    [(set (match_operand:V2DF 0 "register_operand" "=x")
4786         (vec_merge:V2DF
4787 -         (mult:V2DF (match_operand:V2DF 1 "nonimmediate_operand" "%0")
4788 +         (mult:V2DF (match_operand:V2DF 1 "register_operand" "0")
4789                      (match_operand:V2DF 2 "nonimmediate_operand" "xm"))
4790           (match_dup 1)
4791           (const_int 1)))]
4792 @@ -1544,19 +1518,6 @@
4793    [(set_attr "type" "sseadd")
4794     (set_attr "mode" "V2DF")])
4795  
4796 -(define_insn "*sse2_vmsmaxv2df3_finite"
4797 -  [(set (match_operand:V2DF 0 "register_operand" "=x")
4798 -       (vec_merge:V2DF
4799 -         (smax:V2DF (match_operand:V2DF 1 "nonimmediate_operand" "%0")
4800 -                    (match_operand:V2DF 2 "nonimmediate_operand" "xm"))
4801 -         (match_dup 1)
4802 -         (const_int 1)))]
4803 -  "TARGET_SSE2 && flag_finite_math_only
4804 -   && ix86_binary_operator_ok (SMAX, V2DFmode, operands)"
4805 -  "maxsd\t{%2, %0|%0, %2}"
4806 -  [(set_attr "type" "sseadd")
4807 -   (set_attr "mode" "DF")])
4808 -
4809  (define_insn "sse2_vmsmaxv2df3"
4810    [(set (match_operand:V2DF 0 "register_operand" "=x")
4811         (vec_merge:V2DF
4812 @@ -1599,19 +1560,6 @@
4813    [(set_attr "type" "sseadd")
4814     (set_attr "mode" "V2DF")])
4815  
4816 -(define_insn "*sse2_vmsminv2df3_finite"
4817 -  [(set (match_operand:V2DF 0 "register_operand" "=x")
4818 -       (vec_merge:V2DF
4819 -         (smin:V2DF (match_operand:V2DF 1 "nonimmediate_operand" "%0")
4820 -                    (match_operand:V2DF 2 "nonimmediate_operand" "xm"))
4821 -         (match_dup 1)
4822 -         (const_int 1)))]
4823 -  "TARGET_SSE2 && flag_finite_math_only
4824 -   && ix86_binary_operator_ok (SMIN, V2DFmode, operands)"
4825 -  "minsd\t{%2, %0|%0, %2}"
4826 -  [(set_attr "type" "sseadd")
4827 -   (set_attr "mode" "DF")])
4828 -
4829  (define_insn "sse2_vmsminv2df3"
4830    [(set (match_operand:V2DF 0 "register_operand" "=x")
4831         (vec_merge:V2DF
4832 @@ -2778,7 +2726,7 @@
4833    [(set (match_operand:SSEMODE24 0 "register_operand" "=x")
4834         (ashiftrt:SSEMODE24
4835           (match_operand:SSEMODE24 1 "register_operand" "0")
4836 -         (match_operand:SI 2 "nonmemory_operand" "xi")))]
4837 +         (match_operand:TI 2 "nonmemory_operand" "xn")))]
4838    "TARGET_SSE2"
4839    "psra<ssevecsize>\t{%2, %0|%0, %2}"
4840    [(set_attr "type" "sseishft")
4841 @@ -2788,7 +2736,7 @@
4842    [(set (match_operand:SSEMODE248 0 "register_operand" "=x")
4843         (lshiftrt:SSEMODE248
4844           (match_operand:SSEMODE248 1 "register_operand" "0")
4845 -         (match_operand:SI 2 "nonmemory_operand" "xi")))]
4846 +         (match_operand:TI 2 "nonmemory_operand" "xn")))]
4847    "TARGET_SSE2"
4848    "psrl<ssevecsize>\t{%2, %0|%0, %2}"
4849    [(set_attr "type" "sseishft")
4850 @@ -2798,7 +2746,7 @@
4851    [(set (match_operand:SSEMODE248 0 "register_operand" "=x")
4852         (ashift:SSEMODE248
4853           (match_operand:SSEMODE248 1 "register_operand" "0")
4854 -         (match_operand:SI 2 "nonmemory_operand" "xi")))]
4855 +         (match_operand:TI 2 "nonmemory_operand" "xn")))]
4856    "TARGET_SSE2"
4857    "psll<ssevecsize>\t{%2, %0|%0, %2}"
4858    [(set_attr "type" "sseishft")
4859 @@ -2942,7 +2890,7 @@
4860         (umin:V16QI (match_operand:V16QI 1 "nonimmediate_operand" "")
4861                     (match_operand:V16QI 2 "nonimmediate_operand" "")))]
4862    "TARGET_SSE2"
4863 -  "ix86_fixup_binary_operands_no_copy (UMAX, V16QImode, operands);")
4864 +  "ix86_fixup_binary_operands_no_copy (UMIN, V16QImode, operands);")
4865  
4866  (define_insn "*uminv16qi3"
4867    [(set (match_operand:V16QI 0 "register_operand" "=x")
4868 Index: gcc-4_2-branch/gcc/config/i386/emmintrin.h
4869 ===================================================================
4870 --- gcc-4_2-branch/gcc/config/i386/emmintrin.h  (revision 123014)
4871 +++ gcc-4_2-branch/gcc/config/i386/emmintrin.h  (revision 124164)
4872 @@ -1,4 +1,4 @@
4873 -/* Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
4874 +/* Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
4875  
4876     This file is part of GCC.
4877  
4878 @@ -40,8 +40,10 @@
4879  typedef short __v8hi __attribute__ ((__vector_size__ (16)));
4880  typedef char __v16qi __attribute__ ((__vector_size__ (16)));
4881  
4882 -typedef __v2di __m128i;
4883 -typedef __v2df __m128d;
4884 +/* The Intel API is flexible enough that we must allow aliasing with other
4885 +   vector types, and their scalar components.  */
4886 +typedef long long __m128i __attribute__ ((__vector_size__ (16), __may_alias__));
4887 +typedef double __m128d __attribute__ ((__vector_size__ (16), __may_alias__));
4888  
4889  /* Create a selector for use with the SHUFPD instruction.  */
4890  #define _MM_SHUFFLE2(fp1,fp0) \
4891 @@ -1098,6 +1100,7 @@
4892    return (__m128i)__builtin_ia32_pmuludq128 ((__v4si)__A, (__v4si)__B);
4893  }
4894  
4895 +#if 0
4896  static __inline __m128i __attribute__((__always_inline__))
4897  _mm_slli_epi16 (__m128i __A, int __B)
4898  {
4899 @@ -1115,7 +1118,16 @@
4900  {
4901    return (__m128i)__builtin_ia32_psllqi128 ((__v2di)__A, __B);
4902  }
4903 +#else
4904 +#define _mm_slli_epi16(__A, __B) \
4905 +  ((__m128i)__builtin_ia32_psllwi128 ((__v8hi)(__A), __B))
4906 +#define _mm_slli_epi32(__A, __B) \
4907 +  ((__m128i)__builtin_ia32_pslldi128 ((__v8hi)(__A), __B))
4908 +#define _mm_slli_epi64(__A, __B) \
4909 +  ((__m128i)__builtin_ia32_psllqi128 ((__v8hi)(__A), __B))
4910 +#endif
4911  
4912 +#if 0
4913  static __inline __m128i __attribute__((__always_inline__))
4914  _mm_srai_epi16 (__m128i __A, int __B)
4915  {
4916 @@ -1127,18 +1139,24 @@
4917  {
4918    return (__m128i)__builtin_ia32_psradi128 ((__v4si)__A, __B);
4919  }
4920 +#else
4921 +#define _mm_srai_epi16(__A, __B) \
4922 +  ((__m128i)__builtin_ia32_psrawi128 ((__v8hi)(__A), __B))
4923 +#define _mm_srai_epi32(__A, __B) \
4924 +  ((__m128i)__builtin_ia32_psradi128 ((__v8hi)(__A), __B))
4925 +#endif
4926  
4927  #if 0
4928  static __m128i __attribute__((__always_inline__))
4929 -_mm_srli_si128 (__m128i __A, const int __B)
4930 +_mm_srli_si128 (__m128i __A, int __B)
4931  {
4932 -  return ((__m128i)__builtin_ia32_psrldqi128 (__A, __B))
4933 +  return ((__m128i)__builtin_ia32_psrldqi128 (__A, __B * 8));
4934  }
4935  
4936  static __m128i __attribute__((__always_inline__))
4937 -_mm_srli_si128 (__m128i __A, const int __B)
4938 +_mm_srli_si128 (__m128i __A, int __B)
4939  {
4940 -  return ((__m128i)__builtin_ia32_pslldqi128 (__A, __B))
4941 +  return ((__m128i)__builtin_ia32_pslldqi128 (__A, __B * 8));
4942  }
4943  #else
4944  #define _mm_srli_si128(__A, __B) \
4945 @@ -1147,6 +1165,7 @@
4946    ((__m128i)__builtin_ia32_pslldqi128 (__A, (__B) * 8))
4947  #endif
4948  
4949 +#if 0
4950  static __inline __m128i __attribute__((__always_inline__))
4951  _mm_srli_epi16 (__m128i __A, int __B)
4952  {
4953 @@ -1164,53 +1183,61 @@
4954  {
4955    return (__m128i)__builtin_ia32_psrlqi128 ((__v2di)__A, __B);
4956  }
4957 +#else
4958 +#define _mm_srli_epi16(__A, __B) \
4959 +  ((__m128i)__builtin_ia32_psrlwi128 ((__v8hi)(__A), __B))
4960 +#define _mm_srli_epi32(__A, __B) \
4961 +  ((__m128i)__builtin_ia32_psrldi128 ((__v4si)(__A), __B))
4962 +#define _mm_srli_epi64(__A, __B) \
4963 +  ((__m128i)__builtin_ia32_psrlqi128 ((__v4si)(__A), __B))
4964 +#endif
4965  
4966  static __inline __m128i __attribute__((__always_inline__))
4967  _mm_sll_epi16 (__m128i __A, __m128i __B)
4968  {
4969 -  return _mm_slli_epi16 (__A, _mm_cvtsi128_si32 (__B));
4970 +  return (__m128i)__builtin_ia32_psllw128((__v8hi)__A, (__v8hi)__B);
4971  }
4972  
4973  static __inline __m128i __attribute__((__always_inline__))
4974  _mm_sll_epi32 (__m128i __A, __m128i __B)
4975  {
4976 -  return _mm_slli_epi32 (__A, _mm_cvtsi128_si32 (__B));
4977 +  return (__m128i)__builtin_ia32_pslld128((__v4si)__A, (__v4si)__B);
4978  }
4979  
4980  static __inline __m128i __attribute__((__always_inline__))
4981  _mm_sll_epi64 (__m128i __A, __m128i __B)
4982  {
4983 -  return _mm_slli_epi64 (__A, _mm_cvtsi128_si32 (__B));
4984 +  return (__m128i)__builtin_ia32_psllq128((__v2di)__A, (__v2di)__B);
4985  }
4986  
4987  static __inline __m128i __attribute__((__always_inline__))
4988  _mm_sra_epi16 (__m128i __A, __m128i __B)
4989  {
4990 -  return _mm_srai_epi16 (__A, _mm_cvtsi128_si32 (__B));
4991 +  return (__m128i)__builtin_ia32_psraw128 ((__v8hi)__A, (__v8hi)__B);
4992  }
4993  
4994  static __inline __m128i __attribute__((__always_inline__))
4995  _mm_sra_epi32 (__m128i __A, __m128i __B)
4996  {
4997 -  return _mm_srai_epi32 (__A, _mm_cvtsi128_si32 (__B));
4998 +  return (__m128i)__builtin_ia32_psrad128 ((__v4si)__A, (__v4si)__B);
4999  }
5000  
5001  static __inline __m128i __attribute__((__always_inline__))
5002  _mm_srl_epi16 (__m128i __A, __m128i __B)
5003  {
5004 -  return _mm_srli_epi16 (__A, _mm_cvtsi128_si32 (__B));
5005 +  return (__m128i)__builtin_ia32_psrlw128 ((__v8hi)__A, (__v8hi)__B);
5006  }
5007  
5008  static __inline __m128i __attribute__((__always_inline__))
5009  _mm_srl_epi32 (__m128i __A, __m128i __B)
5010  {
5011 -  return _mm_srli_epi32 (__A, _mm_cvtsi128_si32 (__B));
5012 +  return (__m128i)__builtin_ia32_psrld128 ((__v4si)__A, (__v4si)__B);
5013  }
5014  
5015  static __inline __m128i __attribute__((__always_inline__))
5016  _mm_srl_epi64 (__m128i __A, __m128i __B)
5017  {
5018 -  return _mm_srli_epi64 (__A, _mm_cvtsi128_si32 (__B));
5019 +  return (__m128i)__builtin_ia32_psrlq128 ((__v2di)__A, (__v2di)__B);
5020  }
5021  
5022  static __inline __m128i __attribute__((__always_inline__))
5023 Index: gcc-4_2-branch/gcc/config/i386/sync.md
5024 ===================================================================
5025 --- gcc-4_2-branch/gcc/config/i386/sync.md      (revision 123014)
5026 +++ gcc-4_2-branch/gcc/config/i386/sync.md      (revision 124164)
5027 @@ -98,6 +98,15 @@
5028    ""
5029    "lock\;cmpxchg<doublemodesuffix>b\t%1")
5030  
5031 +;; Theoretically we'd like to use constraint "r" (any reg) for operand
5032 +;; 3, but that includes ecx.  If operand 3 and 4 are the same (like when
5033 +;; the input is -1LL) GCC might chose to allocate operand 3 to ecx, like
5034 +;; operand 4.  This breaks, as the xchg will move the PIC register contents
5035 +;; to %ecx then --> boom.  Operands 3 and 4 really need to be different
5036 +;; registers, which in this case means operand 3 must not be ecx.
5037 +;; Instead of playing tricks with fake early clobbers or the like we
5038 +;; just enumerate all regs possible here, which (as this is !TARGET_64BIT)
5039 +;; are just esi and edi.
5040  (define_insn "*sync_double_compare_and_swapdi_pic"
5041    [(set (match_operand:DI 0 "register_operand" "=A")
5042         (match_operand:DI 1 "memory_operand" "+m"))
5043 @@ -105,7 +114,7 @@
5044         (unspec_volatile:DI
5045           [(match_dup 1)
5046            (match_operand:DI 2 "register_operand" "A")
5047 -          (match_operand:SI 3 "register_operand" "r")
5048 +          (match_operand:SI 3 "register_operand" "SD")
5049            (match_operand:SI 4 "register_operand" "c")]
5050           UNSPECV_CMPXCHG_1))
5051     (clobber (reg:CC FLAGS_REG))]
5052 @@ -189,6 +198,8 @@
5053    ""
5054    "lock\;cmpxchg<doublemodesuffix>b\t%1")
5055  
5056 +;; See above for the explanation of using the constraint "SD" for
5057 +;; operand 3.
5058  (define_insn "*sync_double_compare_and_swap_ccdi_pic"
5059    [(set (match_operand:DI 0 "register_operand" "=A")
5060         (match_operand:DI 1 "memory_operand" "+m"))
5061 @@ -196,7 +207,7 @@
5062         (unspec_volatile:DI
5063           [(match_dup 1)
5064            (match_operand:DI 2 "register_operand" "A")
5065 -          (match_operand:SI 3 "register_operand" "r")
5066 +          (match_operand:SI 3 "register_operand" "SD")
5067            (match_operand:SI 4 "register_operand" "c")]
5068           UNSPECV_CMPXCHG_1))
5069     (set (reg:CCZ FLAGS_REG)
5070 Index: gcc-4_2-branch/gcc/config/i386/i386.c
5071 ===================================================================
5072 --- gcc-4_2-branch/gcc/config/i386/i386.c       (revision 123014)
5073 +++ gcc-4_2-branch/gcc/config/i386/i386.c       (revision 124164)
5074 @@ -14666,7 +14666,7 @@
5075      BUILTIN_DESC_SWAP_OPERANDS },
5076    { MASK_SSE, CODE_FOR_sse_vmmaskcmpv4sf3, "__builtin_ia32_cmpngess", IX86_BUILTIN_CMPNGESS, UNGT,
5077      BUILTIN_DESC_SWAP_OPERANDS },
5078 -  { MASK_SSE, CODE_FOR_sse_vmmaskcmpv4sf3, "__builtin_ia32_cmpordss", IX86_BUILTIN_CMPORDSS, UNORDERED, 0 },
5079 +  { MASK_SSE, CODE_FOR_sse_vmmaskcmpv4sf3, "__builtin_ia32_cmpordss", IX86_BUILTIN_CMPORDSS, ORDERED, 0 },
5080  
5081    { MASK_SSE, CODE_FOR_sminv4sf3, "__builtin_ia32_minps", IX86_BUILTIN_MINPS, 0, 0 },
5082    { MASK_SSE, CODE_FOR_smaxv4sf3, "__builtin_ia32_maxps", IX86_BUILTIN_MAXPS, 0, 0 },
5083 @@ -15206,12 +15206,6 @@
5084    tree v8hi_ftype_v8hi_int
5085      = build_function_type_list (V8HI_type_node,
5086                                 V8HI_type_node, integer_type_node, NULL_TREE);
5087 -  tree v8hi_ftype_v8hi_v2di
5088 -    = build_function_type_list (V8HI_type_node,
5089 -                               V8HI_type_node, V2DI_type_node, NULL_TREE);
5090 -  tree v4si_ftype_v4si_v2di
5091 -    = build_function_type_list (V4SI_type_node,
5092 -                               V4SI_type_node, V2DI_type_node, NULL_TREE);
5093    tree v4si_ftype_v8hi_v8hi
5094      = build_function_type_list (V4SI_type_node,
5095                                 V8HI_type_node, V8HI_type_node, NULL_TREE);
5096 @@ -15479,16 +15473,16 @@
5097    def_builtin (MASK_SSE2, "__builtin_ia32_pmuludq", di_ftype_v2si_v2si, IX86_BUILTIN_PMULUDQ);
5098    def_builtin (MASK_SSE2, "__builtin_ia32_pmuludq128", v2di_ftype_v4si_v4si, IX86_BUILTIN_PMULUDQ128);
5099  
5100 -  def_builtin (MASK_SSE2, "__builtin_ia32_psllw128", v8hi_ftype_v8hi_v2di, IX86_BUILTIN_PSLLW128);
5101 -  def_builtin (MASK_SSE2, "__builtin_ia32_pslld128", v4si_ftype_v4si_v2di, IX86_BUILTIN_PSLLD128);
5102 +  def_builtin (MASK_SSE2, "__builtin_ia32_psllw128", v8hi_ftype_v8hi_v8hi, IX86_BUILTIN_PSLLW128);
5103 +  def_builtin (MASK_SSE2, "__builtin_ia32_pslld128", v4si_ftype_v4si_v4si, IX86_BUILTIN_PSLLD128);
5104    def_builtin (MASK_SSE2, "__builtin_ia32_psllq128", v2di_ftype_v2di_v2di, IX86_BUILTIN_PSLLQ128);
5105  
5106 -  def_builtin (MASK_SSE2, "__builtin_ia32_psrlw128", v8hi_ftype_v8hi_v2di, IX86_BUILTIN_PSRLW128);
5107 -  def_builtin (MASK_SSE2, "__builtin_ia32_psrld128", v4si_ftype_v4si_v2di, IX86_BUILTIN_PSRLD128);
5108 +  def_builtin (MASK_SSE2, "__builtin_ia32_psrlw128", v8hi_ftype_v8hi_v8hi, IX86_BUILTIN_PSRLW128);
5109 +  def_builtin (MASK_SSE2, "__builtin_ia32_psrld128", v4si_ftype_v4si_v4si, IX86_BUILTIN_PSRLD128);
5110    def_builtin (MASK_SSE2, "__builtin_ia32_psrlq128", v2di_ftype_v2di_v2di, IX86_BUILTIN_PSRLQ128);
5111  
5112 -  def_builtin (MASK_SSE2, "__builtin_ia32_psraw128", v8hi_ftype_v8hi_v2di, IX86_BUILTIN_PSRAW128);
5113 -  def_builtin (MASK_SSE2, "__builtin_ia32_psrad128", v4si_ftype_v4si_v2di, IX86_BUILTIN_PSRAD128);
5114 +  def_builtin (MASK_SSE2, "__builtin_ia32_psraw128", v8hi_ftype_v8hi_v8hi, IX86_BUILTIN_PSRAW128);
5115 +  def_builtin (MASK_SSE2, "__builtin_ia32_psrad128", v4si_ftype_v4si_v4si, IX86_BUILTIN_PSRAD128);
5116  
5117    def_builtin (MASK_SSE2, "__builtin_ia32_pslldqi128", v2di_ftype_v2di_int, IX86_BUILTIN_PSLLDQI128);
5118    def_builtin (MASK_SSE2, "__builtin_ia32_psllwi128", v8hi_ftype_v8hi_int, IX86_BUILTIN_PSLLWI128);
5119 @@ -15968,7 +15962,7 @@
5120    enum machine_mode tmode, mode1;
5121    tree arg0, arg1, arg2;
5122    int elt;
5123 -  rtx op0, op1;
5124 +  rtx op0, op1, target;
5125  
5126    arg0 = TREE_VALUE (arglist);
5127    arg1 = TREE_VALUE (TREE_CHAIN (arglist));
5128 @@ -15988,9 +15982,13 @@
5129    op0 = force_reg (tmode, op0);
5130    op1 = force_reg (mode1, op1);
5131  
5132 -  ix86_expand_vector_set (true, op0, op1, elt);
5133 +  /* OP0 is the source of these builtin functions and shouldn't be
5134 +     modified.  Create a copy, use it and return it as target.  */
5135 +  target = gen_reg_rtx (tmode);
5136 +  emit_move_insn (target, op0);
5137 +  ix86_expand_vector_set (true, target, op1, elt);
5138  
5139 -  return op0;
5140 +  return target;
5141  }
5142  
5143  /* Expand an expression EXP that calls a built-in function,
5144 @@ -16204,9 +16202,106 @@
5145        emit_insn (pat);
5146        return target;
5147  
5148 +    case IX86_BUILTIN_PSLLWI128:
5149 +      icode = CODE_FOR_ashlv8hi3;
5150 +      goto do_pshifti;
5151 +    case IX86_BUILTIN_PSLLDI128:
5152 +      icode = CODE_FOR_ashlv4si3;
5153 +      goto do_pshifti;
5154 +    case IX86_BUILTIN_PSLLQI128:
5155 +      icode = CODE_FOR_ashlv2di3;
5156 +      goto do_pshifti;
5157 +    case IX86_BUILTIN_PSRAWI128:
5158 +      icode = CODE_FOR_ashrv8hi3;
5159 +      goto do_pshifti;
5160 +    case IX86_BUILTIN_PSRADI128:
5161 +      icode = CODE_FOR_ashrv4si3;
5162 +      goto do_pshifti;
5163 +    case IX86_BUILTIN_PSRLWI128:
5164 +      icode = CODE_FOR_lshrv8hi3;
5165 +      goto do_pshifti;
5166 +    case IX86_BUILTIN_PSRLDI128:
5167 +      icode = CODE_FOR_lshrv4si3;
5168 +      goto do_pshifti;
5169 +    case IX86_BUILTIN_PSRLQI128:
5170 +      icode = CODE_FOR_lshrv2di3;
5171 +      goto do_pshifti;
5172 +    do_pshifti:
5173 +      arg0 = TREE_VALUE (arglist);
5174 +      arg1 = TREE_VALUE (TREE_CHAIN (arglist));
5175 +      op0 = expand_expr (arg0, NULL_RTX, VOIDmode, 0);
5176 +      op1 = expand_expr (arg1, NULL_RTX, VOIDmode, 0);
5177 +
5178 +      if (GET_CODE (op1) != CONST_INT)
5179 +       {
5180 +         error ("shift must be an immediate");
5181 +         return const0_rtx;
5182 +       }
5183 +      if (INTVAL (op1) < 0 || INTVAL (op1) > 255)
5184 +       op1 = GEN_INT (255);
5185 +
5186 +      tmode = insn_data[icode].operand[0].mode;
5187 +      mode1 = insn_data[icode].operand[1].mode;
5188 +      if (! (*insn_data[icode].operand[1].predicate) (op0, mode1))
5189 +       op0 = copy_to_reg (op0);
5190 +
5191 +      target = gen_reg_rtx (tmode);
5192 +      pat = GEN_FCN (icode) (target, op0, op1);
5193 +      if (!pat)
5194 +       return 0;
5195 +      emit_insn (pat);
5196 +      return target;
5197 +
5198 +    case IX86_BUILTIN_PSLLW128:
5199 +      icode = CODE_FOR_ashlv8hi3;
5200 +      goto do_pshift;
5201 +    case IX86_BUILTIN_PSLLD128:
5202 +      icode = CODE_FOR_ashlv4si3;
5203 +      goto do_pshift;
5204 +    case IX86_BUILTIN_PSLLQ128:
5205 +      icode = CODE_FOR_ashlv2di3;
5206 +      goto do_pshift;
5207 +    case IX86_BUILTIN_PSRAW128:
5208 +      icode = CODE_FOR_ashrv8hi3;
5209 +      goto do_pshift;
5210 +    case IX86_BUILTIN_PSRAD128:
5211 +      icode = CODE_FOR_ashrv4si3;
5212 +      goto do_pshift;
5213 +    case IX86_BUILTIN_PSRLW128:
5214 +      icode = CODE_FOR_lshrv8hi3;
5215 +      goto do_pshift;
5216 +    case IX86_BUILTIN_PSRLD128:
5217 +      icode = CODE_FOR_lshrv4si3;
5218 +      goto do_pshift;
5219 +    case IX86_BUILTIN_PSRLQ128:
5220 +      icode = CODE_FOR_lshrv2di3;
5221 +      goto do_pshift;
5222 +    do_pshift:
5223 +      arg0 = TREE_VALUE (arglist);
5224 +      arg1 = TREE_VALUE (TREE_CHAIN (arglist));
5225 +      op0 = expand_expr (arg0, NULL_RTX, VOIDmode, 0);
5226 +      op1 = expand_expr (arg1, NULL_RTX, VOIDmode, 0);
5227 +
5228 +      tmode = insn_data[icode].operand[0].mode;
5229 +      mode1 = insn_data[icode].operand[1].mode;
5230 +
5231 +      if (! (*insn_data[icode].operand[1].predicate) (op0, mode1))
5232 +       op0 = copy_to_reg (op0);
5233 +
5234 +      op1 = simplify_gen_subreg (TImode, op1, GET_MODE (op1), 0);
5235 +      if (! (*insn_data[icode].operand[2].predicate) (op1, TImode))
5236 +       op1 = copy_to_reg (op1);
5237 +
5238 +      target = gen_reg_rtx (tmode);
5239 +      pat = GEN_FCN (icode) (target, op0, op1);
5240 +      if (!pat)
5241 +       return 0;
5242 +      emit_insn (pat);
5243 +      return target;
5244 +
5245      case IX86_BUILTIN_PSLLDQI128:
5246      case IX86_BUILTIN_PSRLDQI128:
5247 -      icode = (  fcode == IX86_BUILTIN_PSLLDQI128 ? CODE_FOR_sse2_ashlti3
5248 +      icode = (fcode == IX86_BUILTIN_PSLLDQI128 ? CODE_FOR_sse2_ashlti3
5249                : CODE_FOR_sse2_lshrti3);
5250        arg0 = TREE_VALUE (arglist);
5251        arg1 = TREE_VALUE (TREE_CHAIN (arglist));
5252 @@ -16227,7 +16322,8 @@
5253           return const0_rtx;
5254         }
5255        target = gen_reg_rtx (V2DImode);
5256 -      pat = GEN_FCN (icode) (simplify_gen_subreg (tmode, target, V2DImode, 0), op0, op1);
5257 +      pat = GEN_FCN (icode) (simplify_gen_subreg (tmode, target, V2DImode, 0),
5258 +                            op0, op1);
5259        if (! pat)
5260         return 0;
5261        emit_insn (pat);
5262 Index: gcc-4_2-branch/gcc/config/avr/predicates.md
5263 ===================================================================
5264 --- gcc-4_2-branch/gcc/config/avr/predicates.md (revision 123014)
5265 +++ gcc-4_2-branch/gcc/config/avr/predicates.md (revision 124164)
5266 @@ -1,5 +1,5 @@
5267  ;; Predicate definitions for ATMEL AVR micro controllers.
5268 -;; Copyright (C) 2006 Free Software Foundation, Inc.
5269 +;; Copyright (C) 2006, 2007 Free Software Foundation, Inc.
5270  ;;
5271  ;; This file is part of GCC.
5272  ;;
5273 @@ -33,23 +33,15 @@
5274    (and (match_code "reg")
5275         (match_test "REGNO (op) == REG_SP")))
5276  
5277 -;; Return true if OP is a valid address for an I/O register.
5278 -(define_predicate "io_address_operand"
5279 -  (and (match_code "const_int")
5280 -       (match_test "INTVAL (op) >= 0x20 
5281 -                    && INTVAL (op) <= 0x60 - GET_MODE_SIZE (mode)")))
5282 -
5283  ;; Return true if OP is a valid address for lower half of I/O space.
5284  (define_predicate "low_io_address_operand"
5285    (and (match_code "const_int")
5286 -       (match_test "INTVAL (op) >= 0x20 
5287 -                    && INTVAL (op) <= 0x40 - GET_MODE_SIZE (mode)")))
5288 -       
5289 -;; Return true if OP is a valid address for higth half of I/O space.
5290 -(define_predicate "higth_io_address_operand"
5291 +       (match_test "IN_RANGE((INTVAL (op)), 0x20, 0x3F)")))
5292 +
5293 +;; Return true if OP is a valid address for high half of I/O space.
5294 +(define_predicate "high_io_address_operand"
5295    (and (match_code "const_int")
5296 -       (match_test "INTVAL (op) >= 0x40 
5297 -                    && INTVAL (op) <= 0x60 - GET_MODE_SIZE (mode)")))
5298 +       (match_test "IN_RANGE((INTVAL (op)), 0x40, 0x5F)")))
5299         
5300  ;; Returns 1 if OP is a SYMBOL_REF.
5301  (define_predicate "symbol_ref_operand"
5302 Index: gcc-4_2-branch/gcc/config/avr/avr.md
5303 ===================================================================
5304 --- gcc-4_2-branch/gcc/config/avr/avr.md        (revision 123014)
5305 +++ gcc-4_2-branch/gcc/config/avr/avr.md        (revision 124164)
5306 @@ -1,7 +1,7 @@
5307  ;; -*- Mode: Scheme -*-
5308  ;;   Machine description for GNU compiler,
5309  ;;   for ATMEL AVR micro controllers.
5310 -;;   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006
5311 +;;   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006, 2007
5312  ;;   Free Software Foundation, Inc.
5313  ;;   Contributed by Denis Chertykov (denisc@overta.ru)
5314  
5315 @@ -463,7 +463,7 @@
5316     (use (match_operand:QI 1 "register_operand" "r"))
5317     (use (match_operand:QI 2 "const_int_operand" "n"))
5318     (clobber (match_scratch:HI 3 "=0"))
5319 -   (clobber (match_scratch:QI 4 "=1"))]
5320 +   (clobber (match_scratch:QI 4 "=&1"))]
5321    ""
5322    "st %a0+,__zero_reg__
5323          dec %1
5324 @@ -477,7 +477,7 @@
5325     (use (match_operand:HI 1 "register_operand" "!w,d"))
5326     (use (match_operand:HI 2 "const_int_operand" "n,n"))
5327     (clobber (match_scratch:HI 3 "=0,0"))
5328 -   (clobber (match_scratch:HI 4 "=1,1"))]
5329 +   (clobber (match_scratch:HI 4 "=&1,&1"))]
5330    ""
5331    "*{
5332       if (which_alternative==0)
5333 @@ -2364,7 +2364,7 @@
5334         (if_then_else
5335          (match_operator 0 "eqne_operator"
5336                          [(zero_extract
5337 -                          (mem:QI (match_operand 1 "higth_io_address_operand" "n"))
5338 +                          (mem:QI (match_operand 1 "high_io_address_operand" "n"))
5339                            (const_int 1)
5340                            (match_operand 2 "const_int_operand" "n"))
5341                           (const_int 0)])
5342 @@ -2385,7 +2385,7 @@
5343    [(set (pc)
5344         (if_then_else
5345          (match_operator 0 "gelt_operator"
5346 -                        [(mem:QI (match_operand 1 "higth_io_address_operand" "n"))
5347 +                        [(mem:QI (match_operand 1 "high_io_address_operand" "n"))
5348                           (const_int 0)])
5349          (label_ref (match_operand 2 "" ""))
5350          (pc)))]
5351 Index: gcc-4_2-branch/gcc/config/avr/avr.c
5352 ===================================================================
5353 --- gcc-4_2-branch/gcc/config/avr/avr.c (revision 123014)
5354 +++ gcc-4_2-branch/gcc/config/avr/avr.c (revision 124164)
5355 @@ -1,5 +1,5 @@
5356  /* Subroutines for insn-output.c for ATMEL AVR micro controllers
5357 -   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006
5358 +   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006, 2007
5359     Free Software Foundation, Inc.
5360     Contributed by Denis Chertykov (denisc@overta.ru)
5361  
5362 @@ -141,12 +141,26 @@
5363    { 1, 0, 0, 0,  NULL },  /* unknown device specified */
5364    { 1, 0, 0, 0, "__AVR_ARCH__=1" },
5365    { 0, 0, 0, 0, "__AVR_ARCH__=2" },
5366 +  { 0, 0, 0, 1, "__AVR_ARCH__=25"},
5367    { 0, 0, 1, 0, "__AVR_ARCH__=3" },
5368    { 0, 1, 0, 1, "__AVR_ARCH__=4" },
5369 -  { 0, 1, 1, 1, "__AVR_ARCH__=5" },
5370 -  { 0, 0, 0, 1, "__AVR_ARCH__=25"}
5371 +  { 0, 1, 1, 1, "__AVR_ARCH__=5" }
5372  };
5373  
5374 +/* These names are used as the index into the avr_arch_types[] table 
5375 +   above.  */
5376 +
5377 +enum avr_arch
5378 +{
5379 +  ARCH_UNKNOWN,
5380 +  ARCH_AVR1,
5381 +  ARCH_AVR2,
5382 +  ARCH_AVR25,
5383 +  ARCH_AVR3,
5384 +  ARCH_AVR4,
5385 +  ARCH_AVR5
5386 +};
5387 +
5388  struct mcu_type_s {
5389    const char *const name;
5390    int arch;  /* index in avr_arch_types[] */
5391 @@ -164,103 +178,103 @@
5392  
5393  static const struct mcu_type_s avr_mcu_types[] = {
5394      /* Classic, <= 8K.  */
5395 -  { "avr2",      2, NULL },
5396 -  { "at90s2313", 2, "__AVR_AT90S2313__" },
5397 -  { "at90s2323", 2, "__AVR_AT90S2323__" },
5398 -  { "at90s2333", 2, "__AVR_AT90S2333__" },
5399 -  { "at90s2343", 2, "__AVR_AT90S2343__" },
5400 -  { "attiny22",  2, "__AVR_ATtiny22__" },
5401 -  { "attiny26",  2, "__AVR_ATtiny26__" },
5402 -  { "at90s4414", 2, "__AVR_AT90S4414__" },
5403 -  { "at90s4433", 2, "__AVR_AT90S4433__" },
5404 -  { "at90s4434", 2, "__AVR_AT90S4434__" },
5405 -  { "at90s8515", 2, "__AVR_AT90S8515__" },
5406 -  { "at90c8534", 2, "__AVR_AT90C8534__" },
5407 -  { "at90s8535", 2, "__AVR_AT90S8535__" },
5408 +  { "avr2",         ARCH_AVR2, NULL },
5409 +  { "at90s2313",    ARCH_AVR2, "__AVR_AT90S2313__" },
5410 +  { "at90s2323",    ARCH_AVR2, "__AVR_AT90S2323__" },
5411 +  { "at90s2333",    ARCH_AVR2, "__AVR_AT90S2333__" },
5412 +  { "at90s2343",    ARCH_AVR2, "__AVR_AT90S2343__" },
5413 +  { "attiny22",     ARCH_AVR2, "__AVR_ATtiny22__" },
5414 +  { "attiny26",     ARCH_AVR2, "__AVR_ATtiny26__" },
5415 +  { "at90s4414",    ARCH_AVR2, "__AVR_AT90S4414__" },
5416 +  { "at90s4433",    ARCH_AVR2, "__AVR_AT90S4433__" },
5417 +  { "at90s4434",    ARCH_AVR2, "__AVR_AT90S4434__" },
5418 +  { "at90s8515",    ARCH_AVR2, "__AVR_AT90S8515__" },
5419 +  { "at90c8534",    ARCH_AVR2, "__AVR_AT90C8534__" },
5420 +  { "at90s8535",    ARCH_AVR2, "__AVR_AT90S8535__" },
5421      /* Classic + MOVW, <= 8K.  */
5422 -  { "avr25",      6, NULL },
5423 -  { "attiny13",   6, "__AVR_ATtiny13__" },
5424 -  { "attiny2313", 6, "__AVR_ATtiny2313__" },
5425 -  { "attiny24",   6, "__AVR_ATtiny24__" },
5426 -  { "attiny44",   6, "__AVR_ATtiny44__" },
5427 -  { "attiny84",   6, "__AVR_ATtiny84__" },
5428 -  { "attiny25",   6, "__AVR_ATtiny25__" },
5429 -  { "attiny45",   6, "__AVR_ATtiny45__" },
5430 -  { "attiny85",   6, "__AVR_ATtiny85__" },
5431 -  { "attiny261",  6, "__AVR_ATtiny261__" },
5432 -  { "attiny461",  6, "__AVR_ATtiny461__" },
5433 -  { "attiny861",  6, "__AVR_ATtiny861__" },
5434 -  { "at86rf401",  6, "__AVR_AT86RF401__" },
5435 +  { "avr25",        ARCH_AVR25, NULL },
5436 +  { "attiny13",     ARCH_AVR25, "__AVR_ATtiny13__" },
5437 +  { "attiny2313",   ARCH_AVR25, "__AVR_ATtiny2313__" },
5438 +  { "attiny24",     ARCH_AVR25, "__AVR_ATtiny24__" },
5439 +  { "attiny44",     ARCH_AVR25, "__AVR_ATtiny44__" },
5440 +  { "attiny84",     ARCH_AVR25, "__AVR_ATtiny84__" },
5441 +  { "attiny25",     ARCH_AVR25, "__AVR_ATtiny25__" },
5442 +  { "attiny45",     ARCH_AVR25, "__AVR_ATtiny45__" },
5443 +  { "attiny85",     ARCH_AVR25, "__AVR_ATtiny85__" },
5444 +  { "attiny261",    ARCH_AVR25, "__AVR_ATtiny261__" },
5445 +  { "attiny461",    ARCH_AVR25, "__AVR_ATtiny461__" },
5446 +  { "attiny861",    ARCH_AVR25, "__AVR_ATtiny861__" },
5447 +  { "at86rf401",    ARCH_AVR25, "__AVR_AT86RF401__" },
5448      /* Classic, > 8K.  */
5449 -  { "avr3",      3, NULL },
5450 -  { "atmega103", 3, "__AVR_ATmega103__" },
5451 -  { "atmega603", 3, "__AVR_ATmega603__" },
5452 -  { "at43usb320", 3, "__AVR_AT43USB320__" },
5453 -  { "at43usb355", 3, "__AVR_AT43USB355__" },
5454 -  { "at76c711",  3, "__AVR_AT76C711__" },
5455 +  { "avr3",         ARCH_AVR3, NULL },
5456 +  { "atmega103",    ARCH_AVR3, "__AVR_ATmega103__" },
5457 +  { "atmega603",    ARCH_AVR3, "__AVR_ATmega603__" },
5458 +  { "at43usb320",   ARCH_AVR3, "__AVR_AT43USB320__" },
5459 +  { "at43usb355",   ARCH_AVR3, "__AVR_AT43USB355__" },
5460 +  { "at76c711",     ARCH_AVR3, "__AVR_AT76C711__" },
5461      /* Enhanced, <= 8K.  */
5462 -  { "avr4",      4, NULL },
5463 -  { "atmega8",   4, "__AVR_ATmega8__" },
5464 -  { "atmega48",   4, "__AVR_ATmega48__" },
5465 -  { "atmega88",   4, "__AVR_ATmega88__" },
5466 -  { "atmega8515", 4, "__AVR_ATmega8515__" },
5467 -  { "atmega8535", 4, "__AVR_ATmega8535__" },
5468 -  { "at90pwm1",  4, "__AVR_AT90PWM1__" },
5469 -  { "at90pwm2",  4, "__AVR_AT90PWM2__" },
5470 -  { "at90pwm3",  4, "__AVR_AT90PWM3__" },
5471 -  { "at90usb82",   5, "__AVR_AT90USB82__" },
5472 +  { "avr4",         ARCH_AVR4, NULL },
5473 +  { "atmega8",      ARCH_AVR4, "__AVR_ATmega8__" },
5474 +  { "atmega48",     ARCH_AVR4, "__AVR_ATmega48__" },
5475 +  { "atmega88",     ARCH_AVR4, "__AVR_ATmega88__" },
5476 +  { "atmega8515",   ARCH_AVR4, "__AVR_ATmega8515__" },
5477 +  { "atmega8535",   ARCH_AVR4, "__AVR_ATmega8535__" },
5478 +  { "at90pwm1",     ARCH_AVR4, "__AVR_AT90PWM1__" },
5479 +  { "at90pwm2",     ARCH_AVR4, "__AVR_AT90PWM2__" },
5480 +  { "at90pwm3",     ARCH_AVR4, "__AVR_AT90PWM3__" },
5481 +  { "at90usb82",    ARCH_AVR4, "__AVR_AT90USB82__" },
5482      /* Enhanced, > 8K.  */
5483 -  { "avr5",      5, NULL },
5484 -  { "atmega16",  5, "__AVR_ATmega16__" },
5485 -  { "atmega161", 5, "__AVR_ATmega161__" },
5486 -  { "atmega162", 5, "__AVR_ATmega162__" },
5487 -  { "atmega163", 5, "__AVR_ATmega163__" },
5488 -  { "atmega164p",5, "__AVR_ATmega164P__" },
5489 -  { "atmega165", 5, "__AVR_ATmega165__" },
5490 -  { "atmega165p",5, "__AVR_ATmega165P__" },
5491 -  { "atmega168", 5, "__AVR_ATmega168__" },
5492 -  { "atmega169", 5, "__AVR_ATmega169__" },
5493 -  { "atmega169p",5, "__AVR_ATmega169P__" },
5494 -  { "atmega32",  5, "__AVR_ATmega32__" },
5495 -  { "atmega323", 5, "__AVR_ATmega323__" },
5496 -  { "atmega324p",5, "__AVR_ATmega324P__" },
5497 -  { "atmega325", 5, "__AVR_ATmega325__" },
5498 -  { "atmega325p",  5, "__AVR_ATmega325P__" },
5499 -  { "atmega3250", 5, "__AVR_ATmega3250__" },
5500 -  { "atmega3250p", 5, "__AVR_ATmega3250P__" },
5501 -  { "atmega329", 5, "__AVR_ATmega329__" },
5502 -  { "atmega329p",  5, "__AVR_ATmega329P__" },
5503 -  { "atmega3290", 5, "__AVR_ATmega3290__" },
5504 -  { "atmega3290p", 5, "__AVR_ATmega3290P__" },
5505 -  { "atmega406", 5, "__AVR_ATmega406__" },
5506 -  { "atmega64",  5, "__AVR_ATmega64__" },
5507 -  { "atmega640", 5, "__AVR_ATmega640__" },
5508 -  { "atmega644", 5, "__AVR_ATmega644__" },
5509 -  { "atmega644p",5, "__AVR_ATmega644P__" },
5510 -  { "atmega645", 5, "__AVR_ATmega645__" },
5511 -  { "atmega6450", 5, "__AVR_ATmega6450__" },
5512 -  { "atmega649", 5, "__AVR_ATmega649__" },
5513 -  { "atmega6490", 5, "__AVR_ATmega6490__" },
5514 -  { "atmega128", 5, "__AVR_ATmega128__" },
5515 -  { "atmega1280",5, "__AVR_ATmega1280__" },
5516 -  { "atmega1281",5, "__AVR_ATmega1281__" },
5517 -  { "at90can32", 5, "__AVR_AT90CAN32__" },
5518 -  { "at90can64", 5, "__AVR_AT90CAN64__" },
5519 -  { "at90can128", 5, "__AVR_AT90CAN128__" },
5520 -  { "at90usb162",  5, "__AVR_AT90USB162__" },
5521 -  { "at90usb646", 5, "__AVR_AT90USB646__" },
5522 -  { "at90usb647", 5, "__AVR_AT90USB647__" },
5523 -  { "at90usb1286", 5, "__AVR_AT90USB1286__" },
5524 -  { "at90usb1287", 5, "__AVR_AT90USB1287__" },
5525 -  { "at94k",     5, "__AVR_AT94K__" },
5526 +  { "avr5",         ARCH_AVR5, NULL },
5527 +  { "atmega16",     ARCH_AVR5, "__AVR_ATmega16__" },
5528 +  { "atmega161",    ARCH_AVR5, "__AVR_ATmega161__" },
5529 +  { "atmega162",    ARCH_AVR5, "__AVR_ATmega162__" },
5530 +  { "atmega163",    ARCH_AVR5, "__AVR_ATmega163__" },
5531 +  { "atmega164p",   ARCH_AVR5, "__AVR_ATmega164P__" },
5532 +  { "atmega165",    ARCH_AVR5, "__AVR_ATmega165__" },
5533 +  { "atmega165p",   ARCH_AVR5, "__AVR_ATmega165P__" },
5534 +  { "atmega168",    ARCH_AVR5, "__AVR_ATmega168__" },
5535 +  { "atmega169",    ARCH_AVR5, "__AVR_ATmega169__" },
5536 +  { "atmega169p",   ARCH_AVR5, "__AVR_ATmega169P__" },
5537 +  { "atmega32",     ARCH_AVR5, "__AVR_ATmega32__" },
5538 +  { "atmega323",    ARCH_AVR5, "__AVR_ATmega323__" },
5539 +  { "atmega324p",   ARCH_AVR5, "__AVR_ATmega324P__" },
5540 +  { "atmega325",    ARCH_AVR5, "__AVR_ATmega325__" },
5541 +  { "atmega325p",   ARCH_AVR5, "__AVR_ATmega325P__" },
5542 +  { "atmega3250",   ARCH_AVR5, "__AVR_ATmega3250__" },
5543 +  { "atmega3250p",  ARCH_AVR5, "__AVR_ATmega3250P__" },
5544 +  { "atmega329",    ARCH_AVR5, "__AVR_ATmega329__" },
5545 +  { "atmega329p",   ARCH_AVR5, "__AVR_ATmega329P__" },
5546 +  { "atmega3290",   ARCH_AVR5, "__AVR_ATmega3290__" },
5547 +  { "atmega3290p",  ARCH_AVR5, "__AVR_ATmega3290P__" },
5548 +  { "atmega406",    ARCH_AVR5, "__AVR_ATmega406__" },
5549 +  { "atmega64",     ARCH_AVR5, "__AVR_ATmega64__" },
5550 +  { "atmega640",    ARCH_AVR5, "__AVR_ATmega640__" },
5551 +  { "atmega644",    ARCH_AVR5, "__AVR_ATmega644__" },
5552 +  { "atmega644p",   ARCH_AVR5, "__AVR_ATmega644P__" },
5553 +  { "atmega645",    ARCH_AVR5, "__AVR_ATmega645__" },
5554 +  { "atmega6450",   ARCH_AVR5, "__AVR_ATmega6450__" },
5555 +  { "atmega649",    ARCH_AVR5, "__AVR_ATmega649__" },
5556 +  { "atmega6490",   ARCH_AVR5, "__AVR_ATmega6490__" },
5557 +  { "atmega128",    ARCH_AVR5, "__AVR_ATmega128__" },
5558 +  { "atmega1280",   ARCH_AVR5, "__AVR_ATmega1280__" },
5559 +  { "atmega1281",   ARCH_AVR5, "__AVR_ATmega1281__" },
5560 +  { "at90can32",    ARCH_AVR5, "__AVR_AT90CAN32__" },
5561 +  { "at90can64",    ARCH_AVR5, "__AVR_AT90CAN64__" },
5562 +  { "at90can128",   ARCH_AVR5, "__AVR_AT90CAN128__" },
5563 +  { "at90usb162",   ARCH_AVR5, "__AVR_AT90USB162__" },
5564 +  { "at90usb646",   ARCH_AVR5, "__AVR_AT90USB646__" },
5565 +  { "at90usb647",   ARCH_AVR5, "__AVR_AT90USB647__" },
5566 +  { "at90usb1286",  ARCH_AVR5, "__AVR_AT90USB1286__" },
5567 +  { "at90usb1287",  ARCH_AVR5, "__AVR_AT90USB1287__" },
5568 +  { "at94k",        ARCH_AVR5, "__AVR_AT94K__" },
5569      /* Assembler only.  */
5570 -  { "avr1",      1, NULL },
5571 -  { "at90s1200", 1, "__AVR_AT90S1200__" },
5572 -  { "attiny11",  1, "__AVR_ATtiny11__" },
5573 -  { "attiny12",  1, "__AVR_ATtiny12__" },
5574 -  { "attiny15",  1, "__AVR_ATtiny15__" },
5575 -  { "attiny28",  1, "__AVR_ATtiny28__" },
5576 -  { NULL,        0, NULL }
5577 +  { "avr1",         ARCH_AVR1, NULL },
5578 +  { "at90s1200",    ARCH_AVR1, "__AVR_AT90S1200__" },
5579 +  { "attiny11",     ARCH_AVR1, "__AVR_ATtiny11__" },
5580 +  { "attiny12",     ARCH_AVR1, "__AVR_ATtiny12__" },
5581 +  { "attiny15",     ARCH_AVR1, "__AVR_ATtiny15__" },
5582 +  { "attiny28",     ARCH_AVR1, "__AVR_ATtiny28__" },
5583 +  { NULL,           ARCH_UNKNOWN, NULL }
5584  };
5585  
5586  int avr_case_values_threshold = 30000;
5587 @@ -316,6 +330,8 @@
5588    const struct mcu_type_s *t;
5589    const struct base_arch_s *base;
5590  
5591 +  flag_delete_null_pointer_checks = 0;
5592 +
5593    for (t = avr_mcu_types; t->name; t++)
5594      if (strcmp (t->name, avr_mcu_name) == 0)
5595        break;
5596 @@ -1025,7 +1041,7 @@
5597      case REG_Y: return "Y";
5598      case REG_Z: return "Z";
5599      default:
5600 -      gcc_unreachable ();
5601 +      output_operand_lossage ("address operand requires constraint for X, Y, or Z register");
5602      }
5603    return NULL;
5604  }
5605 @@ -4698,7 +4714,7 @@
5606      }
5607    else
5608      {
5609 -      const char *func_name = IDENTIFIER_POINTER (DECL_NAME (*node));
5610 +      const char *func_name = IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (*node));
5611        const char *attr = IDENTIFIER_POINTER (name);
5612  
5613        /* If the function has the 'signal' or 'interrupt' attribute, test to
5614 @@ -5092,6 +5108,7 @@
5615             *total = COSTS_N_INSNS (AVR_MEGA ? 2 : 1);
5616           else
5617             return false;
5618 +         break;
5619  
5620         case HImode:
5621           if (AVR_ENHANCED)
5622 @@ -5100,6 +5117,7 @@
5623             *total = COSTS_N_INSNS (AVR_MEGA ? 2 : 1);
5624           else
5625             return false;
5626 +         break;
5627  
5628         default:
5629           return false;
5630 Index: gcc-4_2-branch/gcc/config/avr/avr.h
5631 ===================================================================
5632 --- gcc-4_2-branch/gcc/config/avr/avr.h (revision 123014)
5633 +++ gcc-4_2-branch/gcc/config/avr/avr.h (revision 124164)
5634 @@ -661,7 +661,11 @@
5635  #define ASM_OUTPUT_SKIP(STREAM, N)             \
5636  fprintf (STREAM, "\t.skip %lu,0\n", (unsigned long)(N))
5637  
5638 -#define ASM_OUTPUT_ALIGN(STREAM, POWER)
5639 +#define ASM_OUTPUT_ALIGN(STREAM, POWER)                        \
5640 +  do {                                                 \
5641 +      if ((POWER) > 1)                                 \
5642 +          fprintf (STREAM, "\t.p2align\t%d\n", POWER); \
5643 +  } while (0)
5644  
5645  #define CASE_VECTOR_MODE HImode
5646  
5647 @@ -758,9 +762,7 @@
5648    mmcu=at76*:-m avr3}\
5649  %{mmcu=atmega8*|\
5650    mmcu=atmega48|\
5651 -  mmcu=at90pwm1|\
5652 -  mmcu=at90pwm2|\
5653 -  mmcu=at90pwm3:-m avr4}\
5654 +  mmcu=at90pwm*:-m avr4}\
5655  %{mmcu=atmega16*|\
5656    mmcu=atmega32*|\
5657    mmcu=atmega406|\
5658 @@ -771,18 +773,14 @@
5659    mmcu=at94k:-m avr5}\
5660  %{mmcu=atmega324*|\
5661    mmcu=atmega325*|\
5662 -  mmcu=atmega3250*|\
5663    mmcu=atmega329*|\
5664 -  mmcu=atmega3290*|\
5665    mmcu=atmega406|\
5666    mmcu=atmega48|\
5667    mmcu=atmega88|\
5668    mmcu=atmega64|\
5669    mmcu=atmega644*|\
5670 -  mmcu=atmega645|\
5671 -  mmcu=atmega6450|\
5672 -  mmcu=atmega649|\
5673 -  mmcu=atmega6490|\
5674 +  mmcu=atmega645*|\
5675 +  mmcu=atmega649*|\
5676    mmcu=atmega128|\
5677    mmcu=atmega162|\
5678    mmcu=atmega164*|\
5679 Index: gcc-4_2-branch/gcc/config/rs6000/darwin.h
5680 ===================================================================
5681 --- gcc-4_2-branch/gcc/config/rs6000/darwin.h   (revision 123014)
5682 +++ gcc-4_2-branch/gcc/config/rs6000/darwin.h   (revision 124164)
5683 @@ -280,8 +280,6 @@
5684  
5685  /* This says how to output an assembler line to define a global common
5686     symbol.  */
5687 -/* ? */
5688 -#undef  ASM_OUTPUT_ALIGNED_COMMON
5689  #define ASM_OUTPUT_COMMON(FILE, NAME, SIZE, ROUNDED)                   \
5690    do {                                                                 \
5691      unsigned HOST_WIDE_INT _new_size = SIZE;                           \
5692 Index: gcc-4_2-branch/gcc/config/darwin.h
5693 ===================================================================
5694 --- gcc-4_2-branch/gcc/config/darwin.h  (revision 123014)
5695 +++ gcc-4_2-branch/gcc/config/darwin.h  (revision 124164)
5696 @@ -652,11 +652,11 @@
5697        }                                                                        \
5698    } while (0)
5699  
5700 -/* The maximum alignment which the object file format can support.
5701 -   For Mach-O, this is 2^15.  */
5702 +/* The maximum alignment which the object file format can support in
5703 +   bits.  For Mach-O, this is 2^15 bytes.  */
5704  
5705  #undef MAX_OFILE_ALIGNMENT
5706 -#define MAX_OFILE_ALIGNMENT 0x8000
5707 +#define MAX_OFILE_ALIGNMENT (0x8000 * 8)
5708  
5709  /* Declare the section variables.  */
5710  #ifndef USED_FOR_TARGET
5711 Index: gcc-4_2-branch/gcc/config/score/crti.asm
5712 ===================================================================
5713 --- gcc-4_2-branch/gcc/config/score/crti.asm    (revision 123014)
5714 +++ gcc-4_2-branch/gcc/config/score/crti.asm    (revision 124164)
5715 @@ -43,8 +43,8 @@
5716          .mask   0x00000000, 0
5717  _start:
5718          la      r28, _gp
5719 -        la      r8, _bss_start
5720 -        la      r9, _bss_end__
5721 +        la      r8, __bss_start
5722 +        la      r9, __bss_end__
5723          sub!    r9, r8
5724          srli!   r9, 2
5725          addi    r9, -1
5726 @@ -91,8 +91,8 @@
5727          .mask   0x00000000,0
5728  _start:
5729          la      r28, _gp
5730 -        la      r8, _bss_start
5731 -        la      r9, _bss_end__
5732 +        la      r8, __bss_start
5733 +        la      r9, __bss_end__
5734          sub!    r9, r8
5735          srli!   r9, 2
5736          addi    r9, -1
5737 Index: gcc-4_2-branch/gcc/config/score/misc.md
5738 ===================================================================
5739 --- gcc-4_2-branch/gcc/config/score/misc.md     (revision 123014)
5740 +++ gcc-4_2-branch/gcc/config/score/misc.md     (revision 124164)
5741 @@ -111,7 +111,7 @@
5742          (zero_extract (match_operand:SI 1 "memory_operand" "")
5743                        (match_operand:SI 2 "immediate_operand" "")
5744                        (match_operand:SI 3 "immediate_operand" "")))]
5745 -  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN"
5746 +  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN && TARGET_ULS"
5747  {
5748    if (mdx_unaligned_load (operands))
5749      DONE;
5750 @@ -124,7 +124,7 @@
5751                        (match_operand:SI 1 "immediate_operand" "")
5752                        (match_operand:SI 2 "immediate_operand" ""))
5753          (match_operand:SI 3 "register_operand" ""))]
5754 -  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN"
5755 +  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN && TARGET_ULS"
5756  {
5757    if (mdx_unaligned_store (operands))
5758      DONE;
5759 @@ -137,7 +137,7 @@
5760          (sign_extract (match_operand:SI 1 "memory_operand" "")
5761                        (match_operand:SI 2 "immediate_operand" "")
5762                        (match_operand:SI 3 "immediate_operand" "")))]
5763 -  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN"
5764 +  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN && TARGET_ULS"
5765  {
5766    if (mdx_unaligned_load (operands))
5767      DONE;
5768 @@ -150,7 +150,7 @@
5769                     (match_operand:BLK 1 "general_operand"))
5770                (use (match_operand:SI 2 ""))
5771                (use (match_operand:SI 3 "const_int_operand"))])]
5772 -  "!TARGET_SCORE5U"
5773 +  "!TARGET_SCORE5U && TARGET_ULS"
5774  {
5775    if (mdx_block_move (operands))
5776      DONE;
5777 @@ -164,7 +164,7 @@
5778                   (match_operand:SI 2 "const_simm12" "")))
5779     (set (match_operand:QI 3 "register_operand" "=d")
5780          (mem:QI (match_dup 1)))]
5781 -  "!TARGET_SCORE5U"
5782 +  ""
5783    "lbu     %3, [%1]+, %2"
5784    [(set_attr "type" "load")
5785     (set_attr "mode" "QI")])
5786 @@ -175,7 +175,7 @@
5787                   (match_operand:SI 2 "const_simm12" "")))
5788     (set (match_operand:HI 3 "register_operand" "=d")
5789          (mem:HI (match_dup 1)))]
5790 -  "!TARGET_SCORE5U"
5791 +  ""
5792    "lhu     %3, [%1]+, %2"
5793    [(set_attr "type" "load")
5794     (set_attr "mode" "HI")])
5795 @@ -186,7 +186,7 @@
5796                   (match_operand:SI 2 "const_simm12" "")))
5797     (set (match_operand:SI 3 "register_operand" "=d")
5798          (mem:SI (match_dup 1)))]
5799 -  "!TARGET_SCORE5U"
5800 +  ""
5801    "lw      %3, [%1]+, %2"
5802    [(set_attr "type" "load")
5803     (set_attr "mode" "SI")])
5804 @@ -197,7 +197,7 @@
5805                   (match_operand:SI 2 "const_simm12" "")))
5806     (set (mem:QI (match_dup 1))
5807          (match_operand:QI 3 "register_operand" "d"))]
5808 -  "!TARGET_SCORE5U"
5809 +  ""
5810    "sb      %3, [%1]+, %2"
5811    [(set_attr "type" "store")
5812     (set_attr "mode" "QI")])
5813 @@ -208,7 +208,7 @@
5814                   (match_operand:SI 2 "const_simm12" "")))
5815     (set (mem:HI (match_dup 1))
5816          (match_operand:HI 3 "register_operand" "d"))]
5817 -  "!TARGET_SCORE5U"
5818 +  ""
5819    "sh      %3, [%1]+, %2"
5820    [(set_attr "type" "store")
5821     (set_attr "mode" "HI")])
5822 @@ -219,7 +219,7 @@
5823                   (match_operand:SI 2 "const_simm12" "")))
5824     (set (mem:SI (match_dup 1))
5825          (match_operand:SI 3 "register_operand" "d"))]
5826 -  "!TARGET_SCORE5U"
5827 +  ""
5828    "sw      %3, [%1]+, %2"
5829    [(set_attr "type" "store")
5830     (set_attr "mode" "SI")])
5831 @@ -231,7 +231,7 @@
5832     (set (match_operand:QI 3 "register_operand" "=d")
5833          (mem:QI (plus:SI (match_dup 1)
5834                           (match_dup 2))))]
5835 -  "!TARGET_SCORE5U"
5836 +  ""
5837    "lbu     %3, [%1, %2]+"
5838    [(set_attr "type" "load")
5839     (set_attr "mode" "QI")])
5840 @@ -243,7 +243,7 @@
5841     (set (match_operand:HI 3 "register_operand" "=d")
5842          (mem:HI (plus:SI (match_dup 1)
5843                           (match_dup 2))))]
5844 -  "!TARGET_SCORE5U"
5845 +  ""
5846    "lhu     %3, [%1, %2]+"
5847    [(set_attr "type" "load")
5848     (set_attr "mode" "HI")])
5849 @@ -255,7 +255,7 @@
5850     (set (match_operand:SI 3 "register_operand" "=d")
5851          (mem:SI (plus:SI (match_dup 1)
5852                           (match_dup 2))))]
5853 -  "!TARGET_SCORE5U"
5854 +  ""
5855    "lw      %3, [%1, %2]+"
5856    [(set_attr "type" "load")
5857     (set_attr "mode" "SI")])
5858 @@ -267,7 +267,7 @@
5859     (set (mem:QI (plus:SI (match_dup 1)
5860                           (match_dup 2)))
5861          (match_operand:QI 3 "register_operand" "d"))]
5862 -  "!TARGET_SCORE5U"
5863 +  ""
5864    "sb      %3, [%1, %2]+"
5865    [(set_attr "type" "store")
5866     (set_attr "mode" "QI")])
5867 @@ -279,7 +279,7 @@
5868     (set (mem:HI (plus:SI (match_dup 1)
5869                           (match_dup 2)))
5870          (match_operand:HI 3 "register_operand" "d"))]
5871 -  "!TARGET_SCORE5U"
5872 +  ""
5873    "sh      %3, [%1, %2]+"
5874    [(set_attr "type" "store")
5875     (set_attr "mode" "HI")])
5876 @@ -291,7 +291,7 @@
5877     (set (mem:SI (plus:SI (match_dup 1)
5878                           (match_dup 2)))
5879          (match_operand:SI 3 "register_operand" "d"))]
5880 -  "!TARGET_SCORE5U"
5881 +  ""
5882    "sw      %3, [%1, %2]+"
5883    [(set_attr "type" "store")
5884     (set_attr "mode" "SI")])
5885 @@ -302,7 +302,7 @@
5886                   (const_int 4)))
5887     (set (reg:SI LC_REGNUM)
5888          (unspec:SI [(mem:BLK (match_dup 1))] LCB))]
5889 -  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN"
5890 +  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN && TARGET_ULS"
5891    "lcb     [%1]+"
5892    [(set_attr "type" "load")
5893     (set_attr "mode" "SI")])
5894 @@ -316,7 +316,7 @@
5895                      (reg:SI LC_REGNUM)] LCW))
5896     (set (reg:SI LC_REGNUM)
5897          (unspec:SI [(mem:BLK (match_dup 1))] LCB))]
5898 -  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN"
5899 +  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN && TARGET_ULS"
5900    "lcw     %2, [%1]+"
5901    [(set_attr "type" "load")
5902     (set_attr "mode" "SI")])
5903 @@ -328,7 +328,7 @@
5904     (set (match_operand:SI 2 "register_operand" "=d")
5905          (unspec:SI [(mem:BLK (match_dup 1))
5906                      (reg:SI LC_REGNUM)] LCE))]
5907 -  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN"
5908 +  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN && TARGET_ULS"
5909    "lce     %2, [%1]+"
5910    [(set_attr "type" "load")
5911     (set_attr "mode" "SI")])
5912 @@ -341,7 +341,7 @@
5913          (unspec:BLK [(match_operand:SI 2 "register_operand" "d")] SCB))
5914     (set (reg:SI SC_REGNUM)
5915          (unspec:SI [(match_dup 2)] SCLC))]
5916 -  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN"
5917 +  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN && TARGET_ULS"
5918    "scb     %2, [%1]+"
5919    [(set_attr "type" "store")
5920     (set_attr "mode" "SI")])
5921 @@ -355,7 +355,7 @@
5922                       (reg:SI SC_REGNUM)] SCW))
5923     (set (reg:SI SC_REGNUM)
5924          (unspec:SI [(match_dup 2)] SCLC))]
5925 -  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN"
5926 +  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN && TARGET_ULS"
5927    "scw     %2, [%1]+"
5928    [(set_attr "type" "store")
5929     (set_attr "mode" "SI")])
5930 @@ -366,7 +366,7 @@
5931                   (const_int 4)))
5932     (set (mem:BLK (match_dup 1))
5933          (unspec:BLK [(reg:SI SC_REGNUM)] SCE))]
5934 -  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN"
5935 +  "!TARGET_SCORE5U && !TARGET_LITTLE_ENDIAN && TARGET_ULS"
5936    "sce     [%1]+"
5937    [(set_attr "type" "store")
5938     (set_attr "mode" "SI")])
5939 Index: gcc-4_2-branch/gcc/config/score/mac.md
5940 ===================================================================
5941 --- gcc-4_2-branch/gcc/config/score/mac.md      (revision 123014)
5942 +++ gcc-4_2-branch/gcc/config/score/mac.md      (revision 124164)
5943 @@ -26,7 +26,7 @@
5944    [(set (match_operand:SI 0 "register_operand" "=d")
5945          (smax:SI (match_operand:SI 1 "register_operand" "d")
5946                   (match_operand:SI 2 "register_operand" "d")))]
5947 -  "TARGET_MAC"
5948 +  "TARGET_MAC || TARGET_SCORE7D"
5949    "max     %0, %1, %2"
5950    [(set_attr "type" "arith")
5951     (set_attr "mode" "SI")])
5952 @@ -35,7 +35,7 @@
5953    [(set (match_operand:SI 0 "register_operand" "=d")
5954          (smin:SI (match_operand:SI 1 "register_operand" "d")
5955                   (match_operand:SI 2 "register_operand" "d")))]
5956 -  "TARGET_MAC"
5957 +  "TARGET_MAC || TARGET_SCORE7D"
5958    "min     %0, %1, %2"
5959    [(set_attr "type" "arith")
5960     (set_attr "mode" "SI")])
5961 @@ -43,7 +43,7 @@
5962  (define_insn "abssi2"
5963    [(set (match_operand:SI 0 "register_operand" "=d")
5964          (abs:SI (match_operand:SI 1 "register_operand" "d")))]
5965 -  "TARGET_MAC"
5966 +  "TARGET_MAC || TARGET_SCORE7D"
5967    "abs     %0, %1"
5968    [(set_attr "type" "arith")
5969     (set_attr "mode" "SI")])
5970 @@ -51,7 +51,7 @@
5971  (define_insn "clzsi2"
5972    [(set (match_operand:SI 0 "register_operand" "=d")
5973          (clz:SI (match_operand:SI 1 "register_operand" "d")))]
5974 -  "TARGET_MAC"
5975 +  "TARGET_MAC || TARGET_SCORE7D"
5976    "clz     %0, %1"
5977    [(set_attr "type" "arith")
5978     (set_attr "mode" "SI")])
5979 @@ -59,7 +59,7 @@
5980  (define_insn "sffs"
5981    [(set (match_operand:SI 0 "register_operand" "=d")
5982          (unspec:SI [(match_operand:SI 1 "register_operand" "d")] SFFS))]
5983 -  "TARGET_MAC"
5984 +  "TARGET_MAC || TARGET_SCORE7D"
5985    "bitrev  %0, %1, r0\;clz     %0, %0\;addi    %0, 0x1"
5986    [(set_attr "type" "arith")
5987     (set_attr "mode" "SI")])
5988 @@ -67,7 +67,7 @@
5989  (define_expand "ffssi2"
5990    [(set (match_operand:SI 0 "register_operand")
5991          (ffs:SI (match_operand:SI 1 "register_operand")))]
5992 -  "TARGET_MAC"
5993 +  "TARGET_MAC || TARGET_SCORE7D"
5994  {
5995    emit_insn (gen_sffs (operands[0], operands[1]));
5996    emit_insn (gen_rtx_SET (VOIDmode, gen_rtx_REG (CC_NZmode, CC_REGNUM),
5997 @@ -85,7 +85,7 @@
5998          (match_operand:SI 1 "register_operand" ""))
5999     (set (match_operand:SI 2 "hireg_operand" "")
6000          (match_operand:SI 3 "register_operand" ""))]
6001 -  "TARGET_MAC"
6002 +  "TARGET_MAC || TARGET_SCORE7D"
6003    [(parallel
6004         [(set (match_dup 0) (match_dup 1))
6005          (set (match_dup 2) (match_dup 3))])])
6006 @@ -95,7 +95,7 @@
6007          (match_operand:SI 1 "register_operand" ""))
6008     (set (match_operand:SI 2 "loreg_operand" "")
6009          (match_operand:SI 3 "register_operand" ""))]
6010 -  "TARGET_MAC"
6011 +  "TARGET_MAC || TARGET_SCORE7D"
6012    [(parallel
6013         [(set (match_dup 2) (match_dup 3))
6014          (set (match_dup 0) (match_dup 1))])])
6015 @@ -106,7 +106,7 @@
6016               (match_operand:SI 1 "register_operand" "d"))
6017          (set (match_operand:SI 2 "hireg_operand" "=h")
6018               (match_operand:SI 3 "register_operand" "d"))])]
6019 -  "TARGET_MAC"
6020 +  "TARGET_MAC || TARGET_SCORE7D"
6021    "mtcehl  %3, %1"
6022    [(set_attr "type" "fce")
6023     (set_attr "mode" "SI")])
6024 @@ -117,7 +117,7 @@
6025                            (match_operand:SI 3 "register_operand" "d,d,d"))
6026                   (match_operand:SI 1 "register_operand" "0,d,l")))
6027     (clobber (reg:SI HI_REGNUM))]
6028 -  "TARGET_MAC"
6029 +  "TARGET_MAC || TARGET_SCORE7D"
6030    "@
6031     mad     %2, %3
6032     mtcel%S1 %1\;mad     %2, %3
6033 @@ -130,7 +130,7 @@
6034                    (mult:SI (match_operand:SI 2 "register_operand" "d,d,d")
6035                             (match_operand:SI 3 "register_operand" "d,d,d"))))
6036     (clobber (reg:SI HI_REGNUM))]
6037 -  "TARGET_MAC"
6038 +  "TARGET_MAC || TARGET_SCORE7D"
6039    "@
6040     msb     %2, %3
6041     mtcel%S1 %1\;msb     %2, %3
6042 @@ -143,7 +143,7 @@
6043                    (sign_extend:DI (match_operand:SI 2 "register_operand" "%d"))
6044                    (sign_extend:DI (match_operand:SI 3 "register_operand" "d")))
6045                   (match_operand:DI 1 "register_operand" "0")))]
6046 -  "TARGET_MAC"
6047 +  "TARGET_MAC || TARGET_SCORE7D"
6048    "mad     %2, %3"
6049    [(set_attr "mode" "DI")])
6050  
6051 @@ -153,7 +153,7 @@
6052                    (zero_extend:DI (match_operand:SI 2 "register_operand" "%d"))
6053                    (zero_extend:DI (match_operand:SI 3 "register_operand" "d")))
6054                   (match_operand:DI 1 "register_operand" "0")))]
6055 -  "TARGET_MAC"
6056 +  "TARGET_MAC || TARGET_SCORE7D"
6057    "madu    %2, %3"
6058    [(set_attr "mode" "DI")])
6059  
6060 @@ -164,7 +164,7 @@
6061           (mult:DI
6062            (sign_extend:DI (match_operand:SI 2 "register_operand" "%d"))
6063            (sign_extend:DI (match_operand:SI 3 "register_operand" "d")))))]
6064 -  "TARGET_MAC"
6065 +  "TARGET_MAC || TARGET_SCORE7D"
6066    "msb     %2, %3"
6067    [(set_attr "mode" "DI")])
6068  
6069 @@ -176,6 +176,6 @@
6070                     (match_operand:SI 2 "register_operand" "%d"))
6071                    (zero_extend:DI
6072                     (match_operand:SI 3 "register_operand" "d")))))]
6073 -  "TARGET_MAC"
6074 +  "TARGET_MAC || TARGET_SCORE7D"
6075    "msbu    %2, %3"
6076    [(set_attr "mode" "DI")])
6077 Index: gcc-4_2-branch/gcc/config/score/score.h
6078 ===================================================================
6079 --- gcc-4_2-branch/gcc/config/score/score.h     (revision 123014)
6080 +++ gcc-4_2-branch/gcc/config/score/score.h     (revision 124164)
6081 @@ -38,7 +38,9 @@
6082  
6083  #undef ASM_SPEC
6084  #define ASM_SPEC \
6085 -  "%{!mel:-EB} %{mel:-EL} %{mscore5u:-SCORE5U} %{mscore7:-SCORE7} %{G*}"
6086 +  "%{!mel:-EB} %{mel:-EL} %{mscore5:-SCORE5} %{mscore5u:-SCORE5U} \
6087 +   %{mscore7:%{!mmac:-SCORE7}} %{mscore7:%{mmac:-SCORE7D}} \
6088 +   %{mscore7d:-SCORE7D} %{G*}"
6089  
6090  #undef LINK_SPEC
6091  #define LINK_SPEC                "%{!mel:-EB} %{mel:-EL} %{G*}"
6092 @@ -286,6 +288,16 @@
6093    128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,        \
6094    144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159        }
6095  
6096 +/* Macro to conditionally modify fixed_regs/call_used_regs.  */
6097 +#define PIC_OFFSET_TABLE_REGNUM          29
6098 +
6099 +#define CONDITIONAL_REGISTER_USAGE                     \
6100 +{                                                      \
6101 +   if (!flag_pic)                                      \
6102 +     fixed_regs[PIC_OFFSET_TABLE_REGNUM] =             \
6103 +     call_used_regs[PIC_OFFSET_TABLE_REGNUM] = 0;      \
6104 +}
6105 +
6106  #define HARD_REGNO_NREGS(REGNO, MODE) \
6107    ((GET_MODE_SIZE (MODE) + UNITS_PER_WORD - 1) / UNITS_PER_WORD)
6108  
6109 @@ -534,7 +546,7 @@
6110     If `ACCUMULATE_OUTGOING_ARGS' is also defined, the only effect
6111     of this macro is to determine whether the space is included in
6112     `current_function_outgoing_args_size'.  */
6113 -#define OUTGOING_REG_PARM_STACK_SPACE
6114 +#define OUTGOING_REG_PARM_STACK_SPACE   1
6115  
6116  #define RETURN_POPS_ARGS(FUNDECL, FUNTYPE, STACK_SIZE) 0
6117  
6118 Index: gcc-4_2-branch/gcc/config/score/score.md
6119 ===================================================================
6120 --- gcc-4_2-branch/gcc/config/score/score.md    (revision 123014)
6121 +++ gcc-4_2-branch/gcc/config/score/score.md    (revision 124164)
6122 @@ -1511,7 +1511,7 @@
6123     (use (match_operand 2 "" ""))    ; max iterations
6124     (use (match_operand 3 "" ""))    ; loop level
6125     (use (match_operand 4 "" ""))]   ; label
6126 -  ""
6127 +  "!TARGET_NHWLOOP"
6128    {
6129      if (INTVAL (operands[3]) > 1)
6130        FAIL;
6131 @@ -1539,6 +1539,6 @@
6132                   (const_int -1)))
6133     (clobber (reg:CC CC_REGNUM))
6134  ]
6135 -  ""
6136 +  "!TARGET_NHWLOOP"
6137    "bcnz %1"
6138    [(set_attr "type" "branch")])
6139 Index: gcc-4_2-branch/gcc/config/score/score.opt
6140 ===================================================================
6141 --- gcc-4_2-branch/gcc/config/score/score.opt   (revision 123014)
6142 +++ gcc-4_2-branch/gcc/config/score/score.opt   (revision 124164)
6143 @@ -27,10 +27,22 @@
6144  Target RejectNegative Report Mask(LITTLE_ENDIAN)
6145  Generate little-endian code
6146  
6147 +mnhwloop
6148 +Target RejectNegative Report Mask(NHWLOOP)
6149 +Disable bcnz instruction
6150 +
6151 +muls
6152 +Target RejectNegative Report Mask(ULS)
6153 +Enable unaligned load/store instruction
6154 +
6155  mmac
6156  Target RejectNegative Report Mask(MAC)
6157  Enable mac instruction
6158  
6159 +mscore5
6160 +Target RejectNegative Report Mask(SCORE5)
6161 +Support SCORE 5 ISA
6162 +
6163  mscore5u
6164  Target RejectNegative Report Mask(SCORE5U)
6165  Support SCORE 5U ISA
6166 @@ -39,3 +51,6 @@
6167  Target RejectNegative Report Mask(SCORE7)
6168  Support SCORE 7 ISA
6169  
6170 +mscore7d
6171 +Target RejectNegative Report Mask(SCORE7D)
6172 +Support SCORE 7D ISA
6173 Index: gcc-4_2-branch/gcc/config/arm/linux-gas.h
6174 ===================================================================
6175 --- gcc-4_2-branch/gcc/config/arm/linux-gas.h   (revision 123014)
6176 +++ gcc-4_2-branch/gcc/config/arm/linux-gas.h   (revision 124164)
6177 @@ -28,7 +28,7 @@
6178  #define DEFAULT_SIGNED_CHAR 0
6179  
6180  #undef  SUBTARGET_CPP_SPEC
6181 -#define SUBTARGET_CPP_SPEC  "%{posix:-D_POSIX_SOURCE}"
6182 +#define SUBTARGET_CPP_SPEC  "%{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}"
6183  
6184  #undef  SIZE_TYPE
6185  #define SIZE_TYPE "unsigned int"
6186 Index: gcc-4_2-branch/gcc/config/pa/pa.c
6187 ===================================================================
6188 --- gcc-4_2-branch/gcc/config/pa/pa.c   (revision 123014)
6189 +++ gcc-4_2-branch/gcc/config/pa/pa.c   (revision 124164)
6190 @@ -9276,7 +9276,7 @@
6191    gcc_assert (TARGET_SOM);
6192    if (TARGET_GAS)
6193      {
6194 -      if (cfun && !cfun->machine->in_nsubspa)
6195 +      if (cfun && cfun->machine && !cfun->machine->in_nsubspa)
6196         {
6197           /* We only want to emit a .nsubspa directive once at the
6198              start of the function.  */
6199 @@ -9301,7 +9301,8 @@
6200              text section to output debugging information.  Thus, we
6201              need to forget that we are in the text section so that
6202              varasm.c will call us when text_section is selected again.  */
6203 -         gcc_assert (!cfun || cfun->machine->in_nsubspa == 2);
6204 +         gcc_assert (!cfun || !cfun->machine
6205 +                     || cfun->machine->in_nsubspa == 2);
6206           in_section = NULL;
6207         }
6208        output_section_asm_op ("\t.SPACE $TEXT$\n\t.NSUBSPA $CODE$");
6209 Index: gcc-4_2-branch/gcc/config/darwin9.h
6210 ===================================================================
6211 --- gcc-4_2-branch/gcc/config/darwin9.h (revision 123014)
6212 +++ gcc-4_2-branch/gcc/config/darwin9.h (revision 124164)
6213 @@ -1,2 +1,13 @@
6214  /* The linker can generate branch islands.  */
6215  #define DARWIN_LINKER_GENERATES_ISLANDS 1
6216 +
6217 +#undef  ASM_OUTPUT_ALIGNED_COMMON
6218 +#define ASM_OUTPUT_ALIGNED_COMMON(FILE, NAME, SIZE, ALIGN)             \
6219 +  do {                                                                 \
6220 +    unsigned HOST_WIDE_INT _new_size = (SIZE);                         \
6221 +    fprintf ((FILE), ".comm ");                                                \
6222 +    assemble_name ((FILE), (NAME));                                    \
6223 +    if (_new_size == 0) _new_size = 1;                                 \
6224 +    fprintf ((FILE), ","HOST_WIDE_INT_PRINT_UNSIGNED",%u\n",           \
6225 +            _new_size, floor_log2 ((ALIGN) / BITS_PER_UNIT));          \
6226 +  } while (0)
6227 Index: gcc-4_2-branch/gcc/reload1.c
6228 ===================================================================
6229 --- gcc-4_2-branch/gcc/reload1.c        (revision 123014)
6230 +++ gcc-4_2-branch/gcc/reload1.c        (revision 124164)
6231 @@ -1167,20 +1167,6 @@
6232        {
6233         rtx *pnote;
6234  
6235 -       /* Clean up invalid ASMs so that they don't confuse later passes.
6236 -          See PR 21299.  */
6237 -       if (asm_noperands (PATTERN (insn)) >= 0)
6238 -         {
6239 -           extract_insn (insn);
6240 -           if (!constrain_operands (1))
6241 -             {
6242 -               error_for_asm (insn,
6243 -                              "%<asm%> operand has impossible constraints");
6244 -               delete_insn (insn);
6245 -               continue;
6246 -             }
6247 -         }
6248 -
6249         if (CALL_P (insn))
6250           replace_pseudos_in (& CALL_INSN_FUNCTION_USAGE (insn),
6251                               VOIDmode, CALL_INSN_FUNCTION_USAGE (insn));
6252 @@ -1239,8 +1225,22 @@
6253         add_auto_inc_notes (insn, PATTERN (insn));
6254  #endif
6255  
6256 -       /* And simplify (subreg (reg)) if it appears as an operand.  */
6257 +       /* Simplify (subreg (reg)) if it appears as an operand.  */
6258         cleanup_subreg_operands (insn);
6259 +
6260 +       /* Clean up invalid ASMs so that they don't confuse later passes.
6261 +          See PR 21299.  */
6262 +       if (asm_noperands (PATTERN (insn)) >= 0)
6263 +         {
6264 +           extract_insn (insn);
6265 +           if (!constrain_operands (1))
6266 +             {
6267 +               error_for_asm (insn,
6268 +                              "%<asm%> operand has impossible constraints");
6269 +               delete_insn (insn);
6270 +               continue;
6271 +             }
6272 +         }
6273        }
6274  
6275    /* If we are doing stack checking, give a warning if this function's
6276 Index: gcc-4_2-branch/libstdc++-v3/include/ext/vstring_util.h
6277 ===================================================================
6278 --- gcc-4_2-branch/libstdc++-v3/include/ext/vstring_util.h      (revision 123014)
6279 +++ gcc-4_2-branch/libstdc++-v3/include/ext/vstring_util.h      (revision 124164)
6280 @@ -1,6 +1,6 @@
6281  // Versatile string utility -*- C++ -*-
6282  
6283 -// Copyright (C) 2005, 2006 Free Software Foundation, Inc.
6284 +// Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
6285  //
6286  // This file is part of the GNU ISO C++ Library.  This library is free
6287  // software; you can redistribute it and/or modify it under the
6288 @@ -44,6 +44,7 @@
6289  #include <bits/functexcept.h>
6290  #include <locale>
6291  #include <algorithm> // For std::distance, srd::search.
6292 +#include <bits/ostream_insert.h>
6293  
6294  _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
6295  
6296 Index: gcc-4_2-branch/libstdc++-v3/include/ext/vstring.h
6297 ===================================================================
6298 --- gcc-4_2-branch/libstdc++-v3/include/ext/vstring.h   (revision 123014)
6299 +++ gcc-4_2-branch/libstdc++-v3/include/ext/vstring.h   (revision 124164)
6300 @@ -1,6 +1,6 @@
6301  // Versatile string -*- C++ -*-
6302  
6303 -// Copyright (C) 2005, 2006 Free Software Foundation, Inc.
6304 +// Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
6305  //
6306  // This file is part of the GNU ISO C++ Library.  This library is free
6307  // software; you can redistribute it and/or modify it under the
6308 @@ -2140,10 +2140,15 @@
6309     */
6310    template<typename _CharT, typename _Traits, typename _Alloc,
6311             template <typename, typename, typename> class _Base>
6312 -    basic_ostream<_CharT, _Traits>&
6313 +    inline basic_ostream<_CharT, _Traits>&
6314      operator<<(basic_ostream<_CharT, _Traits>& __os,
6315                const __gnu_cxx::__versa_string<_CharT, _Traits,
6316 -                                              _Alloc, _Base>& __str);
6317 +                                              _Alloc, _Base>& __str)
6318 +    {
6319 +      // _GLIBCXX_RESOLVE_LIB_DEFECTS
6320 +      // 586. string inserter not a formatted function
6321 +      return __ostream_insert(__os, __str.data(), __str.size());
6322 +    }
6323  
6324    /**
6325     *  @brief  Read a line from stream into a string.
6326 Index: gcc-4_2-branch/libstdc++-v3/include/ext/pb_ds/detail/type_utils.hpp
6327 ===================================================================
6328 --- gcc-4_2-branch/libstdc++-v3/include/ext/pb_ds/detail/type_utils.hpp (revision 123014)
6329 +++ gcc-4_2-branch/libstdc++-v3/include/ext/pb_ds/detail/type_utils.hpp (revision 124164)
6330 @@ -52,6 +52,7 @@
6331  #include <utility>
6332  #include <tr1/type_traits>
6333  #include <ext/type_traits.h>
6334 +#include <ext/numeric_traits.h>
6335  
6336  namespace pb_ds
6337  {
6338 Index: gcc-4_2-branch/libstdc++-v3/include/ext/numeric_traits.h
6339 ===================================================================
6340 --- gcc-4_2-branch/libstdc++-v3/include/ext/numeric_traits.h    (revision 0)
6341 +++ gcc-4_2-branch/libstdc++-v3/include/ext/numeric_traits.h    (revision 124164)
6342 @@ -0,0 +1,98 @@
6343 +// -*- C++ -*-
6344 +
6345 +// Copyright (C) 2007 Free Software Foundation, Inc.
6346 +//
6347 +// This file is part of the GNU ISO C++ Library.  This library is free
6348 +// software; you can redistribute it and/or modify it under the terms
6349 +// of the GNU General Public License as published by the Free Software
6350 +// Foundation; either version 2, or (at your option) any later
6351 +// version.
6352 +
6353 +// This library is distributed in the hope that it will be useful, but
6354 +// WITHOUT ANY WARRANTY; without even the implied warranty of
6355 +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
6356 +// General Public License for more details.
6357 +
6358 +// You should have received a copy of the GNU General Public License along
6359 +// with this library; see the file COPYING.  If not, write to the Free
6360 +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
6361 +// USA.
6362 +
6363 +// As a special exception, you may use this file as part of a free
6364 +// software library without restriction.  Specifically, if other files
6365 +// instantiate templates or use macros or inline functions from this
6366 +// file, or you compile this file and link it with other files to
6367 +// produce an executable, this file does not by itself cause the
6368 +// resulting executable to be covered by the GNU General Public
6369 +// License.  This exception does not however invalidate any other
6370 +// reasons why the executable file might be covered by the GNU General
6371 +// Public License.
6372 +
6373 +/** @file ext/numeric_traits.h
6374 + *  This file is a GNU extension to the Standard C++ Library.
6375 + */
6376 +
6377 +#ifndef _EXT_NUMERIC_TRAITS
6378 +#define _EXT_NUMERIC_TRAITS 1
6379 +
6380 +#pragma GCC system_header
6381 +
6382 +#include <limits>
6383 +#include <bits/cpp_type_traits.h>
6384 +#include <ext/type_traits.h>
6385 +
6386 +_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
6387 +
6388 +  // Compile time constants for builtin types.
6389 +  // Sadly std::numeric_limits member functions cannot be used for this.
6390 +#define __glibcxx_signed(_Tp) ((_Tp)(-1) < 0)
6391 +#define __glibcxx_digits(_Tp) \
6392 +  (sizeof(_Tp) * __CHAR_BIT__ - __glibcxx_signed(_Tp))
6393 +
6394 +#define __glibcxx_min(_Tp) \
6395 +  (__glibcxx_signed(_Tp) ? (_Tp)1 << __glibcxx_digits(_Tp) : (_Tp)0)
6396 +
6397 +#define __glibcxx_max(_Tp) \
6398 +  (__glibcxx_signed(_Tp) ? \
6399 +   (((((_Tp)1 << (__glibcxx_digits(_Tp) - 1)) - 1) << 1) + 1) : ~(_Tp)0)
6400 +
6401 +  template<typename _Value>
6402 +    struct __numeric_traits_integer
6403 +    {
6404 +      // Only integers for initialization of member constant.
6405 +      static const _Value __min = __glibcxx_min(_Value);
6406 +      static const _Value __max = __glibcxx_max(_Value);
6407 +    };
6408 +
6409 +  template<typename _Value>
6410 +    const _Value __numeric_traits_integer<_Value>::__min;
6411 +
6412 +  template<typename _Value>
6413 +    const _Value __numeric_traits_integer<_Value>::__max;
6414 +
6415 +  template<typename _Value>
6416 +    struct __numeric_traits_floating
6417 +    {
6418 +      // Only floating point types. See N1822. 
6419 +      static const int __max_digits10 =
6420 +       2 + std::numeric_limits<_Value>::digits * 3010/10000;
6421 +    };
6422 +
6423 +  template<typename _Value>
6424 +    const int __numeric_traits_floating<_Value>::__max_digits10;
6425 +
6426 +  template<typename _Value>
6427 +    struct __numeric_traits
6428 +    : public __conditional_type<std::__is_integer<_Value>::__value,
6429 +                               __numeric_traits_integer<_Value>,
6430 +                               __numeric_traits_floating<_Value> >::__type
6431 +    { };
6432 +
6433 +_GLIBCXX_END_NAMESPACE
6434 +
6435 +#undef __glibcxx_signed
6436 +#undef __glibcxx_min
6437 +#undef __glibcxx_max
6438 +#undef __glibcxx_digits
6439 +
6440 +#endif 
6441 Index: gcc-4_2-branch/libstdc++-v3/include/ext/type_traits.h
6442 ===================================================================
6443 --- gcc-4_2-branch/libstdc++-v3/include/ext/type_traits.h       (revision 123014)
6444 +++ gcc-4_2-branch/libstdc++-v3/include/ext/type_traits.h       (revision 124164)
6445 @@ -1,6 +1,6 @@
6446  // -*- C++ -*-
6447  
6448 -// Copyright (C) 2005, 2006 Free Software Foundation, Inc.
6449 +// Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
6450  //
6451  // This file is part of the GNU ISO C++ Library.  This library is free
6452  // software; you can redistribute it and/or modify it under the terms
6453 @@ -39,8 +39,6 @@
6454  
6455  #include <cstddef>
6456  #include <utility>
6457 -#include <limits>
6458 -#include <iosfwd> // std::streamsize
6459  #include <bits/cpp_type_traits.h>
6460  
6461  _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
6462 @@ -150,51 +148,6 @@
6463    template<>
6464      struct __remove_unsigned<wchar_t>;
6465  
6466 -
6467 -  // Compile time constants for builtin types.
6468 -  // Sadly std::numeric_limits member functions cannot be used for this.
6469 -#define __glibcxx_signed(_Tp) ((_Tp)(-1) < 0)
6470 -#define __glibcxx_digits(_Tp) \
6471 -  (sizeof(_Tp) * __CHAR_BIT__ - __glibcxx_signed(_Tp))
6472 -
6473 -#define __glibcxx_min(_Tp) \
6474 -  (__glibcxx_signed(_Tp) ? (_Tp)1 << __glibcxx_digits(_Tp) : (_Tp)0)
6475 -
6476 -#define __glibcxx_max(_Tp) \
6477 -  (__glibcxx_signed(_Tp) ? ((_Tp)1 << __glibcxx_digits(_Tp)) - 1 : ~(_Tp)0)
6478 -
6479 -  template<typename _Value>
6480 -    struct __numeric_traits_integer
6481 -    {
6482 -      // Only integers for initialization of member constant.
6483 -      static const _Value __min = __glibcxx_min(_Value);
6484 -      static const _Value __max = __glibcxx_max(_Value);
6485 -    };
6486 -
6487 -  template<typename _Value>
6488 -    const _Value __numeric_traits_integer<_Value>::__min;
6489 -
6490 -  template<typename _Value>
6491 -    const _Value __numeric_traits_integer<_Value>::__max;
6492 -
6493 -  template<typename _Value>
6494 -    struct __numeric_traits_floating
6495 -    {
6496 -      // Only floating point types. See N1822. 
6497 -      static const std::streamsize __max_digits10 =
6498 -       2 + std::numeric_limits<_Value>::digits * 3010/10000;
6499 -    };
6500 -
6501 -  template<typename _Value>
6502 -    const std::streamsize __numeric_traits_floating<_Value>::__max_digits10;
6503 -
6504 -  template<typename _Value>
6505 -    struct __numeric_traits 
6506 -    : public __conditional_type<std::__is_integer<_Value>::__value,
6507 -                               __numeric_traits_integer<_Value>,
6508 -                               __numeric_traits_floating<_Value> >::__type
6509 -    { };
6510 -
6511  _GLIBCXX_END_NAMESPACE
6512  
6513  #endif 
6514 Index: gcc-4_2-branch/libstdc++-v3/include/ext/vstring.tcc
6515 ===================================================================
6516 --- gcc-4_2-branch/libstdc++-v3/include/ext/vstring.tcc (revision 123014)
6517 +++ gcc-4_2-branch/libstdc++-v3/include/ext/vstring.tcc (revision 124164)
6518 @@ -1,6 +1,6 @@
6519  // Versatile string -*- C++ -*-
6520  
6521 -// Copyright (C) 2005, 2006 Free Software Foundation, Inc.
6522 +// Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
6523  //
6524  // This file is part of the GNU ISO C++ Library.  This library is free
6525  // software; you can redistribute it and/or modify it under the
6526 @@ -279,7 +279,7 @@
6527  
6528        if (__n <= __size)
6529         {
6530 -         for (; __pos + __n <= __size; ++__pos)
6531 +         for (; __pos <= __size - __n; ++__pos)
6532             if (traits_type::eq(__data[__pos], __s[0])
6533                 && traits_type::compare(__data + __pos + 1,
6534                                         __s + 1, __n - 1) == 0)
6535 @@ -615,39 +615,6 @@
6536  
6537    template<typename _CharT, typename _Traits, typename _Alloc,
6538             template <typename, typename, typename> class _Base>
6539 -    basic_ostream<_CharT, _Traits>&
6540 -    operator<<(basic_ostream<_CharT, _Traits>& __out,
6541 -              const __gnu_cxx::__versa_string<_CharT, _Traits,
6542 -                                              _Alloc, _Base>& __str)
6543 -    {
6544 -      typedef basic_ostream<_CharT, _Traits>            __ostream_type;
6545 -
6546 -      typename __ostream_type::sentry __cerb(__out);
6547 -      if (__cerb)
6548 -       {
6549 -         const streamsize __w = __out.width();
6550 -         streamsize __len = static_cast<streamsize>(__str.size());
6551 -         const _CharT* __s = __str.data();
6552 -
6553 -         // _GLIBCXX_RESOLVE_LIB_DEFECTS
6554 -         // 25. String operator<< uses width() value wrong
6555 -         if (__w > __len)
6556 -           {
6557 -             _CharT* __cs = (static_cast<
6558 -                             _CharT*>(__builtin_alloca(sizeof(_CharT) * __w)));
6559 -             __pad<_CharT, _Traits>::_S_pad(__out, __out.fill(), __cs,
6560 -                                            __s, __w, __len, false);
6561 -             __s = __cs;
6562 -             __len = __w;
6563 -           }
6564 -         __out._M_write(__s, __len);
6565 -         __out.width(0);
6566 -       }
6567 -      return __out;
6568 -    }
6569 -
6570 -  template<typename _CharT, typename _Traits, typename _Alloc,
6571 -           template <typename, typename, typename> class _Base>
6572      basic_istream<_CharT, _Traits>&
6573      getline(basic_istream<_CharT, _Traits>& __in,
6574             __gnu_cxx::__versa_string<_CharT, _Traits, _Alloc, _Base>& __str,
6575 Index: gcc-4_2-branch/libstdc++-v3/include/bits/stl_map.h
6576 ===================================================================
6577 --- gcc-4_2-branch/libstdc++-v3/include/bits/stl_map.h  (revision 123014)
6578 +++ gcc-4_2-branch/libstdc++-v3/include/bits/stl_map.h  (revision 124164)
6579 @@ -1,6 +1,7 @@
6580  // Map implementation -*- C++ -*-
6581  
6582 -// Copyright (C) 2001, 2002, 2004, 2005, 2006 Free Software Foundation, Inc.
6583 +// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007
6584 +// Free Software Foundation, Inc.
6585  //
6586  // This file is part of the GNU ISO C++ Library.  This library is free
6587  // software; you can redistribute it and/or modify it under the
6588 @@ -394,7 +395,7 @@
6589         *
6590         *  Insertion requires logarithmic time.
6591         */
6592 -      std::pair<iterator,bool>
6593 +      std::pair<iterator, bool>
6594        insert(const value_type& __x)
6595        { return _M_t._M_insert_unique(__x); }
6596  
6597 @@ -422,8 +423,8 @@
6598         *  Insertion requires logarithmic time (if the hint is not taken).
6599         */
6600        iterator
6601 -      insert(iterator position, const value_type& __x)
6602 -      { return _M_t._M_insert_unique(position, __x); }
6603 +      insert(iterator __position, const value_type& __x)
6604 +      { return _M_t._M_insert_unique(__position, __x); }
6605  
6606        /**
6607         *  @brief Template function that attemps to insert a range of elements.
6608 Index: gcc-4_2-branch/libstdc++-v3/include/bits/basic_string.h
6609 ===================================================================
6610 --- gcc-4_2-branch/libstdc++-v3/include/bits/basic_string.h     (revision 123014)
6611 +++ gcc-4_2-branch/libstdc++-v3/include/bits/basic_string.h     (revision 124164)
6612 @@ -1,6 +1,7 @@
6613  // Components for manipulating sequences of characters -*- C++ -*-
6614  
6615 -// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
6616 +// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
6617 +// 2006, 2007
6618  // Free Software Foundation, Inc.
6619  //
6620  // This file is part of the GNU ISO C++ Library.  This library is free
6621 @@ -2400,7 +2401,7 @@
6622      {
6623        // _GLIBCXX_RESOLVE_LIB_DEFECTS
6624        // 586. string inserter not a formatted function
6625 -      return __os._M_insert(__str.data(), __str.size());
6626 +      return __ostream_insert(__os, __str.data(), __str.size());
6627      }
6628  
6629    /**
6630 Index: gcc-4_2-branch/libstdc++-v3/include/bits/ostream.tcc
6631 ===================================================================
6632 --- gcc-4_2-branch/libstdc++-v3/include/bits/ostream.tcc        (revision 123014)
6633 +++ gcc-4_2-branch/libstdc++-v3/include/bits/ostream.tcc        (revision 124164)
6634 @@ -283,38 +283,6 @@
6635  
6636    template<typename _CharT, typename _Traits>
6637      basic_ostream<_CharT, _Traits>&
6638 -    basic_ostream<_CharT, _Traits>::
6639 -    _M_insert(const char_type* __s, streamsize __n)
6640 -    {
6641 -      sentry __cerb(*this);
6642 -      if (__cerb)
6643 -       {
6644 -         try
6645 -           {
6646 -             const streamsize __w = this->width();
6647 -             if (__w > __n)
6648 -               {
6649 -                 const bool __left = ((this->flags() & ios_base::adjustfield)
6650 -                                      == ios_base::left);
6651 -                 if (!__left)
6652 -                   _M_write(this->fill(), __w - __n);
6653 -                 if (this->good())
6654 -                   _M_write(__s, __n);
6655 -                 if (__left && this->good())
6656 -                   _M_write(this->fill(), __w - __n);
6657 -               }
6658 -             else
6659 -               _M_write(__s, __n);
6660 -             this->width(0);
6661 -           }
6662 -         catch(...)
6663 -           { this->_M_setstate(ios_base::badbit); }
6664 -       }
6665 -      return *this;
6666 -    }
6667 -
6668 -  template<typename _CharT, typename _Traits>
6669 -    basic_ostream<_CharT, _Traits>&
6670      operator<<(basic_ostream<_CharT, _Traits>& __out, const char* __s)
6671      {
6672        if (!__s)
6673 @@ -340,7 +308,7 @@
6674  
6675           try
6676             {
6677 -             __out._M_insert(__ws, __clen);
6678 +             __ostream_insert(__out, __ws, __clen);
6679               delete [] __ws;
6680             }
6681           catch(...)
6682 @@ -366,6 +334,7 @@
6683    extern template ostream& operator<<(ostream&, const char*);
6684    extern template ostream& operator<<(ostream&, const unsigned char*);
6685    extern template ostream& operator<<(ostream&, const signed char*);
6686 +  extern template ostream& __ostream_insert(ostream&, const char*, streamsize);
6687  
6688    extern template ostream& ostream::_M_insert(long);
6689    extern template ostream& ostream::_M_insert(unsigned long);
6690 @@ -387,6 +356,8 @@
6691    extern template wostream& operator<<(wostream&, char);
6692    extern template wostream& operator<<(wostream&, const wchar_t*);
6693    extern template wostream& operator<<(wostream&, const char*);
6694 +  extern template wostream& __ostream_insert(wostream&, const wchar_t*,
6695 +                                            streamsize);
6696  
6697    extern template wostream& wostream::_M_insert(long);
6698    extern template wostream& wostream::_M_insert(unsigned long);
6699 Index: gcc-4_2-branch/libstdc++-v3/include/bits/basic_string.tcc
6700 ===================================================================
6701 --- gcc-4_2-branch/libstdc++-v3/include/bits/basic_string.tcc   (revision 123014)
6702 +++ gcc-4_2-branch/libstdc++-v3/include/bits/basic_string.tcc   (revision 124164)
6703 @@ -1,6 +1,7 @@
6704  // Components for manipulating sequences of characters -*- C++ -*-
6705  
6706 -// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
6707 +// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
6708 +// 2006, 2007
6709  // Free Software Foundation, Inc.
6710  //
6711  // This file is part of the GNU ISO C++ Library.  This library is free
6712 @@ -726,7 +727,7 @@
6713  
6714        if (__n <= __size)
6715         {
6716 -         for (; __pos + __n <= __size; ++__pos)
6717 +         for (; __pos <= __size - __n; ++__pos)
6718             if (traits_type::eq(__data[__pos], __s[0])
6719                 && traits_type::compare(__data + __pos + 1,
6720                                         __s + 1, __n - 1) == 0)
6721 Index: gcc-4_2-branch/libstdc++-v3/include/bits/ostream_insert.h
6722 ===================================================================
6723 --- gcc-4_2-branch/libstdc++-v3/include/bits/ostream_insert.h   (revision 0)
6724 +++ gcc-4_2-branch/libstdc++-v3/include/bits/ostream_insert.h   (revision 124164)
6725 @@ -0,0 +1,114 @@
6726 +// Helpers for ostream inserters -*- C++ -*-
6727 +
6728 +// Copyright (C) 2007 Free Software Foundation, Inc.
6729 +//
6730 +// This file is part of the GNU ISO C++ Library.  This library is free
6731 +// software; you can redistribute it and/or modify it under the
6732 +// terms of the GNU General Public License as published by the
6733 +// Free Software Foundation; either version 2, or (at your option)
6734 +// any later version.
6735 +
6736 +// This library is distributed in the hope that it will be useful,
6737 +// but WITHOUT ANY WARRANTY; without even the implied warranty of
6738 +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
6739 +// GNU General Public License for more details.
6740 +
6741 +// You should have received a copy of the GNU General Public License along
6742 +// with this library; see the file COPYING.  If not, write to the Free
6743 +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
6744 +// USA.
6745 +
6746 +// As a special exception, you may use this file as part of a free software
6747 +// library without restriction.  Specifically, if other files instantiate
6748 +// templates or use macros or inline functions from this file, or you compile
6749 +// this file and link it with other files to produce an executable, this
6750 +// file does not by itself cause the resulting executable to be covered by
6751 +// the GNU General Public License.  This exception does not however
6752 +// invalidate any other reasons why the executable file might be covered by
6753 +// the GNU General Public License.
6754 +
6755 +/** @file ostream_insert.h
6756 + *  This is an internal header file, included by other library headers.
6757 + *  You should not attempt to use it directly.
6758 + */
6759 +
6760 +#ifndef _OSTREAM_INSERT_H
6761 +#define _OSTREAM_INSERT_H 1
6762 +
6763 +#pragma GCC system_header
6764 +
6765 +#include <iosfwd>
6766 +
6767 +_GLIBCXX_BEGIN_NAMESPACE(std)
6768 +
6769 +  template<typename _CharT, typename _Traits>
6770 +    inline void
6771 +    __ostream_write(basic_ostream<_CharT, _Traits>& __out,
6772 +                   const _CharT* __s, streamsize __n)
6773 +    {
6774 +      typedef basic_ostream<_CharT, _Traits>       __ostream_type;      
6775 +      typedef typename __ostream_type::ios_base    __ios_base;
6776 +
6777 +      const streamsize __put = __out.rdbuf()->sputn(__s, __n);
6778 +      if (__put != __n)
6779 +       __out.setstate(__ios_base::badbit);
6780 +    }
6781 +
6782 +  template<typename _CharT, typename _Traits>
6783 +    inline void
6784 +    __ostream_fill(basic_ostream<_CharT, _Traits>& __out, streamsize __n)
6785 +    {
6786 +      typedef basic_ostream<_CharT, _Traits>       __ostream_type;      
6787 +      typedef typename __ostream_type::ios_base    __ios_base;
6788 +
6789 +      const _CharT __c = __out.fill();
6790 +      for (; __n > 0; --__n)
6791 +       {
6792 +         const typename _Traits::int_type __put = __out.rdbuf()->sputc(__c);
6793 +         if (_Traits::eq_int_type(__put, _Traits::eof()))
6794 +           {
6795 +             __out.setstate(__ios_base::badbit);
6796 +             break;
6797 +           }
6798 +       }
6799 +    }
6800 +
6801 +  template<typename _CharT, typename _Traits>
6802 +    basic_ostream<_CharT, _Traits>&
6803 +    __ostream_insert(basic_ostream<_CharT, _Traits>& __out,
6804 +                    const _CharT* __s, streamsize __n)
6805 +    {
6806 +      typedef basic_ostream<_CharT, _Traits>       __ostream_type;
6807 +      typedef typename __ostream_type::ios_base    __ios_base;
6808 +
6809 +      typename __ostream_type::sentry __cerb(__out);
6810 +      if (__cerb)
6811 +       {
6812 +         try
6813 +           {
6814 +             const streamsize __w = __out.width();
6815 +             if (__w > __n)
6816 +               {
6817 +                 const bool __left = ((__out.flags()
6818 +                                       & __ios_base::adjustfield)
6819 +                                      == __ios_base::left);
6820 +                 if (!__left)
6821 +                   __ostream_fill(__out, __w - __n);
6822 +                 if (__out.good())
6823 +                   __ostream_write(__out, __s, __n);
6824 +                 if (__left && __out.good())
6825 +                   __ostream_fill(__out, __w - __n);
6826 +               }
6827 +             else
6828 +               __ostream_write(__out, __s, __n);
6829 +             __out.width(0);
6830 +           }
6831 +         catch(...)
6832 +           { __out._M_setstate(__ios_base::badbit); }
6833 +       }
6834 +      return __out;
6835 +    }
6836 +
6837 +_GLIBCXX_END_NAMESPACE
6838 +
6839 +#endif /* _OSTREAM_INSERT_H */
6840 Index: gcc-4_2-branch/libstdc++-v3/include/Makefile.in
6841 ===================================================================
6842 --- gcc-4_2-branch/libstdc++-v3/include/Makefile.in     (revision 123014)
6843 +++ gcc-4_2-branch/libstdc++-v3/include/Makefile.in     (revision 124164)
6844 @@ -343,6 +343,7 @@
6845         ${bits_srcdir}/localefwd.h \
6846         ${bits_srcdir}/mask_array.h \
6847         ${bits_srcdir}/ostream.tcc \
6848 +       ${bits_srcdir}/ostream_insert.h \
6849         ${bits_srcdir}/postypes.h \
6850         ${bits_srcdir}/stream_iterator.h \
6851         ${bits_srcdir}/streambuf_iterator.h \
6852 @@ -756,6 +757,7 @@
6853         ${ext_srcdir}/mt_allocator.h \
6854         ${ext_srcdir}/new_allocator.h \
6855         ${ext_srcdir}/numeric \
6856 +       ${ext_srcdir}/numeric_traits.h \
6857         ${ext_srcdir}/pod_char_traits.h \
6858         ${ext_srcdir}/pool_allocator.h \
6859         ${ext_srcdir}/rb_tree \
6860 Index: gcc-4_2-branch/libstdc++-v3/include/tr1/random
6861 ===================================================================
6862 --- gcc-4_2-branch/libstdc++-v3/include/tr1/random      (revision 123014)
6863 +++ gcc-4_2-branch/libstdc++-v3/include/tr1/random      (revision 124164)
6864 @@ -43,6 +43,7 @@
6865  #include <tr1/type_traits>
6866  #include <tr1/cmath>
6867  #include <ext/type_traits.h>
6868 +#include <ext/numeric_traits.h>
6869  #include <bits/concept_check.h>
6870  #include <debug/debug.h>
6871  
6872 Index: gcc-4_2-branch/libstdc++-v3/include/Makefile.am
6873 ===================================================================
6874 --- gcc-4_2-branch/libstdc++-v3/include/Makefile.am     (revision 123014)
6875 +++ gcc-4_2-branch/libstdc++-v3/include/Makefile.am     (revision 124164)
6876 @@ -117,6 +117,7 @@
6877         ${bits_srcdir}/localefwd.h \
6878         ${bits_srcdir}/mask_array.h \
6879         ${bits_srcdir}/ostream.tcc \
6880 +       ${bits_srcdir}/ostream_insert.h \
6881         ${bits_srcdir}/postypes.h \
6882         ${bits_srcdir}/stream_iterator.h \
6883         ${bits_srcdir}/streambuf_iterator.h \
6884 @@ -534,6 +535,7 @@
6885         ${ext_srcdir}/mt_allocator.h \
6886         ${ext_srcdir}/new_allocator.h \
6887         ${ext_srcdir}/numeric \
6888 +       ${ext_srcdir}/numeric_traits.h \
6889         ${ext_srcdir}/pod_char_traits.h \
6890         ${ext_srcdir}/pool_allocator.h \
6891         ${ext_srcdir}/rb_tree \
6892 Index: gcc-4_2-branch/libstdc++-v3/include/std/std_string.h
6893 ===================================================================
6894 --- gcc-4_2-branch/libstdc++-v3/include/std/std_string.h        (revision 123014)
6895 +++ gcc-4_2-branch/libstdc++-v3/include/std/std_string.h        (revision 124164)
6896 @@ -1,6 +1,7 @@
6897  // Components for manipulating sequences of characters -*- C++ -*-
6898  
6899 -// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005
6900 +// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
6901 +// 2006, 2007
6902  // Free Software Foundation, Inc.
6903  //
6904  // This file is part of the GNU ISO C++ Library.  This library is free
6905 @@ -47,6 +48,7 @@
6906  #include <memory>      // For allocator.
6907  #include <bits/cpp_type_traits.h>
6908  #include <iosfwd>      // For operators >>, <<, and getline decls.
6909 +#include <bits/ostream_insert.h>
6910  #include <bits/stl_iterator.h>
6911  #include <bits/stl_function.h>  // For less
6912  #include <bits/basic_string.h>
6913 Index: gcc-4_2-branch/libstdc++-v3/include/std/std_ostream.h
6914 ===================================================================
6915 --- gcc-4_2-branch/libstdc++-v3/include/std/std_ostream.h       (revision 123014)
6916 +++ gcc-4_2-branch/libstdc++-v3/include/std/std_ostream.h       (revision 124164)
6917 @@ -1,6 +1,7 @@
6918  // Output streams -*- C++ -*-
6919  
6920 -// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2006
6921 +// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
6922 +// 2006, 2007
6923  // Free Software Foundation, Inc.
6924  //
6925  // This file is part of the GNU ISO C++ Library.  This library is free
6926 @@ -42,6 +43,7 @@
6927  #pragma GCC system_header
6928  
6929  #include <ios>
6930 +#include <bits/ostream_insert.h>
6931  
6932  _GLIBCXX_BEGIN_NAMESPACE(std)
6933  
6934 @@ -72,31 +74,6 @@
6935                                                         __num_put_type;
6936        typedef ctype<_CharT>                            __ctype_type;
6937  
6938 -      template<typename _CharT2, typename _Traits2>
6939 -        friend basic_ostream<_CharT2, _Traits2>&
6940 -        operator<<(basic_ostream<_CharT2, _Traits2>&, _CharT2);
6941
6942 -      template<typename _Traits2>
6943 -        friend basic_ostream<char, _Traits2>&
6944 -        operator<<(basic_ostream<char, _Traits2>&, char);
6945
6946 -      template<typename _CharT2, typename _Traits2>
6947 -        friend basic_ostream<_CharT2, _Traits2>&
6948 -        operator<<(basic_ostream<_CharT2, _Traits2>&, const _CharT2*);
6949
6950 -      template<typename _Traits2>
6951 -        friend basic_ostream<char, _Traits2>&
6952 -        operator<<(basic_ostream<char, _Traits2>&, const char*);
6953
6954 -      template<typename _CharT2, typename _Traits2>
6955 -        friend basic_ostream<_CharT2, _Traits2>&
6956 -        operator<<(basic_ostream<_CharT2, _Traits2>&, const char*);
6957 -
6958 -      template<typename _CharT2, typename _Traits2, typename _Alloc>
6959 -        friend basic_ostream<_CharT2, _Traits2>&
6960 -        operator<<(basic_ostream<_CharT2, _Traits2>&,
6961 -                  const basic_string<_CharT2, _Traits2, _Alloc>&);
6962 -
6963        // [27.6.2.2] constructor/destructor
6964        /**
6965         *  @brief  Base constructor.
6966 @@ -318,20 +295,6 @@
6967           this->setstate(ios_base::badbit);
6968        }
6969  
6970 -      void
6971 -      _M_write(char_type __c, streamsize __n)
6972 -      {
6973 -       for (; __n > 0; --__n)
6974 -         {
6975 -           const int_type __put = this->rdbuf()->sputc(__c);
6976 -           if (traits_type::eq_int_type(__put, traits_type::eof()))
6977 -             {
6978 -               this->setstate(ios_base::badbit);
6979 -               break;
6980 -             }
6981 -         }
6982 -      }
6983 -
6984        /**
6985         *  @brief  Character string insertion.
6986         *  @param  s  The array to insert.
6987 @@ -405,9 +368,6 @@
6988        template<typename _ValueT>
6989          __ostream_type&
6990          _M_insert(_ValueT __v);
6991 -
6992 -      __ostream_type&
6993 -      _M_insert(const char_type* __s, streamsize __n);
6994      };
6995  
6996    /**
6997 @@ -491,7 +451,7 @@
6998    template<typename _CharT, typename _Traits>
6999      inline basic_ostream<_CharT, _Traits>&
7000      operator<<(basic_ostream<_CharT, _Traits>& __out, _CharT __c)
7001 -    { return __out._M_insert(&__c, 1); }
7002 +    { return __ostream_insert(__out, &__c, 1); }
7003  
7004    template<typename _CharT, typename _Traits>
7005      inline basic_ostream<_CharT, _Traits>&
7006 @@ -502,7 +462,7 @@
7007    template <class _Traits> 
7008      inline basic_ostream<char, _Traits>&
7009      operator<<(basic_ostream<char, _Traits>& __out, char __c)
7010 -    { return __out._M_insert(&__c, 1); }
7011 +    { return __ostream_insert(__out, &__c, 1); }
7012  
7013    // Signed and unsigned
7014    template<class _Traits>
7015 @@ -537,7 +497,8 @@
7016        if (!__s)
7017         __out.setstate(ios_base::badbit);
7018        else
7019 -       __out._M_insert(__s, static_cast<streamsize>(_Traits::length(__s)));
7020 +       __ostream_insert(__out, __s,
7021 +                        static_cast<streamsize>(_Traits::length(__s)));
7022        return __out;
7023      }
7024  
7025 @@ -553,7 +514,8 @@
7026        if (!__s)
7027         __out.setstate(ios_base::badbit);
7028        else
7029 -       __out._M_insert(__s, static_cast<streamsize>(_Traits::length(__s)));
7030 +       __ostream_insert(__out, __s,
7031 +                        static_cast<streamsize>(_Traits::length(__s)));
7032        return __out;
7033      }
7034  
7035 Index: gcc-4_2-branch/libstdc++-v3/ChangeLog
7036 ===================================================================
7037 --- gcc-4_2-branch/libstdc++-v3/ChangeLog       (revision 123014)
7038 +++ gcc-4_2-branch/libstdc++-v3/ChangeLog       (revision 124164)
7039 @@ -1,3 +1,73 @@
7040 +2007-04-12  Paolo Carlini  <pcarlini@suse.de>
7041 +
7042 +       PR libstdc++/28277 (partial: vstring bits)
7043 +       * include/bits/ostream_insert.h: New.
7044 +       * include/Makefile.am: Add.
7045 +       * include/ext/vstring.h (operator<<(basic_ostream<>&,
7046 +       const __versa_string<>&): Forward to __ostream_insert.
7047 +       * include/bits/basic_string.h (operator<<(basic_ostream<>&,
7048 +       const string<>&)): Likewise.
7049 +       * include/std/std_ostream.h (operator<<(basic_ostream<>&, _CharT),
7050 +       operator<<(basic_ostream<char,>&, char), operator<<(basic_ostream<>&,
7051 +       const _CharT*), operator<<(basic_ostream<char,>&, const char*)):
7052 +       Likewise.
7053 +       * include/ext/vstring.tcc (operator<<(basic_ostream<>&,
7054 +       const __versa_string<>&)): Remove.
7055 +       (class basic_ostream): Remove friend declarations.
7056 +       (basic_ostream<>::_M_write(char_type, streamsize),
7057 +       _M_insert(const char_type*, streamsize)): Remove.
7058 +       * include/bits/ostream.tcc (_M_insert(const char_type*, streamsize)):
7059 +       Remove definition.
7060 +       (operator<<(basic_ostream<>&, const char*)): Use __ostream_insert.
7061 +       * include/ext/vstring_util.h: Include <bits/ostream_insert.h>.
7062 +       * include/std/std_string.h: Likewise.
7063 +       * config/abi/pre/gnu.ver: Adjust.
7064 +       * src/ostream-inst.cc: Add __ostream_insert instantiations.
7065 +       * include/Makefile.in: Rebuild.
7066 +       * testsuite/ext/vstring/inserters_extractors/char/28277.cc: New.
7067 +       * testsuite/ext/vstring/inserters_extractors/wchar_t/28277.cc: New.
7068 +
7069 +2007-04-07  Paolo Carlini  <pcarlini@suse.de>
7070 +
7071 +       PR libstdc++/31481
7072 +       * include/ext/type_traits.h (__numeric_traits): Move...
7073 +       * include/ext/numeric_traits.h: ... here; fix type of
7074 +       __max_digits10.
7075 +       * include/Makefile.am: Add.
7076 +       * include/ext/pb_ds/detail/type_utils.hpp: Include 
7077 +       <ext/numeric_traits.h> too.
7078 +       * include/tr1/random: Likewise.
7079 +       * testsuite/ext/type_traits/numeric_traits.cc: Move...
7080 +       * testsuite/ext/numeric_traits/numeric_traits.cc: ... here.
7081 +       * include/Makefile.in: Regenerate.
7082 +       * testsuite/ext/type_traits/remove_unsigned_integer_neg.cc:
7083 +       Adjust dg-error line number.
7084 +       * testsuite/ext/type_traits/add_unsigned_floating_neg.cc:
7085 +       Likewise.
7086 +       * testsuite/ext/type_traits/remove_unsigned_floating_neg.cc:
7087 +       Likewise.
7088 +       * testsuite/ext/type_traits/add_unsigned_integer_neg.cc:
7089 +       Likewise.
7090 +
7091 +2007-04-03  Paolo Carlini  <pcarlini@suse.de>
7092 +
7093 +       * include/bits/stl_map.h (map<>::insert(iterator, const value_type&):
7094 +       Uglify parameter.
7095 +
7096 +2007-04-02  Paolo Carlini  <pcarlini@suse.de>
7097 +
7098 +       PR libstdc++/31401 (vstring bits)
7099 +       * include/ext/vstring.tcc (find(const _CharT*, size_type,
7100 +       size_type)): Avoid unsigned overflow.
7101 +
7102 +2007-03-30  Paolo Carlini  <pcarlini@suse.de>
7103 +
7104 +       PR libstdc++/31401
7105 +       * include/bits/basic_string.tcc (find(const _CharT*, size_type,
7106 +       size_type)): Avoid unsigned overflow.
7107 +       * testsuite/21_strings/basic_string/find/char/4.cc: New.
7108 +       * testsuite/21_strings/basic_string/find/wchar_t/4.cc: Likewise.
7109 +
7110  2007-03-06  Paolo Carlini  <pcarlini@suse.de>
7111  
7112         PR libstdc++/28080 (partial)
7113 Index: gcc-4_2-branch/libstdc++-v3/src/ostream-inst.cc
7114 ===================================================================
7115 --- gcc-4_2-branch/libstdc++-v3/src/ostream-inst.cc     (revision 123014)
7116 +++ gcc-4_2-branch/libstdc++-v3/src/ostream-inst.cc     (revision 124164)
7117 @@ -55,6 +55,7 @@
7118    template ostream& operator<<(ostream&, _Setbase);
7119    template ostream& operator<<(ostream&, _Setprecision);
7120    template ostream& operator<<(ostream&, _Setw);
7121 +  template ostream& __ostream_insert(ostream&, const char*, streamsize);
7122  
7123    template ostream& ostream::_M_insert(long);
7124    template ostream& ostream::_M_insert(unsigned long);
7125 @@ -83,6 +84,7 @@
7126    template wostream& operator<<(wostream&, _Setbase);
7127    template wostream& operator<<(wostream&, _Setprecision);
7128    template wostream& operator<<(wostream&, _Setw);
7129 +  template wostream& __ostream_insert(wostream&, const wchar_t*, streamsize);
7130  
7131    template wostream& wostream::_M_insert(long);
7132    template wostream& wostream::_M_insert(unsigned long);
7133 Index: gcc-4_2-branch/libstdc++-v3/testsuite/21_strings/basic_string/find/wchar_t/4.cc
7134 ===================================================================
7135 --- gcc-4_2-branch/libstdc++-v3/testsuite/21_strings/basic_string/find/wchar_t/4.cc     (revision 0)
7136 +++ gcc-4_2-branch/libstdc++-v3/testsuite/21_strings/basic_string/find/wchar_t/4.cc     (revision 124164)
7137 @@ -0,0 +1,43 @@
7138 +// 2007-03-30  Paolo Carlini  <pcarlini@suse.de>
7139 +
7140 +// Copyright (C) 2007 Free Software Foundation, Inc.
7141 +//
7142 +// This file is part of the GNU ISO C++ Library.  This library is free
7143 +// software; you can redistribute it and/or modify it under the
7144 +// terms of the GNU General Public License as published by the
7145 +// Free Software Foundation; either version 2, or (at your option)
7146 +// any later version.
7147 +
7148 +// This library is distributed in the hope that it will be useful,
7149 +// but WITHOUT ANY WARRANTY; without even the implied warranty of
7150 +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
7151 +// GNU General Public License for more details.
7152 +
7153 +// You should have received a copy of the GNU General Public License along
7154 +// with this library; see the file COPYING.  If not, write to the Free
7155 +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
7156 +// USA.
7157 +
7158 +// 21.3.6.1 basic_string find
7159 +
7160 +#include <string>
7161 +#include <testsuite_hooks.h>
7162 +
7163 +// libstdc++/31401
7164 +void test01()
7165 +{
7166 +  bool test __attribute__((unused)) = true;
7167 +  typedef std::wstring::size_type csize_type;
7168 +  csize_type npos = std::wstring::npos;
7169 +
7170 +  std::wstring use = L"anu";
7171 +  csize_type pos1 = use.find(L"a", npos);
7172 +
7173 +  VERIFY( pos1 == npos );
7174 +}
7175 +
7176 +int main()
7177 +{
7178 +  test01();
7179 +  return 0;
7180 +}
7181 Index: gcc-4_2-branch/libstdc++-v3/testsuite/21_strings/basic_string/find/char/4.cc
7182 ===================================================================
7183 --- gcc-4_2-branch/libstdc++-v3/testsuite/21_strings/basic_string/find/char/4.cc        (revision 0)
7184 +++ gcc-4_2-branch/libstdc++-v3/testsuite/21_strings/basic_string/find/char/4.cc        (revision 124164)
7185 @@ -0,0 +1,43 @@
7186 +// 2007-03-30  Paolo Carlini  <pcarlini@suse.de>
7187 +
7188 +// Copyright (C) 2007 Free Software Foundation, Inc.
7189 +//
7190 +// This file is part of the GNU ISO C++ Library.  This library is free
7191 +// software; you can redistribute it and/or modify it under the
7192 +// terms of the GNU General Public License as published by the
7193 +// Free Software Foundation; either version 2, or (at your option)
7194 +// any later version.
7195 +
7196 +// This library is distributed in the hope that it will be useful,
7197 +// but WITHOUT ANY WARRANTY; without even the implied warranty of
7198 +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
7199 +// GNU General Public License for more details.
7200 +
7201 +// You should have received a copy of the GNU General Public License along
7202 +// with this library; see the file COPYING.  If not, write to the Free
7203 +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
7204 +// USA.
7205 +
7206 +// 21.3.6.1 basic_string find
7207 +
7208 +#include <string>
7209 +#include <testsuite_hooks.h>
7210 +
7211 +// libstdc++/31401
7212 +void test01()
7213 +{
7214 +  bool test __attribute__((unused)) = true;
7215 +  typedef std::string::size_type csize_type;
7216 +  csize_type npos = std::string::npos;
7217 +
7218 +  std::string use = "anu";
7219 +  csize_type pos1 = use.find("a", npos);
7220 +
7221 +  VERIFY( pos1 == npos );
7222 +}
7223 +
7224 +int main()
7225 +{
7226 +  test01();
7227 +  return 0;
7228 +}
7229 Index: gcc-4_2-branch/libstdc++-v3/testsuite/ext/numeric_traits/numeric_traits.cc
7230 ===================================================================
7231 --- gcc-4_2-branch/libstdc++-v3/testsuite/ext/numeric_traits/numeric_traits.cc  (revision 0)
7232 +++ gcc-4_2-branch/libstdc++-v3/testsuite/ext/numeric_traits/numeric_traits.cc  (revision 124164)
7233 @@ -0,0 +1,28 @@
7234 +// { dg-do compile }
7235 +// { dg-options "-pedantic" }
7236 +// -*- C++ -*-
7237 +
7238 +// Copyright (C) 2006 Free Software Foundation, Inc.
7239 +//
7240 +// This file is part of the GNU ISO C++ Library.  This library is free
7241 +// software; you can redistribute it and/or modify it under the
7242 +// terms of the GNU General Public License as published by the
7243 +// Free Software Foundation; either version 2, or (at your option)
7244 +// any later version.
7245 +//
7246 +// This library is distributed in the hope that it will be useful,
7247 +// but WITHOUT ANY WARRANTY; without even the implied warranty of
7248 +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
7249 +// GNU General Public License for more details.
7250 +//
7251 +// You should have received a copy of the GNU General Public License along
7252 +// with this library; see the file COPYING.  If not, write to the Free
7253 +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
7254 +// USA.
7255 +
7256 +#include <ext/numeric_traits.h>
7257 +
7258 +using __gnu_cxx::__numeric_traits;
7259 +template struct __numeric_traits<short>;
7260 +template struct __numeric_traits<unsigned short>;
7261 +template struct __numeric_traits<double>;
7262 Index: gcc-4_2-branch/libstdc++-v3/testsuite/ext/vstring/inserters_extractors/wchar_t/28277.cc
7263 ===================================================================
7264 --- gcc-4_2-branch/libstdc++-v3/testsuite/ext/vstring/inserters_extractors/wchar_t/28277.cc     (revision 0)
7265 +++ gcc-4_2-branch/libstdc++-v3/testsuite/ext/vstring/inserters_extractors/wchar_t/28277.cc     (revision 124164)
7266 @@ -0,0 +1,48 @@
7267 +// 2007-04-09  Paolo Carlini  <pcarlini@suse.de>
7268 +
7269 +// Copyright (C) 2007 Free Software Foundation
7270 +//
7271 +// This file is part of the GNU ISO C++ Library.  This library is free
7272 +// software; you can redistribute it and/or modify it under the
7273 +// terms of the GNU General Public License as published by the
7274 +// Free Software Foundation; either version 2, or (at your option)
7275 +// any later version.
7276 +
7277 +// This library is distributed in the hope that it will be useful,
7278 +// but WITHOUT ANY WARRANTY; without even the implied warranty of
7279 +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
7280 +// GNU General Public License for more details.
7281 +
7282 +// You should have received a copy of the GNU General Public License along
7283 +// with this library; see the file COPYING.  If not, write to the Free
7284 +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
7285 +// USA.
7286 +
7287 +#include <ostream>
7288 +#include <sstream>
7289 +#include <ext/vstring.h>
7290 +#include <testsuite_hooks.h>
7291 +
7292 +// libstdc++/28277
7293 +void test01()
7294 +{
7295 +  using namespace std;
7296 +  bool test __attribute__((unused)) = true;
7297 +
7298 +  wostringstream oss_01;
7299 +  const __gnu_cxx::__wvstring str_01(50, L'a');
7300 +
7301 +  oss_01.width(5000000);
7302 +  const streamsize width = oss_01.width();
7303 +
7304 +  oss_01 << str_01;
7305 +
7306 +  VERIFY( oss_01.good() );
7307 +  VERIFY( oss_01.str().size() == width );
7308 +}
7309 +
7310 +int main()
7311 +{
7312 +  test01();
7313 +  return 0;
7314 +}
7315 Index: gcc-4_2-branch/libstdc++-v3/testsuite/ext/vstring/inserters_extractors/char/28277.cc
7316 ===================================================================
7317 --- gcc-4_2-branch/libstdc++-v3/testsuite/ext/vstring/inserters_extractors/char/28277.cc        (revision 0)
7318 +++ gcc-4_2-branch/libstdc++-v3/testsuite/ext/vstring/inserters_extractors/char/28277.cc        (revision 124164)
7319 @@ -0,0 +1,48 @@
7320 +// 2007-04-09  Paolo Carlini  <pcarlini@suse.de>
7321 +
7322 +// Copyright (C) 2007 Free Software Foundation
7323 +//
7324 +// This file is part of the GNU ISO C++ Library.  This library is free
7325 +// software; you can redistribute it and/or modify it under the
7326 +// terms of the GNU General Public License as published by the
7327 +// Free Software Foundation; either version 2, or (at your option)
7328 +// any later version.
7329 +
7330 +// This library is distributed in the hope that it will be useful,
7331 +// but WITHOUT ANY WARRANTY; without even the implied warranty of
7332 +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
7333 +// GNU General Public License for more details.
7334 +
7335 +// You should have received a copy of the GNU General Public License along
7336 +// with this library; see the file COPYING.  If not, write to the Free
7337 +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
7338 +// USA.
7339 +
7340 +#include <ostream>
7341 +#include <sstream>
7342 +#include <ext/vstring.h>
7343 +#include <testsuite_hooks.h>
7344 +
7345 +// libstdc++/28277
7346 +void test01()
7347 +{
7348 +  using namespace std;
7349 +  bool test __attribute__((unused)) = true;
7350 +
7351 +  ostringstream oss_01;
7352 +  const __gnu_cxx::__vstring str_01(50, 'a');
7353 +
7354 +  oss_01.width(20000000);
7355 +  const streamsize width = oss_01.width();
7356 +
7357 +  oss_01 << str_01;
7358 +
7359 +  VERIFY( oss_01.good() );
7360 +  VERIFY( oss_01.str().size() == width );
7361 +}
7362 +
7363 +int main()
7364 +{
7365 +  test01();
7366 +  return 0;
7367 +}
7368 Index: gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/numeric_traits.cc
7369 ===================================================================
7370 --- gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/numeric_traits.cc     (revision 123014)
7371 +++ gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/numeric_traits.cc     (revision 124164)
7372 @@ -1,28 +0,0 @@
7373 -// { dg-do compile }
7374 -// { dg-options "-pedantic" }
7375 -// -*- C++ -*-
7376 -
7377 -// Copyright (C) 2006 Free Software Foundation, Inc.
7378 -//
7379 -// This file is part of the GNU ISO C++ Library.  This library is free
7380 -// software; you can redistribute it and/or modify it under the
7381 -// terms of the GNU General Public License as published by the
7382 -// Free Software Foundation; either version 2, or (at your option)
7383 -// any later version.
7384 -//
7385 -// This library is distributed in the hope that it will be useful,
7386 -// but WITHOUT ANY WARRANTY; without even the implied warranty of
7387 -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
7388 -// GNU General Public License for more details.
7389 -//
7390 -// You should have received a copy of the GNU General Public License along
7391 -// with this library; see the file COPYING.  If not, write to the Free
7392 -// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
7393 -// USA.
7394 -
7395 -#include <ext/type_traits.h>
7396 -
7397 -using __gnu_cxx::__numeric_traits;
7398 -template struct __numeric_traits<short>;
7399 -template struct __numeric_traits<unsigned short>;
7400 -template struct __numeric_traits<double>;
7401 Index: gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/remove_unsigned_integer_neg.cc
7402 ===================================================================
7403 --- gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/remove_unsigned_integer_neg.cc        (revision 123014)
7404 +++ gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/remove_unsigned_integer_neg.cc        (revision 124164)
7405 @@ -1,7 +1,7 @@
7406  // { dg-do compile }
7407  // -*- C++ -*-
7408  
7409 -// Copyright (C) 2006 Free Software Foundation, Inc.
7410 +// Copyright (C) 2006, 2007 Free Software Foundation, Inc.
7411  //
7412  // This file is part of the GNU ISO C++ Library.  This library is free
7413  // software; you can redistribute it and/or modify it under the
7414 @@ -37,4 +37,4 @@
7415  }
7416  
7417  // { dg-error "invalid use of incomplete" "" { target *-*-* } 29 } 
7418 -// { dg-error "declaration of" "" { target *-*-* } 114 } 
7419 +// { dg-error "declaration of" "" { target *-*-* } 112 } 
7420 Index: gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/add_unsigned_floating_neg.cc
7421 ===================================================================
7422 --- gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/add_unsigned_floating_neg.cc  (revision 123014)
7423 +++ gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/add_unsigned_floating_neg.cc  (revision 124164)
7424 @@ -1,7 +1,7 @@
7425  // { dg-do compile }
7426  // -*- C++ -*-
7427  
7428 -// Copyright (C) 2006 Free Software Foundation, Inc.
7429 +// Copyright (C) 2006, 2007 Free Software Foundation, Inc.
7430  //
7431  // This file is part of the GNU ISO C++ Library.  This library is free
7432  // software; you can redistribute it and/or modify it under the
7433 @@ -36,5 +36,5 @@
7434  }
7435  
7436  // { dg-error "instantiated from" "" { target *-*-* } 29 } 
7437 -// { dg-error "no type" "" { target *-*-* } 76 } 
7438 +// { dg-error "no type" "" { target *-*-* } 74 } 
7439  // { dg-excess-errors "In instantiation of" }
7440 Index: gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/remove_unsigned_floating_neg.cc
7441 ===================================================================
7442 --- gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/remove_unsigned_floating_neg.cc       (revision 123014)
7443 +++ gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/remove_unsigned_floating_neg.cc       (revision 124164)
7444 @@ -1,7 +1,7 @@
7445  // { dg-do compile }
7446  // -*- C++ -*-
7447  
7448 -// Copyright (C) 2006 Free Software Foundation, Inc.
7449 +// Copyright (C) 2006, 2007 Free Software Foundation, Inc.
7450  //
7451  // This file is part of the GNU ISO C++ Library.  This library is free
7452  // software; you can redistribute it and/or modify it under the
7453 @@ -36,5 +36,5 @@
7454  }
7455  
7456  // { dg-error "instantiated from" "" { target *-*-* } 29 }
7457 -// { dg-error "no type" "" { target *-*-* } 119 }
7458 +// { dg-error "no type" "" { target *-*-* } 117 }
7459  // { dg-excess-errors "In instantiation of" }
7460 Index: gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/add_unsigned_integer_neg.cc
7461 ===================================================================
7462 --- gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/add_unsigned_integer_neg.cc   (revision 123014)
7463 +++ gcc-4_2-branch/libstdc++-v3/testsuite/ext/type_traits/add_unsigned_integer_neg.cc   (revision 124164)
7464 @@ -1,7 +1,7 @@
7465  // { dg-do compile }
7466  // -*- C++ -*-
7467  
7468 -// Copyright (C) 2006 Free Software Foundation, Inc.
7469 +// Copyright (C) 2006, 2007 Free Software Foundation, Inc.
7470  //
7471  // This file is part of the GNU ISO C++ Library.  This library is free
7472  // software; you can redistribute it and/or modify it under the
7473 @@ -37,4 +37,4 @@
7474  }
7475  
7476  // { dg-error "invalid use of incomplete" "" { target *-*-* } 29 } 
7477 -// { dg-error "declaration of" "" { target *-*-* } 71 } 
7478 +// { dg-error "declaration of" "" { target *-*-* } 69 } 
7479 Index: gcc-4_2-branch/libstdc++-v3/config/abi/pre/gnu.ver
7480 ===================================================================
7481 --- gcc-4_2-branch/libstdc++-v3/config/abi/pre/gnu.ver  (revision 123014)
7482 +++ gcc-4_2-branch/libstdc++-v3/config/abi/pre/gnu.ver  (revision 124164)
7483 @@ -676,8 +676,7 @@
7484  
7485      _ZSt21__copy_streambufs_eofI[cw]St11char_traitsI[cw]EE[il]PSt15basic_streambuf*;
7486  
7487 -    _ZNSo9_M_insertEPKc[il];
7488 -    _ZNSt13basic_ostreamIwSt11char_traitsIwEE9_M_insertEPKw[il];
7489 +    _ZSt16__ostream_insert*;
7490  
7491      _ZN11__gnu_debug19_Safe_sequence_base12_M_get_mutexEv;
7492      _ZN11__gnu_debug19_Safe_iterator_base16_M_attach_singleEPNS_19_Safe_sequence_baseEb;
7493 Index: gcc-4_2-branch/libgfortran/configure
7494 ===================================================================
7495 --- gcc-4_2-branch/libgfortran/configure        (revision 123014)
7496 +++ gcc-4_2-branch/libgfortran/configure        (revision 124164)
7497 @@ -10222,7 +10222,10 @@
7498  
7499  
7500  
7501 -for ac_func in wait setmode gettimeofday
7502 +
7503 +
7504 +
7505 +for ac_func in wait setmode gettimeofday stat fstat lstat
7506  do
7507  as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
7508  echo "$as_me:$LINENO: checking for $ac_func" >&5
7509 Index: gcc-4_2-branch/libgfortran/intrinsics/stat.c
7510 ===================================================================
7511 --- gcc-4_2-branch/libgfortran/intrinsics/stat.c        (revision 123014)
7512 +++ gcc-4_2-branch/libgfortran/intrinsics/stat.c        (revision 124164)
7513 @@ -49,6 +49,9 @@
7514  
7515  #include <errno.h>
7516  
7517 +
7518 +#ifdef HAVE_STAT
7519 +
7520  /* SUBROUTINE STAT(FILE, SARRAY, STATUS)
7521     CHARACTER(len=*), INTENT(IN) :: FILE
7522     INTEGER, INTENT(OUT), :: SARRAY(13)
7523 @@ -88,9 +91,12 @@
7524    memcpy (str, name, name_len);
7525    str[name_len] = '\0';
7526  
7527 +  /* On platforms that don't provide lstat(), we use stat() instead.  */
7528 +#ifdef HAVE_LSTAT
7529    if (is_lstat)
7530      val = lstat(str, &sb);
7531    else
7532 +#endif
7533      val = stat(str, &sb);
7534  
7535    if (val == 0)
7536 @@ -204,9 +210,12 @@
7537    memcpy (str, name, name_len);
7538    str[name_len] = '\0';
7539  
7540 +  /* On platforms that don't provide lstat(), we use stat() instead.  */
7541 +#ifdef HAVE_LSTAT
7542    if (is_lstat)
7543      val = lstat(str, &sb);
7544    else
7545 +#endif
7546      val = stat(str, &sb);
7547  
7548    if (val == 0)
7549 @@ -319,13 +328,13 @@
7550  }
7551  
7552  
7553 -/* SUBROUTINE STAT(FILE, SARRAY, STATUS)
7554 +/* SUBROUTINE LSTAT(FILE, SARRAY, STATUS)
7555     CHARACTER(len=*), INTENT(IN) :: FILE
7556     INTEGER, INTENT(OUT), :: SARRAY(13)
7557     INTEGER, INTENT(OUT), OPTIONAL :: STATUS
7558  
7559 -   FUNCTION STAT(FILE, SARRAY)
7560 -   INTEGER STAT
7561 +   FUNCTION LSTAT(FILE, SARRAY)
7562 +   INTEGER LSTAT
7563     CHARACTER(len=*), INTENT(IN) :: FILE
7564     INTEGER, INTENT(OUT), :: SARRAY(13)  */
7565  
7566 @@ -351,8 +360,11 @@
7567    return val;
7568  }
7569  
7570 +#endif
7571  
7572  
7573 +#ifdef HAVE_FSTAT
7574 +
7575  /* SUBROUTINE FSTAT(UNIT, SARRAY, STATUS)
7576     INTEGER, INTENT(IN) :: UNIT
7577     INTEGER, INTENT(OUT) :: SARRAY(13)
7578 @@ -546,3 +558,5 @@
7579    fstat_i8_sub (unit, sarray, &val);
7580    return val;
7581  }
7582 +
7583 +#endif
7584 Index: gcc-4_2-branch/libgfortran/ChangeLog
7585 ===================================================================
7586 --- gcc-4_2-branch/libgfortran/ChangeLog        (revision 123014)
7587 +++ gcc-4_2-branch/libgfortran/ChangeLog        (revision 124164)
7588 @@ -1,3 +1,19 @@
7589 +2007-04-17  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
7590 +
7591 +       PR libgfortran/31366
7592 +       * io/transfer.c (read_block_direct): Do not generate error when reading
7593 +       past EOF on a short record that is less than the RECL= specified.
7594 +
7595 +2007-04-13  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
7596 +
7597 +       PR libfortran/31335
7598 +       * intrinsics/stat.c: Only provide STAT and FSTAT library routines
7599 +       if stat() and fstat() library functions are available. When lstat()
7600 +       is not available, use stat() instead.
7601 +       * configure.ac: Add checks for stat, fstat and lstat.
7602 +       * configure: Regenerate.
7603 +       * config.h.in: Regenerate.
7604 +
7605  2007-03-15  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
7606  
7607         PR libgfortran/31099
7608 @@ -3,4 +19,9 @@
7609         * io/file_pos.c (st_rewind): Don't set bytes_left to zero.
7610  
7611 +2007-03-14  Jakub Jelinek  <jakub@redhat.com>
7612 +
7613 +       * io/unix.c (regular_file): For ACTION_UNSPECIFIED retry with
7614 +       O_RDONLY even if errno is EROFS.
7615 +
7616  2007-03-09  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
7617  
7618 Index: gcc-4_2-branch/libgfortran/config.h.in
7619 ===================================================================
7620 --- gcc-4_2-branch/libgfortran/config.h.in      (revision 123014)
7621 +++ gcc-4_2-branch/libgfortran/config.h.in      (revision 124164)
7622 @@ -357,6 +357,9 @@
7623  /* libm includes frexpl */
7624  #undef HAVE_FREXPL
7625  
7626 +/* Define to 1 if you have the `fstat' function. */
7627 +#undef HAVE_FSTAT
7628 +
7629  /* Define to 1 if you have the `ftruncate' function. */
7630  #undef HAVE_FTRUNCATE
7631  
7632 @@ -462,6 +465,9 @@
7633  /* libm includes logl */
7634  #undef HAVE_LOGL
7635  
7636 +/* Define to 1 if you have the `lstat' function. */
7637 +#undef HAVE_LSTAT
7638 +
7639  /* Define to 1 if you have the <math.h> header file. */
7640  #undef HAVE_MATH_H
7641  
7642 @@ -552,6 +558,9 @@
7643  /* libm includes sqrtl */
7644  #undef HAVE_SQRTL
7645  
7646 +/* Define to 1 if you have the `stat' function. */
7647 +#undef HAVE_STAT
7648 +
7649  /* Define to 1 if you have the <stddef.h> header file. */
7650  #undef HAVE_STDDEF_H
7651  
7652 Index: gcc-4_2-branch/libgfortran/configure.ac
7653 ===================================================================
7654 --- gcc-4_2-branch/libgfortran/configure.ac     (revision 123014)
7655 +++ gcc-4_2-branch/libgfortran/configure.ac     (revision 124164)
7656 @@ -177,7 +177,7 @@
7657  AC_CHECK_FUNCS(getrusage times mkstemp strtof strtold snprintf ftruncate chsize)
7658  AC_CHECK_FUNCS(chdir strerror getlogin gethostname kill link symlink perror)
7659  AC_CHECK_FUNCS(sleep time ttyname signal alarm ctime clock access fork execl)
7660 -AC_CHECK_FUNCS(wait setmode gettimeofday)
7661 +AC_CHECK_FUNCS(wait setmode gettimeofday stat fstat lstat)
7662  
7663  # Check for types
7664  AC_CHECK_TYPES([intptr_t])
7665 Index: gcc-4_2-branch/libgfortran/io/unix.c
7666 ===================================================================
7667 --- gcc-4_2-branch/libgfortran/io/unix.c        (revision 123014)
7668 +++ gcc-4_2-branch/libgfortran/io/unix.c        (revision 124164)
7669 @@ -1186,7 +1186,7 @@
7670        break;
7671  
7672      case STATUS_REPLACE:
7673 -        crflag = O_CREAT | O_TRUNC;
7674 +      crflag = O_CREAT | O_TRUNC;
7675        break;
7676  
7677      default:
7678 @@ -1202,14 +1202,14 @@
7679    mode = S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH;
7680    fd = open (path, rwflag | crflag, mode);
7681    if (flags->action != ACTION_UNSPECIFIED)
7682 -      return fd;
7683 +    return fd;
7684  
7685    if (fd >= 0)
7686      {
7687        flags->action = ACTION_READWRITE;
7688        return fd;
7689      }
7690 -  if (errno != EACCES)
7691 +  if (errno != EACCES && errno != EROFS)
7692       return fd;
7693  
7694    /* retry for read-only access */
7695 Index: gcc-4_2-branch/libgfortran/io/transfer.c
7696 ===================================================================
7697 --- gcc-4_2-branch/libgfortran/io/transfer.c    (revision 123014)
7698 +++ gcc-4_2-branch/libgfortran/io/transfer.c    (revision 124164)
7699 @@ -410,7 +410,6 @@
7700           /* Short read, e.g. if we hit EOF.  Apparently, we read
7701            more than was written to the last record.  */
7702           *nbytes = to_read_record;
7703 -         generate_error (&dtp->common, ERROR_SHORT_RECORD, NULL);
7704           return;
7705         }
7706  
7707 Index: gcc-4_2-branch/libffi/configure
7708 ===================================================================
7709 --- gcc-4_2-branch/libffi/configure     (revision 123014)
7710 +++ gcc-4_2-branch/libffi/configure     (revision 124164)
7711 @@ -5401,7 +5401,11 @@
7712  sparc-*-linux* | sparc-*-netbsdelf* | sparc-*-knetbsd*-gnu) TARGET=SPARC; TARGETDIR=sparc;;
7713  sparc*-*-rtems*) TARGET=SPARC; TARGETDIR=sparc;;
7714  sparc64-*-linux* | sparc64-*-freebsd* | sparc64-*-netbsd* | sparc64-*-knetbsd*-gnu) TARGET=SPARC; TARGETDIR=sparc;;
7715 -alpha*-*-linux* | alpha*-*-osf* | alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu | alpha*-*-netbsd* | alpha*-*-knetbsd*-gnu) TARGET=ALPHA; TARGETDIR=alpha;;
7716 +alpha*-*-linux* | alpha*-*-osf* | alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu | alpha*-*-netbsd* | alpha*-*-knetbsd*-gnu)
7717 +       TARGET=ALPHA; TARGETDIR=alpha
7718 +       # Support 128-bit long double, changable via command-line switch.
7719 +       HAVE_LONG_DOUBLE='defined(__LONG_DOUBLE_128__)'
7720 +       ;;
7721  ia64*-*-*) TARGET=IA64; TARGETDIR=ia64;;
7722  m32r*-*-linux* ) TARGET=M32R; TARGETDIR=m32r;;
7723  m68k-*-linux*) TARGET=M68K; TARGETDIR=m68k;;
7724 @@ -7142,15 +7146,17 @@
7725  
7726  
7727  # Also AC_SUBST this variable for ffi.h.
7728 -HAVE_LONG_DOUBLE=0
7729 -if test $ac_cv_sizeof_double != $ac_cv_sizeof_long_double; then
7730 -  if test $ac_cv_sizeof_long_double != 0; then
7731 -    HAVE_LONG_DOUBLE=1
7732 +if test -z "$HAVE_LONG_DOUBLE"; then
7733 +  HAVE_LONG_DOUBLE=0
7734 +  if test $ac_cv_sizeof_double != $ac_cv_sizeof_long_double; then
7735 +    if test $ac_cv_sizeof_long_double != 0; then
7736 +      HAVE_LONG_DOUBLE=1
7737  
7738  cat >>confdefs.h <<\_ACEOF
7739  #define HAVE_LONG_DOUBLE 1
7740  _ACEOF
7741  
7742 +    fi
7743    fi
7744  fi
7745  
7746 Index: gcc-4_2-branch/libffi/include/ffi.h.in
7747 ===================================================================
7748 --- gcc-4_2-branch/libffi/include/ffi.h.in      (revision 123014)
7749 +++ gcc-4_2-branch/libffi/include/ffi.h.in      (revision 124164)
7750 @@ -153,9 +153,13 @@
7751  extern ffi_type ffi_type_sint64;
7752  extern ffi_type ffi_type_float;
7753  extern ffi_type ffi_type_double;
7754 -extern ffi_type ffi_type_longdouble;
7755  extern ffi_type ffi_type_pointer;
7756  
7757 +#if @HAVE_LONG_DOUBLE@
7758 +extern ffi_type ffi_type_longdouble;
7759 +#else
7760 +#define ffi_type_longdouble ffi_type_double
7761 +#endif
7762  
7763  typedef enum {
7764    FFI_OK = 0,
7765 Index: gcc-4_2-branch/libffi/src/alpha/ffi.c
7766 ===================================================================
7767 --- gcc-4_2-branch/libffi/src/alpha/ffi.c       (revision 123014)
7768 +++ gcc-4_2-branch/libffi/src/alpha/ffi.c       (revision 124164)
7769 @@ -25,13 +25,24 @@
7770  
7771  #include <ffi.h>
7772  #include <ffi_common.h>
7773 -
7774  #include <stdlib.h>
7775  
7776 -extern void ffi_call_osf(void *, unsigned long, unsigned, void *, void (*)());
7777 -extern void ffi_closure_osf(void);
7778 +/* Force FFI_TYPE_LONGDOUBLE to be different than FFI_TYPE_DOUBLE;
7779 +   all further uses in this file will refer to the 128-bit type.  */
7780 +#if defined(__LONG_DOUBLE_128__)
7781 +# if FFI_TYPE_LONGDOUBLE != 4
7782 +#  error FFI_TYPE_LONGDOUBLE out of date
7783 +# endif
7784 +#else
7785 +# undef FFI_TYPE_LONGDOUBLE
7786 +# define FFI_TYPE_LONGDOUBLE 4
7787 +#endif
7788  
7789 +extern void ffi_call_osf(void *, unsigned long, unsigned, void *, void (*)())
7790 +  FFI_HIDDEN;
7791 +extern void ffi_closure_osf(void) FFI_HIDDEN;
7792  
7793 +
7794  ffi_status
7795  ffi_prep_cif_machdep(ffi_cif *cif)
7796  {
7797 @@ -49,6 +60,11 @@
7798        cif->flags = cif->rtype->type;
7799        break;
7800  
7801 +    case FFI_TYPE_LONGDOUBLE:
7802 +      /* 128-bit long double is returned in memory, like a struct.  */
7803 +      cif->flags = FFI_TYPE_STRUCT;
7804 +      break;
7805 +
7806      default:
7807        cif->flags = FFI_TYPE_INT;
7808        break;
7809 @@ -57,6 +73,7 @@
7810    return FFI_OK;
7811  }
7812  
7813 +
7814  void
7815  ffi_call(ffi_cif *cif, void (*fn)(), void *rvalue, void **avalue)
7816  {
7817 @@ -64,8 +81,6 @@
7818    long i, avn;
7819    ffi_type **arg_types;
7820    
7821 -  FFI_ASSERT (cif->abi == FFI_OSF);
7822 -
7823    /* If the return value is a struct and we don't have a return
7824       value address then we need to make one.  */
7825    if (rvalue == NULL && cif->flags == FFI_TYPE_STRUCT)
7826 @@ -84,6 +99,8 @@
7827  
7828    while (i < avn)
7829      {
7830 +      size_t size = (*arg_types)->size;
7831 +
7832        switch ((*arg_types)->type)
7833         {
7834         case FFI_TYPE_SINT8:
7835 @@ -129,6 +146,12 @@
7836           *(double *) argp = *(double *)(* avalue);
7837           break;
7838  
7839 +       case FFI_TYPE_LONGDOUBLE:
7840 +         /* 128-bit long double is passed by reference.  */
7841 +         *(long double **) argp = (long double *)(* avalue);
7842 +         size = sizeof (long double *);
7843 +         break;
7844 +
7845         case FFI_TYPE_STRUCT:
7846           memcpy(argp, *avalue, (*arg_types)->size);
7847           break;
7848 @@ -137,7 +160,7 @@
7849           FFI_ASSERT(0);
7850         }
7851  
7852 -      argp += ALIGN((*arg_types)->size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG;
7853 +      argp += ALIGN(size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG;
7854        i++, arg_types++, avalue++;
7855      }
7856  
7857 @@ -153,8 +176,6 @@
7858  {
7859    unsigned int *tramp;
7860  
7861 -  FFI_ASSERT (cif->abi == FFI_OSF);
7862 -
7863    tramp = (unsigned int *) &closure->tramp[0];
7864    tramp[0] = 0x47fb0401;       /* mov $27,$1           */
7865    tramp[1] = 0xa77b0010;       /* ldq $27,16($27)      */
7866 @@ -177,7 +198,8 @@
7867    return FFI_OK;
7868  }
7869  
7870 -int
7871 +
7872 +long FFI_HIDDEN
7873  ffi_closure_osf_inner(ffi_closure *closure, void *rvalue, unsigned long *argp)
7874  {
7875    ffi_cif *cif;
7876 @@ -205,6 +227,8 @@
7877    /* Grab the addresses of the arguments from the stack frame.  */
7878    while (i < avn)
7879      {
7880 +      size_t size = arg_types[i]->size;
7881 +
7882        switch (arg_types[i]->type)
7883         {
7884         case FFI_TYPE_SINT8:
7885 @@ -236,16 +260,22 @@
7886           avalue[i] = &argp[argn - (argn < 6 ? 6 : 0)];
7887           break;
7888  
7889 +       case FFI_TYPE_LONGDOUBLE:
7890 +         /* 128-bit long double is passed by reference.  */
7891 +         avalue[i] = (long double *) argp[argn];
7892 +         size = sizeof (long double *);
7893 +         break;
7894 +
7895         default:
7896 -         FFI_ASSERT(0);
7897 +         abort ();
7898         }
7899  
7900 -      argn += ALIGN(arg_types[i]->size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG;
7901 +      argn += ALIGN(size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG;
7902        i++;
7903      }
7904  
7905    /* Invoke the closure.  */
7906 -  (closure->fun) (cif, rvalue, avalue, closure->user_data);
7907 +  closure->fun (cif, rvalue, avalue, closure->user_data);
7908  
7909    /* Tell ffi_closure_osf how to perform return type promotions.  */
7910    return cif->rtype->type;
7911 Index: gcc-4_2-branch/libffi/src/alpha/osf.S
7912 ===================================================================
7913 --- gcc-4_2-branch/libffi/src/alpha/osf.S       (revision 123014)
7914 +++ gcc-4_2-branch/libffi/src/alpha/osf.S       (revision 124164)
7915 @@ -1,10 +1,8 @@
7916  /* -----------------------------------------------------------------------
7917 -   osf.S - Copyright (c) 1998, 2001 Red Hat
7918 +   osf.S - Copyright (c) 1998, 2001, 2007 Red Hat
7919     
7920     Alpha/OSF Foreign Function Interface 
7921  
7922 -   $Id$
7923 -
7924     Permission is hereby granted, free of charge, to any person obtaining
7925     a copy of this software and associated documentation files (the
7926     ``Software''), to deal in the Software without restriction, including
7927 @@ -42,6 +40,8 @@
7928         .align  3
7929         .globl  ffi_call_osf
7930         .ent    ffi_call_osf
7931 +       FFI_HIDDEN(ffi_call_osf)
7932 +
7933  ffi_call_osf:
7934         .frame  $15, 32, $26, 0
7935         .mask   0x4008000, -32
7936 @@ -129,6 +129,8 @@
7937         .align  3
7938         .globl  ffi_closure_osf
7939         .ent    ffi_closure_osf
7940 +       FFI_HIDDEN(ffi_closure_osf)
7941 +
7942  ffi_closure_osf:
7943         .frame  $30, 16*8, $26, 0
7944         .mask   0x4000000, -16*8
7945 @@ -265,7 +267,7 @@
7946         .gprel32 $load_32       # FFI_TYPE_INT
7947         .gprel32 $load_float    # FFI_TYPE_FLOAT
7948         .gprel32 $load_double   # FFI_TYPE_DOUBLE
7949 -       .gprel32 $load_double   # FFI_TYPE_LONGDOUBLE
7950 +       .gprel32 $load_none     # FFI_TYPE_LONGDOUBLE
7951         .gprel32 $load_u8       # FFI_TYPE_UINT8
7952         .gprel32 $load_s8       # FFI_TYPE_SINT8
7953         .gprel32 $load_u16      # FFI_TYPE_UINT16
7954 Index: gcc-4_2-branch/libffi/src/types.c
7955 ===================================================================
7956 --- gcc-4_2-branch/libffi/src/types.c   (revision 123014)
7957 +++ gcc-4_2-branch/libffi/src/types.c   (revision 124164)
7958 @@ -57,4 +57,17 @@
7959  
7960  FFI_TYPEDEF(float, float, FFI_TYPE_FLOAT);
7961  FFI_TYPEDEF(double, double, FFI_TYPE_DOUBLE);
7962 +
7963 +#ifdef __alpha__
7964 +/* Even if we're not configured to default to 128-bit long double, 
7965 +   maintain binary compatibility, as -mlong-double-128 can be used
7966 +   at any time.  */
7967 +/* Validate the hard-coded number below.  */
7968 +# if defined(__LONG_DOUBLE_128__) && FFI_TYPE_LONGDOUBLE != 4
7969 +#  error FFI_TYPE_LONGDOUBLE out of date
7970 +# endif
7971 +# undef ffi_type_longdouble
7972 +ffi_type ffi_type_longdouble = { 16, 16, 4, NULL };
7973 +#elif FFI_TYPE_LONGDOUBLE != FFI_TYPE_DOUBLE
7974  FFI_TYPEDEF(longdouble, long double, FFI_TYPE_LONGDOUBLE);
7975 +#endif
7976 Index: gcc-4_2-branch/libffi/ChangeLog
7977 ===================================================================
7978 --- gcc-4_2-branch/libffi/ChangeLog     (revision 123014)
7979 +++ gcc-4_2-branch/libffi/ChangeLog     (revision 124164)
7980 @@ -1,3 +1,16 @@
7981 +2007-04-20  Richard Henderson  <rth@redhat.com>
7982 +
7983 +       * configure.ac (alpha*-*-*): Define HAVE_LONG_DOUBLE.
7984 +       * configure: Regenerate.
7985 +       * include/ffi.h.in (ffi_type_longdouble): Define as ffi_type_double
7986 +       if HAVE_LONG_DOUBLE is false.
7987 +       * src/alpha/ffi.c (ffi_prep_cif_machdep): Support the 128-bit
7988 +       long double type.
7989 +       (ffi_call_osf, ffi_closure_osf): Likewise.
7990 +       * src/alpha/osf.S (ffi_call_osf, ffi_closure_osf): Mark hidden.
7991 +       * src/types.c (ffi_type_longdouble): For alpha, always generate
7992 +       for the 128-bit long double type.
7993 +
7994  2007-02-13  Andreas Krebbel  <krebbel1@de.ibm.com>
7995  
7996         * src/s390/ffi.c (ffi_prep_args, ffi_prep_cif_machdep,
7997 Index: gcc-4_2-branch/libffi/configure.ac
7998 ===================================================================
7999 --- gcc-4_2-branch/libffi/configure.ac  (revision 123014)
8000 +++ gcc-4_2-branch/libffi/configure.ac  (revision 124164)
8001 @@ -59,7 +59,11 @@
8002  sparc-*-linux* | sparc-*-netbsdelf* | sparc-*-knetbsd*-gnu) TARGET=SPARC; TARGETDIR=sparc;;
8003  sparc*-*-rtems*) TARGET=SPARC; TARGETDIR=sparc;;
8004  sparc64-*-linux* | sparc64-*-freebsd* | sparc64-*-netbsd* | sparc64-*-knetbsd*-gnu) TARGET=SPARC; TARGETDIR=sparc;;
8005 -alpha*-*-linux* | alpha*-*-osf* | alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu | alpha*-*-netbsd* | alpha*-*-knetbsd*-gnu) TARGET=ALPHA; TARGETDIR=alpha;;
8006 +alpha*-*-linux* | alpha*-*-osf* | alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu | alpha*-*-netbsd* | alpha*-*-knetbsd*-gnu)
8007 +       TARGET=ALPHA; TARGETDIR=alpha
8008 +       # Support 128-bit long double, changable via command-line switch.
8009 +       HAVE_LONG_DOUBLE='defined(__LONG_DOUBLE_128__)'
8010 +       ;;
8011  ia64*-*-*) TARGET=IA64; TARGETDIR=ia64;;
8012  m32r*-*-linux* ) TARGET=M32R; TARGETDIR=m32r;;
8013  m68k-*-linux*) TARGET=M68K; TARGETDIR=m68k;;
8014 @@ -132,11 +136,13 @@
8015  AC_CHECK_SIZEOF(long double)
8016  
8017  # Also AC_SUBST this variable for ffi.h.
8018 -HAVE_LONG_DOUBLE=0
8019 -if test $ac_cv_sizeof_double != $ac_cv_sizeof_long_double; then
8020 -  if test $ac_cv_sizeof_long_double != 0; then
8021 -    HAVE_LONG_DOUBLE=1
8022 -    AC_DEFINE(HAVE_LONG_DOUBLE, 1, [Define if you have the long double type and it is bigger than a double])
8023 +if test -z "$HAVE_LONG_DOUBLE"; then
8024 +  HAVE_LONG_DOUBLE=0
8025 +  if test $ac_cv_sizeof_double != $ac_cv_sizeof_long_double; then
8026 +    if test $ac_cv_sizeof_long_double != 0; then
8027 +      HAVE_LONG_DOUBLE=1
8028 +      AC_DEFINE(HAVE_LONG_DOUBLE, 1, [Define if you have the long double type and it is bigger than a double])
8029 +    fi
8030    fi
8031  fi
8032  AC_SUBST(HAVE_LONG_DOUBLE)
8033 Index: gcc-4_2-branch/contrib/ChangeLog
8034 ===================================================================
8035 --- gcc-4_2-branch/contrib/ChangeLog    (revision 123014)
8036 +++ gcc-4_2-branch/contrib/ChangeLog    (revision 124164)
8037 @@ -1,3 +1,18 @@
8038 +2007-04-04  Eric Christopher  <echristo@apple.com>
8039 +
8040 +       Backport from mainline:
8041 +       2007-04-04  Zack Weinberg  <zack@mrtock.ucsd.edu>
8042 +
8043 +        * texi2pod.pl: Correct handling of @itemize with no argument.
8044 +
8045 +        2007-02-16  Matthias Klose  <doko@debian.org>
8046 +
8047 +        * texi2pod.pl: Handle @subsubsection, ignore @anchor.
8048 +
8049 +        2007-02-06  Richard Sandiford  <richard@codesourcery.com>
8050 +
8051 +       * texi2pod.pl: Handle @multitable.
8052 +
8053  2006-09-27  Matthew Sachs  <msachs@apple.com>
8054  
8055         * compareSumTests3: POD syntax fix.
8056 @@ -84,14 +99,14 @@
8057  
8058  2005-10-28  Daniel Berlin  <dberlin@dberlin.org>
8059             Ben Elliston <bje@au1.ibm.com>
8060 -       
8061 +
8062         * gcc_update: Update for svn.
8063         * newcvsroot: Ditto.
8064         * gcc_build: Ditto.
8065  
8066  2005-10-21  Mark Mitchell  <mark@codesourcery.com>
8067  
8068 -       * texi2pod.pl: Substitue for @value even when part of @include. 
8069 +       * texi2pod.pl: Substitue for @value even when part of @include.
8070  
8071  2005-10-21  Bob Wilson  <bob.wilson@acm.org>
8072  
8073 Index: gcc-4_2-branch/contrib/texi2pod.pl
8074 ===================================================================
8075 --- gcc-4_2-branch/contrib/texi2pod.pl  (revision 123014)
8076 +++ gcc-4_2-branch/contrib/texi2pod.pl  (revision 124164)
8077 @@ -162,6 +162,8 @@
8078         } elsif ($ended =~ /^(?:itemize|enumerate|[fv]?table)$/) {
8079             $_ = "\n=back\n";
8080             $ic = pop @icstack;
8081 +       } elsif ($ended eq "multitable") {
8082 +           $_ = "\n=back\n";
8083         } else {
8084             die "unknown command \@end $ended at line $.\n";
8085         }
8086 @@ -252,6 +254,8 @@
8087         and $_ = "\n=head2 $1\n";
8088      /^\@subsection\s+(.+)$/
8089         and $_ = "\n=head3 $1\n";
8090 +    /^\@subsubsection\s+(.+)$/
8091 +       and $_ = "\n=head4 $1\n";
8092  
8093      # Block command handlers:
8094      /^\@itemize(?:\s+(\@[a-z]+|\*|-))?/ and do {
8095 @@ -260,7 +264,7 @@
8096         if (defined $1) {
8097             $ic = $1;
8098         } else {
8099 -           $ic = '@bullet';
8100 +           $ic = '*';
8101         }
8102         $_ = "\n=over 4\n";
8103         $endw = "itemize";
8104 @@ -278,6 +282,12 @@
8105         $endw = "enumerate";
8106      };
8107  
8108 +    /^\@multitable\s.*/ and do {
8109 +       push @endwstack, $endw;
8110 +       $endw = "multitable";
8111 +       $_ = "\n=over 4\n";
8112 +    };
8113 +
8114      /^\@([fv]?table)\s+(\@[a-z]+)/ and do {
8115         push @endwstack, $endw;
8116         push @icstack, $ic;
8117 @@ -297,6 +307,16 @@
8118         $_ = "";        # need a paragraph break
8119      };
8120  
8121 +    /^\@item\s+(.*\S)\s*$/ and $endw eq "multitable" and do {
8122 +       @columns = ();
8123 +       for $column (split (/\s*\@tab\s*/, $1)) {
8124 +           # @strong{...} is used a @headitem work-alike
8125 +           $column =~ s/^\@strong{(.*)}$/$1/;
8126 +           push @columns, $column;
8127 +       }
8128 +       $_ = "\n=item ".join (" : ", @columns)."\n";
8129 +    };
8130 +
8131      /^\@itemx?\s*(.+)?$/ and do {
8132         if (defined $1) {
8133             # Entity escapes prevent munging by the <> processing below.
8134 @@ -382,6 +402,9 @@
8135      s/\@gol//g;
8136      s/\@\*\s*\n?//g;
8137  
8138 +    # Anchors are thrown away
8139 +    s/\@anchor\{(?:[^\}]*)\}//g;
8140 +
8141      # @uref can take one, two, or three arguments, with different
8142      # semantics each time.  @url and @email are just like @uref with
8143      # one argument, for our purposes.
8144 Index: gcc-4_2-branch/libjava/configure
8145 ===================================================================
8146 --- gcc-4_2-branch/libjava/configure    (revision 123014)
8147 +++ gcc-4_2-branch/libjava/configure    (revision 124164)
8148 @@ -7687,7 +7687,7 @@
8149    # See if we find them without any special options.
8150    # Don't add to $LIBS permanently.
8151    ac_save_LIBS=$LIBS
8152 -  LIBS="-lXt $LIBS"
8153 +  LIBS="-lX11 $LIBS"
8154    if test x$gcc_no_link = xyes; then
8155    { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
8156  echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
8157 @@ -9414,12 +9414,13 @@
8158  
8159  
8160  
8161 +
8162  for ac_func in strerror ioctl select fstat open fsync sleep opendir \
8163                     gmtime_r localtime_r readdir_r getpwuid_r getcwd \
8164                    access stat lstat mkdir rename rmdir unlink utime chmod readlink \
8165                    nl_langinfo setlocale \
8166                    inet_pton uname inet_ntoa \
8167 -                  fork execvp pipe sigaction ftruncate mmap \
8168 +                  fork execvp getrlimit pipe sigaction ftruncate mmap \
8169                    getifaddrs
8170  do
8171  as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8172 @@ -9875,7 +9876,8 @@
8173  
8174  
8175  
8176 -for ac_header in execinfo.h unistd.h dlfcn.h
8177 +
8178 +for ac_header in execinfo.h unistd.h dlfcn.h sys/resource.h
8179  do
8180  as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8181  if eval "test \"\${$as_ac_Header+set}\" = set"; then
8182 Index: gcc-4_2-branch/libjava/gnu/java/nio/channels/natFileChannelPosix.cc
8183 ===================================================================
8184 --- gcc-4_2-branch/libjava/gnu/java/nio/channels/natFileChannelPosix.cc (revision 123014)
8185 +++ gcc-4_2-branch/libjava/gnu/java/nio/channels/natFileChannelPosix.cc (revision 124164)
8186 @@ -178,8 +178,6 @@
8187        throw new ::java::io::FileNotFoundException (msg->toString ());
8188      }
8189  
8190 -  _Jv_platform_close_on_exec (fd);
8191 -
8192    return fd;
8193  }
8194  
8195 Index: gcc-4_2-branch/libjava/gnu/java/net/natPlainSocketImplPosix.cc
8196 ===================================================================
8197 --- gcc-4_2-branch/libjava/gnu/java/net/natPlainSocketImplPosix.cc      (revision 123014)
8198 +++ gcc-4_2-branch/libjava/gnu/java/net/natPlainSocketImplPosix.cc      (revision 124164)
8199 @@ -72,8 +72,6 @@
8200        throw new ::java::io::IOException (JvNewStringUTF (strerr));
8201      }
8202  
8203 -  _Jv_platform_close_on_exec (sock);
8204 -
8205    // We use native_fd in place of fd here.  From leaving fd null we avoid
8206    // the double close problem in FileDescriptor.finalize.
8207    native_fd = sock;
8208 @@ -285,8 +283,6 @@
8209    if (new_socket < 0)
8210      goto error;
8211  
8212 -  _Jv_platform_close_on_exec (new_socket);
8213 -
8214    jbyteArray raddr;
8215    jint rport;
8216    if (u.address.sin_family == AF_INET)
8217 Index: gcc-4_2-branch/libjava/gnu/java/net/natPlainDatagramSocketImplPosix.cc
8218 ===================================================================
8219 --- gcc-4_2-branch/libjava/gnu/java/net/natPlainDatagramSocketImplPosix.cc      (revision 123014)
8220 +++ gcc-4_2-branch/libjava/gnu/java/net/natPlainDatagramSocketImplPosix.cc      (revision 124164)
8221 @@ -83,8 +83,6 @@
8222        throw new ::java::net::SocketException (JvNewStringUTF (strerr));
8223      }
8224  
8225 -  _Jv_platform_close_on_exec (sock);
8226 -
8227    // We use native_fd in place of fd here.  From leaving fd null we avoid
8228    // the double close problem in FileDescriptor.finalize.
8229    native_fd = sock;
8230 Index: gcc-4_2-branch/libjava/configure.ac
8231 ===================================================================
8232 --- gcc-4_2-branch/libjava/configure.ac (revision 123014)
8233 +++ gcc-4_2-branch/libjava/configure.ac (revision 124164)
8234 @@ -906,10 +906,10 @@
8235                    access stat lstat mkdir rename rmdir unlink utime chmod readlink \
8236                    nl_langinfo setlocale \
8237                    inet_pton uname inet_ntoa \
8238 -                  fork execvp pipe sigaction ftruncate mmap \
8239 +                  fork execvp getrlimit pipe sigaction ftruncate mmap \
8240                    getifaddrs])
8241     AC_CHECK_FUNCS(inet_aton inet_addr, break)
8242 -   AC_CHECK_HEADERS(execinfo.h unistd.h dlfcn.h)
8243 +   AC_CHECK_HEADERS(execinfo.h unistd.h dlfcn.h sys/resource.h)
8244     # Do an additional check on dld, HP-UX for example has dladdr in libdld.sl
8245     AC_CHECK_LIB(dl, dladdr, [
8246         AC_DEFINE(HAVE_DLADDR, 1, [Define if you have dladdr()])], [
8247 Index: gcc-4_2-branch/libjava/java/lang/natPosixProcess.cc
8248 ===================================================================
8249 --- gcc-4_2-branch/libjava/java/lang/natPosixProcess.cc (revision 123014)
8250 +++ gcc-4_2-branch/libjava/java/lang/natPosixProcess.cc (revision 124164)
8251 @@ -17,6 +17,9 @@
8252  #include <fcntl.h>
8253  #include <sys/types.h>
8254  #include <sys/wait.h>
8255 +#ifdef HAVE_SYS_RESOURCE_H
8256 +#include <sys/resource.h>
8257 +#endif
8258  #include <signal.h>
8259  #include <string.h>
8260  #include <stdlib.h>
8261 @@ -341,7 +344,31 @@
8262                   _exit (127);
8263                 }
8264             }
8265 -
8266 +          // Make sure all file descriptors are closed.  In
8267 +          // multi-threaded programs, there is a race between when a
8268 +          // descriptor is obtained, when we can set FD_CLOEXEC, and
8269 +          // fork().  If the fork occurs before FD_CLOEXEC is set, the
8270 +          // descriptor would leak to the execed process if we did not
8271 +          // manually close it.  So that is what we do.  Since we
8272 +          // close all the descriptors, it is redundant to set
8273 +          // FD_CLOEXEC on them elsewhere.
8274 +          int max_fd;
8275 +#ifdef HAVE_GETRLIMIT
8276 +          rlimit rl;
8277 +          int rv = getrlimit(RLIMIT_NOFILE, &rl);
8278 +          if (rv == 0)
8279 +            max_fd = rl.rlim_max - 1;
8280 +          else
8281 +            max_fd = 1024 - 1;
8282 +#else
8283 +          max_fd = 1024 - 1;
8284 +#endif
8285 +          while(max_fd > 2)
8286 +            {
8287 +              if (max_fd != msgp[1])
8288 +                close (max_fd);
8289 +              max_fd--;
8290 +            }
8291           // Make sure that SIGCHLD is unblocked for the new process.
8292           sigset_t mask;
8293           sigemptyset (&mask);
8294 @@ -425,11 +452,4 @@
8295  
8296    myclose (msgp[0]);
8297    cleanup (args, env, path);
8298 -
8299 -  if (exception == NULL)
8300 -    {
8301 -      fcntl (outp[1], F_SETFD, FD_CLOEXEC);
8302 -      fcntl (inp[0], F_SETFD, FD_CLOEXEC);
8303 -      fcntl (errp[0], F_SETFD, FD_CLOEXEC);
8304 -    }
8305  }
8306 Index: gcc-4_2-branch/libjava/include/posix.h
8307 ===================================================================
8308 --- gcc-4_2-branch/libjava/include/posix.h      (revision 123014)
8309 +++ gcc-4_2-branch/libjava/include/posix.h      (revision 124164)
8310 @@ -91,15 +91,6 @@
8311  extern void _Jv_platform_initialize (void);
8312  extern void _Jv_platform_initProperties (java::util::Properties*);
8313  
8314 -inline void
8315 -_Jv_platform_close_on_exec (jint fd)
8316 -{
8317 -  // Ignore errors.
8318 -  ::fcntl (fd, F_SETFD, FD_CLOEXEC);
8319 -}
8320 -
8321 -#undef fcntl
8322 -
8323  #ifdef JV_HASH_SYNCHRONIZATION
8324  #ifndef HAVE_USLEEP_DECL
8325  extern "C" int usleep (useconds_t useconds);
8326 Index: gcc-4_2-branch/libjava/include/config.h.in
8327 ===================================================================
8328 --- gcc-4_2-branch/libjava/include/config.h.in  (revision 123014)
8329 +++ gcc-4_2-branch/libjava/include/config.h.in  (revision 124164)
8330 @@ -124,6 +124,9 @@
8331  /* Define to 1 if you have the `getpwuid_r' function. */
8332  #undef HAVE_GETPWUID_R
8333  
8334 +/* Define to 1 if you have the `getrlimit' function. */
8335 +#undef HAVE_GETRLIMIT
8336 +
8337  /* Define to 1 if you have the `gettimeofday' function. */
8338  #undef HAVE_GETTIMEOFDAY
8339  
8340 @@ -304,6 +307,9 @@
8341  /* Define to 1 if you have the <sys/ioctl.h> header file. */
8342  #undef HAVE_SYS_IOCTL_H
8343  
8344 +/* Define to 1 if you have the <sys/resource.h> header file. */
8345 +#undef HAVE_SYS_RESOURCE_H
8346 +
8347  /* Define to 1 if you have the <sys/rw_lock.h> header file. */
8348  #undef HAVE_SYS_RW_LOCK_H
8349  
8350 Index: gcc-4_2-branch/libjava/ChangeLog
8351 ===================================================================
8352 --- gcc-4_2-branch/libjava/ChangeLog    (revision 123014)
8353 +++ gcc-4_2-branch/libjava/ChangeLog    (revision 124164)
8354 @@ -1,3 +1,19 @@
8355 +2007-03-25  David Daney  <ddaney@avtrex.com>
8356 +
8357 +       PR libgcj/31228
8358 +       * configure.ac: Add checks for getrlimit and sys/resource.h.
8359 +       * include/posix.h (_Jv_platform_close_on_exec): Remove.
8360 +       * include/config.h.in: Regenerate.
8361 +       * configure: Regenerate.
8362 +       * gnu/java/nio/channels/natFileChannelPosix.cc (open): Remove call to
8363 +       _Jv_platform_close_on_exec;
8364 +       * gnu/java/net/natPlainSocketImplPosix.cc (create): Likewise.
8365 +       (accept): Likewise.
8366 +       * gnu/java/net/natPlainDatagramSocketImplPosix.cc (create):Likewise.
8367 +       * java/lang/natPosixProcess.cc: Include sys/resource.h.
8368 +       (nativeSpawn): Close all file descriptors.  Don't set FD_CLOEXEC on
8369 +       pipes.
8370 +
8371  2007-01-29  Kaloian Doganov  <kaloian@doganov.org>
8372  
8373         PR libgcj/30600:
8374 Index: gcc-4_2-branch/libcpp/ChangeLog
8375 ===================================================================
8376 --- gcc-4_2-branch/libcpp/ChangeLog     (revision 123014)
8377 +++ gcc-4_2-branch/libcpp/ChangeLog     (revision 124164)
8378 @@ -1,3 +1,9 @@
8379 +2007-04-23  Tom Tromey  <tromey@redhat.com>
8380 +
8381 +       PR preprocessor/30468:
8382 +       * mkdeps.c (apply_vpath): Strip successive '/'s if we stripped
8383 +       './'.
8384 +
8385  2006-12-29  Jakub Jelinek  <jakub@redhat.com>
8386  
8387         PR preprocessor/29612
8388 Index: gcc-4_2-branch/libcpp/mkdeps.c
8389 ===================================================================
8390 --- gcc-4_2-branch/libcpp/mkdeps.c      (revision 123014)
8391 +++ gcc-4_2-branch/libcpp/mkdeps.c      (revision 124164)
8392 @@ -1,5 +1,5 @@
8393  /* Dependency generator for Makefile fragments.
8394 -   Copyright (C) 2000, 2001, 2003 Free Software Foundation, Inc.
8395 +   Copyright (C) 2000, 2001, 2003, 2007 Free Software Foundation, Inc.
8396     Contributed by Zack Weinberg, Mar 2000
8397  
8398  This program is free software; you can redistribute it and/or modify it
8399 @@ -141,7 +141,13 @@
8400  
8401    /* Remove leading ./ in any case.  */
8402    while (t[0] == '.' && IS_DIR_SEPARATOR (t[1]))
8403 -    t += 2;
8404 +    {
8405 +      t += 2;
8406 +      /* If we removed a leading ./, then also remove any /s after the
8407 +        first.  */
8408 +      while (IS_DIR_SEPARATOR (t[0]))
8409 +       ++t;
8410 +    }
8411  
8412    return t;
8413  }
This page took 1.008045 seconds and 2 git commands to generate.