[Bug tree-optimization/14703] [4.4 regression] Inadequate optimization of inline templated functions, infinite loop in ipa-reference and memory hog

2008-09-18 Thread hubicka at gcc dot gnu dot org


--- Comment #15 from hubicka at gcc dot gnu dot org  2008-09-19 06:22 
---
The infinite loop in ipa-reference is solved now.  Is the sixtrack problem
remaining and if so, would be possible to test the proposed patch?
We probably could track it as independent PR and close this one.

Honza


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14703



[Bug fortran/37580] New: invalid code accepted without notice

2008-09-18 Thread jpr at csc dot fi
Hi,

following invalid code compiles w/o error with gfortran 4.4.0

program test
  real, pointer :: a(:), b(:)
  a(:) => b(:)
end program test

works as expected with earliear versions.

$ gfortran -v
Using built-in specs.
Target: i586-pc-linux-gnu
Configured with: /home/fx/gfortran_nightbuild/trunk/configure
--prefix=/home/fx/gfortran_nightbuild/irun-20080918
--enable-languages=c,fortran --build=i586-pc-linux-gnu
--enable-checking=release --with-gmp=/home/fx/gfortran_nightbuild/software
Thread model: posix
gcc version 4.4.0 20080918 (experimental) [trunk revision 140443] (GCC)

Regards, Juha


-- 
   Summary: invalid code accepted without notice
   Product: gcc
   Version: 4.4.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: jpr at csc dot fi


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37580



[Bug target/37381] [4.4 Regression] ICE in ia64_speculate_insn, at config/ia64/ia64.c:6902

2008-09-18 Thread hjl dot tools at gmail dot com


--- Comment #5 from hjl dot tools at gmail dot com  2008-09-19 05:20 ---
Steve, can you review ia64 changes from sel-sched branch?
When sel-sched branch branch was merged into trunk, ia64
changes were left out and are still pending for review.


-- 

hjl dot tools at gmail dot com changed:

   What|Removed |Added

 CC||sje at cup dot hp dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37381



[Bug tree-optimization/37579] New: Vectorizer is causing code bloat and worse performance than unrolling would for a loop in SPEC 2k's eon

2008-09-18 Thread pinskia at gcc dot gnu dot org
Hi,
The following reduced testcase shows the issue:
struct f
{
  float a[8];
};

void set(struct f *a, float b)
{
  int i = 0;
  for(i=0;i<8;i++)
a->a[i] = b;
}
--- CUT ---
Currently we vectorize this loop when really unrolling would perform better on
SPU, Altivec (PPC) and SSE (x86).
For Cell's PPC, it would cause a LHS as we have to transfer between the
floating point registers and the vector registers.


-- 
   Summary: Vectorizer is causing code bloat and worse performance
than unrolling would for a loop in SPEC 2k's eon
   Product: gcc
   Version: 4.4.0
Status: UNCONFIRMED
  Keywords: missed-optimization
  Severity: normal
  Priority: P3
 Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pinskia at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37579



[Bug testsuite/25241] [C++] DejaGNU does not distinguish between errors and warnings

2008-09-18 Thread janis at gcc dot gnu dot org


--- Comment #64 from janis at gcc dot gnu dot org  2008-09-18 22:31 ---
Subject: Bug 25241

Author: janis
Date: Thu Sep 18 22:29:39 2008
New Revision: 140476

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140476
Log:
PR testsuite/25241
* lib/g++.exp (g++_init): Enable overrides of dg-error, dg-warning
for C++ tests.
* g++.dg/conversion/ambig1.C: Clean up dg-error/dg-warning; use
dg-message for notes.
* g++.dg/conversion/simd1.C: Ditto.
* g++.dg/conversion/simd3.C: Ditto.
* g++.dg/cpp0x/rv2n.C: Ditto.
* g++.dg/cpp0x/rv3n.C: Ditto.
* g++.dg/cpp0x/rv4n.C: Ditto.
* g++.dg/cpp0x/rv5n.C: Ditto.
* g++.dg/cpp0x/rv6n.C: Ditto.
* g++.dg/cpp0x/rv7n.C: Ditto.
* g++.dg/cpp0x/variadic36.C: Ditto.
* g++.dg/cpp0x/variadic59.C: Ditto.
* g++.dg/cpp0x/variadic71.C: Ditto.
* g++.dg/cpp0x/variadic-ex13.C: Ditto.
* g++.dg/expr/cond9.C: Ditto.
* g++.dg/expr/pmf-1.C: Ditto.
* g++.dg/ext/case-range2.C: Ditto.
* g++.dg/ext/case-range3.C: Ditto.
* g++.dg/ext/is_class_error2.C: Ditto.
* g++.dg/ext/label5.C: Ditto.
* g++.dg/ext/pr27019.C: Ditto.
* g++.dg/gomp/pr26690-1.C: Ditto.
* g++.dg/gomp/pr26690-2.C: Ditto.
* g++.dg/gomp/pr34694.C: Ditto.
* g++.dg/gomp/tpl-parallel-2.C: Ditto.
* g++.dg/inherit/base3.C: Ditto.
* g++.dg/inherit/using6.C: Ditto.
* g++.dg/init/brace6.C: Ditto.
* g++.dg/init/ctor4.C: Ditto.
* g++.dg/lookup/conv-1.C: Ditto.
* g++.dg/lookup/new1.C: Ditto.
* g++.dg/lookup/scoped6.C: Ditto.
* g++.dg/lookup/using7.C: Ditto.
* g++.dg/lookup/using9.C: Ditto.
* g++.dg/other/abstract1.C: Ditto.
* g++.dg/other/abstract2.C: Ditto.
* g++.dg/other/anon5.C: Ditto.
* g++.dg/other/crash-4.C: Ditto.
* g++.dg/other/error10.C: Ditto.
* g++.dg/other/error13.C: Ditto.
* g++.dg/other/error20.C: Ditto.
* g++.dg/other/error5.C: Ditto.
* g++.dg/other/field1.C: Ditto.
* g++.dg/other/offsetof5.C: Ditto.
* g++.dg/other/semicolon.C: Ditto.
* g++.dg/overload/ambig1.C: Ditto.
* g++.dg/overload/arg3.C: Ditto.
* g++.dg/overload/builtin1.C: Ditto.
* g++.dg/overload/copy1.C: Ditto.
* g++.dg/overload/new1.C: Ditto.
* g++.dg/overload/template4.C: Ditto.
* g++.dg/overload/using2.C: Ditto.
* g++.dg/parse/bitfield2.C: Ditto.
* g++.dg/parse/constant4.C: Ditto.
* g++.dg/parse/crash20.C: Ditto.
* g++.dg/parse/crash36.C: Ditto.
* g++.dg/parse/crash5.C: Ditto.
* g++.dg/parse/error11.C: Ditto.
* g++.dg/parse/error12.C: Ditto.
* g++.dg/parse/error19.C: Ditto.
* g++.dg/parse/error28.C: Ditto.
* g++.dg/parse/friend5.C: Ditto.
* g++.dg/parse/invalid-op1.C: Ditto.
* g++.dg/parse/missing-template1.C: Ditto.
* g++.dg/parse/non-dependent2.C: Ditto.
* g++.dg/parse/ret-type2.C: Ditto.
* g++.dg/parse/specialization1.C: Ditto.
* g++.dg/parse/template18.C: Ditto.
* g++.dg/parse/template3.C: Ditto.
* g++.dg/parse/template9.C: Ditto.
* g++.dg/tc1/dr108.C: Ditto.
* g++.dg/tc1/dr152.C: Ditto.
* g++.dg/tc1/dr166.C: Ditto.
* g++.dg/template/access11.C: Ditto.
* g++.dg/template/access2.C: Ditto.
* g++.dg/template/access3.C: Ditto.
* g++.dg/template/access7.C: Ditto.
* g++.dg/template/copy1.C: Ditto.
* g++.dg/template/crash13.C: Ditto.
* g++.dg/template/crash37.C: Ditto.
* g++.dg/template/crash40.C: Ditto.
* g++.dg/template/crash58.C: Ditto.
* g++.dg/template/ctor5.C: Ditto.
* g++.dg/template/dependent-expr5.C: Ditto.
* g++.dg/template/eh2.C: Ditto.
* g++.dg/template/error2.C: Ditto.
* g++.dg/template/error33.C: Ditto.
* g++.dg/template/error4.C: Ditto.
* g++.dg/template/friend31.C: Ditto.
* g++.dg/template/friend32.C: Ditto.
* g++.dg/template/instantiate1.C: Ditto.
* g++.dg/template/instantiate3.C: Ditto.
* g++.dg/template/instantiate5.C: Ditto.
* g++.dg/template/instantiate7.C: Ditto.
* g++.dg/template/local6.C: Ditto.
* g++.dg/template/lookup2.C: Ditto.
* g++.dg/template/member5.C: Ditto.
* g++.dg/template/memfriend15.C: Ditto.
* g++.dg/template/memfriend16.C: Ditto.
* g++.dg/template/memfriend17.C: Ditto.
* g++.dg/template/memfriend7.C: Ditto.
* g++.dg/template/meminit1.C: Ditto.
* g++.dg/template/nested3.C: Ditto.
* g++.dg/template/new3.C: Ditto.
* g++.dg/template/nontype12.C: Ditto.
* g++.dg/template/nontype13.C: Ditto.
* g++.dg/template/nontype6.C: Ditto.
* g++.dg/template/non-type-templa

[Bug middle-end/32581] make profiledbootstrap - stageprofile - gcc/ada/a-except.adb:1301: error: control flow in the middle of basic block 20

2008-09-18 Thread rob1weld at aol dot com


--- Comment #12 from rob1weld at aol dot com  2008-09-18 22:21 ---
(In reply to comment #11)
> Subject: Bug 32581
> Author: hubicka
> Date: Sat Sep 13 21:39:44 2008
> New Revision: 140349
> Modified:
> trunk/gcc/tree-profile.c
> ...
> Fixed by my patch.

I have since switched target platforms and can not test your patch but thank
you kindly for fixing the bug I reported on 2007-07-02. 


It only took 14 months for everyone to be annoyed with this breakage for
someone (great) to fix it.


Leaving such a bug in for so long only served to foul the code and to prove
that something was not correct leaving other portions suspect. Removing the bug
instills greater confidence in that portion of the code and indeed leads one to
imagine that the rest of gcc is now better for it. For this we all thank you.

Rob

PS: Did I mention that I was really ticked off that profiling was broken :) .


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32581



[Bug fortran/30249] Pointers not given target type in GFORTRAN

2008-09-18 Thread dominiq at lps dot ens dot fr


--- Comment #3 from dominiq at lps dot ens dot fr  2008-09-18 21:12 ---
With gdb on i686-apple-darwin9, I get either

(gdb) pt rd
type = real*4 (0:-1,0:-1)

or

(gdb) pt rd
No symbol "rd" in current context.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30249



[Bug middle-end/37448] [4.3 Regression] gcc 4.3.1 cannot compile big function

2008-09-18 Thread hubicka at gcc dot gnu dot org


--- Comment #18 from hubicka at gcc dot gnu dot org  2008-09-18 21:11 
---
Hi,
some stats on instruction counts and references Kenny asked about:

At -O2:
[EMAIL PROTECTED]:~/gcc-baseline/build-ada/prev-gcc$ grep "(insn"
e.i.157r.outof_cfglayout | wc -l
307811
[EMAIL PROTECTED]:~/gcc-baseline/build-ada/prev-gcc$ grep "(call_insn"
e.i.157r.outof_cfglayout | wc -l
157016
[EMAIL PROTECTED]:~/gcc-baseline/build-ada/prev-gcc$ grep "(jump_insn"
e.i.157r.outof_cfglayout | wc -l
18650

