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)
6 # does some of this, but throws away the result.
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/'`
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)
19 +2007-03-18 Andreas Schwab <schwab@suse.de>
21 + * acinclude.m4: Adjust regular expression for ld version
23 + * configure: Regenerate.
25 2007-02-07 Jakub Jelinek <jakub@redhat.com>
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)
33 # does some of this, but throws away the result.
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/'`
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)
47 cmp = compare_values (min, max);
48 gcc_assert (cmp == 0 || cmp == -1 || cmp == -2);
50 + if (needs_overflow_infinity (TREE_TYPE (min)))
51 + gcc_assert (!is_overflow_infinity (min)
52 + || !is_overflow_infinity (max));
55 if (t == VR_UNDEFINED || t == VR_VARYING)
57 bitmap_clear (vr->equiv);
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. */
66 +set_value_range_to_value (value_range_t *vr, tree val)
68 + gcc_assert (is_gimple_min_invariant (val));
69 + if (is_overflow_infinity (val))
71 + val = copy_node (val);
72 + TREE_OVERFLOW (val) = 0;
74 + set_value_range (vr, VR_RANGE, val, val, NULL);
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
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);
87 set_value_range_to_varying (&vr0);
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);
96 set_value_range_to_varying (&vr1);
98 @@ -1892,10 +1913,18 @@
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
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)))
117 set_value_range_to_varying (vr);
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);
126 set_value_range_to_varying (&vr0);
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)))
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));
139 @@ -2254,6 +2285,18 @@
140 if (needs_overflow_infinity (TREE_TYPE (expr)))
142 gcc_assert (code != NEGATE_EXPR && code != ABS_EXPR);
144 + /* If both sides have overflowed, we don't know
146 + if ((is_overflow_infinity (vr0.min)
147 + || TREE_OVERFLOW (min))
148 + && (is_overflow_infinity (vr0.max)
149 + || TREE_OVERFLOW (max)))
151 + set_value_range_to_varying (vr);
155 if (is_overflow_infinity (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);
165 set_value_range_to_varying (vr);
167 @@ -4514,6 +4557,17 @@
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))))
178 + set_value_range_to_varying (vr0);
182 /* The resulting set of equivalences is the intersection of
184 if (vr0->equiv && vr1->equiv && vr0->equiv != vr1->equiv)
185 @@ -4639,6 +4693,12 @@
186 vr_arg = *(get_value_range (arg));
189 + if (is_overflow_infinity (arg))
191 + arg = copy_node (arg);
192 + TREE_OVERFLOW (arg) = 0;
195 vr_arg.type = VR_RANGE;
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)
203 -mwarn-framesize -mwarn-dynamicstack -mstack-size -mstack-guard}
206 -@gccoptlist{-mel -mel @gol
207 +@gccoptlist{-meb -mel @gol
212 +-mscore5 -mscore5u -mscore7 -mscore7d}
215 @gccoptlist{-m1 -m2 -m2e -m3 -m3e @gol
216 @@ -2834,7 +2836,7 @@
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
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.
246 @@ -5298,7 +5303,7 @@
247 @option{-funroll-loops},
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.
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.
264 @@ -8161,13 +8166,13 @@
265 @samp{"PrivateHeaders"} or @samp{"Headers"} directory.
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@.
277 Emit debugging information for all symbols and types.
279 @item -mmacosx-version-min=@var{version}
280 @@ -8189,7 +8194,7 @@
281 @option{-mlong-branch} for PowerPC targets.
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.
293 -@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.
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.
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.
315 @@ -9947,8 +9954,8 @@
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 @@
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 @@
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 @@
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 @@
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 @@
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 @@
384 @itemx -mno-sched-ldc
385 -@opindex -msched-ldc
386 -@opindex -mno-sched-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 @@
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 @@
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.
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 @@
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 @@
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:
450 -Compile code for little endian mode.
454 Compile code for big endian mode. This is the default.
458 +Compile code for little endian mode.
462 +Disable generate bcnz instruction.
466 +Enable generate unaligned load and store instruction.
470 Enable the use of multiply-accumulate instructions. Disabled by default.
474 +Specify the SCORE5 as the target architecture.
478 Specify the SCORE5U of the target architecture.
482 -Specify the SCORE7 of the target architecture. This is the default.
483 +Specify the SCORE7 as the target architecture. This is the default.
487 +Specify the SCORE7D as the target architecture.
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.
499 -Unsigned 15 bit integer (in the range 0 to 32767).
500 +High 16-bit constant (32-bit constant with 16 LSBs zero).
503 Unsigned 5 bit integer (in the range 0 to 31).
504 @@ -2831,18 +2831,6 @@
506 Signed 14 bit integer (in the range @minus{}8192 to 8191).
509 -Signed 15 bit integer (in the range @minus{}16384 to 16383).
512 -Signed 12 bit integer (in the range @minus{}2048 to 2047).
515 -An integer constant with exactly a single bit set.
518 -An integer constant.
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)
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)
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.
539 This file is part of GCC.
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)
556 + for (i = 0; i < n_bbs; ++i)
560 + last = last_stmt (copied_bbs[i]);
561 + if (TREE_CODE (last) == COND_EXPR)
562 + TREE_NO_WARNING (last) = 1;
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)))))
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)
595 + enum machine_mode old_mode;
597 /* Expand the operands. */
598 mem = get_builtin_sync_mem (TREE_VALUE (arglist), mode);
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);
612 return expand_sync_operation (mem, val, code);
613 @@ -5517,19 +5522,28 @@
614 bool is_bool, rtx target)
616 rtx old_val, new_val, mem;
617 + enum machine_mode old_mode;
619 /* Expand the operands. */
620 mem = get_builtin_sync_mem (TREE_VALUE (arglist), mode);
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);
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);
645 return expand_bool_compare_and_swap (mem, old_val, new_val, target);
646 @@ -5548,14 +5562,19 @@
650 + enum machine_mode old_mode;
652 /* Expand the operands. */
653 mem = get_builtin_sync_mem (TREE_VALUE (arglist), mode);
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);
666 return expand_sync_lock_test_and_set (mem, val, target);
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 @@
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;
680 /* There are always 32 bits in each long, no matter the size of
681 @@ -7062,19 +7062,20 @@
683 if (total_bytes > len)
685 - words = total_bytes / UNITS_PER_WORD;
686 + words = 32 / UNITS_PER_WORD;
688 real_to_target (tmp, TREE_REAL_CST_PTR (expr), TYPE_MODE (type));
690 - for (byte = 0; byte < total_bytes; byte++)
691 + for (bitpos = 0; bitpos < total_bytes * BITS_PER_UNIT;
692 + bitpos += BITS_PER_UNIT)
694 - int bitpos = byte * BITS_PER_UNIT;
695 + byte = (bitpos / BITS_PER_UNIT) & 3;
696 value = (unsigned char) (tmp[bitpos / 32] >> (bitpos & 31));
698 - if (total_bytes > UNITS_PER_WORD)
699 + if (UNITS_PER_WORD < 4)
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;
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;
718 @@ -7241,7 +7242,7 @@
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;
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)
731 - words = total_bytes / UNITS_PER_WORD;
732 + words = 32 / UNITS_PER_WORD;
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)
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)
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;
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)];
759 tmp[bitpos / 32] |= (unsigned long)value << (bitpos & 31);
761 @@ -7732,7 +7734,7 @@
762 return fold_build1 (BIT_NOT_EXPR, type, fold_convert (type, tem));
765 - tem = fold_convert_const (code, type, arg0);
766 + tem = fold_convert_const (code, type, op0);
767 return tem ? tem : NULL_TREE;
769 case VIEW_CONVERT_EXPR:
770 @@ -11126,13 +11128,13 @@
771 return omit_one_operand (type, integer_zero_node, arg0);
774 - return fold_build2 (EQ_EXPR, type, arg0, arg1);
775 + return fold_build2 (EQ_EXPR, type, op0, op1);
778 return omit_one_operand (type, integer_one_node, arg0);
781 - return fold_build2 (NE_EXPR, type, arg0, arg1);
782 + return fold_build2 (NE_EXPR, type, op0, op1);
784 /* The GE_EXPR and LT_EXPR cases above are not normally
785 reached because of previous transformations. */
786 @@ -11147,10 +11149,14 @@
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),
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),
803 @@ -11163,7 +11169,7 @@
804 return omit_one_operand (type, integer_zero_node, arg0);
807 - return fold_build2 (EQ_EXPR, type, arg0, arg1);
808 + return fold_build2 (EQ_EXPR, type, op0, op1);
811 return omit_one_operand (type, integer_one_node, arg0);
812 @@ -11181,10 +11187,14 @@
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),
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),
829 @@ -11200,12 +11210,11 @@
830 and X >= signed_max+1 because previous transformations. */
831 if (code == LE_EXPR || code == GT_EXPR)
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));
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));
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;
855 + bool do_cleanup_cfg = false;
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);
863 + do_cleanup_cfg = true;
867 @@ -2546,6 +2548,14 @@
869 /* Emit a library call to launch the children threads. */
870 expand_parallel_call (region, new_bb, entry_stmt, ws_args);
872 + if (do_cleanup_cfg)
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 ();
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 @@
889 struct _objc_exception_data _stack;
890 - id volatile _rethrow = 0;
894 objc_exception_try_enter (&_stack);
895 @@ -3676,7 +3676,6 @@
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;
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)
908 +2007-04-25 Anatoly Sokolov <aesok@post.ru>
911 + * config/avr/avr.h (ASM_OUTPUT_ALIGN): Redefine.
913 +2007-04-24 Andrew Pinski <andrew_pinski@playstation.sony.com>
914 + Roger Sayle <roger@eyesopen.com>
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.
920 +2007-04-24 Ian Lance Taylor <iant@google.com>
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.
934 +2007-04-24 Ian Lance Taylor <iant@google.com>
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.
944 +2007-04-24 Andreas Krebbel <krebbel1@de.ibm.com>
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.
952 +2007-04-24 Daniel Franke <franke.daniel@gmail.com>
954 + * doc/invoke.texi: Removed leading '-' from option index entries.
956 +2007-04-22 Andrew Pinski <andrew_pinski@playstation.sony.com>
958 + PR middle-end/31448
959 + * expr.c (reduce_to_bit_field_precision): Handle
962 +2007-04-20 Richard Henderson <rth@redhat.com>
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.
978 +2007-04-21 Richard Guenther <rguenther@suse.de>
980 + PR middle-end/31136
981 + * fold-const.c (fold_unary): Call fold_convert_const on the
984 +2007-04-20 Richard Henderson <rth@redhat.com>
986 + * config/alpha/linux.h (CPP_SPEC): Undef before redefine.
988 +2007-04-20 Bernd Schmidt <bernd.schmidt@analog.com>
990 + * reload.c (combine_reloads): When trying to use a dying register,
991 + check whether it's uninitialized and don't use if so.
993 +2007-04-20 Jakub Jelinek <jakub@redhat.com>
995 + * config/i386/i386.c (bdesc_2arg): Use ORDERED rather than UNORDERED
996 + for __builtin_ia32_cmpordss.
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.
1004 +2007-04-19 Eric Botcazou <ebotcazou@libertysurf.fr>
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.
1012 +2007-04-18 Anatoly Sokolov <aesok@post.ru>
1014 + * config/avr/avr.c (ptrreg_to_str): Replace error() with
1015 + output_operand_lossage().
1017 +2007-04-17 Anatoly Sokolov <aesok@post.ru>
1020 + * config/avr/avr.c (ptrreg_to_str): Replace gcc_unreachable() with
1023 +2007-04-17 Jan Hubicka <jh@suse.cz>
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
1030 +2007-04-17 H.J. Lu <hongjiu.lu@intel.com>
1032 + * Backport from mainline:
1033 + 2007-04-17 H.J. Lu <hongjiu.lu@intel.com>
1035 + * config/i386/sse.md (sse_vmaddv4sf3): Use register_operand
1037 + (sse_vmmulv4sf3): Likewise.
1038 + (sse2_vmaddv2df3): Likewise.
1039 + (sse2_vmmulv2df3): Likewise.
1041 +2007-04-16 Matthias Klose <doko@debian.org>
1043 + * config/alpha/linux.h (CPP_SPEC): Define.
1044 + * config/arm/linux-gas.h (SUBTARGET_CPP_SPEC): Extend.
1046 +2007-04-16 Anatoly Sokolov <aesok@post.ru>
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
1052 + * config/avr/avr.h (LINK_SPEC): Simplify.
1054 +2007-04-16 Jan Hubicka <jh@suse.cz>
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.
1063 +2007-04-16 H.J. Lu <hongjiu.lu@intel.com>
1065 + * Backport from mainline:
1066 + 2007-04-16 H.J. Lu <hongjiu.lu@intel.com>
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
1073 +2007-04-14 Andrew Pinski <andrew_pinski@playstation.sony.com>
1076 + * c-decl.c (finish_decl): Grab the type of the decl after the call
1077 + to store_init_value.
1079 +2007-04-14 Jakub Jelinek <jakub@redhat.com>
1082 + * omp-low.c (expand_omp_parallel): If child_cfun->cfg, free dominators,
1083 + post dominators and cleanup cfg before returning.
1085 +2007-04-11 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
1087 + * pa.c (pa_som_asm_init_sections): Ensure that cfun->machine is not
1088 + null before emitting a .nsubspa directive.
1090 +2007-04-08 Anatoly Sokolov <aesok@post.ru>
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
1100 +2007-04-07 Anatoly Sokolov <aesok@post.ru>
1103 + * config/avr/avr.md (*clrmemqi, *clrmemhi): Mark operand 4 as
1106 +2007-04-05 Anatoly Sokolov <aesok@post.ru>
1109 + * config/avr/avr.c (avr_handle_fndecl_attribute): Use the
1110 + DECL_ASSEMBLER_NAME, not the DECL_NAME.
1112 +2007-04-04 Richard Henderson <rth@redhat.com>
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.
1129 +2007-04-04 Chen liqin <liqin@sunnorth.com.cn>
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.
1142 +2007-04-03 Stuart Hastings <stuart@apple.com>
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.
1148 +2007-04-03 Jakub Jelinek <jakub@redhat.com>
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
1156 +2007-04-02 Eric Christopher <echristo@apple.com>
1158 + * doc/invoke.texi (i386 and x86-64 Options): Document -m64
1159 + limitations on darwin.
1161 +2007-04-02 Anatoly Sokolov <aesok@post.ru>
1164 + * config/avr/avr.c (avr_rtx_costs): Add missing 'break' statements.
1166 +2007-04-02 H.J. Lu <hongjiu.lu@intel.com>
1168 + * Backport from mainline:
1169 + 2007-03-28 Grigory Zagorodnev <grigory_zagorodnev@linux.intel.com>
1172 + * config/i386/sse.md (uminv16qi3): Use UMIN instead of UMAX.
1174 +2007-03-30 Anatoly Sokolov <aesok@post.ru>
1176 + * config/avr/avr.c (avr_override_options): Clear
1177 + 'flag_delete_null_pointer_checks'.
1179 +2007-03-29 Michael Matz <matz@suse.de>
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
1186 + * config/i386/sync.md (sync_double_compare_and_swapdi_pic,
1187 + sync_double_compare_and_swap_ccdi_pic): Use "SD" as constraint
1190 +2007-03-28 Mike Stump <mrs@apple.com>
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.
1196 +2007-03-27 Anatoly Sokolov <aesok@post.ru>
1198 + * config/avr/avr.c (avr_mcu_types): Move at90usb82 device to 'avr4'
1201 +2007-03-26 Ian Lance Taylor <iant@google.com>
1203 + PR tree-optimization/31345
1204 + * tree-vrp.c (extract_range_from_binary_expr): Turn ranges like
1205 + [+INF, +INF(OVF)] into VARYING.
1207 +2007-03-23 Martin Michlmayr <tbm@cyrius.com>
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.
1213 +2007-03-21 Mike Stump <mrs@apple.com>
1215 + * c.opt: Fixup for Objective-C/C++.
1217 +2007-03-21 Richard Henderson <rth@redhat.com>
1220 + * config/i386/emmintrin.h (__m128i, __m128d): Mark may_alias.
1221 + * config/i386/mmintrin.h (__m64): Likewise.
1222 + * config/i386/xmmintrin.h (__m128): Likewise.
1224 +2007-03-20 Jakub Jelinek <jakub@redhat.com>
1227 + * c-typeck.c (convert_for_assignment): Call comptypes for
1228 + RECORD_TYPE or UNION_TYPE.
1230 + PR inline-asm/30505
1231 + * reload1.c (reload): Do invalid ASM checking after
1232 + cleanup_subreg_operands.
1234 +2007-03-19 Jeff Law <law@redhat.com>
1236 + * tree-cfg.c (find_taken_edge): Tighten conditions for
1237 + optimizing computed gotos.
1239 2007-03-16 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
1241 * pa.c (attr_length_call): Partially revert change of 2007-03-09.
1244 * pa.md (vdepi_ior): Don't allow zero length deposit. Likewise for
1245 two unamed patterns.
1248 2007-03-12 Brooks Moses <brooks.moses@codesourcery.com>
1250 * doc/extend.texi: Edit "gnu_inline" documentation.
1252 * doc/passes.texi: Fix gcc.info cross-reference.
1254 2007-03-12 Daniel Berlin <dberlin@dberlin.org>
1257 Fix PR tree-optimization/28544
1258 * tree-ssa-operands.c (add_virtual_operand):
1259 Move assert triggering on aliasing violations into
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.
1267 2007-03-05 Ian Lance Taylor <iant@google.com>
1270 2007-03-09 Andrew Pinski <andrew_pinski@playstation.sony.com>
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.
1277 2006-03-09 Mark Shinwell <shinwell@codesourcery.com>
1279 * builtins.def (lceil, lceilf, lceill, lfloor, lfloorf, lfloorl,
1280 llceil, llceilf, llceill, llfloor, llfloorf, llfloorl): Mark with
1281 ATTR_CONST_NOTHROW_LIST.
1284 * fold-const.c (tree_expr_nonnegative_p): Handle FIX_TRUNC_EXPR.
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
1290 * opts.c (common_handle_option): Likewise.
1293 2007-03-06 Anatoly Sokolov <aesok@post.ru>
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
1299 * config/avr/avr.h (LINK_SPEC, CRT_BINUTILS_SPECS): (Ditto.).
1300 * config/avr/t-avr (MULTILIB_MATCHES): (Ditto.).
1302 in soft-float DFmode pattern.
1303 (movdf): Fail if operand1 is a CONST_DOUBLE and operand0 is a hard
1305 - (movsf): Likewise.
1306 + (movsf): Likewise.
1308 2007-03-05 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1311 2007-03-01 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
1313 * doc/invoke.texi (Wextra): Delete outdated paragraph.
1316 2007-02-27 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
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>
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
1326 * tree-flow.h (may_aliases_intersect): Add function declaration.
1328 @@ -764,7 +1095,7 @@
1330 2007-02-06 Rask Ingemann Lamberisen <rask@sygehus.dk>
1334 * config/rs6000/t-ppccomm: Correct Makefile typo.
1336 2007-02-06 Roger Sayle <roger@eyesopen.com>
1337 @@ -788,7 +1119,7 @@
1338 2007-02-05 Bob Wilson <bob.wilson@acm.org>
1340 * config/xtensa/xtensa.c (constantpool_mem_p): Skip over SUBREGs.
1343 2007-02-02 Maxim Kuvyrkov <mkuvyrkov@ispras.ru>
1346 @@ -817,7 +1148,7 @@
1348 Revert for x86 darwin:
1349 2005-06-19 Uros Bizjak <uros@kss-loka.si>
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)
1360 +/* PR middle-end/31448, this used to ICE during expand because
1361 + reduce_to_bit_field_precision was not ready to handle constants. */
1363 +typedef struct _st {
1372 + const static int constreg[] = { 0,};
1374 + next->iIndex = constreg[nIndx];
1379 + const static int constreg[] = { 0xFEFEFEFE,};
1381 + next->iIndex = constreg[nIndx];
1382 + next->iIndex1 = constreg[nIndx];
1389 + if (next->iIndex != 0xFFFEFEFE)
1390 + __builtin_abort ();
1391 + if (next->iIndex1 != 0xFFFEFEFE)
1392 + __builtin_abort ();
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)
1401 +extern void abort (void);
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)
1423 +/* PR middle-end/30704 */
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);
1431 +__attribute__((noinline))
1435 + double d = 0x0.fffffffffffff000p-1022;
1436 + memcpy (&t, &d, sizeof (long long));
1441 +__attribute__((noinline))
1444 + long long t = 0x000fedcba9876543LL;
1446 + memcpy (&d, &t, sizeof (long long));
1459 + if (sizeof (long long) != sizeof (double) || __DBL_MIN_EXP__ != -1021)
1463 + if (u.d != 0x0.fffffffffffff000p-1022)
1467 + if (u.ll != 0x000fedcba9876543LL)
1473 + memcpy (&c, &b, sizeof (double));
1475 + if (memcmp (&e, &d, sizeof (double)) != 0)
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)
1485 +void put_field (unsigned int start, unsigned int len)
1487 + int cur_bitshift = ((start + len) % 8) - 8;
1488 + if (cur_bitshift > -8)
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)
1503 +set torture_eval_before_compile {
1504 + set compiler_conditional_xfail_data {
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)
1518 +/* PR tree-optimization/31345
1519 + This caused a crash in VRP when dealing with overflow infinities. */
1522 +dpsnaffle (const char *kbuf)
1524 + int hash, thash, head[2], off;
1527 + (hash) = 19780211;
1529 + (hash) = (hash) + (kbuf)[_DP_i];
1531 + (hash) = ((hash) * 43321879) & 0x7FFFFFFF;
1535 + if (hash > thash) {}
1536 + else if (hash < thash)
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)
1547 +int fs_exec(int ino)
1551 + src = (void*)0xe000;
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)
1559 +/* PR tree-optimization/31632 */
1572 + if (a <= ((void *) 0))
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)
1581 +/* { dg-do run } */
1582 +/* { dg-options "-O" } */
1584 +#include <stdlib.h>
1586 +void __attribute__((noinline))
1589 + if (a != 43 || b != 42)
1595 + register int r0 asm("r0") = 42;
1596 + register int r1 asm("r1") = 43;
1597 + asm volatile("": "+r" (r0), "+r" (r1));
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)
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" } } */
1618 +#include <emmintrin.h>
1621 +f1 (__m128 x, __m128 y)
1623 + return _mm_cmpord_ss (x, y);
1627 +f2 (__m128 x, __m128 y)
1629 + return _mm_cmpord_ps (x, y);
1633 +f3 (__m128d x, __m128d y)
1635 + return _mm_cmpord_sd (x, y);
1639 +f4 (__m128d x, __m128d y)
1641 + return _mm_cmpord_pd (x, y);
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)
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" } } */
1659 +#include <emmintrin.h>
1662 +f1 (__m128 x, __m128 y)
1664 + return _mm_cmpunord_ss (x, y);
1668 +f2 (__m128 x, __m128 y)
1670 + return _mm_cmpunord_ps (x, y);
1674 +f3 (__m128d x, __m128d y)
1676 + return _mm_cmpunord_sd (x, y);
1680 +f4 (__m128d x, __m128d y)
1682 + return _mm_cmpunord_pd (x, y);
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)
1689 +/* PR inline-asm/30505 */
1690 +/* { dg-do compile { target ilp32 } } */
1691 +/* { dg-options "-O2" } */
1693 +unsigned long long a, c;
1699 + unsigned int e, f;
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),
1706 + c = (unsigned long long) e << 32 | f;
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)
1713 +/* { dg-options "-O -fopenmp" } */
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)
1724 +/* { dg-do compile } */
1726 +typedef struct { int i; } D;
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)
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)
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)
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)
1770 +/* PR rtl-optimization/29841 */
1771 +/* Testcase by Khem Raj <raj.khem@gmail.com> */
1773 +/* { dg-do compile } */
1774 +/* { dg-options "-O2" } */
1775 +/* { dg-options "-O2 -mtune=i586" { target i?86-*-* } } */
1777 +typedef void (*fp)(void);
1778 +extern char* bar(void* a1, int a2);
1779 +extern char* mar(int n);
1785 + ((char *(*)(void *,int (*)(void *,unsigned char **),char**))((fp)bar))(0,0,(void*)(0)); /* { dg-warning "" "non-compatible type" } */
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)
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" } */
1796 +int a[] = (int[4]){1, 1, 2};
1799 + int sum = 0; int i;
1800 + for(i = 0;i<4;i++)
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)
1809 +/* { dg-do compile { target *-*-darwin9* } } */
1810 +/* { dg-final { scan-assembler ".comm _foo,1,15" } } */
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)
1819 +/* { dg-do compile } */
1820 +/* { dg-options "--combine -O3" } */
1821 +/* { dg-additional-sources pr30762-2.c } */
1823 +typedef struct { int i; } D;
1824 +extern void foo (D);
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)
1838 +2007-04-24 Paolo Carlini <pcarlini@suse.de>
1841 + * g++.dg/warn/pragma-system_header3.C: New test.
1842 + * g++.dg/warn/pragma-system_header3.h. New.
1844 +2007-04-24 Ian Lance Taylor <iant@google.com>
1846 + PR tree-optimization/31605
1847 + * gcc.c-torture/execute/pr31605.c: New test.
1849 +2007-04-24 Andreas Krebbel <krebbel1@de.ibm.com>
1852 + * gcc.c-torture/compile/pr31641.c: New testcase.
1854 +2007-04-22 Andrew Pinski <andrew_pinski@playstation.sony.com>
1856 + PR middle-end/31448
1857 + * gcc.c-torture/execute/pr31448.c: New testcase.
1859 +2007-04-21 Richard Guenther <rguenther@suse.de>
1861 + PR middle-end/31136
1862 + * gcc.c-torture/execute/pr31136.c: New testcase.
1864 +2007-04-20 Jakub Jelinek <jakub@redhat.com>
1866 + * gcc.target/i386/ordcmp-1.c: New test.
1867 + * gcc.target/i386/unordcmp-1.c: New test.
1869 + PR tree-optimization/31632
1870 + * gcc.c-torture/compile/20070419-1.c: New test.
1872 +2007-04-19 Eric Botcazou <ebotcazou@libertysurf.fr>
1874 + * gcc.dg/invalid-call-1.c: New test.
1876 +2007-04-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1878 + PR libgfortran/31366
1879 + * gfortran.dg/direct_io_6.f90: New test.
1881 +2007-04-17 Simon Martin <simartin@users.sourceforge.net>
1884 + * g++.dg/template/init7.C: New test.
1886 +2007-04-16 Mark Mitchell <mark@codesourcery.com>
1889 + * g++.dg/expr/bitfield8.C: New test.
1891 +2007-04-14 Andrew Pinski <andrew_pinski@playstation.sony.com>
1893 + PR testsuite/31578
1894 + * gcc.dg/gnu89-init-4.c: Change to a compile only test.
1896 +2007-04-14 Andrew Pinski <andrew_pinski@playstation.sony.com>
1899 + * gcc.dg/gnu89-init-4.c: New testcase.
1901 +2007-04-14 Jakub Jelinek <jakub@redhat.com>
1904 + * gcc.dg/gomp/pr25874.c: Add dg-options.
1905 + * g++.dg/gomp/pr25874.C: Add dg-options.
1907 +2007-04-13 Jason Merrill <jason@redhat.com>
1910 + * conv3.C: New test.
1912 +2007-04-13 Joseph Myers <joseph@codesourcery.com>
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.
1918 +2007-04-10 Mike Stump <mrs@apple.com>
1920 + * g++.dg/tree-ssa/pr29585.C: Don't die on an expected warning.
1922 +2007-04-09 Mark Mitchell <mark@codesourcery.com>
1925 + * g++.dg/init/const5.C: New test.
1927 +2007-04-03 Eric Christopher <echristo@apple.com>
1929 + * g++.dg/tree-ssa/pr29902.C: Require ilp32.
1931 +2007-04-03 Stuart Hastings <stuart@apple.com>
1934 + * testsuite/objc/execute/exceptions/pr31281.m: New.
1936 +2007-04-03 Jakub Jelinek <jakub@redhat.com>
1939 + * g++.dg/parse/cond3.C: New test.
1941 + PR middle-end/30704
1942 + * gcc.c-torture/execute/ieee/pr30704.c: New test.
1944 +2007-04-02 Jason Merrill <jason@redhat.com>
1947 + * g++.dg/ext/visibility/anon3.C: New test.
1949 +2007-03-31 Diego Novillo <dnovillo@redhat.com>
1952 + * g++.dg/tree-ssa/pr29585.C: New test.
1954 +2007-03-30 Kazu Hirata <kazu@codesourcery.com>
1956 + * gcc.c-torture/execute/mayalias-2.x: New.
1958 +2007-03-28 Mike Stump <mrs@apple.com>
1960 + * gcc.dg/darwin-comm.c: Add.
1962 +2007-03-26 Ian Lance Taylor <iant@google.com>
1964 + PR tree-optimization/31345
1965 + * gcc.c-torture/compile/pr31345-1.c: New test.
1967 +2007-03-22 Mark Mitchell <mark@codesourcery.com>
1970 + * g++.dg/template/error24.C: New test.
1971 + * g++.dg/parse/tmpl-outside1.C: Tweak error markers.
1974 + * g++.dg/expr/bitfield7.C: New test.
1976 +2007-03-20 Seongbae Park <seongbae.park@gmail.com>
1978 + PR tree-optimization/30590
1979 + * g++.dg/opt/pr30590.C: New testcase.
1981 +2007-03-20 Jakub Jelinek <jakub@redhat.com>
1984 + * gcc.dg/pr30762-1.c: New test.
1985 + * gcc.dg/pr30762-2.c: New test.
1987 + PR inline-asm/30505
1988 + * gcc.target/i386/pr30505.c: New test.
1990 +2007-03-19 Mark Shinwell <shinwell@codesourcery.com>
1992 + * gcc.target/arm/register-variables.c: New.
1994 +2007-03-19 Jeff Law <law@redhat.com>
1996 + * PR tree-optimization/30984
1997 + * gcc.c-torture/pr30984.c: New test.
1999 2007-03-16 Alexandre Oliva <aoliva@redhat.com>
2002 @@ -123,12 +284,12 @@
2003 PR rtl-optimization/30643
2004 * gcc.dg/pr30643.c: New.
2006 -2007-03-09 Andrew Pinski <andrew_pinski@playstation.sony.com>
2007 +2007-03-09 Andrew Pinski <andrew_pinski@playstation.sony.com>
2010 * gcc.dg/pr30045.c: New test.
2012 -2007-03-09 Andrew Pinski <andrew_pinski@playstation.sony.com>
2013 +2007-03-09 Andrew Pinski <andrew_pinski@playstation.sony.com>
2016 * gcc.dg/Wunused-value-2.c: New testcase.
2018 2007-03-08 Brooks Moses <brooks.moses@codesourcery.com>
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
2025 2007-03-08 Paul Thomas <pault@gcc.gnu.org>
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.
2032 2007-03-06 Roger Sayle <roger@eyesopen.com>
2037 2007-02-23 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2039 - PR libgfortran/30910
2040 + PR libgfortran/30910
2041 * gfortran.dg/fmt_zero_precision.f90: Update test.
2043 2007-02-23 Tobias Burnus <burnus@net-b.de>
2045 2007-02-16 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2048 - * gcc/testsuite/gfortran.dg/repeat_1.f90: New test.
2049 + * gfortran.dg/repeat_1.f90: New test.
2051 2007-02-16 Thomas Koenig <Thomas.Koenig@online.de>
2055 2007-02-07 Hans-Peter Nilsson <hp@axis.com>
2057 - * lib/target-supports.exp (check_effective_target_simulator): New.
2058 + * lib/target-supports.exp (check_effective_target_simulator): New.
2060 2007-02-05 Alexandre Oliva <aoliva@redhat.com>
2065 * gfortran.dg/ctrl-z.f90: New test.
2068 2007-01-26 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2071 @@ -1319,7 +1480,7 @@
2072 2006-11-13 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2075 - * gcc/testsuite/gfortran.dg/zero_sized_1.f90: Uncomment checks
2076 + * gfortran.dg/zero_sized_1.f90: Uncomment checks
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>
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
2096 - * gcc/testsuite/gfortran.dg/direct_io_2.f90: Add a FILE=
2097 + * gfortran.dg/direct_io_2.f90: Add a FILE=
2099 - * gcc/testsuite/gfortran.dg/iomsg_1.f90: Add check for
2100 + * gfortran.dg/iomsg_1.f90: Add check for
2101 compile-time warning.
2103 2006-10-12 Jan Hubicka <jh@suse.cz>
2104 @@ -1899,12 +2060,12 @@
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.
2119 2006-10-07 Richard Sandiford <richard@codesourcery.com>
2121 @@ -4158,7 +4319,7 @@
2122 2006-06-08 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2125 - * gcc/testsuite/gfortran.dg/substr_2.f: New test.
2126 + * gfortran.dg/substr_2.f: New test.
2128 2006-06-08 Asher Langton <langton2@llnl.gov>
2130 @@ -6195,7 +6356,7 @@
2132 2006-03-03 Paul Brook <paul@codesourcery.com>
2134 - * gcc/testsuite/lib/target-supports.exp (check_profiling_available):
2135 + * lib/target-supports.exp (check_profiling_available):
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>
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.
2152 2005-11-04 Hans-Peter Nilsson <hp@axis.com>
2154 @@ -17467,7 +17628,7 @@
2155 2005-02-11 Jakub Jelinek <jakub@redhat.com>
2158 - * gcc/testsuite/g++.dg/other/ptrmem6.C: New test.
2159 + * g++.dg/other/ptrmem6.C: New test.
2162 * gcc.c-torture/compile/20050210-1.c: New test.
2163 @@ -33085,33 +33246,33 @@
2165 2003-01-16 Mark Mitchell <mark@codesourcery.com>
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
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
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
2196 - * gcc/testsuite/g++.old-deja/g++.pt/crash5.C: Improve error
2197 + * g++.old-deja/g++.pt/crash5.C: Improve error
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->.
2215 2003-01-16 Nathan Sidwell <nathan@codesourcery.com>
2217 @@ -34702,9 +34863,9 @@
2219 2002-09-25 Mark Mitchell <mark@codesourcery.com>
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.
2228 2002-09-25 Richard Henderson <rth@redhat.com>
2230 @@ -35726,7 +35887,7 @@
2232 2002-05-23 Mark Mitchell <mark@codesourcery.com>
2234 - * gcc/testsuite/gcc.dg/weak-8.c: New test.
2235 + * gcc.dg/weak-8.c: New test.
2237 2002-05-23 J"orn Rennecke <joern.rennecke@superh.com>
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)
2244 +/* { dg-do compile } */
2245 +/* { dg-options "-O2 -w" } */
2248 +struct basic_ostream : virtual ios_base{};
2251 + struct Nullostream : basic_ostream{};
2256 + Nullostream nullout;
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)
2264 /* { dg-do compile { target i?86-*-* } } */
2265 /* { dg-options "-O1 -fprefetch-loop-arrays -march=athlon" } */
2266 +/* { dg-require-effective-target ilp32 } */
2271 for (int i = 1; i < capacity_; i++){old_storage[i] = 0;}
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)
2281 +// Bug: the repeated declaration was confusing the compiler into
2282 +// thinking that foo1 had language internal linkage.
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)
2302 +// Bug: The reference cast wasn't finding the desired static_cast followed by
2303 +// const_cast interpretation.
2308 + virtual ~Shape() {}
2314 + virtual ~Loop() {}
2315 + virtual void func() {}
2323 + virtual ~Rect() {}
2328 + const Rect* rect = new Rect();
2329 + Loop &l = ((Loop&)(*rect));
2330 + return (&l != (const Loop *)rect);
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)
2337 +// { dg-options "-O -fopenmp" }
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)
2347 +/* { dg-do run } */
2348 +/* { dg-options "-O" } */
2352 + char buffer[4242]; /* should trigger pass-by-reference */
2360 + struct test retval;
2368 + struct test result;
2371 + for (int i = 0; i < 2; ++i)
2373 + struct test candidate = reset ();
2375 + result = candidate;
2384 + struct test result = test ();
2385 + return result.type;
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)
2395 +class Bar : public Foo {};
2396 +static const Foo *foo = 0;
2398 +static Bar *bar = static_cast<const Bar*>(foo); // { dg-error "conversion" }
2400 +void func(const Foo *foo) {
2401 + Bar *bar = static_cast<const Bar*>(foo); // { dg-error "conversion" }
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)
2409 +// { dg-options "-Wcast-align" }
2411 +#include "pragma-system_header3.h"
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)
2423 +#pragma GCC system_header
2425 +template <typename T>
2426 + int* g() { static char c; return reinterpret_cast<int*>(&c); }
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)
2436 +// { dg-do compile }
2437 +// { dg-options "" }
2440 +extern void baz ();
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" }
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)
2455 template <int i> struct Y {};
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)
2468 +template <typename T>
2472 + unsigned s<int> x; // { dg-error "invalid" }
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)
2479 +/* PR c++/31517. This used to ICE. */
2480 +/* { dg-do "compile" } */
2482 +template<typename> struct A
2484 + static const int i=0;
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)
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)
2509 +extern "C" void abort();
2512 + unsigned int precision : 9;
2515 +void bork(unsigned int i) {
2520 +void foo(struct tree_type *t)
2522 + bork(t->precision);
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)
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
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
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)
2556 +/* From PR31281. */
2557 +extern void abort (void);
2558 +int __attribute__((noinline))
2562 + @try { } @catch(id) { return 13; }
2563 + for (j=0; j<i; j++)
2564 + for (k=0; k<i; k++)
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 @@
2589 tree preeval = NULL_TREE;
2591 + if (VOID_TYPE_P (TREE_TYPE (rhs)))
2593 + error ("void value not ignored as it ought to be");
2594 + return error_mark_node;
2597 rhs = stabilize_expr (rhs, &preeval);
2599 /* Check this here to avoid odd errors when trying to convert
2600 @@ -6795,6 +6801,16 @@
2601 return TYPE_QUALS (type);
2604 +/* Returns nonzero if the TYPE is const from a C++ perspective: look inside
2608 +cp_type_readonly (tree type)
2610 + type = strip_array_types (type);
2611 + return TYPE_READONLY (type);
2614 /* Returns nonzero if the TYPE contains a mutable member. */
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);
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));
2634 + = cp_build_qualified_type (target_type,
2635 + cp_type_quals (class_type));
2636 + return build_nop (build_pointer_type (target_type), expr);
2638 null_test = error_mark_node;
2641 @@ -7101,7 +7112,13 @@
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 @@
2666 *pushed_scope_p = NULL_TREE;
2668 @@ -3969,6 +3970,8 @@
2672 + was_public = TREE_PUBLIC (decl);
2674 /* Enter this declaration into the symbol table. */
2675 tem = maybe_push_decl (decl);
2677 @@ -3989,6 +3992,17 @@
2678 && !have_global_bss_p ())
2679 DECL_COMMON (tem) = 1;
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))
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;
2692 if (!processing_template_decl && TREE_CODE (tem) == VAR_DECL)
2693 start_decl_1 (tem, initialized);
2695 @@ -5301,14 +5315,6 @@
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))
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;
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)
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);
2726 conv = build_identity_conv (from, expr);
2727 - if (fcode == FUNCTION_TYPE)
2728 + if (fcode == FUNCTION_TYPE || fcode == ARRAY_TYPE)
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);
2735 - else if (fcode == ARRAY_TYPE)
2737 - from = build_pointer_type (TREE_TYPE (from));
2738 - fcode = TREE_CODE (from);
2739 - conv = build_conv (ck_lvalue, from, conv);
2741 else if (fromref || (expr && lvalue_p (expr)))
2744 @@ -632,7 +626,10 @@
2746 bitfield_type = is_bitfield_expr_with_lowered_type (expr);
2748 - from = strip_top_quals (bitfield_type);
2750 + from = strip_top_quals (bitfield_type);
2751 + fcode = TREE_CODE (from);
2754 conv = build_conv (ck_rvalue, from, conv);
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. */
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)
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);
2781 if (lvalue_p && compatible_p)
2782 @@ -1227,7 +1230,7 @@
2783 if (related_p && !at_least_as_qualified_p (to, from))
2786 - conv = implicit_conversion (to, from, expr, /*c_cast_p=*/false,
2787 + conv = implicit_conversion (to, from, expr, c_cast_p,
2791 @@ -1257,7 +1260,7 @@
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);
2798 conv = standard_conversion (to, from, expr, c_cast_p, flags);
2800 @@ -4655,6 +4658,7 @@
2802 convert_for_arg_passing (tree type, tree val)
2804 + val = convert_bitfield_to_declared_type (val);
2805 if (val == error_mark_node)
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);
2812 - conv = reference_binding (type, TREE_TYPE (expr), expr, LOOKUP_NORMAL);
2813 + conv = reference_binding (type, TREE_TYPE (expr), expr, /*c_cast_p=*/false,
2815 if (!conv || conv->bad_p)
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)
2835 +2007-04-24 Paolo Carlini <pcarlini@suse.de>
2838 + * pt.c (instantiate_decl): Set in_system_header.
2840 +2007-04-17 Simon Martin <simartin@users.sourceforge.net>
2843 + * pt.c (value_dependent_expression_p): Handle MODOP_EXPRs.
2845 +2007-04-16 Mark Mitchell <mark@codesourcery.com>
2848 + * call.c (convert_for_arg_passing): Convert bitfields to their
2851 +2007-04-13 Jason Merrill <jason@redhat.com>
2854 + * call.c (reference_binding): Add c_cast_p parm. If true,
2855 + add quals to TO as needed to make it reference-compatible.
2857 +2007-04-10 Mike Stump <mrs@apple.com>
2859 + * class.c (dfs_accumulate_vtbl_inits): Slam the vtbl type back to
2860 + vtbl_ptr_type_node to ensure the mode is correct.
2862 +2007-04-09 Mark Mitchell <mark@codesourcery.com>
2865 + * class.c (build_base_path): Ensure that the converted pointer has
2866 + the same cv-qualification as the input.
2868 +2007-04-03 Jakub Jelinek <jakub@redhat.com>
2871 + * typeck.c (build_modify_expr): For COND_EXPR on LHS, if RHS has void
2872 + type issue error and return early.
2874 +2007-03-30 Jason Merrill <jason@redhat.com>
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.
2882 +2007-03-31 Diego Novillo <dnovillo@redhat.com>
2883 + Mark Mitchell <mark@codesourcery.com>
2886 + * class.c (dfs_accumulate_vtbl_inits): Use build_address
2887 + to build the vtbl entry.
2889 +2007-03-22 Mark Mitchell <mark@codesourcery.com>
2892 + * parser.c (cp_parser_parse_and_diagnose_invalid_type_name): Do
2893 + not consume tokens when failing.
2895 +2007-03-22 Jim Wilson <wilson@specifix.com>
2896 + Mark Mitchell <mark@codesourcery.com>
2899 + * call.c (standard_conversion): Use type_decays_to. Keep FCODE
2900 + consistent with FROM.
2902 2007-03-14 Andrew Pinski <andrew_pinski@playstation.sony.com>
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;
2912 location_t saved_loc = input_location;
2913 + int saved_in_system_header = in_system_header;
2916 /* This function should only be used to instantiate templates for
2917 @@ -12116,6 +12117,7 @@
2920 input_location = DECL_SOURCE_LOCATION (d);
2921 + in_system_header = DECL_IN_SYSTEM_HEADER (d);
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 @@
2928 input_location = saved_loc;
2929 + in_system_header = saved_in_system_header;
2930 pop_deferring_access_checks ();
2933 @@ -12924,6 +12927,10 @@
2934 such calls are value-dependent. */
2938 + return ((value_dependent_expression_p (TREE_OPERAND (expression, 0)))
2939 + || (value_dependent_expression_p (TREE_OPERAND (expression, 2))));
2942 /* A constant expression is value-dependent if any subexpression is
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)
2956 cp_parser_abort_tentative_parse (parser);
2959 - if (!cp_parser_parse_definitely (parser) || TREE_CODE (id) == TYPE_DECL)
2960 + if (!cp_parser_parse_definitely (parser))
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);
2971 code = find_comparison_args (code, &op0, &op1, &mode0, &mode1);
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
2977 + if (GET_MODE_CLASS (mode0) == MODE_CC)
2980 if (! cond_known_true)
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))
2991 - else if (DECL_P (*tp) && TREE_CODE (*tp) != FUNCTION_DECL)
2992 + else if (!flag_unit_at_a_time)
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)
2999 struct cgraph_varpool_node *node = cgraph_varpool_node (*tp);
3003 + else if (DECL_P (*tp) && TREE_CODE (*tp) == FUNCTION_DECL
3004 + && (!DECL_EXTERNAL (*tp) || DECL_DECLARED_INLINE_P (*tp)))
3006 + struct cgraph_node *node = cgraph_node (*tp);
3007 + if (!node->output)
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))
3021 - if (TYPE_UNSIGNED (type))
3022 + /* For constant values, reduce using build_int_cst_type. */
3023 + if (GET_CODE (exp) == CONST_INT)
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);
3029 + else if (TYPE_UNSIGNED (type))
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));
3042 + /* Treat trap instructions like noreturn calls (same provision). */
3043 + if (GET_CODE (PATTERN (insn)) == TRAP_IF
3044 + && XEXP (PATTERN (insn), 0) == const1_rtx)
3047 return (flag_non_call_exceptions && can_throw_internal (insn));
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 @@
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");
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 @@
3069 finish_decl (tree decl, tree init, tree asmspec_tree)
3071 - tree type = TREE_TYPE (decl);
3073 int was_incomplete = (DECL_SIZE (decl) == 0);
3074 const char *asmspec = 0;
3076 @@ -3364,6 +3364,8 @@
3077 || TREE_CODE (decl) == FIELD_DECL))
3078 objc_check_decl (decl);
3080 + type = TREE_TYPE (decl);
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)
3090 +2007-04-12 Daniel Franke <franke.daniel@gmail.com>
3093 + * intrinsic.texi (RANDOM_SEED, RANDOM_NUMBER): New.
3095 +2007-03-23 Brooks Moses <brooks.moses@codesourcery.com>
3097 + * invoke.texi: Misc. small typo fixes.
3098 + (-Wcharacter-truncation): Add.
3099 + (-Wnonstd-intrinsics): Correct spelling.
3102 +2007-03-17 Francois-Xavier Coudert <coudert@clipper.ens.fr>
3105 + * invoke.texi: Fix typo.
3107 2007-03-14 Jakub Jelinek <jakub@redhat.com>
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)
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}
3125 @item Debugging Options
3126 @xref{Debugging Options,,Options for Debugging Your Program or GCC}.
3127 @@ -138,11 +138,12 @@
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}}
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}}
3140 @item Code Generation Options
3141 @xref{Code Gen Options,,Options for Code Generation Conventions}.
3143 @command{gfortran} will ignore @option{-Wnonstd-intrinsics}.
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
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}.
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.
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.
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.
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.
3213 @cindex @code{-Wsurprising} option
3214 @@ -608,9 +621,11 @@
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}
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
3236 -Intrinsic implemented, documentation pending.
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}.
3243 @item @emph{Standard}:
3246 @@ -7625,9 +7626,31 @@
3247 Elemental subroutine
3249 @item @emph{Syntax}:
3250 +@code{RANDOM_NUMBER(HARVEST)}
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(*)}.
3258 @item @emph{Example}:
3260 +program test_random_number
3262 + CALL init_random_seed() ! see example of RANDOM_SEED
3263 + CALL RANDOM_NUMBER(r)
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.
3276 @item @emph{See also}:
3279 @@ -7639,10 +7662,15 @@
3280 @cindex @code{RANDOM_SEED} intrinsic
3281 @cindex random numbers
3283 -Intrinsic implemented, documentation pending.
3286 @item @emph{Description}:
3287 +Restarts or queries the state of the pseudorandom number generator used by
3288 +@code{RANDOM_NUMBER}.
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.
3294 @item @emph{Standard}:
3297 @@ -7650,9 +7678,41 @@
3300 @item @emph{Syntax}:
3301 +@code{CALL RANDOM_SEED(SIZE, PUT, GET)}
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.
3319 @item @emph{Example}:
3321 +SUBROUTINE init_random_seed()
3322 + INTEGER :: i, n, clock
3323 + INTEGER, DIMENSION(:), ALLOCATABLE :: seed
3325 + CALL RANDOM_SEED(size = n)
3328 + CALL SYSTEM_CLOCK(COUNT=clock)
3330 + seed = clock + 37 * (/ (i - 1, i = 1, n) /)
3331 + CALL RANDOM_SEED(PUT = seed)
3337 @item @emph{See also}:
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)
3345 Warn about casting functions to incompatible types
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++
3354 Warn about deprecated compiler features
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
3363 Generate code for GNU runtime environment
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
3372 Emit implicit instantiations of templates
3375 -C++ Var(flag_friend_injection)
3376 +C++ ObjC++ Var(flag_friend_injection)
3377 Inject friend functions into enclosing namespace
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);
3388 + /* Aggregates in different TUs might need conversion. */
3389 + if ((codel == RECORD_TYPE || codel == UNION_TYPE)
3391 + && comptypes (type, rhstype))
3392 + return convert_and_check (type, rhs);
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))
3401 tree memb, marginal_memb = NULL_TREE;
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 @@
3413 + int units = CONST_VECTOR_NUNITS (x);
3414 + tree itype = TREE_TYPE (type);
3418 - units = CONST_VECTOR_NUNITS (x);
3420 /* Build a tree with vector elements. */
3421 for (i = units - 1; i >= 0; --i)
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);
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)
3435 +2007-04-21 Joseph S. Myers <joseph@codesourcery.com>
3439 2007-03-08 Joseph S. Myers <joseph@codesourcery.com>
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)
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.
3454 # Remember: GCC team does not want RCS keywords in the header!
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"
3468 msgid "braces around scalar initializer"
3469 -msgstr "klamrar funt skalär initierare"
3470 +msgstr "klamrar runt skalär initierare"
3473 msgid "initialization of flexible array member in a nested context"
3474 @@ -9266,19 +9266,19 @@
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"
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"
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"
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"
3497 msgid "Deprecated; use --classpath instead"
3498 @@ -9370,23 +9370,23 @@
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"
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"
3510 #: fortran/lang.opt:50
3511 msgid "Warn about implicit conversion"
3512 -msgstr "Varna om implicita konverteringar"
3513 +msgstr "Varna för implicita konverteringar"
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"
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"
3525 #: fortran/lang.opt:62
3526 msgid "Warn about usage of non-standard intrinsics"
3527 @@ -9394,11 +9394,11 @@
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"
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"
3539 #: fortran/lang.opt:74 common.opt:162
3540 msgid "Warn when a label is unused"
3541 @@ -9936,11 +9936,11 @@
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"
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"
3553 #: config/s390/s390.opt:100
3554 msgid "z/Architecture"
3555 @@ -10690,7 +10690,7 @@
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"
3562 #: config/rs6000/rs6000.opt:219
3563 msgid "Select GPR floating point method"
3564 @@ -12214,7 +12214,7 @@
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"
3572 msgid "Enable most warning messages"
3573 @@ -12226,23 +12226,23 @@
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"
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++"
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"
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\""
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"
3601 msgid "Synonym for -Wcomment"
3602 @@ -12250,7 +12250,7 @@
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"
3610 msgid "Warn when all constructors and destructors are private"
3611 @@ -12262,19 +12262,19 @@
3614 msgid "Warn about deprecated compiler features"
3615 -msgstr "Varna om kompilatorfunktioner som undanbedes"
3616 +msgstr "Varna för kompilatorfunktioner bör undvikas"
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"
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++"
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"
3634 msgid "Make implicit function declarations an error"
3635 @@ -12286,35 +12286,35 @@
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"
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"
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"
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"
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"
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"
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"
3673 msgid "Warn about implicit function declarations"
3674 -msgstr "Varna om implicita funktionsdeklarationer"
3675 +msgstr "Varna för implicita funktionsdeklarationer"
3678 msgid "Warn when a declaration does not specify a type"
3679 @@ -12326,15 +12326,15 @@
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"
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\""
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"
3697 msgid "Do not warn about using \"long long\" when -pedantic"
3698 @@ -12342,31 +12342,31 @@
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\""
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"
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"
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"
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"
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"
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"
3736 msgid "Warn about use of multi-character character constants"
3737 @@ -12374,7 +12374,7 @@
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å"
3745 msgid "Warn when non-templatized friend functions are declared within a template"
3746 @@ -12382,31 +12382,31 @@
3749 msgid "Warn about non-virtual destructors"
3750 -msgstr "Varna om ickevirtuella destruerare"
3751 +msgstr "Varna för ickevirtuella destruerare"
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"
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"
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"
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"
3774 msgid "Warn about overloaded virtual function names"
3775 -msgstr "Varna om överlastade virtuella funktionsnamn"
3776 +msgstr "Varna för överlagrade virtuella funktionsnamn"
3779 msgid "Warn about possibly missing parentheses"
3780 -msgstr "Varna om eventuellt saknade parenteser"
3781 +msgstr "Varna för eventuellt saknade parenteser"
3784 msgid "Warn when converting the type of pointers to member functions"
3785 @@ -12414,7 +12414,7 @@
3788 msgid "Warn about function pointer arithmetic"
3789 -msgstr "Varna om aritmetik med funktionspekare"
3790 +msgstr "Varna för aritmetik med funktionspekare"
3793 msgid "Warn when a pointer is cast to an integer of a different size"
3794 @@ -12422,15 +12422,15 @@
3797 msgid "Warn about misuses of pragmas"
3798 -msgstr "Varna om missbruk av pragman"
3799 +msgstr "Varna för missbruk av pragman"
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"
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"
3812 msgid "Warn when the compiler reorders code"
3813 @@ -12442,31 +12442,31 @@
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"
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"
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"
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"
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"
3841 msgid "Warn about unprototyped function declarations"
3842 -msgstr "Varna om funktionsdeklarationer utan prototyp"
3843 +msgstr "Varna för funktionsdeklarationer utan prototyp"
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"
3851 msgid "Warn when synthesis behavior differs from Cfront"
3852 @@ -12478,27 +12478,27 @@
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"
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"
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"
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"
3875 msgid "Warn about unrecognized pragmas"
3876 -msgstr "Varna om okända pragman"
3877 +msgstr "Varna för okända pragman"
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"
3885 msgid "Do not warn about using variadic macros when -pedantic"
3886 @@ -12886,23 +12886,23 @@
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"
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"
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"
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"
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"
3914 msgid "Warn when an optimization pass is disabled"
3915 @@ -12926,15 +12926,15 @@
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"
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."
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))"
3933 msgid "Warn when the packed attribute has no effect on struct layout"
3934 @@ -12950,31 +12950,31 @@
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"
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"
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"
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"
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"
3962 msgid "Warn about uninitialized automatic variables"
3963 -msgstr "Varna om oinitierade automatiska variabler"
3964 +msgstr "Varna för oinitierade automatiska variabler"
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"
3972 msgid "Enable all -Wunused- warnings"
3973 @@ -13106,7 +13106,7 @@
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"
3981 msgid "Defer popping functions args from stack until later"
3982 @@ -13118,7 +13118,7 @@
3985 msgid "Delete useless null pointer checks"
3986 -msgstr "Tag bort oanvändbara nollpekarkontroller"
3987 +msgstr "Tag bort onödiga nollpekarkontroller"
3990 msgid "How often to emit source location at the beginning of line-wrapped diagnostics"
3991 @@ -13214,7 +13214,7 @@
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"
3999 msgid "Perform conversion of conditional jumps to conditional execution"
4000 @@ -13730,15 +13730,15 @@
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"
4008 msgid "Perform whole program optimizations"
4009 -msgstr "Utför optimeringav hela program"
4010 +msgstr "Utför optimering av hela program"
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"
4018 msgid "Put zero initialized data in the bss section"
4019 @@ -14044,7 +14044,7 @@
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"
4027 #, gcc-internal-format
4028 @@ -14059,7 +14059,7 @@
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"
4036 #, gcc-internal-format
4037 @@ -14129,12 +14129,12 @@
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"
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"
4050 #. Common Ada/Pascal programmer's mistake. We always warn
4051 #. about this since it is so bad.
4052 @@ -14196,7 +14196,7 @@
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"
4060 #, gcc-internal-format
4061 @@ -14236,7 +14236,7 @@
4063 #, gcc-internal-format
4064 msgid "%Hswitch missing default case"
4065 -msgstr "%Hswitch saknare default-fall"
4066 +msgstr "%Hswitch saknar default-fall"
4068 #. Warn if there are enumerators that don't correspond to
4069 #. case expressions.
4070 @@ -14279,7 +14279,7 @@
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"
4078 #, gcc-internal-format
4079 @@ -14339,7 +14339,7 @@
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"
4087 #, gcc-internal-format
4088 @@ -19077,7 +19077,7 @@
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"
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)"
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)"
4111 #, gcc-internal-format
4112 msgid "%qs is deprecated"
4113 -msgstr "%qs undanbedes"
4114 +msgstr "%qs bör undvikas"
4117 #, gcc-internal-format
4118 msgid "type is deprecated"
4119 -msgstr "type undanbedes"
4120 +msgstr "typen bör undvikas"
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"
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%>"
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"
4149 #. It's no good looking for an overloaded operator() on a
4150 #. pointer-to-member-function.
4151 @@ -22522,7 +22522,7 @@
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"
4159 #, gcc-internal-format
4160 @@ -22602,7 +22602,7 @@
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"
4168 #, gcc-internal-format
4169 @@ -22880,7 +22880,7 @@
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"
4177 #, gcc-internal-format
4178 @@ -22890,7 +22890,7 @@
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"
4186 #, gcc-internal-format
4187 @@ -23022,7 +23022,7 @@
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"
4194 #. Only warn when there is no &.
4196 @@ -23565,7 +23565,7 @@
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"
4204 #, gcc-internal-format
4205 @@ -24427,7 +24427,7 @@
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 ?:"
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"
4222 #, gcc-internal-format
4223 @@ -25242,7 +25242,7 @@
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)"
4231 #, gcc-internal-format
4232 @@ -25562,7 +25562,7 @@
4234 #, gcc-internal-format
4235 msgid "minimum/maximum operators are deprecated"
4236 -msgstr "minimum-/maximumoperatorer undanbedes"
4237 +msgstr "minimum-/maximumoperatorer bör undvikas"
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"
4248 #: cp/parser.c:12373
4249 #, gcc-internal-format
4250 @@ -26728,7 +26728,7 @@
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"
4257 #: cp/search.c:1849 cp/search.c:1864 cp/search.c:1869
4258 #, gcc-internal-format
4259 @@ -27013,7 +27013,7 @@
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"
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"
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 @@
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;
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)
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)),
4308 WARN_STRICT_OVERFLOW_CONDITIONAL);
4310 COND_EXPR_COND (stmt) = boolean_false_node;
4311 @@ -2121,8 +2123,19 @@
4312 return find_taken_edge_switch_expr (bb, val);
4314 if (computed_goto_p (stmt))
4315 - return find_taken_edge_computed_goto (bb, TREE_OPERAND( val, 0));
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.
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));
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)
4338 %{!shared: %{profile:-lc_p}%{!profile:-lc}}"
4341 +#define CPP_SPEC "%{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}"
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. */
4354 -get_unaligned_address (rtx ref, int extra_offset)
4355 +get_unaligned_address (rtx ref)
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);
4363 - return plus_constant (base, offset + extra_offset);
4364 + return plus_constant (base, offset);
4367 +/* Compute a value X, such that X & 7 == (ADDR + OFS) & 7.
4368 + X is always returned in a register. */
4371 +get_unaligned_offset (rtx addr, HOST_WIDE_INT ofs)
4373 + if (GET_CODE (addr) == PLUS)
4375 + ofs += INTVAL (XEXP (addr, 1));
4376 + addr = XEXP (addr, 0);
4379 + return expand_simple_binop (Pmode, PLUS, addr, GEN_INT (ofs & 7),
4380 + NULL_RTX, 1, OPTAB_LIB_WIDEN);
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]),
4393 alpha_set_memflags (seq, operands[1]);
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));
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 @@
4410 if (unaligned_memory_operand (operands[1], QImode))
4413 - = gen_unaligned_extendqidi (operands[0],
4414 - get_unaligned_address (operands[1], 1));
4416 + rtx seq = gen_unaligned_extendqidi (operands[0], XEXP (operands[1], 0));
4417 alpha_set_memflags (seq, operands[1]);
4420 @@ -1670,9 +1667,7 @@
4422 if (unaligned_memory_operand (operands[1], HImode))
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));
4429 alpha_set_memflags (seq, operands[1]);
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).
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" ""))]
4442 + operands[0] = gen_lowpart (DImode, operands[0]);
4443 if (WORDS_BIG_ENDIAN)
4444 emit_insn (gen_unaligned_extendqidi_be (operands[0], operands[1]));
4446 @@ -1701,48 +1697,40 @@
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))
4454 + [(set (match_dup 3)
4455 + (mem:DI (and:DI (match_operand:DI 1 "" "") (const_int -8))))
4457 (ashift:DI (match_dup 3)
4458 (minus:DI (const_int 64)
4460 (and:DI (match_dup 2) (const_int 7))
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"
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);
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))))
4479 - (mem:DI (and:DI (match_dup 3)
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)
4487 - (plus:DI (match_dup 5) (const_int 1))
4488 + (plus:DI (match_dup 2) (const_int 1))
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)))]
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);
4505 (define_expand "unaligned_extendhidi"
4506 @@ -1751,17 +1739,16 @@
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]));
4516 + emit_insn (gen_unaligned_extendhidi_le (operands[0], operands[1]));
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))
4525 + [(set (match_dup 3)
4526 + (mem:DI (and:DI (match_operand:DI 1 "" "") (const_int -8))))
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"
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);
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))))
4546 - (mem:DI (and:DI (match_dup 3)
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)
4554 - (plus:DI (match_dup 5) (const_int 1))
4555 + (plus:DI (match_dup 2) (const_int 1))
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)))]
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);
4571 (define_insn "*extxl_const"
4572 @@ -6065,7 +6046,7 @@
4574 scratch = gen_rtx_REG (DImode, REGNO (operands[2]));
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 @@
4583 scratch = gen_rtx_REG (DImode, REGNO (operands[2]));
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 @@
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 @@
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)
4613 extern rtx split_small_symbolic_operand (rtx);
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 @@
4628 emit_move_insn (count, temp);
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);
4633 emit_move_insn (blocks, temp);
4635 @@ -3592,10 +3592,12 @@
4637 s390_expand_setmem (rtx dst, rtx len, rtx val)
4639 - gcc_assert (GET_CODE (len) != CONST_INT || INTVAL (len) > 0);
4640 + if (GET_CODE (len) == CONST_INT && INTVAL (len) == 0)
4643 gcc_assert (GET_CODE (val) == CONST_INT || GET_MODE (val) == QImode);
4645 - if (GET_CODE (len) == CONST_INT && INTVAL (len) <= 257)
4646 + if (GET_CODE (len) == CONST_INT && INTVAL (len) > 0 && INTVAL (len) <= 257)
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 @@
4652 emit_move_insn (count, temp);
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);
4657 emit_move_insn (blocks, temp);
4659 @@ -3761,7 +3763,7 @@
4661 emit_move_insn (count, temp);
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);
4666 emit_move_insn (blocks, temp);
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)
4673 -/* Copyright (C) 2002, 2003, 2004, 2005, 2006
4674 +/* Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007
4675 Free Software Foundation, Inc.
4677 This file is part of GCC.
4680 # error "MMX instruction set not enabled"
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__));
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)
4695 -/* Copyright (C) 2002, 2003, 2004, 2005, 2006
4696 +/* Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007
4697 Free Software Foundation, Inc.
4699 This file is part of GCC.
4701 /* Get _mm_malloc () and _mm_free (). */
4702 #include <mm_malloc.h>
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__));
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)
4717 (define_insn "sse_vmaddv4sf3"
4718 [(set (match_operand:V4SF 0 "register_operand" "=x")
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"))
4726 (define_insn "sse_vmmulv4sf3"
4727 [(set (match_operand:V4SF 0 "register_operand" "=x")
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"))
4734 @@ -492,19 +492,6 @@
4735 [(set_attr "type" "sse")
4736 (set_attr "mode" "V4SF")])
4738 -(define_insn "*sse_vmsmaxv4sf3_finite"
4739 - [(set (match_operand:V4SF 0 "register_operand" "=x")
4741 - (smax:V4SF (match_operand:V4SF 1 "nonimmediate_operand" "%0")
4742 - (match_operand:V4SF 2 "nonimmediate_operand" "xm"))
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")])
4751 (define_insn "sse_vmsmaxv4sf3"
4752 [(set (match_operand:V4SF 0 "register_operand" "=x")
4754 @@ -547,19 +534,6 @@
4755 [(set_attr "type" "sse")
4756 (set_attr "mode" "V4SF")])
4758 -(define_insn "*sse_vmsminv4sf3_finite"
4759 - [(set (match_operand:V4SF 0 "register_operand" "=x")
4761 - (smin:V4SF (match_operand:V4SF 1 "nonimmediate_operand" "%0")
4762 - (match_operand:V4SF 2 "nonimmediate_operand" "xm"))
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")])
4771 (define_insn "sse_vmsminv4sf3"
4772 [(set (match_operand:V4SF 0 "register_operand" "=x")
4774 @@ -1398,7 +1372,7 @@
4775 (define_insn "sse2_vmaddv2df3"
4776 [(set (match_operand:V2DF 0 "register_operand" "=x")
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"))
4783 @@ -1454,7 +1428,7 @@
4784 (define_insn "sse2_vmmulv2df3"
4785 [(set (match_operand:V2DF 0 "register_operand" "=x")
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"))
4792 @@ -1544,19 +1518,6 @@
4793 [(set_attr "type" "sseadd")
4794 (set_attr "mode" "V2DF")])
4796 -(define_insn "*sse2_vmsmaxv2df3_finite"
4797 - [(set (match_operand:V2DF 0 "register_operand" "=x")
4799 - (smax:V2DF (match_operand:V2DF 1 "nonimmediate_operand" "%0")
4800 - (match_operand:V2DF 2 "nonimmediate_operand" "xm"))
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")])
4809 (define_insn "sse2_vmsmaxv2df3"
4810 [(set (match_operand:V2DF 0 "register_operand" "=x")
4812 @@ -1599,19 +1560,6 @@
4813 [(set_attr "type" "sseadd")
4814 (set_attr "mode" "V2DF")])
4816 -(define_insn "*sse2_vmsminv2df3_finite"
4817 - [(set (match_operand:V2DF 0 "register_operand" "=x")
4819 - (smin:V2DF (match_operand:V2DF 1 "nonimmediate_operand" "%0")
4820 - (match_operand:V2DF 2 "nonimmediate_operand" "xm"))
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")])
4829 (define_insn "sse2_vmsminv2df3"
4830 [(set (match_operand:V2DF 0 "register_operand" "=x")
4832 @@ -2778,7 +2726,7 @@
4833 [(set (match_operand:SSEMODE24 0 "register_operand" "=x")
4835 (match_operand:SSEMODE24 1 "register_operand" "0")
4836 - (match_operand:SI 2 "nonmemory_operand" "xi")))]
4837 + (match_operand:TI 2 "nonmemory_operand" "xn")))]
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")))]
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")
4853 (match_operand:SSEMODE248 1 "register_operand" "0")
4854 - (match_operand:SI 2 "nonmemory_operand" "xi")))]
4855 + (match_operand:TI 2 "nonmemory_operand" "xn")))]
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" "")))]
4863 - "ix86_fixup_binary_operands_no_copy (UMAX, V16QImode, operands);")
4864 + "ix86_fixup_binary_operands_no_copy (UMIN, V16QImode, operands);")
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)
4873 -/* Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
4874 +/* Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
4876 This file is part of GCC.
4879 typedef short __v8hi __attribute__ ((__vector_size__ (16)));
4880 typedef char __v16qi __attribute__ ((__vector_size__ (16)));
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__));
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);
4896 static __inline __m128i __attribute__((__always_inline__))
4897 _mm_slli_epi16 (__m128i __A, int __B)
4899 @@ -1115,7 +1118,16 @@
4901 return (__m128i)__builtin_ia32_psllqi128 ((__v2di)__A, __B);
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))
4913 static __inline __m128i __attribute__((__always_inline__))
4914 _mm_srai_epi16 (__m128i __A, int __B)
4916 @@ -1127,18 +1139,24 @@
4918 return (__m128i)__builtin_ia32_psradi128 ((__v4si)__A, __B);
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))
4928 static __m128i __attribute__((__always_inline__))
4929 -_mm_srli_si128 (__m128i __A, const int __B)
4930 +_mm_srli_si128 (__m128i __A, int __B)
4932 - return ((__m128i)__builtin_ia32_psrldqi128 (__A, __B))
4933 + return ((__m128i)__builtin_ia32_psrldqi128 (__A, __B * 8));
4936 static __m128i __attribute__((__always_inline__))
4937 -_mm_srli_si128 (__m128i __A, const int __B)
4938 +_mm_srli_si128 (__m128i __A, int __B)
4940 - return ((__m128i)__builtin_ia32_pslldqi128 (__A, __B))
4941 + return ((__m128i)__builtin_ia32_pslldqi128 (__A, __B * 8));
4944 #define _mm_srli_si128(__A, __B) \
4945 @@ -1147,6 +1165,7 @@
4946 ((__m128i)__builtin_ia32_pslldqi128 (__A, (__B) * 8))
4950 static __inline __m128i __attribute__((__always_inline__))
4951 _mm_srli_epi16 (__m128i __A, int __B)
4953 @@ -1164,53 +1183,61 @@
4955 return (__m128i)__builtin_ia32_psrlqi128 ((__v2di)__A, __B);
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))
4966 static __inline __m128i __attribute__((__always_inline__))
4967 _mm_sll_epi16 (__m128i __A, __m128i __B)
4969 - return _mm_slli_epi16 (__A, _mm_cvtsi128_si32 (__B));
4970 + return (__m128i)__builtin_ia32_psllw128((__v8hi)__A, (__v8hi)__B);
4973 static __inline __m128i __attribute__((__always_inline__))
4974 _mm_sll_epi32 (__m128i __A, __m128i __B)
4976 - return _mm_slli_epi32 (__A, _mm_cvtsi128_si32 (__B));
4977 + return (__m128i)__builtin_ia32_pslld128((__v4si)__A, (__v4si)__B);
4980 static __inline __m128i __attribute__((__always_inline__))
4981 _mm_sll_epi64 (__m128i __A, __m128i __B)
4983 - return _mm_slli_epi64 (__A, _mm_cvtsi128_si32 (__B));
4984 + return (__m128i)__builtin_ia32_psllq128((__v2di)__A, (__v2di)__B);
4987 static __inline __m128i __attribute__((__always_inline__))
4988 _mm_sra_epi16 (__m128i __A, __m128i __B)
4990 - return _mm_srai_epi16 (__A, _mm_cvtsi128_si32 (__B));
4991 + return (__m128i)__builtin_ia32_psraw128 ((__v8hi)__A, (__v8hi)__B);
4994 static __inline __m128i __attribute__((__always_inline__))
4995 _mm_sra_epi32 (__m128i __A, __m128i __B)
4997 - return _mm_srai_epi32 (__A, _mm_cvtsi128_si32 (__B));
4998 + return (__m128i)__builtin_ia32_psrad128 ((__v4si)__A, (__v4si)__B);
5001 static __inline __m128i __attribute__((__always_inline__))
5002 _mm_srl_epi16 (__m128i __A, __m128i __B)
5004 - return _mm_srli_epi16 (__A, _mm_cvtsi128_si32 (__B));
5005 + return (__m128i)__builtin_ia32_psrlw128 ((__v8hi)__A, (__v8hi)__B);
5008 static __inline __m128i __attribute__((__always_inline__))
5009 _mm_srl_epi32 (__m128i __A, __m128i __B)
5011 - return _mm_srli_epi32 (__A, _mm_cvtsi128_si32 (__B));
5012 + return (__m128i)__builtin_ia32_psrld128 ((__v4si)__A, (__v4si)__B);
5015 static __inline __m128i __attribute__((__always_inline__))
5016 _mm_srl_epi64 (__m128i __A, __m128i __B)
5018 - return _mm_srli_epi64 (__A, _mm_cvtsi128_si32 (__B));
5019 + return (__m128i)__builtin_ia32_psrlq128 ((__v2di)__A, (__v2di)__B);
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)
5029 "lock\;cmpxchg<doublemodesuffix>b\t%1")
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"))
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")]
5051 (clobber (reg:CC FLAGS_REG))]
5054 "lock\;cmpxchg<doublemodesuffix>b\t%1")
5056 +;; See above for the explanation of using the constraint "SD" for
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"))
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")]
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 },
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);
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);
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);
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);
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;
5124 + rtx op0, op1, target;
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);
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);
5143 /* Expand an expression EXP that calls a built-in function,
5144 @@ -16204,9 +16202,106 @@
5148 + case IX86_BUILTIN_PSLLWI128:
5149 + icode = CODE_FOR_ashlv8hi3;
5151 + case IX86_BUILTIN_PSLLDI128:
5152 + icode = CODE_FOR_ashlv4si3;
5154 + case IX86_BUILTIN_PSLLQI128:
5155 + icode = CODE_FOR_ashlv2di3;
5157 + case IX86_BUILTIN_PSRAWI128:
5158 + icode = CODE_FOR_ashrv8hi3;
5160 + case IX86_BUILTIN_PSRADI128:
5161 + icode = CODE_FOR_ashrv4si3;
5163 + case IX86_BUILTIN_PSRLWI128:
5164 + icode = CODE_FOR_lshrv8hi3;
5166 + case IX86_BUILTIN_PSRLDI128:
5167 + icode = CODE_FOR_lshrv4si3;
5169 + case IX86_BUILTIN_PSRLQI128:
5170 + icode = CODE_FOR_lshrv2di3;
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);
5178 + if (GET_CODE (op1) != CONST_INT)
5180 + error ("shift must be an immediate");
5181 + return const0_rtx;
5183 + if (INTVAL (op1) < 0 || INTVAL (op1) > 255)
5184 + op1 = GEN_INT (255);
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);
5191 + target = gen_reg_rtx (tmode);
5192 + pat = GEN_FCN (icode) (target, op0, op1);
5198 + case IX86_BUILTIN_PSLLW128:
5199 + icode = CODE_FOR_ashlv8hi3;
5201 + case IX86_BUILTIN_PSLLD128:
5202 + icode = CODE_FOR_ashlv4si3;
5204 + case IX86_BUILTIN_PSLLQ128:
5205 + icode = CODE_FOR_ashlv2di3;
5207 + case IX86_BUILTIN_PSRAW128:
5208 + icode = CODE_FOR_ashrv8hi3;
5210 + case IX86_BUILTIN_PSRAD128:
5211 + icode = CODE_FOR_ashrv4si3;
5213 + case IX86_BUILTIN_PSRLW128:
5214 + icode = CODE_FOR_lshrv8hi3;
5216 + case IX86_BUILTIN_PSRLD128:
5217 + icode = CODE_FOR_lshrv4si3;
5219 + case IX86_BUILTIN_PSRLQ128:
5220 + icode = CODE_FOR_lshrv2di3;
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);
5228 + tmode = insn_data[icode].operand[0].mode;
5229 + mode1 = insn_data[icode].operand[1].mode;
5231 + if (! (*insn_data[icode].operand[1].predicate) (op0, mode1))
5232 + op0 = copy_to_reg (op0);
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);
5238 + target = gen_reg_rtx (tmode);
5239 + pat = GEN_FCN (icode) (target, op0, op1);
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 @@
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),
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)
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.
5271 ;; This file is part of GCC.
5274 (and (match_code "reg")
5275 (match_test "REGNO (op) == REG_SP")))
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)")))
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)")))
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)")))
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)")))
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)
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)
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"))]
5322 "st %a0+,__zero_reg__
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"))]
5332 if (which_alternative==0)
5333 @@ -2364,7 +2364,7 @@
5335 (match_operator 0 "eqne_operator"
5337 - (mem:QI (match_operand 1 "higth_io_address_operand" "n"))
5338 + (mem:QI (match_operand 1 "high_io_address_operand" "n"))
5340 (match_operand 2 "const_int_operand" "n"))
5342 @@ -2385,7 +2385,7 @@
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"))
5349 (label_ref (match_operand 2 "" ""))
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)
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)
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" }
5374 +/* These names are used as the index into the avr_arch_types[] table
5389 const char *const name;
5390 int arch; /* index in avr_arch_types[] */
5391 @@ -164,103 +178,103 @@
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__" },
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 }
5586 int avr_case_values_threshold = 30000;
5588 const struct mcu_type_s *t;
5589 const struct base_arch_s *base;
5591 + flag_delete_null_pointer_checks = 0;
5593 for (t = avr_mcu_types; t->name; t++)
5594 if (strcmp (t->name, avr_mcu_name) == 0)
5596 @@ -1025,7 +1041,7 @@
5597 case REG_Y: return "Y";
5598 case REG_Z: return "Z";
5600 - gcc_unreachable ();
5601 + output_operand_lossage ("address operand requires constraint for X, Y, or Z register");
5605 @@ -4698,7 +4714,7 @@
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);
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);
5622 @@ -5100,6 +5117,7 @@
5623 *total = COSTS_N_INSNS (AVR_MEGA ? 2 : 1);
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))
5638 -#define ASM_OUTPUT_ALIGN(STREAM, POWER)
5639 +#define ASM_OUTPUT_ALIGN(STREAM, POWER) \
5641 + if ((POWER) > 1) \
5642 + fprintf (STREAM, "\t.p2align\t%d\n", POWER); \
5645 #define CASE_VECTOR_MODE HImode
5648 mmcu=at76*:-m avr3}\
5653 - mmcu=at90pwm3:-m avr4}\
5654 + mmcu=at90pwm*:-m avr4}\
5658 @@ -771,18 +773,14 @@
5659 mmcu=at94k:-m avr5}\
5662 - mmcu=atmega3250*|\
5664 - mmcu=atmega3290*|\
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)
5685 /* This says how to output an assembler line to define a global common
5688 -#undef ASM_OUTPUT_ALIGNED_COMMON
5689 #define ASM_OUTPUT_COMMON(FILE, NAME, SIZE, ROUNDED) \
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 @@
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. */
5705 #undef MAX_OFILE_ALIGNMENT
5706 -#define MAX_OFILE_ALIGNMENT 0x8000
5707 +#define MAX_OFILE_ALIGNMENT (0x8000 * 8)
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)
5721 + la r8, __bss_start
5722 + la r9, __bss_end__
5732 + la r8, __bss_start
5733 + la r9, __bss_end__
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)
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"
5748 if (mdx_unaligned_load (operands))
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"
5757 if (mdx_unaligned_store (operands))
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"
5766 if (mdx_unaligned_load (operands))
5769 (match_operand:BLK 1 "general_operand"))
5770 (use (match_operand:SI 2 ""))
5771 (use (match_operand:SI 3 "const_int_operand"))])]
5773 + "!TARGET_SCORE5U && TARGET_ULS"
5775 if (mdx_block_move (operands))
5778 (match_operand:SI 2 "const_simm12" "")))
5779 (set (match_operand:QI 3 "register_operand" "=d")
5780 (mem:QI (match_dup 1)))]
5784 [(set_attr "type" "load")
5785 (set_attr "mode" "QI")])
5787 (match_operand:SI 2 "const_simm12" "")))
5788 (set (match_operand:HI 3 "register_operand" "=d")
5789 (mem:HI (match_dup 1)))]
5793 [(set_attr "type" "load")
5794 (set_attr "mode" "HI")])
5796 (match_operand:SI 2 "const_simm12" "")))
5797 (set (match_operand:SI 3 "register_operand" "=d")
5798 (mem:SI (match_dup 1)))]
5802 [(set_attr "type" "load")
5803 (set_attr "mode" "SI")])
5805 (match_operand:SI 2 "const_simm12" "")))
5806 (set (mem:QI (match_dup 1))
5807 (match_operand:QI 3 "register_operand" "d"))]
5811 [(set_attr "type" "store")
5812 (set_attr "mode" "QI")])
5814 (match_operand:SI 2 "const_simm12" "")))
5815 (set (mem:HI (match_dup 1))
5816 (match_operand:HI 3 "register_operand" "d"))]
5820 [(set_attr "type" "store")
5821 (set_attr "mode" "HI")])
5823 (match_operand:SI 2 "const_simm12" "")))
5824 (set (mem:SI (match_dup 1))
5825 (match_operand:SI 3 "register_operand" "d"))]
5829 [(set_attr "type" "store")
5830 (set_attr "mode" "SI")])
5832 (set (match_operand:QI 3 "register_operand" "=d")
5833 (mem:QI (plus:SI (match_dup 1)
5838 [(set_attr "type" "load")
5839 (set_attr "mode" "QI")])
5841 (set (match_operand:HI 3 "register_operand" "=d")
5842 (mem:HI (plus:SI (match_dup 1)
5847 [(set_attr "type" "load")
5848 (set_attr "mode" "HI")])
5850 (set (match_operand:SI 3 "register_operand" "=d")
5851 (mem:SI (plus:SI (match_dup 1)
5856 [(set_attr "type" "load")
5857 (set_attr "mode" "SI")])
5859 (set (mem:QI (plus:SI (match_dup 1)
5861 (match_operand:QI 3 "register_operand" "d"))]
5865 [(set_attr "type" "store")
5866 (set_attr "mode" "QI")])
5868 (set (mem:HI (plus:SI (match_dup 1)
5870 (match_operand:HI 3 "register_operand" "d"))]
5874 [(set_attr "type" "store")
5875 (set_attr "mode" "HI")])
5877 (set (mem:SI (plus:SI (match_dup 1)
5879 (match_operand:SI 3 "register_operand" "d"))]
5883 [(set_attr "type" "store")
5884 (set_attr "mode" "SI")])
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"
5892 [(set_attr "type" "load")
5893 (set_attr "mode" "SI")])
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"
5901 [(set_attr "type" "load")
5902 (set_attr "mode" "SI")])
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"
5910 [(set_attr "type" "load")
5911 (set_attr "mode" "SI")])
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"
5919 [(set_attr "type" "store")
5920 (set_attr "mode" "SI")])
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"
5928 [(set_attr "type" "store")
5929 (set_attr "mode" "SI")])
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"
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)
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")))]
5948 + "TARGET_MAC || TARGET_SCORE7D"
5950 [(set_attr "type" "arith")
5951 (set_attr "mode" "SI")])
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")))]
5957 + "TARGET_MAC || TARGET_SCORE7D"
5959 [(set_attr "type" "arith")
5960 (set_attr "mode" "SI")])
5962 (define_insn "abssi2"
5963 [(set (match_operand:SI 0 "register_operand" "=d")
5964 (abs:SI (match_operand:SI 1 "register_operand" "d")))]
5966 + "TARGET_MAC || TARGET_SCORE7D"
5968 [(set_attr "type" "arith")
5969 (set_attr "mode" "SI")])
5971 (define_insn "clzsi2"
5972 [(set (match_operand:SI 0 "register_operand" "=d")
5973 (clz:SI (match_operand:SI 1 "register_operand" "d")))]
5975 + "TARGET_MAC || TARGET_SCORE7D"
5977 [(set_attr "type" "arith")
5978 (set_attr "mode" "SI")])
5981 [(set (match_operand:SI 0 "register_operand" "=d")
5982 (unspec:SI [(match_operand:SI 1 "register_operand" "d")] SFFS))]
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")])
5989 (define_expand "ffssi2"
5990 [(set (match_operand:SI 0 "register_operand")
5991 (ffs:SI (match_operand:SI 1 "register_operand")))]
5993 + "TARGET_MAC || TARGET_SCORE7D"
5995 emit_insn (gen_sffs (operands[0], operands[1]));
5996 emit_insn (gen_rtx_SET (VOIDmode, gen_rtx_REG (CC_NZmode, CC_REGNUM),
5998 (match_operand:SI 1 "register_operand" ""))
5999 (set (match_operand:SI 2 "hireg_operand" "")
6000 (match_operand:SI 3 "register_operand" ""))]
6002 + "TARGET_MAC || TARGET_SCORE7D"
6004 [(set (match_dup 0) (match_dup 1))
6005 (set (match_dup 2) (match_dup 3))])])
6007 (match_operand:SI 1 "register_operand" ""))
6008 (set (match_operand:SI 2 "loreg_operand" "")
6009 (match_operand:SI 3 "register_operand" ""))]
6011 + "TARGET_MAC || TARGET_SCORE7D"
6013 [(set (match_dup 2) (match_dup 3))
6014 (set (match_dup 0) (match_dup 1))])])
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"))])]
6020 + "TARGET_MAC || TARGET_SCORE7D"
6022 [(set_attr "type" "fce")
6023 (set_attr "mode" "SI")])
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))]
6029 + "TARGET_MAC || TARGET_SCORE7D"
6032 mtcel%S1 %1\;mad %2, %3
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))]
6038 + "TARGET_MAC || TARGET_SCORE7D"
6041 mtcel%S1 %1\;msb %2, %3
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")))]
6047 + "TARGET_MAC || TARGET_SCORE7D"
6049 [(set_attr "mode" "DI")])
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")))]
6056 + "TARGET_MAC || TARGET_SCORE7D"
6058 [(set_attr "mode" "DI")])
6062 (sign_extend:DI (match_operand:SI 2 "register_operand" "%d"))
6063 (sign_extend:DI (match_operand:SI 3 "register_operand" "d")))))]
6065 + "TARGET_MAC || TARGET_SCORE7D"
6067 [(set_attr "mode" "DI")])
6070 (match_operand:SI 2 "register_operand" "%d"))
6072 (match_operand:SI 3 "register_operand" "d")))))]
6074 + "TARGET_MAC || TARGET_SCORE7D"
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)
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*}"
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 }
6096 +/* Macro to conditionally modify fixed_regs/call_used_regs. */
6097 +#define PIC_OFFSET_TABLE_REGNUM 29
6099 +#define CONDITIONAL_REGISTER_USAGE \
6102 + fixed_regs[PIC_OFFSET_TABLE_REGNUM] = \
6103 + call_used_regs[PIC_OFFSET_TABLE_REGNUM] = 0; \
6106 #define HARD_REGNO_NREGS(REGNO, MODE) \
6107 ((GET_MODE_SIZE (MODE) + UNITS_PER_WORD - 1) / UNITS_PER_WORD)
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
6116 #define RETURN_POPS_ARGS(FUNDECL, FUNTYPE, STACK_SIZE) 0
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
6129 if (INTVAL (operands[3]) > 1)
6131 @@ -1539,6 +1539,6 @@
6133 (clobber (reg:CC CC_REGNUM))
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)
6144 Target RejectNegative Report Mask(LITTLE_ENDIAN)
6145 Generate little-endian code
6148 +Target RejectNegative Report Mask(NHWLOOP)
6149 +Disable bcnz instruction
6152 +Target RejectNegative Report Mask(ULS)
6153 +Enable unaligned load/store instruction
6156 Target RejectNegative Report Mask(MAC)
6157 Enable mac instruction
6160 +Target RejectNegative Report Mask(SCORE5)
6161 +Support SCORE 5 ISA
6164 Target RejectNegative Report Mask(SCORE5U)
6165 Support SCORE 5U ISA
6167 Target RejectNegative Report Mask(SCORE7)
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)
6178 #define DEFAULT_SIGNED_CHAR 0
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}"
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);
6194 - if (cfun && !cfun->machine->in_nsubspa)
6195 + if (cfun && cfun->machine && !cfun->machine->in_nsubspa)
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);
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)
6214 /* The linker can generate branch islands. */
6215 #define DARWIN_LINKER_GENERATES_ISLANDS 1
6217 +#undef ASM_OUTPUT_ALIGNED_COMMON
6218 +#define ASM_OUTPUT_ALIGNED_COMMON(FILE, NAME, SIZE, ALIGN) \
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)); \
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 @@
6235 - /* Clean up invalid ASMs so that they don't confuse later passes.
6237 - if (asm_noperands (PATTERN (insn)) >= 0)
6239 - extract_insn (insn);
6240 - if (!constrain_operands (1))
6242 - error_for_asm (insn,
6243 - "%<asm%> operand has impossible constraints");
6244 - delete_insn (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));
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);
6260 + /* Clean up invalid ASMs so that they don't confuse later passes.
6262 + if (asm_noperands (PATTERN (insn)) >= 0)
6264 + extract_insn (insn);
6265 + if (!constrain_operands (1))
6267 + error_for_asm (insn,
6268 + "%<asm%> operand has impossible constraints");
6269 + delete_insn (insn);
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)
6281 // Versatile string utility -*- C++ -*-
6283 -// Copyright (C) 2005, 2006 Free Software Foundation, Inc.
6284 +// Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
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
6289 #include <bits/functexcept.h>
6291 #include <algorithm> // For std::distance, srd::search.
6292 +#include <bits/ostream_insert.h>
6294 _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
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)
6301 // Versatile string -*- C++ -*-
6303 -// Copyright (C) 2005, 2006 Free Software Foundation, Inc.
6304 +// Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
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 @@
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)
6319 + // _GLIBCXX_RESOLVE_LIB_DEFECTS
6320 + // 586. string inserter not a formatted function
6321 + return __ostream_insert(__os, __str.data(), __str.size());
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)
6332 #include <tr1/type_traits>
6333 #include <ext/type_traits.h>
6334 +#include <ext/numeric_traits.h>
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)
6345 +// Copyright (C) 2007 Free Software Foundation, Inc.
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
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.
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,
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
6373 +/** @file ext/numeric_traits.h
6374 + * This file is a GNU extension to the Standard C++ Library.
6377 +#ifndef _EXT_NUMERIC_TRAITS
6378 +#define _EXT_NUMERIC_TRAITS 1
6380 +#pragma GCC system_header
6383 +#include <bits/cpp_type_traits.h>
6384 +#include <ext/type_traits.h>
6386 +_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
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))
6394 +#define __glibcxx_min(_Tp) \
6395 + (__glibcxx_signed(_Tp) ? (_Tp)1 << __glibcxx_digits(_Tp) : (_Tp)0)
6397 +#define __glibcxx_max(_Tp) \
6398 + (__glibcxx_signed(_Tp) ? \
6399 + (((((_Tp)1 << (__glibcxx_digits(_Tp) - 1)) - 1) << 1) + 1) : ~(_Tp)0)
6401 + template<typename _Value>
6402 + struct __numeric_traits_integer
6404 + // Only integers for initialization of member constant.
6405 + static const _Value __min = __glibcxx_min(_Value);
6406 + static const _Value __max = __glibcxx_max(_Value);
6409 + template<typename _Value>
6410 + const _Value __numeric_traits_integer<_Value>::__min;
6412 + template<typename _Value>
6413 + const _Value __numeric_traits_integer<_Value>::__max;
6415 + template<typename _Value>
6416 + struct __numeric_traits_floating
6418 + // Only floating point types. See N1822.
6419 + static const int __max_digits10 =
6420 + 2 + std::numeric_limits<_Value>::digits * 3010/10000;
6423 + template<typename _Value>
6424 + const int __numeric_traits_floating<_Value>::__max_digits10;
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
6433 +_GLIBCXX_END_NAMESPACE
6435 +#undef __glibcxx_signed
6436 +#undef __glibcxx_min
6437 +#undef __glibcxx_max
6438 +#undef __glibcxx_digits
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)
6448 -// Copyright (C) 2005, 2006 Free Software Foundation, Inc.
6449 +// Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
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
6458 -#include <iosfwd> // std::streamsize
6459 #include <bits/cpp_type_traits.h>
6461 _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
6462 @@ -150,51 +148,6 @@
6464 struct __remove_unsigned<wchar_t>;
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))
6473 -#define __glibcxx_min(_Tp) \
6474 - (__glibcxx_signed(_Tp) ? (_Tp)1 << __glibcxx_digits(_Tp) : (_Tp)0)
6476 -#define __glibcxx_max(_Tp) \
6477 - (__glibcxx_signed(_Tp) ? ((_Tp)1 << __glibcxx_digits(_Tp)) - 1 : ~(_Tp)0)
6479 - template<typename _Value>
6480 - struct __numeric_traits_integer
6482 - // Only integers for initialization of member constant.
6483 - static const _Value __min = __glibcxx_min(_Value);
6484 - static const _Value __max = __glibcxx_max(_Value);
6487 - template<typename _Value>
6488 - const _Value __numeric_traits_integer<_Value>::__min;
6490 - template<typename _Value>
6491 - const _Value __numeric_traits_integer<_Value>::__max;
6493 - template<typename _Value>
6494 - struct __numeric_traits_floating
6496 - // Only floating point types. See N1822.
6497 - static const std::streamsize __max_digits10 =
6498 - 2 + std::numeric_limits<_Value>::digits * 3010/10000;
6501 - template<typename _Value>
6502 - const std::streamsize __numeric_traits_floating<_Value>::__max_digits10;
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
6511 _GLIBCXX_END_NAMESPACE
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)
6519 // Versatile string -*- C++ -*-
6521 -// Copyright (C) 2005, 2006 Free Software Foundation, Inc.
6522 +// Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
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
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 @@
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)
6544 - typedef basic_ostream<_CharT, _Traits> __ostream_type;
6546 - typename __ostream_type::sentry __cerb(__out);
6549 - const streamsize __w = __out.width();
6550 - streamsize __len = static_cast<streamsize>(__str.size());
6551 - const _CharT* __s = __str.data();
6553 - // _GLIBCXX_RESOLVE_LIB_DEFECTS
6554 - // 25. String operator<< uses width() value wrong
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);
6564 - __out._M_write(__s, __len);
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)
6580 // Map implementation -*- C++ -*-
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.
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
6590 * Insertion requires logarithmic time.
6592 - std::pair<iterator,bool>
6593 + std::pair<iterator, bool>
6594 insert(const value_type& __x)
6595 { return _M_t._M_insert_unique(__x); }
6598 * Insertion requires logarithmic time (if the hint is not taken).
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); }
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)
6613 // Components for manipulating sequences of characters -*- C++ -*-
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,
6618 // Free Software Foundation, Inc.
6620 // This file is part of the GNU ISO C++ Library. This library is free
6621 @@ -2400,7 +2401,7 @@
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());
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 @@
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)
6641 - sentry __cerb(*this);
6646 - const streamsize __w = this->width();
6649 - const bool __left = ((this->flags() & ios_base::adjustfield)
6650 - == ios_base::left);
6652 - _M_write(this->fill(), __w - __n);
6654 - _M_write(__s, __n);
6655 - if (__left && this->good())
6656 - _M_write(this->fill(), __w - __n);
6659 - _M_write(__s, __n);
6663 - { this->_M_setstate(ios_base::badbit); }
6668 - template<typename _CharT, typename _Traits>
6669 - basic_ostream<_CharT, _Traits>&
6670 operator<<(basic_ostream<_CharT, _Traits>& __out, const char* __s)
6677 - __out._M_insert(__ws, __clen);
6678 + __ostream_insert(__out, __ws, __clen);
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);
6688 extern template ostream& ostream::_M_insert(long);
6689 extern template ostream& ostream::_M_insert(unsigned long);
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*,
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)
6704 // Components for manipulating sequences of characters -*- C++ -*-
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,
6709 // Free Software Foundation, Inc.
6711 // This file is part of the GNU ISO C++ Library. This library is free
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)
6726 +// Helpers for ostream inserters -*- C++ -*-
6728 +// Copyright (C) 2007 Free Software Foundation, Inc.
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.
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.
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,
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.
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.
6760 +#ifndef _OSTREAM_INSERT_H
6761 +#define _OSTREAM_INSERT_H 1
6763 +#pragma GCC system_header
6767 +_GLIBCXX_BEGIN_NAMESPACE(std)
6769 + template<typename _CharT, typename _Traits>
6771 + __ostream_write(basic_ostream<_CharT, _Traits>& __out,
6772 + const _CharT* __s, streamsize __n)
6774 + typedef basic_ostream<_CharT, _Traits> __ostream_type;
6775 + typedef typename __ostream_type::ios_base __ios_base;
6777 + const streamsize __put = __out.rdbuf()->sputn(__s, __n);
6779 + __out.setstate(__ios_base::badbit);
6782 + template<typename _CharT, typename _Traits>
6784 + __ostream_fill(basic_ostream<_CharT, _Traits>& __out, streamsize __n)
6786 + typedef basic_ostream<_CharT, _Traits> __ostream_type;
6787 + typedef typename __ostream_type::ios_base __ios_base;
6789 + const _CharT __c = __out.fill();
6790 + for (; __n > 0; --__n)
6792 + const typename _Traits::int_type __put = __out.rdbuf()->sputc(__c);
6793 + if (_Traits::eq_int_type(__put, _Traits::eof()))
6795 + __out.setstate(__ios_base::badbit);
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)
6806 + typedef basic_ostream<_CharT, _Traits> __ostream_type;
6807 + typedef typename __ostream_type::ios_base __ios_base;
6809 + typename __ostream_type::sentry __cerb(__out);
6814 + const streamsize __w = __out.width();
6817 + const bool __left = ((__out.flags()
6818 + & __ios_base::adjustfield)
6819 + == __ios_base::left);
6821 + __ostream_fill(__out, __w - __n);
6823 + __ostream_write(__out, __s, __n);
6824 + if (__left && __out.good())
6825 + __ostream_fill(__out, __w - __n);
6828 + __ostream_write(__out, __s, __n);
6832 + { __out._M_setstate(__ios_base::badbit); }
6837 +_GLIBCXX_END_NAMESPACE
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)
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 \
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)
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>
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)
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 \
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)
6897 // Components for manipulating sequences of characters -*- C++ -*-
6899 -// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005
6900 +// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
6902 // Free Software Foundation, Inc.
6904 // This file is part of the GNU ISO C++ Library. This library is free
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)
6918 // Output streams -*- C++ -*-
6920 -// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2006
6921 +// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
6923 // Free Software Foundation, Inc.
6925 // This file is part of the GNU ISO C++ Library. This library is free
6927 #pragma GCC system_header
6930 +#include <bits/ostream_insert.h>
6932 _GLIBCXX_BEGIN_NAMESPACE(std)
6936 typedef ctype<_CharT> __ctype_type;
6938 - template<typename _CharT2, typename _Traits2>
6939 - friend basic_ostream<_CharT2, _Traits2>&
6940 - operator<<(basic_ostream<_CharT2, _Traits2>&, _CharT2);
6942 - template<typename _Traits2>
6943 - friend basic_ostream<char, _Traits2>&
6944 - operator<<(basic_ostream<char, _Traits2>&, char);
6946 - template<typename _CharT2, typename _Traits2>
6947 - friend basic_ostream<_CharT2, _Traits2>&
6948 - operator<<(basic_ostream<_CharT2, _Traits2>&, const _CharT2*);
6950 - template<typename _Traits2>
6951 - friend basic_ostream<char, _Traits2>&
6952 - operator<<(basic_ostream<char, _Traits2>&, const char*);
6954 - template<typename _CharT2, typename _Traits2>
6955 - friend basic_ostream<_CharT2, _Traits2>&
6956 - operator<<(basic_ostream<_CharT2, _Traits2>&, const char*);
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>&);
6963 // [27.6.2.2] constructor/destructor
6965 * @brief Base constructor.
6966 @@ -318,20 +295,6 @@
6967 this->setstate(ios_base::badbit);
6971 - _M_write(char_type __c, streamsize __n)
6973 - for (; __n > 0; --__n)
6975 - const int_type __put = this->rdbuf()->sputc(__c);
6976 - if (traits_type::eq_int_type(__put, traits_type::eof()))
6978 - this->setstate(ios_base::badbit);
6985 * @brief Character string insertion.
6986 * @param s The array to insert.
6988 template<typename _ValueT>
6990 _M_insert(_ValueT __v);
6993 - _M_insert(const char_type* __s, streamsize __n);
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); }
7004 template<typename _CharT, typename _Traits>
7005 inline basic_ostream<_CharT, _Traits>&
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); }
7013 // Signed and unsigned
7014 template<class _Traits>
7017 __out.setstate(ios_base::badbit);
7019 - __out._M_insert(__s, static_cast<streamsize>(_Traits::length(__s)));
7020 + __ostream_insert(__out, __s,
7021 + static_cast<streamsize>(_Traits::length(__s)));
7027 __out.setstate(ios_base::badbit);
7029 - __out._M_insert(__s, static_cast<streamsize>(_Traits::length(__s)));
7030 + __ostream_insert(__out, __s,
7031 + static_cast<streamsize>(_Traits::length(__s)));
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)
7040 +2007-04-12 Paolo Carlini <pcarlini@suse.de>
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*)):
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.
7069 +2007-04-07 Paolo Carlini <pcarlini@suse.de>
7071 + PR libstdc++/31481
7072 + * include/ext/type_traits.h (__numeric_traits): Move...
7073 + * include/ext/numeric_traits.h: ... here; fix type of
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:
7086 + * testsuite/ext/type_traits/remove_unsigned_floating_neg.cc:
7088 + * testsuite/ext/type_traits/add_unsigned_integer_neg.cc:
7091 +2007-04-03 Paolo Carlini <pcarlini@suse.de>
7093 + * include/bits/stl_map.h (map<>::insert(iterator, const value_type&):
7096 +2007-04-02 Paolo Carlini <pcarlini@suse.de>
7098 + PR libstdc++/31401 (vstring bits)
7099 + * include/ext/vstring.tcc (find(const _CharT*, size_type,
7100 + size_type)): Avoid unsigned overflow.
7102 +2007-03-30 Paolo Carlini <pcarlini@suse.de>
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.
7110 2007-03-06 Paolo Carlini <pcarlini@suse.de>
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)
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);
7123 template ostream& ostream::_M_insert(long);
7124 template ostream& ostream::_M_insert(unsigned long);
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);
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)
7138 +// 2007-03-30 Paolo Carlini <pcarlini@suse.de>
7140 +// Copyright (C) 2007 Free Software Foundation, Inc.
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.
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.
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,
7158 +// 21.3.6.1 basic_string find
7161 +#include <testsuite_hooks.h>
7166 + bool test __attribute__((unused)) = true;
7167 + typedef std::wstring::size_type csize_type;
7168 + csize_type npos = std::wstring::npos;
7170 + std::wstring use = L"anu";
7171 + csize_type pos1 = use.find(L"a", npos);
7173 + VERIFY( pos1 == npos );
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)
7186 +// 2007-03-30 Paolo Carlini <pcarlini@suse.de>
7188 +// Copyright (C) 2007 Free Software Foundation, Inc.
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.
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.
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,
7206 +// 21.3.6.1 basic_string find
7209 +#include <testsuite_hooks.h>
7214 + bool test __attribute__((unused)) = true;
7215 + typedef std::string::size_type csize_type;
7216 + csize_type npos = std::string::npos;
7218 + std::string use = "anu";
7219 + csize_type pos1 = use.find("a", npos);
7221 + VERIFY( pos1 == npos );
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)
7234 +// { dg-do compile }
7235 +// { dg-options "-pedantic" }
7238 +// Copyright (C) 2006 Free Software Foundation, Inc.
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.
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.
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,
7256 +#include <ext/numeric_traits.h>
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)
7267 +// 2007-04-09 Paolo Carlini <pcarlini@suse.de>
7269 +// Copyright (C) 2007 Free Software Foundation
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.
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.
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,
7289 +#include <ext/vstring.h>
7290 +#include <testsuite_hooks.h>
7295 + using namespace std;
7296 + bool test __attribute__((unused)) = true;
7298 + wostringstream oss_01;
7299 + const __gnu_cxx::__wvstring str_01(50, L'a');
7301 + oss_01.width(5000000);
7302 + const streamsize width = oss_01.width();
7306 + VERIFY( oss_01.good() );
7307 + VERIFY( oss_01.str().size() == width );
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)
7320 +// 2007-04-09 Paolo Carlini <pcarlini@suse.de>
7322 +// Copyright (C) 2007 Free Software Foundation
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.
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.
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,
7342 +#include <ext/vstring.h>
7343 +#include <testsuite_hooks.h>
7348 + using namespace std;
7349 + bool test __attribute__((unused)) = true;
7351 + ostringstream oss_01;
7352 + const __gnu_cxx::__vstring str_01(50, 'a');
7354 + oss_01.width(20000000);
7355 + const streamsize width = oss_01.width();
7359 + VERIFY( oss_01.good() );
7360 + VERIFY( oss_01.str().size() == width );
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)
7373 -// { dg-do compile }
7374 -// { dg-options "-pedantic" }
7377 -// Copyright (C) 2006 Free Software Foundation, Inc.
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.
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.
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,
7395 -#include <ext/type_traits.h>
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)
7406 // { dg-do compile }
7409 -// Copyright (C) 2006 Free Software Foundation, Inc.
7410 +// Copyright (C) 2006, 2007 Free Software Foundation, Inc.
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
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)
7425 // { dg-do compile }
7428 -// Copyright (C) 2006 Free Software Foundation, Inc.
7429 +// Copyright (C) 2006, 2007 Free Software Foundation, Inc.
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
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)
7445 // { dg-do compile }
7448 -// Copyright (C) 2006 Free Software Foundation, Inc.
7449 +// Copyright (C) 2006, 2007 Free Software Foundation, Inc.
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
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)
7465 // { dg-do compile }
7468 -// Copyright (C) 2006 Free Software Foundation, Inc.
7469 +// Copyright (C) 2006, 2007 Free Software Foundation, Inc.
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
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)
7485 _ZSt21__copy_streambufs_eofI[cw]St11char_traitsI[cw]EE[il]PSt15basic_streambuf*;
7487 - _ZNSo9_M_insertEPKc[il];
7488 - _ZNSt13basic_ostreamIwSt11char_traitsIwEE9_M_insertEPKw[il];
7489 + _ZSt16__ostream_insert*;
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 @@
7501 -for ac_func in wait setmode gettimeofday
7505 +for ac_func in wait setmode gettimeofday stat fstat lstat
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)
7520 /* SUBROUTINE STAT(FILE, SARRAY, STATUS)
7521 CHARACTER(len=*), INTENT(IN) :: FILE
7522 INTEGER, INTENT(OUT), :: SARRAY(13)
7524 memcpy (str, name, name_len);
7525 str[name_len] = '\0';
7527 + /* On platforms that don't provide lstat(), we use stat() instead. */
7530 val = lstat(str, &sb);
7533 val = stat(str, &sb);
7536 @@ -204,9 +210,12 @@
7537 memcpy (str, name, name_len);
7538 str[name_len] = '\0';
7540 + /* On platforms that don't provide lstat(), we use stat() instead. */
7543 val = lstat(str, &sb);
7546 val = stat(str, &sb);
7549 @@ -319,13 +328,13 @@
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
7559 - FUNCTION STAT(FILE, SARRAY)
7561 + FUNCTION LSTAT(FILE, SARRAY)
7563 CHARACTER(len=*), INTENT(IN) :: FILE
7564 INTEGER, INTENT(OUT), :: SARRAY(13) */
7566 @@ -351,8 +360,11 @@
7575 /* SUBROUTINE FSTAT(UNIT, SARRAY, STATUS)
7576 INTEGER, INTENT(IN) :: UNIT
7577 INTEGER, INTENT(OUT) :: SARRAY(13)
7579 fstat_i8_sub (unit, sarray, &val);
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)
7589 +2007-04-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
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.
7595 +2007-04-13 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
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.
7605 2007-03-15 Jerry DeLisle <jvdelisle@gcc.gnu.org>
7607 PR libgfortran/31099
7609 * io/file_pos.c (st_rewind): Don't set bytes_left to zero.
7611 +2007-03-14 Jakub Jelinek <jakub@redhat.com>
7613 + * io/unix.c (regular_file): For ACTION_UNSPECIFIED retry with
7614 + O_RDONLY even if errno is EROFS.
7616 2007-03-09 Jerry DeLisle <jvdelisle@gcc.gnu.org>
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)
7623 /* libm includes frexpl */
7626 +/* Define to 1 if you have the `fstat' function. */
7629 /* Define to 1 if you have the `ftruncate' function. */
7630 #undef HAVE_FTRUNCATE
7633 /* libm includes logl */
7636 +/* Define to 1 if you have the `lstat' function. */
7639 /* Define to 1 if you have the <math.h> header file. */
7643 /* libm includes sqrtl */
7646 +/* Define to 1 if you have the `stat' function. */
7649 /* Define to 1 if you have the <stddef.h> header file. */
7650 #undef HAVE_STDDEF_H
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)
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)
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 @@
7672 case STATUS_REPLACE:
7673 - crflag = O_CREAT | O_TRUNC;
7674 + crflag = O_CREAT | O_TRUNC;
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)
7687 flags->action = ACTION_READWRITE;
7690 - if (errno != EACCES)
7691 + if (errno != EACCES && errno != EROFS)
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)
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);
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__)'
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 @@
7727 # Also AC_SUBST this variable for ffi.h.
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
7738 cat >>confdefs.h <<\_ACEOF
7739 #define HAVE_LONG_DOUBLE 1
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;
7757 +#if @HAVE_LONG_DOUBLE@
7758 +extern ffi_type ffi_type_longdouble;
7760 +#define ffi_type_longdouble ffi_type_double
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)
7772 #include <ffi_common.h>
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
7785 +# undef FFI_TYPE_LONGDOUBLE
7786 +# define FFI_TYPE_LONGDOUBLE 4
7789 +extern void ffi_call_osf(void *, unsigned long, unsigned, void *, void (*)())
7791 +extern void ffi_closure_osf(void) FFI_HIDDEN;
7795 ffi_prep_cif_machdep(ffi_cif *cif)
7798 cif->flags = cif->rtype->type;
7801 + case FFI_TYPE_LONGDOUBLE:
7802 + /* 128-bit long double is returned in memory, like a struct. */
7803 + cif->flags = FFI_TYPE_STRUCT;
7807 cif->flags = FFI_TYPE_INT;
7815 ffi_call(ffi_cif *cif, void (*fn)(), void *rvalue, void **avalue)
7819 ffi_type **arg_types;
7821 - FFI_ASSERT (cif->abi == FFI_OSF);
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)
7830 + size_t size = (*arg_types)->size;
7832 switch ((*arg_types)->type)
7834 case FFI_TYPE_SINT8:
7835 @@ -129,6 +146,12 @@
7836 *(double *) argp = *(double *)(* avalue);
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 *);
7845 case FFI_TYPE_STRUCT:
7846 memcpy(argp, *avalue, (*arg_types)->size);
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++;
7859 unsigned int *tramp;
7861 - FFI_ASSERT (cif->abi == FFI_OSF);
7863 tramp = (unsigned int *) &closure->tramp[0];
7864 tramp[0] = 0x47fb0401; /* mov $27,$1 */
7865 tramp[1] = 0xa77b0010; /* ldq $27,16($27) */
7873 ffi_closure_osf_inner(ffi_closure *closure, void *rvalue, unsigned long *argp)
7877 /* Grab the addresses of the arguments from the stack frame. */
7880 + size_t size = arg_types[i]->size;
7882 switch (arg_types[i]->type)
7884 case FFI_TYPE_SINT8:
7885 @@ -236,16 +260,22 @@
7886 avalue[i] = &argp[argn - (argn < 6 ? 6 : 0)];
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 *);
7900 - argn += ALIGN(arg_types[i]->size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG;
7901 + argn += ALIGN(size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG;
7905 /* Invoke the closure. */
7906 - (closure->fun) (cif, rvalue, avalue, closure->user_data);
7907 + closure->fun (cif, rvalue, avalue, closure->user_data);
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)
7916 /* -----------------------------------------------------------------------
7917 - osf.S - Copyright (c) 1998, 2001 Red Hat
7918 + osf.S - Copyright (c) 1998, 2001, 2007 Red Hat
7920 Alpha/OSF Foreign Function Interface
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
7931 + FFI_HIDDEN(ffi_call_osf)
7934 .frame $15, 32, $26, 0
7935 .mask 0x4008000, -32
7938 .globl ffi_closure_osf
7939 .ent ffi_closure_osf
7940 + FFI_HIDDEN(ffi_closure_osf)
7943 .frame $30, 16*8, $26, 0
7944 .mask 0x4000000, -16*8
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)
7960 FFI_TYPEDEF(float, float, FFI_TYPE_FLOAT);
7961 FFI_TYPEDEF(double, double, FFI_TYPE_DOUBLE);
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
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
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);
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)
7981 +2007-04-20 Richard Henderson <rth@redhat.com>
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
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.
7994 2007-02-13 Andreas Krebbel <krebbel1@de.ibm.com>
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)
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__)'
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)
8017 # Also AC_SUBST this variable for ffi.h.
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])
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)
8038 +2007-04-04 Eric Christopher <echristo@apple.com>
8040 + Backport from mainline:
8041 + 2007-04-04 Zack Weinberg <zack@mrtock.ucsd.edu>
8043 + * texi2pod.pl: Correct handling of @itemize with no argument.
8045 + 2007-02-16 Matthias Klose <doko@debian.org>
8047 + * texi2pod.pl: Handle @subsubsection, ignore @anchor.
8049 + 2007-02-06 Richard Sandiford <richard@codesourcery.com>
8051 + * texi2pod.pl: Handle @multitable.
8053 2006-09-27 Matthew Sachs <msachs@apple.com>
8055 * compareSumTests3: POD syntax fix.
8058 2005-10-28 Daniel Berlin <dberlin@dberlin.org>
8059 Ben Elliston <bje@au1.ibm.com>
8062 * gcc_update: Update for svn.
8063 * newcvsroot: Ditto.
8066 2005-10-21 Mark Mitchell <mark@codesourcery.com>
8068 - * texi2pod.pl: Substitue for @value even when part of @include.
8069 + * texi2pod.pl: Substitue for @value even when part of @include.
8071 2005-10-21 Bob Wilson <bob.wilson@acm.org>
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)
8078 } elsif ($ended =~ /^(?:itemize|enumerate|[fv]?table)$/) {
8081 + } elsif ($ended eq "multitable") {
8084 die "unknown command \@end $ended at line $.\n";
8087 and $_ = "\n=head2 $1\n";
8088 /^\@subsection\s+(.+)$/
8089 and $_ = "\n=head3 $1\n";
8090 + /^\@subsubsection\s+(.+)$/
8091 + and $_ = "\n=head4 $1\n";
8093 # Block command handlers:
8094 /^\@itemize(?:\s+(\@[a-z]+|\*|-))?/ and do {
8104 @@ -278,6 +282,12 @@
8105 $endw = "enumerate";
8108 + /^\@multitable\s.*/ and do {
8109 + push @endwstack, $endw;
8110 + $endw = "multitable";
8111 + $_ = "\n=over 4\n";
8114 /^\@([fv]?table)\s+(\@[a-z]+)/ and do {
8115 push @endwstack, $endw;
8117 @@ -297,6 +307,16 @@
8118 $_ = ""; # need a paragraph break
8121 + /^\@item\s+(.*\S)\s*$/ and $endw eq "multitable" and do {
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;
8128 + $_ = "\n=item ".join (" : ", @columns)."\n";
8131 /^\@itemx?\s*(.+)?$/ and do {
8133 # Entity escapes prevent munging by the <> processing below.
8138 + # Anchors are thrown away
8139 + s/\@anchor\{(?:[^\}]*)\}//g;
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.
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 @@
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 \
8171 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8172 @@ -9875,7 +9876,8 @@
8176 -for ac_header in execinfo.h unistd.h dlfcn.h
8178 +for ac_header in execinfo.h unistd.h dlfcn.h sys/resource.h
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)
8187 throw new ::java::io::FileNotFoundException (msg->toString ());
8190 - _Jv_platform_close_on_exec (fd);
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)
8200 throw new ::java::io::IOException (JvNewStringUTF (strerr));
8203 - _Jv_platform_close_on_exec (sock);
8205 // We use native_fd in place of fd here. From leaving fd null we avoid
8206 // the double close problem in FileDescriptor.finalize.
8212 - _Jv_platform_close_on_exec (new_socket);
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)
8222 throw new ::java::net::SocketException (JvNewStringUTF (strerr));
8225 - _Jv_platform_close_on_exec (sock);
8227 // We use native_fd in place of fd here. From leaving fd null we avoid
8228 // the double close problem in FileDescriptor.finalize.
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 \
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)
8253 #include <sys/types.h>
8254 #include <sys/wait.h>
8255 +#ifdef HAVE_SYS_RESOURCE_H
8256 +#include <sys/resource.h>
8261 @@ -341,7 +344,31 @@
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.
8275 +#ifdef HAVE_GETRLIMIT
8277 + int rv = getrlimit(RLIMIT_NOFILE, &rl);
8279 + max_fd = rl.rlim_max - 1;
8281 + max_fd = 1024 - 1;
8283 + max_fd = 1024 - 1;
8287 + if (max_fd != msgp[1])
8291 // Make sure that SIGCHLD is unblocked for the new process.
8293 sigemptyset (&mask);
8294 @@ -425,11 +452,4 @@
8297 cleanup (args, env, path);
8299 - if (exception == NULL)
8301 - fcntl (outp[1], F_SETFD, FD_CLOEXEC);
8302 - fcntl (inp[0], F_SETFD, FD_CLOEXEC);
8303 - fcntl (errp[0], F_SETFD, FD_CLOEXEC);
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)
8311 extern void _Jv_platform_initialize (void);
8312 extern void _Jv_platform_initProperties (java::util::Properties*);
8315 -_Jv_platform_close_on_exec (jint fd)
8318 - ::fcntl (fd, F_SETFD, FD_CLOEXEC);
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)
8331 /* Define to 1 if you have the `getpwuid_r' function. */
8332 #undef HAVE_GETPWUID_R
8334 +/* Define to 1 if you have the `getrlimit' function. */
8335 +#undef HAVE_GETRLIMIT
8337 /* Define to 1 if you have the `gettimeofday' function. */
8338 #undef HAVE_GETTIMEOFDAY
8341 /* Define to 1 if you have the <sys/ioctl.h> header file. */
8342 #undef HAVE_SYS_IOCTL_H
8344 +/* Define to 1 if you have the <sys/resource.h> header file. */
8345 +#undef HAVE_SYS_RESOURCE_H
8347 /* Define to 1 if you have the <sys/rw_lock.h> header file. */
8348 #undef HAVE_SYS_RW_LOCK_H
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)
8355 +2007-03-25 David Daney <ddaney@avtrex.com>
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
8371 2007-01-29 Kaloian Doganov <kaloian@doganov.org>
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)
8379 +2007-04-23 Tom Tromey <tromey@redhat.com>
8381 + PR preprocessor/30468:
8382 + * mkdeps.c (apply_vpath): Strip successive '/'s if we stripped
8385 2006-12-29 Jakub Jelinek <jakub@redhat.com>
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)
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
8398 This program is free software; you can redistribute it and/or modify it
8399 @@ -141,7 +141,13 @@
8401 /* Remove leading ./ in any case. */
8402 while (t[0] == '.' && IS_DIR_SEPARATOR (t[1]))
8406 + /* If we removed a leading ./, then also remove any /s after the
8408 + while (IS_DIR_SEPARATOR (t[0]))