at -O0:
[EMAIL PROTECTED]:~/gcc-baseline/build-ada/prev-gcc/O0$ grep "(insn"
e.i.157r.outof_cfglayout | wc -l
411876
[EMAIL PROTECTED]:~/gcc-baseline/build-ada/prev-gcc/O0$ grep "(call_insn"
e.i.157r.outof_cfglayout | wc -l
166471
[EMAIL PROTECTED]:~/gcc-baseline/build-ada/prev-gcc/O0$ grep "(jump_insn"
e.i.157r.outof_cfglayout | wc -l
18218

I am not sure if I can grep for references in some of the RTL dumps...

Honza


-- 

hubicka at gcc dot gnu dot org changed:

   What|Removed |Added

   Last reconfirmed|2008-09-10 08:02:43 |2008-09-18 21:11:40
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37448



[Bug testsuite/37578] Testsuite cannot tell systems with REAL(10) and REAL(16) apart

2008-09-18 Thread dominiq at lps dot ens dot fr


--- Comment #1 from dominiq at lps dot ens dot fr  2008-09-18 21:10 ---
If I am right real(10) is a leftover of the "coprocessor" era and is a
peculiarity of the x86 processors (may be also 68k, I cannot remember). I think
for all the other platforms with "fortran_large_real" use real(16).

If this is correct a short term solution is to have two programs, one for
"fortran_large_real" and *86* (and may be || *68k*) and one for
"fortran_large_real" and !*86* (using the right syntax for the platform
selection).


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37578



[Bug fortran/37159] RANDOM_SEED: PUT= check array size at compile time

2008-09-18 Thread dennis dot wassel at googlemail dot com


--- Comment #3 from dennis dot wassel at googlemail dot com  2008-09-18 
21:00 ---
Updated patch: http://gcc.gnu.org/ml/fortran/2008-09/msg00161.html
Will be committed by Thomas Koenig as soon as my copyright assignment is done.

How come I cannot add myself in the "assigned to" or change the status?


-- 

dennis dot wassel at googlemail dot com changed:

   What|Removed |Added

 CC||dennis dot wassel at
   ||googlemail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37159



[Bug testsuite/37578] New: Testsuite cannot tell systems with REAL(10) and REAL(16) apart

2008-09-18 Thread dennis dot wassel at googlemail dot com
The testsuite defines "fortran_large_real" for all systems that have a REAL
kind > 8. However, there are cases where different things should really be
tested for REAL(10) vs REAL(16) [my upcoming patch to fortran/PR37159 being one
of them].

To not break existing testcases, how about defining two additional
conditionals, say "fortran_has_real_10" and "fortan_has_real_16"?

One (seemingly) simple way of figuring those guys out could be to compile the
two canonical code snippets, dg-test for success and then run the actual
Fortran tests.
Without a clue of the testsuite-internals, unfortunately I have no idea if this
is feasible.


-- 
   Summary: Testsuite cannot tell systems with REAL(10) and REAL(16)
apart
   Product: gcc
   Version: 4.4.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: testsuite
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: dennis dot wassel at googlemail dot com
  GCC host triplet: any


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37578



[Bug target/37394] [4.4 Regression] Segfault in ia64_variable_issue with -O -fschedule-insns2

2008-09-18 Thread hjl dot tools at gmail dot com


--- Comment #11 from hjl dot tools at gmail dot com  2008-09-18 20:35 
---
Fixed.


-- 

hjl dot tools at gmail dot com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37394



[Bug target/37394] [4.4 Regression] Segfault in ia64_variable_issue with -O -fschedule-insns2

2008-09-18 Thread hjl at gcc dot gnu dot org


--- Comment #10 from hjl at gcc dot gnu dot org  2008-09-18 20:28 ---
Subject: Bug 37394

Author: hjl
Date: Thu Sep 18 20:27:36 2008
New Revision: 140475

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140475
Log:
gcc/

2008-09-18  H.J. Lu  <[EMAIL PROTECTED]>

PR target/37394
* config/ia64/ia64.c (ia64_optimization_options): Move
checking and setting flag_schedule_insns_after_reload and
ia64_flag_schedule_insns2 back to ...
(ia64_override_options): Here.

gcc/testsuite/

2008-09-18  H.J. Lu  <[EMAIL PROTECTED]>

PR target/37394
* g++.dg/other/pr37394.C: New.

Added:
trunk/gcc/testsuite/g++.dg/other/pr37394.C
Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/ia64/ia64.c
trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37394



[Bug middle-end/37567] tree SSA to normal checking takes abnormally long time

2008-09-18 Thread lucier at math dot purdue dot edu


--- Comment #7 from lucier at math dot purdue dot edu  2008-09-18 20:28 
---
I just found it, too; it's been approved, but it hasn't been installed yet.

Wow, fixing bugs before they're reported, that's pretty efficient ;-)!

I'll wait until it's installed.

Thanks.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37567



[Bug middle-end/37567] tree SSA to normal checking takes abnormally long time

2008-09-18 Thread amacleod at redhat dot com


--- Comment #6 from amacleod at redhat dot com  2008-09-18 20:23 ---
here it is

http://gcc.gnu.org/ml/gcc-patches/2008-09/msg01072.html


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37567



[Bug fortran/36700] [4.3/4.4 Regression] ICE on calling a function

2008-09-18 Thread pault at gcc dot gnu dot org


--- Comment #5 from pault at gcc dot gnu dot org  2008-09-18 20:22 ---
Subject: Bug 36700

Author: pault
Date: Thu Sep 18 20:21:03 2008
New Revision: 140474

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140474
Log:
2008-09-18  Paul Thomas  <[EMAIL PROTECTED]>

   PR fortran/35945
   * resolve.c (resolve_fl_variable_derived):  Remove derived type
   comparison for use associated derived types.  Host association
   of a derived type will not arise if there is a local derived type
   whose use name is the same.

   PR fortran/36700
   * match.c (gfc_match_call):  Use the existing symbol even if
   it is a function.

2008-09-18  Paul Thomas  <[EMAIL PROTECTED]>

   PR fortran/35945
   * gfortran.dg/host_assoc_types_2.f90: New test.

   PR fortran/36700
   * gfortran.dg/host_assoc_call_2.f90: New test.

Added:
trunk/gcc/testsuite/gfortran.dg/host_assoc_call_2.f90
trunk/gcc/testsuite/gfortran.dg/host_assoc_types_2.f90
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/match.c
trunk/gcc/fortran/resolve.c
trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36700



[Bug fortran/35945] Complex module-based overloading fails

2008-09-18 Thread pault at gcc dot gnu dot org


--- Comment #2 from pault at gcc dot gnu dot org  2008-09-18 20:22 ---
Subject: Bug 35945

Author: pault
Date: Thu Sep 18 20:21:03 2008
New Revision: 140474

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140474
Log:
2008-09-18  Paul Thomas  <[EMAIL PROTECTED]>

   PR fortran/35945
   * resolve.c (resolve_fl_variable_derived):  Remove derived type
   comparison for use associated derived types.  Host association
   of a derived type will not arise if there is a local derived type
   whose use name is the same.

   PR fortran/36700
   * match.c (gfc_match_call):  Use the existing symbol even if
   it is a function.

2008-09-18  Paul Thomas  <[EMAIL PROTECTED]>

   PR fortran/35945
   * gfortran.dg/host_assoc_types_2.f90: New test.

   PR fortran/36700
   * gfortran.dg/host_assoc_call_2.f90: New test.

Added:
trunk/gcc/testsuite/gfortran.dg/host_assoc_call_2.f90
trunk/gcc/testsuite/gfortran.dg/host_assoc_types_2.f90
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/match.c
trunk/gcc/fortran/resolve.c
trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35945



[Bug fortran/37577] New: Change internal array descriptor format for better syntax, C interop TR, rank 15

2008-09-18 Thread burnus at gcc dot gnu dot org
There are a couple of issues with regards to the internal representation of
arrays in gfortran.

The solution is to revamp the internal format.

The main format should match the "Further Interoperability with C" technical
report (TR) which is currently developed.

It further more needs to:
- Support the distinction between pointer/allocatable targets and
nondeallocatable targets -> PR 35718
- It could support a flag to store the contiguous status. Ifort has and it
might make more sense than having to check it everytime when needed explicitly.
(Or is this faster on average?) Need also to check CONTIGIOUS flag of F2008
- A storage allocated flag (as ifort has) for zero-sized arrays; currently a
single item is allocated.
- Be prepared for coarrays - they can be handled by the normal dim etc., but
one might want to store information none the less.
- Possibly save some space for extensions

Internal format of ifort:

http://www.intel.com/software/products/compilers/docs/flin/main_for/mergedProjects/bldaps_for/common/bldaps_hndl_arrdesc.htm


"SC 22 N 4146, New Work Item Proposal for Further Interoperability with C, TR
Type 2": Not yet publicly available; check status or ask your TR/WG5 contact
;-)
The original proposal is available at
http://j3-fortran.org/doc/year/06/06-171.txt


For subref arrays, a byte-based approach should replace the span:

> > Is there a plan to do it right with the next major ABI change (i.e.
> > represent strides in bytes rather than elements and kill this span stuff)?
> > I think there are comments about intending to go from 7 to 15 maximum rank
> > and that will need ABI changes to the array descriptors anyway.
>
> At the time that subref array pointers were implemented, there was a
> discussion on the list on how to do this.  Changing the ABI for array
> descriptors was favoured but nobody had the time to carry out the
> necessary surgery.  Therefore, I came up with the span kludge, which
> arguably is worse than nothing:-(


-- 
   Summary: Change internal array descriptor format for better
syntax, C interop TR, rank 15
   Product: gcc
   Version: 4.4.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: burnus at gcc dot gnu dot org
OtherBugsDependingO 20923,34528,35718,36825
 nThis:


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37577



[Bug middle-end/37567] tree SSA to normal checking takes abnormally long time

2008-09-18 Thread amacleod at redhat dot com


--- Comment #5 from amacleod at redhat dot com  2008-09-18 20:19 ---
huh, didn't I already see a patch go by to move this check to after all the
BB's were processed instead of doing it after each BB??


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37567



[Bug middle-end/37567] tree SSA to normal checking takes abnormally long time

2008-09-18 Thread lucier at math dot purdue dot edu


--- Comment #4 from lucier at math dot purdue dot edu  2008-09-18 20:09 
---
Actually, it's pretty clear this is the problem:

extern gimple *
find_replaceable_exprs (var_map map)
{
  basic_block bb;
  temp_expr_table_p table;
  gimple *ret;

  table = new_temp_expr_table (map);
  FOR_EACH_BB (bb)
{
  find_replaceable_in_bb (table, bb);
  gcc_assert (bitmap_empty_p (table->partition_in_use));

#ifdef ENABLE_CHECKING
  {
unsigned i;
/* Make sure all the tables have been cleared out.  */
for (i = 0; i < num_ssa_names + 1; i++)
  {
gcc_assert (table->partition_dependencies[i] == NULL);
gcc_assert (table->expr_decl_uids[i] == NULL);
if (i < num_var_partitions (map))
  gcc_assert (table->kill_list[i] == NULL);
  }
  }
#endif
}

  ret = free_temp_expr_table (table);
  return ret;
}


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37567



[Bug fortran/30249] Pointers not given target type in GFORTRAN

2008-09-18 Thread burnus at gcc dot gnu dot org


--- Comment #2 from burnus at gcc dot gnu dot org  2008-09-18 20:03 ---
Works for me. Can you check with a recent 4.4 compiler? There I get:

(idb) pt RD
type = REAL(4)(10)(10)

which looks OK.


-- 

burnus at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|NEW |WAITING


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30249



[Bug middle-end/37567] tree SSA to normal checking takes abnormally long time

2008-09-18 Thread lucier at math dot purdue dot edu


--- Comment #3 from lucier at math dot purdue dot edu  2008-09-18 20:07 
---
Created an attachment (id=16358)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16358&action=view)
gprof output for the test case

The compiler (which was bootstrapped with BOOT_CFLAGS='-O2 -g -pg'):

Using built-in specs.
Target: x86_64-unknown-linux-gnu
Configured with: ../../mainline/configure --with-gmp=/pkgs/gmp-4.2.2/
--with-mpfr=/pkgs/gmp-4.2.2/ --prefix=/pkgs/gcc-mainline --enable-languages=c
--enable-gather-detailed-mem-stats
Thread model: posix
gcc version 4.4.0 20080917 (experimental) [trunk revision 140425] (GCC) 
GNU C (GCC) version 4.4.0 20080917 (experimental) [trunk revision 140425]
(x86_64-unknown-linux-gnu)
compiled by GNU C version 4.4.0 20080917 (experimental) [trunk revision
140425], GMP version 4.2.2, MPFR version 2.3.0-p4.
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096

the command line


/export/pkgs/gcc-mainline/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.4.0/cc1
-fpreprocessed all.i -quiet -dumpbase all.i -mtune=generic -auxbase all -O1
-Wall -W -Wno-unused -version -fno-math-errno -fschedule-insns2
-fno-trapping-math -fno-strict-aliasing -fwrapv -fomit-frame-pointer -fPIC
-ftime-report -fmem-report -o all.s >>& mainline-stats-2008-09-18

Highlights of the gprof output:

Flat profile:

Each sample counts as 0.01 seconds.
  %   cumulative   self  self total   
 time   seconds   secondscalls   s/call   s/call  name
 63.13422.59   422.593   140.86   141.03  find_replaceable_exprs

---
  422.590.50   3/3   rewrite_out_of_ssa [6]
[7] 63.2  422.590.50   3 find_replaceable_exprs [7]
0.200.30   63203/63203   find_replaceable_in_bb [290]
0.000.00   6/13254347 bitmap_obstack_free [162]
0.000.00   6/6476878 bitmap_obstack_alloc_stat
[339]
---

Doesn't tell me much ...


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37567



[Bug tree-optimization/37102] [4.3 Regression] out-of-SSA is broken

2008-09-18 Thread amacleod at redhat dot com


--- Comment #19 from amacleod at redhat dot com  2008-09-18 20:04 ---
The patch should be fine for 4.3, but I'll give it a few days in mainline and
see if anything shows up on any overnight or weekly runs


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37102



[Bug middle-end/37567] tree SSA to normal checking takes abnormally long time

2008-09-18 Thread amacleod at redhat dot com


--- Comment #2 from amacleod at redhat dot com  2008-09-18 20:00 ---
I will also look into it and take out some of the excess checking which is
probably not necessary anymore.


-- 

amacleod at redhat dot com changed:

   What|Removed |Added

 AssignedTo|unassigned at gcc dot gnu   |amacleod at redhat dot com
   |dot org |
 Status|UNCONFIRMED |ASSIGNED
 Ever Confirmed|0   |1
   Last reconfirmed|-00-00 00:00:00 |2008-09-18 20:00:46
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37567



[Bug c++/37554] [4.3/4.4 regression] ICE with invalid cast

2008-09-18 Thread pinskia at gcc dot gnu dot org


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
   Last reconfirmed|-00-00 00:00:00 |2008-09-18 19:59:24
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37554



[Bug rtl-optimization/37377] [4.4 Regression] Bootstrap failure compiling libgcc

2008-09-18 Thread pinskia at gcc dot gnu dot org


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

   Target Milestone|--- |4.4.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37377



[Bug c++/37383] optimization - compiler crash

2008-09-18 Thread pinskia at gcc dot gnu dot org


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |WAITING


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37383



[Bug middle-end/37576] [4.4 Regression] -v --help ICEs

2008-09-18 Thread pinskia at gcc dot gnu dot org


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

   Target Milestone|--- |4.4.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37576



[Bug middle-end/37576] New: [4.4 Regression] -v --help ICEs

2008-09-18 Thread pinskia at gcc dot gnu dot org
Just running gcc -v --help ICEs with the following ICE:
cc1: internal compiler error: unrecognized include_flags 0x2 passed to
print_specific_help
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.

--- CUT---
I was able to reproduce this on both powerpc-linux-gnu and i386-darwin so I
know it is not a target specific option which is causing it.
[EMAIL PROTECTED] gcc]$ ~/gcc-mainline/bin/gcc -v 
Using built-in specs.
Target: powerpc64-unknown-linux-gnu
Configured with: /home/apinski/src/local/gcc/configure
--prefix=/home/apinski/gcc-mainline --with-mpfr=/usr/local --with-cpu=default32
--enable-languages=obj-c++,fortran --with-tune=cell
Thread model: posix
gcc version 4.4.0 20080917 (experimental) [trunk revision 140428] (GCC)


-- 
   Summary: [4.4 Regression] -v --help ICEs
   Product: gcc
   Version: 4.4.0
Status: UNCONFIRMED
  Keywords: ice-on-valid-code
  Severity: normal
  Priority: P3
 Component: middle-end
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pinskia at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37576



[Bug c++/37555] [4.2/4.3/4.4 regression] ICE with invalid typedef

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #1 from pinskia at gcc dot gnu dot org  2008-09-18 19:42 ---
Confirmed.
#0  maybe_dummy_object (type=???, binfop=???) at
/Users/apinski/src/local/gcc/gcc/cp/tree.c:2067


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

   Severity|normal  |minor
 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
  Known to fail||4.4.0 4.0.0
   Last reconfirmed|-00-00 00:00:00 |2008-09-18 19:42:41
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37555



[Bug c++/37556] [4.4 regression] ICE with invalid typedef

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #1 from pinskia at gcc dot gnu dot org  2008-09-18 19:40 ---
Confirmed.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 CC||doug dot gregor at gmail dot
   ||com
   Severity|normal  |minor
 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
   Last reconfirmed|-00-00 00:00:00 |2008-09-18 19:40:54
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37556



[Bug c++/37575] compile of xpdf finished in errors

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #1 from pinskia at gcc dot gnu dot org  2008-09-18 19:39 ---
GCC is not the one which is failing but the assembler is seg faulting.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||INVALID


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37575



[Bug c++/37554] [4.3/4.4 regression] ICE with invalid cast

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #1 from pinskia at gcc dot gnu dot org  2008-09-18 19:38 ---
Confirmed, worked with 
GNU C++ (GCC) version 4.3.0 20080201 (experimental) [trunk revision 131996]
(i386-apple-darwin8.11.1)


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 CC||pinskia at gcc dot gnu dot
   ||org
   Severity|normal  |minor
  Known to fail||4.4.0
  Known to work||4.1.1


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37554



[Bug c++/37575] New: compile of xpdf finished in errors

2008-09-18 Thread rosie dot coffey at intl dot pepsico dot com
My aim is to get pdf printing on AIX (running oracle financials) - which
requires pdftops.
I am on aix 5.3, just installed GCC compiler, GNU MAKE, then FREETYPE2
(pre-req) all apparently successfully.  Then when configuring and installing
xpdf to get pdftops, it bombed out in the install.  


#
.
.
.
Function.cc
g++ -g -O2 -DHAVE_CONFIG_H -I.. -I./../goo -I./../fofi -I./../splash -I.   
   -c Gfx.cc

configure: WARNING: Couldn't find Motif
configure: WARNING: Couldn't find FreeType
configure: WARNING: -- You will be able to compile pdftops, pdftotext,
pdfinfo, pdffonts, and pdfimages, but not xpdf or pdftoppm
#

#
g++: Internal error: Segmentation fault (program as)
Please submit a full bug report.
See http://gcc.gnu.org/bugs.html> for instructions.
make[1]: *** [Gfx.o] Error 1
make[1]: Leaving directory `/apps/gcc/xpdf-3.02/xpdf'
make: *** [all] Error 2
#


-- 
   Summary: compile  of xpdf finished in errors
   Product: gcc
   Version: 3.3.2
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: rosie dot coffey at intl dot pepsico dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37575



[Bug fortran/37545] impossible to link with -fopenmp

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #7 from pinskia at gcc dot gnu dot org  2008-09-18 19:33 ---
This is only a problem if you used a compiled GCC that was compiled for a newer
version of glibc and you are using on an older glibc version.

Aka not a GCC bug.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|WAITING |RESOLVED
 Resolution||INVALID


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37545



[Bug rtl-optimization/37451] Extra addition for doloop in some cases

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #4 from pinskia at gcc dot gnu dot org  2008-09-18 19:30 ---
This is still not fully fixed.  There is still an issue dealing the DECL_RTX's
being promoted early on.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37451



[Bug rtl-optimization/37451] Extra addition for doloop in some cases

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #3 from pinskia at gcc dot gnu dot org  2008-09-18 19:30 ---
Subject: Bug 37451

Author: pinskia
Date: Thu Sep 18 19:28:48 2008
New Revision: 140470

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140470
Log:
2008-09-18  Andrew Pinski  <[EMAIL PROTECTED]>

PR rtl-opt/37451
* loop-doloop.c (doloop_modify): New argument zero_extend_p and
zero extend count after the correction to it is done.
(doloop_optimize): Update call to doloop_modify, don't zero extend
count before call.


Modified:
trunk/gcc/ChangeLog
trunk/gcc/loop-doloop.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37451



[Bug c++/37570] friend class expected to have access over a class-es private members but doesn't and gives "internal compile error"

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #1 from pinskia at gcc dot gnu dot org  2008-09-18 19:18 ---
This code is invalid.
And has since been fixed to give an error back, see PR 34912.

*** This bug has been marked as a duplicate of 34912 ***


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

   Severity|major   |normal
 Status|UNCONFIRMED |RESOLVED
 Resolution||DUPLICATE


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37570



[Bug c++/34912] [4.1/4.2 Regression] ICE with friend in local class

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #5 from pinskia at gcc dot gnu dot org  2008-09-18 19:18 ---
*** Bug 37570 has been marked as a duplicate of this bug. ***


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 CC||stefan dot petrea at gmail
   ||dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34912




[Bug tree-optimization/37573] [4.4 Regression] gcc-4.4 regression: incorrect code generation with -O1 -ftree-vectorize

2008-09-18 Thread pinskia at gcc dot gnu dot org


--- Comment #3 from pinskia at gcc dot gnu dot org  2008-09-18 19:14 ---
Also fails on powerpc-linux-gnu.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
  GCC build triplet|x86_64-unknown-linux-gnu-   |
   |gcc-4.4.0   |
   GCC host triplet|x86_64-unknown-linux-gnu-   |
   |gcc-4.4.0   |
 GCC target triplet|x86_64-unknown-linux-gnu-   |
   |gcc-4.4.0   |
   Keywords||wrong-code
   Last reconfirmed|-00-00 00:00:00 |2008-09-18 19:14:33
   date||
Summary|gcc-4.4 regression: |[4.4 Regression] gcc-4.4
   |incorrect code generation   |regression: incorrect code
   |with -O1 -ftree-vectorize   |generation with -O1 -ftree-
   ||vectorize
   Target Milestone|--- |4.4.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37573



[Bug tree-optimization/37574] [4.4 Regression] ICE with the vectorizer and GC

2008-09-18 Thread pinskia at gcc dot gnu dot org


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

   Target Milestone|--- |4.4.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37574



[Bug tree-optimization/37574] New: [4.4 Regression] ICE with the vectorizer and GC

2008-09-18 Thread pinskia at gcc dot gnu dot org
I noticed this while working on a rs6000 back-end patch and was questioning how
I could have caused this failure and then I noticed it was a GC issue and could
be reproduced without my patch.
Anyways here is the testcase reduced from vect-outer-4m.c:
unsigned short in[40 +128];
int main (void) {
  int i = 0, j = 0;
  unsigned int diff;
  unsigned int s=0,sum=0;
  for (i = 0; i < 40;i++)
  {
 diff = 0;
 for (j = 0; j < 128;j+=8) 
   diff += in[j+i];
 s += ((unsigned short)diff>>3);
   }
   if (s != sum)
 abort ();
 }
--- CUT ---
Compile with -O2 -ftree-vectorize  --param ggc-min-expand=0 --param
ggc-min-heapsize=0 -maltivec to reproduce the bug.


-- 
   Summary: [4.4 Regression] ICE with the vectorizer and GC
   Product: gcc
   Version: 4.4.0
Status: UNCONFIRMED
  Keywords: ice-on-valid-code, GC
  Severity: normal
  Priority: P3
 Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pinskia at gcc dot gnu dot org
GCC target triplet: powerpc-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37574



[Bug target/35620] ICE passing dereferenced pointer to _Decimal32

2008-09-18 Thread janis at gcc dot gnu dot org


--- Comment #4 from janis at gcc dot gnu dot org  2008-09-18 18:39 ---
Subject: Bug 35620

Author: janis
Date: Thu Sep 18 18:37:52 2008
New Revision: 140468

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140468
Log:
Backport from mainline:
2008-04-08  Janis Johnson  <[EMAIL PROTECTED]>
gcc/
PR target/35620
* config/rs6000/rs6000.c (rs6000_check_sdmode): Handle additional
kinds of indirect references.
gcc/testsuite/
PR target/35620
* gcc.dg/dfp/pr35620.c: New test.
* gcc.dg/dfp/func-pointer.c: New test.
* gcc.dg/dfp/func-deref.c: New test.

Added:
branches/gcc-4_3-branch/gcc/testsuite/gcc.dg/dfp/func-deref.c
branches/gcc-4_3-branch/gcc/testsuite/gcc.dg/dfp/func-pointer.c
branches/gcc-4_3-branch/gcc/testsuite/gcc.dg/dfp/pr35620.c
Modified:
branches/gcc-4_3-branch/gcc/ChangeLog
branches/gcc-4_3-branch/gcc/config/rs6000/rs6000.c
branches/gcc-4_3-branch/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35620



[Bug target/35713] [4.4 Regression] invalid type for va_arg with _Decimal128

2008-09-18 Thread janis at gcc dot gnu dot org


--- Comment #5 from janis at gcc dot gnu dot org  2008-09-18 18:36 ---
Subject: Bug 35713

Author: janis
Date: Thu Sep 18 18:35:24 2008
New Revision: 140467

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140467
Log:
Backport from mainline:
2008-04-03  Janis Johnson  <[EMAIL PROTECTED]>

PR target/35713
* config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Use integer
constants of the appropriate size for runtime calculations.

Modified:
branches/gcc-4_3-branch/gcc/ChangeLog
branches/gcc-4_3-branch/gcc/config/rs6000/rs6000.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35713



[Bug c/35712] decimal float literal constant zero loses significant trailing zeroes

2008-09-18 Thread janis at gcc dot gnu dot org


--- Comment #4 from janis at gcc dot gnu dot org  2008-09-18 18:35 ---
Subject: Bug 35712

Author: janis
Date: Thu Sep 18 18:33:58 2008
New Revision: 140466

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140466
Log:
Backport from mainline:
2008-04-03  Janis Johnson  <[EMAIL PROTECTED]>
gcc/
PR c/35712
* dfp.c (decimal_from_decnumber): Retain trailing zeroes for
decimal-float literal constant zero.
testsuite/
PR c/35712
* gcc.dg/dfp/constants-zero.c: New test.

Added:
branches/gcc-4_3-branch/gcc/testsuite/gcc.dg/dfp/constants-zero.c
Modified:
branches/gcc-4_3-branch/gcc/ChangeLog
branches/gcc-4_3-branch/gcc/dfp.c
branches/gcc-4_3-branch/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35712



[Bug middle-end/37448] [4.3 Regression] gcc 4.3.1 cannot compile big function

2008-09-18 Thread hubicka at gcc dot gnu dot org


--- Comment #17 from hubicka at gcc dot gnu dot org  2008-09-18 18:18 
---
Subject: Bug 37448

Author: hubicka
Date: Thu Sep 18 18:16:45 2008
New Revision: 140465

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140465
Log:

PR middle-end/37448
* ipa-reference.c (ipa_reference_local_vars_info_d,
ipa_reference_global_vars_info_d,
ipa_reference_local_vars_info_t, ipa_reference_global_vars_info_t,
ipa_reference_vars_info_t): Move here from ipa-reference.h
(node_duplication_hook_holder, node_removal_hook_holder): New.
(get_reference_vars_info_from_cgraph): Rename to ...
(get_reference_vars_info): ... this one, use cgraph uids.
(get_local_reference_vars_info, get_global_reference_vars_info):
Use cgraph instead of decl.
(ipa_reference_get_read_local, ipa_reference_get_written_local):
Remove.
(ipa_reference_get_read_global, ipa_reference_get_not_read_global
ipa_reference_get_written_global,
ipa_reference_get_not_written_global): Use
cgraph argument.
(check_call): Simplify avail check.
(scan_stmt_for_static_refs): Update.
(propagate_bits): Update.
(merge_callee_local_info): Remove.
(init_function_info): Use cgraph nodes.
(clean_function_local_data): Break out from ...
(clean_function): ... here.
(copy_local_bitmap, copy_global_bitmap): New functions.
(duplicate_node_data, remove_node_data): New functions.
(generate_summary): Register hooks; use visibility instead of
master clones.
(propafate): Use cgraph nodes; copy bitmap to each node in cycle.
* ipa-reference.h (ipa_reference_local_vars_info_d,
ipa_reference_global_vars_info_d,
ipa_reference_local_vars_info_t, ipa_reference_global_vars_info_t,
ipa_reference_vars_info_t): Move to ipa-reference.c
(ipa_reference_get_read_local, ipa_reference_get_written_local):
Remove.
(ipa_reference_get_read_global, ipa_reference_get_written_global,
ipa_reference_get_not_read_global,
ipa_reference_get_not_written_global):
Update prototype.
* ipa-pure-const.c (funct_state_vec): Turn into VECtor.
(init_state): Remove.
(node_duplication_hook_holder, node_removal_hook_holder): New.
(get_function_state, set_function_state): Use VECtor.
(analyze_function): Check body availability.
(add_new_function): Likewise.
(duplicate_node_data, remove_node_data): New.
(generate_summary): Register hooks; do not care about clones.
(propafate): Do not care about clones; recursive functions are not
looping.
* ipa-utils.c (searchc, ipa_utils_reduced_inorder): Do not skip clones.
* ipa-prop.c (edge_removal_hook_holder, node_removal_hook_holder,
* edge_duplication_hook_holder, node_duplication_hook_holder): Make
static.
* tree-flow.h (function_ann_d): Remove reference_vars_info.
* tree-ssa-opreands.c (add_call_clobber_ops, add_call_read_ops): Update
call of
ipa-reference accesors.

Modified:
trunk/gcc/tree-flow.h


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37448



[Bug fortran/35846] ICE on nested character constructors

2008-09-18 Thread domob at gcc dot gnu dot org


-- 

domob at gcc dot gnu dot org changed:

   What|Removed |Added

 AssignedTo|unassigned at gcc dot gnu   |domob at gcc dot gnu dot org
   |dot org |
 Status|NEW |ASSIGNED
   Last reconfirmed|2008-04-13 20:33:00 |2008-09-18 18:22:59
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35846



[Bug ada/37572] compile Ada program fails (XML/Ada, 64 bit AMD)

2008-09-18 Thread jdecs at mssblue dot net


--- Comment #2 from jdecs at mssblue dot net  2008-09-18 17:34 ---
[EMAIL PROTECTED]

Thomas Locke is the main author of this code, I am mostly the mathematician. It
seems to compile and run fine on his 32bit SLAC system, but fails on my SUSE
10.3 64 bit. Prior to the latest update, using the XML/Ada feature at the point
of the bug 
(sheba.adb 58:18 =>  Event_Data := XML.Get_Event_Data_Record (Stack_Index =>
i);
it was also compiling OK on my machine.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37572



[Bug tree-optimization/37573] gcc-4.4 regression: incorrect code generation with -O1 -ftree-vectorize

2008-09-18 Thread edwintorok at gmail dot com


--- Comment #2 from edwintorok at gmail dot com  2008-09-18 17:31 ---
Created an attachment (id=16357)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16357&action=view)
config.log for gcc 4.4

Some more system info:
$ uname -a
Linux debian 2.6.26-1-amd64 #1 SMP Wed Sep 10 15:31:12 UTC 2008 x86_64
GNU/Linux
$ cat /proc/cpuinfo
processor   : 0
vendor_id   : GenuineIntel
cpu family  : 6
model   : 23
model name  : Intel(R) Core(TM)2 Quad  CPU   Q9550  @ 2.83GHz
stepping: 7
cpu MHz : 2000.000
cache size  : 6144 KB
physical id : 0
siblings: 4
core id : 0
cpu cores   : 4
apicid  : 0
initial apicid  : 0
fpu : yes
fpu_exception   : yes
cpuid level : 10
wp  : yes
flags   : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov
pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx lm
constant_tsc arch_perfmon pebs bts rep_good pni monitor ds_cpl vmx smx est tm2
ssse3 cx16 xtpr sse4_1 lahf_lm
bogomips: 5669.97
clflush size: 64
cache_alignment : 64
address sizes   : 36 bits physical, 48 bits virtual
power management:

processor   : 1
vendor_id   : GenuineIntel
cpu family  : 6
model   : 23
model name  : Intel(R) Core(TM)2 Quad  CPU   Q9550  @ 2.83GHz
stepping: 7
cpu MHz : 2000.000
cache size  : 6144 KB
physical id : 0
siblings: 4
core id : 3
cpu cores   : 4
apicid  : 3
initial apicid  : 3
fpu : yes
fpu_exception   : yes
cpuid level : 10
wp  : yes
flags   : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov
pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx lm
constant_tsc arch_perfmon pebs bts rep_good pni monitor ds_cpl vmx smx est tm2
ssse3 cx16 xtpr sse4_1 lahf_lm
bogomips: 5666.05
clflush size: 64
cache_alignment : 64
address sizes   : 36 bits physical, 48 bits virtual
power management:

processor   : 2
vendor_id   : GenuineIntel
cpu family  : 6
model   : 23
model name  : Intel(R) Core(TM)2 Quad  CPU   Q9550  @ 2.83GHz
stepping: 7
cpu MHz : 2000.000
cache size  : 6144 KB
physical id : 0
siblings: 4
core id : 1
cpu cores   : 4
apicid  : 1
initial apicid  : 1
fpu : yes
fpu_exception   : yes
cpuid level : 10
wp  : yes
flags   : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov
pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx lm
constant_tsc arch_perfmon pebs bts rep_good pni monitor ds_cpl vmx smx est tm2
ssse3 cx16 xtpr sse4_1 lahf_lm
bogomips: 5666.03
clflush size: 64
cache_alignment : 64
address sizes   : 36 bits physical, 48 bits virtual
power management:

processor   : 3
vendor_id   : GenuineIntel
cpu family  : 6
model   : 23
model name  : Intel(R) Core(TM)2 Quad  CPU   Q9550  @ 2.83GHz
stepping: 7
cpu MHz : 2000.000
cache size  : 6144 KB
physical id : 0
siblings: 4
core id : 2
cpu cores   : 4
apicid  : 2
initial apicid  : 2
fpu : yes
fpu_exception   : yes
cpuid level : 10
wp  : yes
flags   : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov
pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx lm
constant_tsc arch_perfmon pebs bts rep_good pni monitor ds_cpl vmx smx est tm2
ssse3 cx16 xtpr sse4_1 lahf_lm
bogomips: 5666.03
clflush size: 64
cache_alignment : 64
address sizes   : 36 bits physical, 48 bits virtual
power management:


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37573



[Bug tree-optimization/37573] gcc-4.4 regression: incorrect code generation with -O1 -ftree-vectorize

2008-09-18 Thread edwintorok at gmail dot com


--- Comment #1 from edwintorok at gmail dot com  2008-09-18 17:30 ---
Testcase:
extern int printf (__const char *__restrict __format, ...);
extern int strcmp (__const char *__s1, __const char *__s2);
extern int puts (__const char *__s);
typedef unsigned char uint8_t;
typedef unsigned int uint32_t;
struct MT
{
  uint32_t *next;
  uint32_t items;
  uint32_t mt[624];
};
static uint8_t
MT_getnext (struct MT *MT)
{
  uint32_t r;
  if (!--MT->items)
{
  uint32_t *mt = MT->mt;
  unsigned int i;
  MT->next = mt;
  for (i = 0; i < 227; i++)
mt[i] =
 mt[i] ^ mt[i + 1]) & 0x7ffe) ^ mt[i]) >> 1) ^
   ((0 - (mt[i + 1] & 1)) & 0x9908b0df) ^ mt[i + 397];
}
  r = *(MT->next++);
  r ^= (r >> 11);
  r ^= ((r & 0xff3a58ad) << 7);
  r ^= ((r & 0xdf8c) << 15);
  r ^= (r >> 18);
  return (uint8_t) (r >> 1);
}

static void
MT_decrypt (uint8_t * buf, unsigned int size, uint32_t seed)
{
  struct MT MT;
  unsigned int i;
  uint32_t *mt = MT.mt;
  *mt = seed;
  for (i = 1; i < 624; i++)
mt[i] = i + 0x6c078965 * ((mt[i - 1] >> 30) ^ mt[i - 1]);
  MT.items = 1;
  while (size--)
*buf++ ^= MT_getnext (&MT);
};

static uint8_t buf[23] = {
  0xc0, 0x49, 0x17, 0x32, 0x62, 0x1e, 0x2e, 0xd5, 0x4c, 0x19, 0x28, 0x49,
0x91, 0xe4, 0x72, 0x83, 0x91, 0x3d, 0x93, 0x83, 0xb3, 0x61, 0x38
};

int
main (void)
{
  uint32_t s;
  s = 23;
  MT_decrypt (buf, s, s + 0xa25e);
  if (!strcmp (">AUTOIT UNICODE SCRIPT<", buf))
{
  puts ("OK");
  return 0;
}
  else
{
  printf ("Failed:%s\n", buf);
  return 1;
}
}


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37573



[Bug tree-optimization/37573] New: gcc-4.4 regression: incorrect code generation with -O1 -ftree-vectorize

2008-09-18 Thread edwintorok at gmail dot com
Compiling the testcase below with -O2 works, and fails with -O3.
gcc-4.3 works with both -O2 and -O3.

$ x86_64-unknown-linux-gnu-gcc-4.4.0 -O2 testcase-min.i
$ ./a.out
OK
$ x86_64-unknown-linux-gnu-gcc-4.4.0 -O3 testcase-min.i
$ ./a.out
Failed:
/.G7��G��?�?�;
$ ./a.out
Failed: �G7
h�G��3�?�

$ gcc-4.3 -O3 testcase-min.i
$ ./a.out
OK

Actually it is -ftree-vectorize that causes the failure:

$ x86_64-unknown-linux-gnu-gcc-4.4.0 -O1 -ftree-vectorize testcase-min.i
$ ./a.out
Failed:"�@���@ �?��

The output is random garbage with -O3, but should be '>AUTOIT UNICODE SCRIPT<'.

$ x86_64-unknown-linux-gnu-gcc-4.4.0 --version
x86_64-unknown-linux-gnu-gcc-4.4.0 (GCC) 4.4.0 20080918 (experimental)
Copyright (C) 2008 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

gcc-4.4 is a build from svn:
$ svn info
Path: .
URL: svn://gcc.gnu.org/svn/gcc/trunk
Repository Root: svn://gcc.gnu.org/svn/gcc
Repository UUID: 138bc75d-0d04-0410-961f-82ee72b054a4
Revision: 140456
Node Kind: directory
Schedule: normal
Last Changed Author: amacleod
Last Changed Rev: 140456
Last Changed Date: 2008-09-18 17:07:35 +0300 (Thu, 18 Sep 2008)

$ gcc-4.3 --version
gcc-4.3 (Debian 4.3.2-1) 4.3.2
Copyright (C) 2008 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


-- 
   Summary: gcc-4.4 regression: incorrect code generation with -O1 -
ftree-vectorize
   Product: gcc
   Version: 4.4.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: edwintorok at gmail dot com
 GCC build triplet: x86_64-unknown-linux-gnu-gcc-4.4.0
  GCC host triplet: x86_64-unknown-linux-gnu-gcc-4.4.0
GCC target triplet: x86_64-unknown-linux-gnu-gcc-4.4.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37573



[Bug middle-end/37448] [4.3 Regression] gcc 4.3.1 cannot compile big function

2008-09-18 Thread hubicka at gcc dot gnu dot org


--- Comment #16 from hubicka at gcc dot gnu dot org  2008-09-18 17:30 
---
Subject: Bug 37448

Author: hubicka
Date: Thu Sep 18 17:28:40 2008
New Revision: 140463

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140463
Log:

PR middle-end/37448
* ipa-reference.c (ipa_reference_local_vars_info_d,
ipa_reference_global_vars_info_d,
ipa_reference_local_vars_info_t, ipa_reference_global_vars_info_t,
ipa_reference_vars_info_t): Move here from ipa-reference.h
(node_duplication_hook_holder, node_removal_hook_holder): New.
(get_reference_vars_info_from_cgraph): Rename to ...
(get_reference_vars_info): ... this one, use cgraph uids.
(get_local_reference_vars_info, get_global_reference_vars_info):
Use cgraph instead of decl.
(ipa_reference_get_read_local, ipa_reference_get_written_local):
Remove.
(ipa_reference_get_read_global, ipa_reference_get_not_read_global
ipa_reference_get_written_global,
ipa_reference_get_not_written_global): Use
cgraph argument.
(check_call): Simplify avail check.
(scan_stmt_for_static_refs): Update.
(propagate_bits): Update.
(merge_callee_local_info): Remove.
(init_function_info): Use cgraph nodes.
(clean_function_local_data): Break out from ...
(clean_function): ... here.
(copy_local_bitmap, copy_global_bitmap): New functions.
(duplicate_node_data, remove_node_data): New functions.
(generate_summary): Register hooks; use visibility instead of
master clones.
(propafate): Use cgraph nodes; copy bitmap to each node in cycle.
* ipa-reference.h (ipa_reference_local_vars_info_d,
ipa_reference_global_vars_info_d,
ipa_reference_local_vars_info_t, ipa_reference_global_vars_info_t,
ipa_reference_vars_info_t): Move to ipa-reference.c
(ipa_reference_get_read_local, ipa_reference_get_written_local):
Remove.
(ipa_reference_get_read_global, ipa_reference_get_written_global,
ipa_reference_get_not_read_global,
ipa_reference_get_not_written_global):
Update prototype.
* ipa-pure-const.c (funct_state_vec): Turn into VECtor.
(init_state): Remove.
(node_duplication_hook_holder, node_removal_hook_holder): New.
(get_function_state, set_function_state): Use VECtor.
(analyze_function): Check body availability.
(add_new_function): Likewise.
(duplicate_node_data, remove_node_data): New.
(generate_summary): Register hooks; do not care about clones.
(propafate): Do not care about clones; recursive functions are not
looping.
* ipa-utils.c (searchc, ipa_utils_reduced_inorder): Do not skip clones.
* ipa-prop.c (edge_removal_hook_holder, node_removal_hook_holder,
* edge_duplication_hook_holder, node_duplication_hook_holder): Make
static.
* tree-flow.h (function_ann_d): Remove reference_vars_info.
* tree-ssa-opreands.c (add_call_clobber_ops, add_call_read_ops): Update
call of
ipa-reference accesors.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/ipa-prop.c
trunk/gcc/ipa-pure-const.c
trunk/gcc/ipa-reference.c
trunk/gcc/ipa-reference.h
trunk/gcc/ipa-utils.c
trunk/gcc/tree-ssa-operands.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37448



[Bug ada/37572] compile Ada program fails (XML/Ada, 64 bit AMD)

2008-09-18 Thread jdecs at mssblue dot net


--- Comment #1 from jdecs at mssblue dot net  2008-09-18 17:29 ---
Created an attachment (id=16356)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16356&action=view)
the project file and all the files the bug report from the compiler named


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37572



[Bug ada/37572] New: compile Ada program fails (XML/Ada, 64 bit AMD)

2008-09-18 Thread jdecs at mssblue dot net
(Bear with me, this is the first time I have done this!)
[EMAIL PROTECTED]:~> gcc -v
Using built-in specs.
Target: x86_64-suse-linux
Configured with: ../configure --enable-threads=posix --prefix=/usr
--with-local-prefix=/usr/local --infodir=/usr/share/info
--mandir=/usr/share/man --libdir=/usr/lib64 --libexecdir=/usr/lib64
--enable-languages=c,c++,objc,fortran,obj-c++,java,ada
--enable-checking=release --with-gxx-include-dir=/usr/include/c++/4.2.1
--enable-ssp --disable-libssp --disable-libgcj --with-slibdir=/lib64
--with-system-zlib --enable-shared --enable-__cxa_atexit
--enable-libstdcxx-allocator=new --disable-libstdcxx-pch --program-suffix=-4.2
--enable-version-specific-runtime-libs --without-system-libunwind
--with-cpu=generic --host=x86_64-suse-linux
Thread model: posix
gcc version 4.2.1 (SUSE Linux)

The tbug command contains: BUILD=Debug gnatmake -P Project_File.gpr

[EMAIL PROTECTED]:~/Ada/Sheba> ../tbug
gcc -c -gnatQ -shared -E -gnat05 -gnatwcfijkmruv -gnaty3abcefhiklmnoprstx -Wall
-g -gnata -gnatVa -gnatQ -gnato -gnatwe -I- -gnatA
/home/JDECS/Ada/Sheba/sheba.adb
+===GNAT BUG DETECTED==+
| 4.2.1 (SUSE Linux) (x86_64-suse-linux-gnu) Assert_Failure atree.adb:812  |
| Error detected at sheba.adb:58:18|
| Please submit a bug report; see http://gcc.gnu.org/bugs.html.|
| Use a subject line meaningful to you and us to track the bug.|
| Include the entire contents of this bug box in the report.   |
| Include the exact gcc or gnatmake command that you entered.  |
| Also include sources listed below in gnatchop format |
| (concatenated together with no headers between files).   |
+==+

Please include these source files with error report
Note that list may not be accurate in some cases,
so please double check that the problem can still
be reproduced with the set of files listed.

/home/JDECS/Ada/Sheba/sheba.adb
/home/JDECS/Ada/Sheba/source/agent.ads
/home/JDECS/Ada/Sheba/source/event.ads
/home/JDECS/Ada/Sheba/source/event_pattern.ads
/home/JDECS/Ada/Sheba/source/xml_config.ads
/usr/share/include/xmlada/dom.ads
/usr/share/include/xmlada/dom-core.ads
/usr/share/include/xmlada/unicode.ads
/usr/share/include/xmlada/unicode-ces.ads
/usr/share/include/xmlada/sax.ads
/usr/share/include/xmlada/sax-htable.ads

compilation abandoned
gcc -c -gnatQ -shared -E -gnat05 -gnatwcfijkmruv -gnaty3abcefhiklmnoprstx -Wall
-g -gnata -gnatVa -gnatQ -gnato -gnatwe -I- -gnatA
/home/JDECS/Ada/Sheba/source/agent.adb
gcc -c -gnatQ -shared -E -gnat05 -gnatwcfijkmruv -gnaty3abcefhiklmnoprstx -Wall
-g -gnata -gnatVa -gnatQ -gnato -gnatwe -I- -gnatA
/home/JDECS/Ada/Sheba/source/event.adb
gcc -c -gnatQ -shared -E -gnat05 -gnatwcfijkmruv -gnaty3abcefhiklmnoprstx -Wall
-g -gnata -gnatVa -gnatQ -gnato -gnatwe -I- -gnatA
/home/JDECS/Ada/Sheba/source/event_pattern.adb
gcc -c -gnatQ -shared -E -gnat05 -gnatwcfijkmruv -gnaty3abcefhiklmnoprstx -Wall
-g -gnata -gnatVa -gnatQ -gnato -gnatwe -I- -gnatA
/home/JDECS/Ada/Sheba/source/xml_config.adb
gnatmake: "/home/JDECS/Ada/Sheba/sheba.adb" compilation error
[EMAIL PROTECTED]:~/Ada/Sheba>

Do I attach the source here or somewhere else?


-- 
   Summary: compile Ada program fails (XML/Ada, 64 bit AMD)
   Product: gcc
   Version: 4.2.1
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: ada
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: jdecs at mssblue dot net


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37572



[Bug c++/35782] support for standard layout types

2008-09-18 Thread jason at gcc dot gnu dot org


--- Comment #8 from jason at gcc dot gnu dot org  2008-09-18 17:01 ---
(In reply to comment #7)
> Lawrence's suggestion won't work because the copy constructor is deleted.

It seems I was wrong about this: the wording that went into the standard
doesn't require the copy for copy-list-initialization.  Guess I need to fix the
compiler.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35782



[Bug middle-end/37448] [4.3 Regression] gcc 4.3.1 cannot compile big function

2008-09-18 Thread hubicka at gcc dot gnu dot org


--- Comment #15 from hubicka at gcc dot gnu dot org  2008-09-18 16:49 
---
We seem to make nice progress on the testcase ;)

Conversion to FUD would probably help here, but looking at the DF dumps, the
testcase don't look like your average testcase showing DU/UD chain explosion. 
The chains seem relatively short at least in manual inspection through first
part of dump. Yet we produe about 40 DU/UD records live at once for every
instruction ever emit, so it seems we are doing some wrong still.

If someone more familiar with dataflow branch could look into why we have so
many DU/UDs, it would be great.

Honza


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37448



[Bug middle-end/37372] [graphite] SCoP detection splits bbs / Define SCoPs with single entry and exit edge

2008-09-18 Thread grosser at gcc dot gnu dot org


--- Comment #5 from grosser at gcc dot gnu dot org  2008-09-18 16:34 ---
I need to read the paper now. It seems I was not informed about any updates by
the bugtracker so I just got the information. Sorry.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37372



[Bug middle-end/37372] [graphite] SCoP detection splits bbs / Define SCoPs with single entry and exit edge

2008-09-18 Thread grosser at gcc dot gnu dot org


--- Comment #4 from grosser at gcc dot gnu dot org  2008-09-18 16:25 ---
Created an attachment (id=16355)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16355&action=view)
Create single entry single exit edges for the SCoPs of the SCoP detection

Here is a idea how to handle the single exit single entry edges. Have also a
look at this mail:
http://gcc.gnu.org/ml/gcc-patches/2008-09/msg01324.html

I would just like to discuss the idea. A little explanation that was not
possible during our phone call today (Since about two minutes my
internet is working again)

During SCoP detection we can not represent the SCoPs as a single exit
single entry region as it is described in the graphite.h SCOP_REGION, as
this data structure uses a single edge to describe e.g. the entry.

But code like

  |  1  2
  |  | /
  |  |/
  |  3  <- entry
  |  |\
  |  | |
  |  4 ^
  |  | |
  |  |/
  |  5


is also single entry, even if we do not have a single entry edge. But
the edges (1->3, 2->3) can easily be combined using a forwarder bb.

  |  1  2
  |  | /
  |  |/
  |3.0
  |  |  (3.0 -> 3.1) = entry edge
  |3.1  <- entry
  |  |\
  |  | |
  |  4 ^
  |  | |
  |  |/
  |  5  */

Here we get a single entry edge.

If we do not want to modify the CFG during SCoP detection, we have to
use a representation (sd_region), that is able to represent SCoPs
like the above.
After SCoP detection we can introduce forwarder blocks, to be able to
use a single edges to describe the entry and exit points.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37372



[Bug rtl-optimization/37571] Performance regression with -mtune=core2

2008-09-18 Thread hjl dot tools at gmail dot com


--- Comment #2 from hjl dot tools at gmail dot com  2008-09-18 16:10 ---
(In reply to comment #1)
> Root cause is that instruction length of fused jcc is set to 16, which prevent
> the block from merging and copying. For some reason Core2 runs poorly with a
> unmerged branch block under certain circonstances.
> 
> Following patch fixes it:
> 
> Index: i386.md

>  (include "k6.md")
>  (include "athlon.md")
>  (include "geode.md")
> -;;(include "core2.md")
> +(include "core2.md")
> 

Your patch won't work on trunk. Can you provide a patch
for trunk?


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37571



[Bug rtl-optimization/37571] Performance regression with -mtune=core2

2008-09-18 Thread Joey dot ye at intel dot com


--- Comment #1 from Joey dot ye at intel dot com  2008-09-18 16:01 ---
Root cause is that instruction length of fused jcc is set to 16, which prevent
the block from merging and copying. For some reason Core2 runs poorly with a
unmerged branch block under certain circonstances.

Following patch fixes it:

Index: i386.md
===
--- i386.md (revision 3923)
+++ i386.md (working copy)
@@ -421,6 +421,9 @@
 ]
 (const_int 1)))

+(define_attr "length_jcc_fuse" ""
+  (const_int 0))
+
 ;; The (bounding maximum) length of an instruction in bytes.
 ;; ??? fistp and frndint are in fact fldcw/{fistp,frndint}/fldcw sequences.
 ;; Later we may want to split them and compute proper length as for
@@ -442,7 +445,8 @@
   (plus (attr "prefix_rep")
 (plus (attr "prefix_data16")
   (plus (attr "length_immediate")
-(attr "length_address")))
+(plus (attr "length_address")
+   (attr "length_jcc_fuse"

 ;; The `memory' attribute is `none' if no memory is referenced, `load' or
 ;; `store' if there is a simple memory reference therein, or `unknown'
@@ -645,7 +649,7 @@
 (include "k6.md")
 (include "athlon.md")
 (include "geode.md")
-;;(include "core2.md")
+(include "core2.md")


 ;; Operand and operator predicates and constraints
@@ -14033,7 +14037,8 @@
   return "test{}\t%2, %2\n\t"
 "%+j%E1\t%l0\t" ASM_COMMENT_START " fused";
 }
-  [(set_attr "type" "multi")
+  [(set_attr "type" "icmp")
+   (set_attr "length_jcc_fuse" "2")
(set_attr "mode" "")])

 (define_insn "*jcc_fused_2"
@@ -14048,7 +14053,8 @@
   return "test{}\t%2, %2\n\t"
 "%+j%e1\t%l0\t" ASM_COMMENT_START " fused";
 }
-  [(set_attr "type" "multi")
+  [(set_attr "type" "icmp")
+   (set_attr "length_jcc_fuse" "2")
(set_attr "mode" "")])

 (define_insn "*jcc_fused_3"
@@ -14066,7 +14072,8 @@
   return "cmp{}\t{%3, %2|%2, %3}\n\t"
 "%+j%E1\t%l0\t" ASM_COMMENT_START " fused";
 }
-  [(set_attr "type" "multi")
+  [(set_attr "type" "icmp")
+   (set_attr "length_jcc_fuse" "2")
(set_attr "mode" "")])

 (define_insn "*jcc_fused_4"
@@ -14084,7 +14091,8 @@
   return "cmp{}\t{%3, %2|%2, %3}\n\t"
 "%+j%e1\t%l0\t" ASM_COMMENT_START " fused";
 }
-  [(set_attr "type" "multi")
+  [(set_attr "type" "icmp")
+   (set_attr "length_jcc_fuse" "2")
(set_attr "mode" "")])

 ;; In general it is not safe to assume too much about CCmode registers,


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37571



[Bug rtl-optimization/37571] New: Performance regression with -mtune=core2

2008-09-18 Thread Joey dot ye at intel dot com
On Core2 ix86 machine following case (reduced from cpu2000.mcf) runs 50% slower
if compiled with trunk -mtune=core2 -O2

unsigned int g_i,g_j;
unsigned int g_a=1,g_b;
void __attribute__((noinline)) foo()
{
do {
if (g_a & g_i)
{g_i++;}
else
{g_j++;}
 } while (g_b--);
}

int main()
{
int i;
for (i=0; i<4; i++)
{
g_b=0x7fff;
foo();
}
return 0;
}


-- 
   Summary: Performance regression with -mtune=core2
   Product: gcc
   Version: 4.4.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: rtl-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: Joey dot ye at intel dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37571



[Bug c++/37570] New: friend class expected to have access over a class-es private members but doesn't and gives "internal compile error"

2008-09-18 Thread stefan dot petrea at gmail dot com
I will give full details about my compiler version at the end of this message.


piece of code I tried to run:

  1 
  2 
  3 #include 
  4 
  5 using namespace std;
  6 
  7 
  8 
  9 
 10 
 11 class A {
 12 friend class AOnClick;
 13 private:
 14 int g;
 15 public:
 16  A(){ r = 300 ; g=20;};
 17 ~A(){};
 18 int r;
 19 };
 20 
 21 
 22 
 23 
 24 
 25 
 26 int main() {
 27 A a;
 28 
 29 class AOnClick {
 30 friend class A;
 31 public:
 32 AOnClick(A* a1) { cout for instructions.
For Debian GNU/Linux specific bug reporting instructions,
see .
Preprocessed source stored into /tmp/ccgvFQ3G.out file, please attach this to
your bugreport.



The full details about the compiler I'm using:




Using built-in specs.
Target: i486-linux-gnu
Configured with: ../src/configure -v
--enable-languages=c,c++,fortran,objc,obj-c++,treelang --prefix=/usr
--enable-shared --with-system-zlib --libexecdir=/usr/lib
--without-included-gettext --enable-threads=posix --enable-nls
--program-suffix=-4.1 --enable-__cxa_atexit --enable-clocale=gnu
--enable-libstdcxx-debug --enable-mpfr --with-tune=i686
--enable-checking=release i486-linux-gnu
Thread model: posix
gcc version 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)


-- 
   Summary: friend class expected to have access over a class-es
private members but doesn't and gives "internal compile
error"
   Product: gcc
   Version: 4.1.2
Status: UNCONFIRMED
  Severity: major
  Priority: P3
 Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: stefan dot petrea at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37570



[Bug tree-optimization/37258] [4.4 Regression] ice in simplify_subreg, at simplify-rtx.c:4957

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #5 from rguenth at gcc dot gnu dot org  2008-09-18 15:46 ---
Fixed.


-- 

rguenth at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37258



[Bug tree-optimization/37258] [4.4 Regression] ice in simplify_subreg, at simplify-rtx.c:4957

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #4 from rguenth at gcc dot gnu dot org  2008-09-18 15:28 ---
Subject: Bug 37258

Author: rguenth
Date: Thu Sep 18 15:27:21 2008
New Revision: 140460

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140460
Log:
2008-09-18  Richard Guenther  <[EMAIL PROTECTED]>

PR tree-optimization/37258
* tree-ssa-sccvn.c (vn_phi_compute_hash): Include the precision
and signedness for integral types.
(vn_phi_eq): Require compatible types.

* gcc.c-torture/compile/pr37258.c: New testcase.

Added:
trunk/gcc/testsuite/gcc.c-torture/compile/pr37258.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-ssa-sccvn.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37258



[Bug debug/34037] [4.2/4.3/4.4 Regression] Bounds for VLAs not emitted into debuginfo

2008-09-18 Thread jakub at gcc dot gnu dot org


--- Comment #6 from jakub at gcc dot gnu dot org  2008-09-18 15:18 ---
Fixed on the trunk.


-- 

jakub at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34037



[Bug debug/34037] [4.2/4.3/4.4 Regression] Bounds for VLAs not emitted into debuginfo

2008-09-18 Thread jakub at gcc dot gnu dot org


--- Comment #5 from jakub at gcc dot gnu dot org  2008-09-18 15:18 ---
Subject: Bug 34037

Author: jakub
Date: Thu Sep 18 15:17:10 2008
New Revision: 140459

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140459
Log:
PR debug/34037
* gimplify.c (gimplify_type_sizes): When not optimizing, ensure
TYPE_MIN_VALUE and TYPE_MAX_VALUE is not is not DECL_IGNORED_P
VAR_DECL.
* cfgexpand.c (expand_used_vars): Keep DECL_ARTIFICIAL
!DECL_IGNORED_P vars in local_decls list for instantiate_decls,
ggc_free other TREE_LIST nodes from that chain.
* function.c (instantiate_decls): Instantiate also DECL_RTL
of vars in cfun->local_decls, free that list afterwards.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/cfgexpand.c
trunk/gcc/function.c
trunk/gcc/gimplify.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34037



[Bug rtl-optimization/37544] Conversion double -> unsigned long long -> unsigned -> double gives wrong results

2008-09-18 Thread ubizjak at gmail dot com


--- Comment #13 from ubizjak at gmail dot com  2008-09-18 14:31 ---
Fixed for 4.4, latent on 4.3 and 4.2.

BTW: This problem was uncovered by the patch that fixed PR target/13958 [1].

[1] http://gcc.gnu.org/ml/gcc-patches/2008-03/msg01295.html


-- 

ubizjak at gmail dot com changed:

   What|Removed |Added

Summary|[4.4 Regression] Conversion |Conversion double ->
   |double -> unsigned long long|unsigned long long ->
   |-> unsigned -> double gives |unsigned -> double gives
   |wrong results   |wrong results


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37544



[Bug target/37394] [4.4 Regression] Segfault in ia64_variable_issue with -O -fschedule-insns2

2008-09-18 Thread hjl dot tools at gmail dot com


--- Comment #9 from hjl dot tools at gmail dot com  2008-09-18 14:14 ---
A patch is posted at

http://gcc.gnu.org/ml/gcc-patches/2008-09/msg01275.html


-- 

hjl dot tools at gmail dot com changed:

   What|Removed |Added

 CC||sje at cup dot hp dot com
URL||http://gcc.gnu.org/ml/gcc-
   ||patches/2008-
   ||09/msg01275.html


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37394



[Bug tree-optimization/37102] [4.3/4.4 Regression] out-of-SSA is broken

2008-09-18 Thread amacleod at gcc dot gnu dot org


--- Comment #18 from amacleod at redhat dot com  2008-09-18 14:00 ---
Subject: Bug 37102

Author: amacleod
Date: Thu Sep 18 13:58:55 2008
New Revision: 140455

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140455
Log:
fix PR 37102 by having out of ssa remove dead PHI nodes.


Added:
trunk/gcc/testsuite/gcc.c-torture/execute/pr37102.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-outof-ssa.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37102



[Bug tree-optimization/37258] [4.4 Regression] ice in simplify_subreg, at simplify-rtx.c:4957

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #3 from rguenth at gcc dot gnu dot org  2008-09-18 13:49 ---
The problem is that

  int64_t p1;
  int p;

  p1 = PHI <1, 0>
  p = PHI <1, 0>

are value-numbered the same.  I have a patch.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37258



[Bug ada/37431] SPARC ACATS failures for alignment

2008-09-18 Thread joel at gcc dot gnu dot org


--- Comment #2 from joel at gcc dot gnu dot org  2008-09-18 13:41 ---
ACATS for 4.3.2 

http://gcc.gnu.org/ml/gcc-testresults/2008-09/msg00876.html


-- 

joel at gcc dot gnu dot org changed:

   What|Removed |Added

  Known to work|4.3.0   |4.3.0 4.3.2


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37431



[Bug tree-optimization/34416] Tree optimization pipeline needs re-tuning

2008-09-18 Thread rguenth at gcc dot gnu dot org


-- 

rguenth at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
   Last reconfirmed|-00-00 00:00:00 |2008-09-18 12:55:11
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34416



[Bug tree-optimization/34416] Tree optimization pipeline needs re-tuning

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #4 from rguenth at gcc dot gnu dot org  2008-09-18 12:55 ---
Confirmed.   For 4.4 the following was done:

2008-08-20  Richard Guenther  <[EMAIL PROTECTED]>

* passes.c (init_optimization_passes): Move the second
forwprop pass before alias computation.  Remove the second
DCE pass.  Remove the first dominator and phi copy/const
prop passes.

2008-08-19  Richard Guenther  <[EMAIL PROTECTED]>

* passes.c (init_optimization_passes): Exchange store-ccp
with a ccp pass.

2008-08-18  Richard Guenther  <[EMAIL PROTECTED]>

* passes.c (init_optimization_passes): Remove cleanup_cfg1,
sdse1 and addressables2 passes.  Replace dce1 with cddce1.
Move call_cdce before build_alias.  Move copyrename2,
cunrolli and ccp2 beafore build_alias.  Re-add addressable2
right after final inlining.


unassigning for now.


-- 

rguenth at gcc dot gnu dot org changed:

   What|Removed |Added

 AssignedTo|rguenth at gcc dot gnu dot  |unassigned at gcc dot gnu
   |org |dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34416



[Bug middle-end/37284] [4.4 Regression] ICE on valid code with -fstrict-aliasing

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #7 from rguenth at gcc dot gnu dot org  2008-09-18 12:53 ---
Subject: Bug 37284

Author: rguenth
Date: Thu Sep 18 12:52:31 2008
New Revision: 140453

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140453
Log:
2008-09-18  Richard Guenther  <[EMAIL PROTECTED]>

PR middle-end/37284
* tree-cfg.c (remove_useless_stmts_1): Remove
GIMPLE_CHANGE_DYNAMIC_TYPE if not optimizing.

* g++.dg/tree-ssa/pr37284.C: New testcase.

Added:
trunk/gcc/testsuite/g++.dg/tree-ssa/pr37284.C
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-cfg.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37284



[Bug middle-end/37284] [4.4 Regression] ICE on valid code with -fstrict-aliasing

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #6 from rguenth at gcc dot gnu dot org  2008-09-18 12:52 ---
Fixed.


-- 

rguenth at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37284



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread ppr at melexis dot com


--- Comment #13 from ppr at melexis dot com  2008-09-18 12:15 ---
(In reply to comment #12)
> Note you can do the same as AVR does - force flag_delete_null_pointer_checks 
> to
> zero:
> 

Thanks for the hint, I'll use it!

Plamen


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug fortran/37507] Print location in (DE)ALLOCATION errors

2008-09-18 Thread domob at gcc dot gnu dot org


--- Comment #4 from domob at gcc dot gnu dot org  2008-09-18 12:06 ---
Fixed for trunk.


-- 

domob at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37507



[Bug fortran/37507] Print location in (DE)ALLOCATION errors

2008-09-18 Thread domob at gcc dot gnu dot org


--- Comment #3 from domob at gcc dot gnu dot org  2008-09-18 12:04 ---
Subject: Bug 37507

Author: domob
Date: Thu Sep 18 12:02:50 2008
New Revision: 140451

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140451
Log:
2008-09-18  Daniel Kraft  <[EMAIL PROTECTED]>

PR fortran/37507
* trans.h (gfc_trans_runtime_error): New method.
(gfc_trans_runtime_error_vararg): New method.
(gfc_allocate_array_with_status): New argument `expr' for
locus/varname.
(gfc_deallocate_array_with_status): Ditto.
* trans-array.h (gfc_array_deallocate): Ditto.
* trans.c (gfc_trans_runtime_error): New method.
(gfc_trans_runtime_error_vararg): New method, moved parts of the code
from gfc_trans_runtime_check here.
(gfc_trans_runtime_error_check): Moved code partly to new method.
(gfc_call_malloc): Fix tab-indentation.
(gfc_allocate_array_with_status): New argument `expr' and call
gfc_trans_runtime_error for error reporting to include locus.
(gfc_deallocate_with_status): Ditto.
* trans-stmt.c (gfc_trans_deallocate): Pass expr as new argument.
* trans-array.c (gfc_array_allocate): Ditto.
(gfc_array_deallocate): New argument `expr', passed on.
(gfc_trans_dealloc_allocated): Pass NULL for expr.
* trans-openmp.c (gfc_omp_clause_default): Ditto.

2008-09-18  Daniel Kraft  <[EMAIL PROTECTED]>

PR fortran/37507
* gfortran.dg/allocate_error_1.f90: New test.
* gfortran.dg/deallocate_error_1.f90: New test.
* gfortran.dg/deallocate_error_2.f90: New test.

Added:
trunk/gcc/testsuite/gfortran.dg/allocate_error_1.f90
trunk/gcc/testsuite/gfortran.dg/deallocate_error_1.f90
trunk/gcc/testsuite/gfortran.dg/deallocate_error_2.f90
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/trans-array.c
trunk/gcc/fortran/trans-array.h
trunk/gcc/fortran/trans-openmp.c
trunk/gcc/fortran/trans-stmt.c
trunk/gcc/fortran/trans.c
trunk/gcc/fortran/trans.h
trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37507



[Bug middle-end/37535] [4.4 Regression] gcc/libgcc2.c:404: internal compiler error: Floating point exception

2008-09-18 Thread krebbel at gcc dot gnu dot org


--- Comment #8 from krebbel at gcc dot gnu dot org  2008-09-18 12:02 ---
This also seem to break S/390 bootstrap currently.  Please see:
http://gcc.gnu.org/ml/gcc/2008-09/msg00304.html


-- 

krebbel at gcc dot gnu dot org changed:

   What|Removed |Added

 CC||krebbel at gcc dot gnu dot
   ||org
 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
   Last reconfirmed|-00-00 00:00:00 |2008-09-18 12:02:59
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37535



[Bug middle-end/37456] [4.4 Regression] ICE: verify_flow_info failed: control flow in the middle of basic block

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #7 from rguenth at gcc dot gnu dot org  2008-09-18 11:29 ---
Subject: Bug 37456

Author: rguenth
Date: Thu Sep 18 11:28:18 2008
New Revision: 140449

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140449
Log:
2008-09-18  Richard Guenther  <[EMAIL PROTECTED]>

PR tree-optimization/37456
* tree-ssa-reassoc.c (build_and_add_sum): If the stmt we
want to insert after ends a BB insert on the single fallthru
outgoing edge.

* testsuite/g++.dg/torture/pr37456.C: New testcase.

Added:
trunk/gcc/testsuite/g++.dg/torture/pr37456.C
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-ssa-reassoc.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37456



[Bug middle-end/37456] [4.4 Regression] ICE: verify_flow_info failed: control flow in the middle of basic block

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #6 from rguenth at gcc dot gnu dot org  2008-09-18 11:28 ---
Fixed.


-- 

rguenth at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37456



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #12 from rguenth at gcc dot gnu dot org  2008-09-18 11:11 
---
Note you can do the same as AVR does - force flag_delete_null_pointer_checks to
zero:

grep flag_delete_null_pointer_checks config/*/*.c
config/avr/avr.c:  flag_delete_null_pointer_checks = 0;


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread ppr at melexis dot com


--- Comment #11 from ppr at melexis dot com  2008-09-18 10:57 ---
(In reply to comment #10)

This workaround doesn't work with GCC 3.4.3 (the base for our 16-bit port). It
does work with the latest GCC4.3 though.

Anyway, thanks for your support, and for explaining the reasons behind the
compiler's behaviour.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread brian at dessent dot net


--- Comment #10 from brian at dessent dot net  2008-09-18 10:45 ---
Subject: Re:  Loop incorrectly optimized to endless loop with 
 -Os/-O2/-O3

That fact that the hardware allows it doesn't change the fact that it's
still invalid in ISO C, and that is the spec that gcc follows.

Seems to me you can avoid invoking undefined behavior by:

uint16 i = 0x0FFE, sum = 0;
do {
  i -= sizeof (uint16);
  sum += *((uint16 *)i);
} while (i);


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread ppr at melexis dot com


--- Comment #9 from ppr at melexis dot com  2008-09-18 10:20 ---
(In reply to comment #8)
> I think this code is invalid.  I seem to recall the argument that it's
> undefined behavior to increment or decrement a pointer to 0.

Well, the pointer is not NULL initially, it's just decremented until it reaches
 zero. I agree this code doesn't make much sense in i686-pc environment, but
I've discovered the issue while working with GCC port for 16-bit
microcontroller. The routine is used to calculate ROM checksum and address 0 is
a perfectly valid address at this target.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug rtl-optimization/37544] [4.4 Regression] Conversion double -> unsigned long long -> unsigned -> double gives wrong results

2008-09-18 Thread uros at gcc dot gnu dot org


--- Comment #12 from uros at gcc dot gnu dot org  2008-09-18 10:19 ---
Subject: Bug 37544

Author: uros
Date: Thu Sep 18 10:17:42 2008
New Revision: 140446

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140446
Log:
PR rtl-optimization/37544
* regrename.c (maybe_mode_change): Exit early when copy_mode
is narrower than orig_mode and narrower than new_mode.

testsuite/ChangeLog:

PR rtl-optimization/37544
* gcc.dg/pr37544.c: New test.


Added:
trunk/gcc/testsuite/gcc.dg/pr37544.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/regrename.c
trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37544



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread brian at dessent dot net


--- Comment #8 from brian at dessent dot net  2008-09-18 09:25 ---
Subject: Re:   New: Loop incorrectly optimized to endless loop with 
 -Os/-O2/-O3

I think this code is invalid.  I seem to recall the argument that it's
undefined behavior to increment or decrement a pointer to 0.

Speaking of the binary addition and subtraction operators when applied
to a pointer and integer constant, C99 6.5.6 #8 says that "If both the
pointer operand and the result point to elements of the same array
object, or one past the last element of the array object, the evaluation
shall not produce an overflow; otherwise, the behavior is undefined.

6.3.2.3 #3 says that "[a null pointer] is guaranteed to compare unequal
to a pointer to any object or function".

Thus if the null pointer is the result of subtracting an integer
constant from a pointer, it is undefined behavior because it cannot
possibly be pointing to any valid object, let alone one that is within
the allowed range in 6.5.6.  So the compiler is allowed to assume that
"--i" can never result in the null pointer in valid code, and optimizes
away the test.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #7 from rguenth at gcc dot gnu dot org  2008-09-18 08:57 ---
Well ... VRP validly asserts that i_7 is not NULL after dereferencing it:

:
  # i_2 = PHI <4094B(2), i_20(8)>
  # sum_1 = PHI <0(2), sum_9(8)>
  i_7 = i_2 + -4;
  D.1209_8 = *i_7;
  i_20 = ASSERT_EXPR ;
  sum_9 = D.1209_8 + sum_1;
  if (i_20 != 0B)
goto ;
  else
goto ;

:
  goto ;


which makes it optimize the check for i_20 != NULL to true.

You can work around this with -fno-delete-null-pointer-checks, but frankly
in a hosted i686-pc-cygwin environment the code is just broken.


-- 

rguenth at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||INVALID


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug middle-end/37567] tree SSA to normal checking takes abnormally long time

2008-09-18 Thread rguenth at gcc dot gnu dot org


--- Comment #1 from rguenth at gcc dot gnu dot org  2008-09-18 08:49 ---
While there's a lot of checking code in out-of-ssa I don't see any that
should cause this slowdown.  Can you possibly profile it and point to
the worts offender?


-- 

rguenth at gcc dot gnu dot org changed:

   What|Removed |Added

 CC||rguenth at gcc dot gnu dot
   ||org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37567



[Bug tree-optimization/37539] Hang for -O3

2008-09-18 Thread irar at il dot ibm dot com


-- 

irar at il dot ibm dot com changed:

   What|Removed |Added

 AssignedTo|unassigned at gcc dot gnu   |irar at il dot ibm dot com
   |dot org |
 Status|NEW |ASSIGNED
   Last reconfirmed|2008-09-18 07:26:21 |2008-09-18 08:43:27
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37539



[Bug middle-end/37499] [4.4 Regression] Scheduling pass 2 time increases by order of magnitude

2008-09-18 Thread amonakov at gcc dot gnu dot org


--- Comment #7 from amonakov at gcc dot gnu dot org  2008-09-18 08:34 
---
Fixed with above commit.


-- 

amonakov at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37499



[Bug middle-end/37499] [4.4 Regression] Scheduling pass 2 time increases by order of magnitude

2008-09-18 Thread amonakov at gcc dot gnu dot org


--- Comment #6 from amonakov at gcc dot gnu dot org  2008-09-18 08:31 
---
Subject: Bug 37499

Author: amonakov
Date: Thu Sep 18 08:29:48 2008
New Revision: 140445

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=140445
Log:
2008-09-18  Alexander Monakov  <[EMAIL PROTECTED]>

PR middle-end/37499
* sched-int.h (struct _haifa_insn_data): Remove unused field
ref_count.

* sched-rgn.c (ref_counts): Remove.
(insn_referenced): New static variable.
(INSN_REF_COUNT): Remove.
(sched_run_compute_dependencies): Use insn_referenced instead of
INSN_REF_COUNT.
(add_branch_dependences): Likewise.  Delete dead assignment.


Modified:
trunk/gcc/ChangeLog
trunk/gcc/sched-int.h
trunk/gcc/sched-rgn.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37499



[Bug tree-optimization/30930] [4.3/4.4 Regression] vector can cause to create an extra variable, DECL_GIMPLE_REG_P not recomputed

2008-09-18 Thread rguenther at suse dot de


--- Comment #12 from rguenther at suse dot de  2008-09-18 08:23 ---
Subject: Re:  [4.3/4.4 Regression] vector can
 cause to create an extra variable, DECL_GIMPLE_REG_P not recomputed

On Wed, 17 Sep 2008, pinskia at gcc dot gnu dot org wrote:

> --- Comment #10 from pinskia at gcc dot gnu dot org  2008-09-17 22:50 
> ---
> Here is a testcase where we were missing an optimization at the tree level
> because of DECL_GIMPLE_REG_P:
> #define vector __attribute__(( vector_size(16) ))
> 
> float f(vector float a, int b, vector float c)
> {
>   vector float dd = c*a;
>   a = (vector float){0,0,0,0};
>   c = (vector float){0,0,0,0};
>   {
>float d = ((float*)&a)[0];
>float d1 = ((float*)&c)[0];
>return d*d1;
>   }
> }

I wonder why we not just can add both, TREE_ADDRESSABLE and
DECL_GIMPLE_REG_P ...

Richard.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30930



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread ppr at melexis dot com


--- Comment #6 from ppr at melexis dot com  2008-09-18 08:22 ---
(In reply to comment #5)
> another vrp bug? -fno-tree-vrp helps.
> 
Yes, -fno-tree-vrp does help


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread pluto at agmk dot net


--- Comment #5 from pluto at agmk dot net  2008-09-18 08:08 ---
another vrp bug? -fno-tree-vrp helps.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread ppr at melexis dot com


--- Comment #4 from ppr at melexis dot com  2008-09-18 07:58 ---
The problem seems to be related with the i pointer reaching 0. If the loop
condition is e.g. "while ( i != 2 )" everything is ok.
The same if the "sum = sum + *(i)" is replaced e.g. with "sum = sum + *(i+1)"


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread ppr at melexis dot com


--- Comment #3 from ppr at melexis dot com  2008-09-18 07:53 ---
Created an attachment (id=16354)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16354&action=view)
The compiler output


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread ppr at melexis dot com


--- Comment #2 from ppr at melexis dot com  2008-09-18 07:53 ---
Created an attachment (id=16353)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16353&action=view)
The produced assembler source


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread ppr at melexis dot com


--- Comment #1 from ppr at melexis dot com  2008-09-18 07:52 ---
Created an attachment (id=16352)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16352&action=view)
preprocessed source of the test case


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



[Bug c/37569] New: Loop incorrectly optimized to endless loop with -Os/-O2/-O3

2008-09-18 Thread ppr at melexis dot com
The loop in the example is incorrectly replaced with endless loop when
compiling with -Os, -O2 or -O3. It is compiled correctly with -O0 or -O1.

uint16 sum=0;
uint16 *i;

/*sum all words in inspected area*/
i = (uint16 *)0x0FFE;
do
{
--i;
sum = sum + *(i);
} while ( i != 0 );

(see the full source in the attachment)

Target: i686-pc-cygwin
Configured with: ../gcc-4.3.2/configure
Thread model: single
gcc version 4.3.2 (GCC) 

(the same problem occurs with earlier versions of GCC (e.g. 3.4.3) and G++ )


-- 
   Summary: Loop incorrectly optimized to endless loop with -Os/-
O2/-O3
   Product: gcc
   Version: 4.3.2
Status: UNCONFIRMED
  Severity: major
  Priority: P3
 Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: ppr at melexis dot com
  GCC host triplet: i686-pc-cygwin


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37569



  1   2   >