[Bug c++/30567] -fPIC -O3 optimizer bug (32-bit target only)

2007-02-25 Thread rwgk at yahoo dot com


--- Comment #16 from rwgk at yahoo dot com  2007-02-26 07:54 ---
Created an attachment (id=13110)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13110&action=view)
minimal reproducer

I got it down to 29 lines. There aren't any includes, defines are typedefs
left.
Attempts to further reduce the code change the result.
The command line I used during the reduction process was:

g++ -fPIC -O3 dbg_minimal.cpp && ./a.out ; echo $status ; g++ -fPIC -O0
dbg_minimal.cpp && ./a.out ; echo $status

The resulting output is:
0
1

Here 0 indicates failure.

I really hope this helps you pin-pointing the bug!

For completeness:
% g++ --version
g++ (GCC) 4.2.0 20070225 (prerelease)

This is SVN revision 122315.


-- 

rwgk at yahoo dot com changed:

   What|Removed |Added

  Attachment #12945|0   |1
is obsolete||


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



[Bug target/30770] [4.3 regression] BOOT_CFLAGS="-O2 -g -mtune=nocona" miscompiled the stage 3 compiler

2007-02-25 Thread ubizjak at gmail dot com


--- Comment #8 from ubizjak at gmail dot com  2007-02-26 07:05 ---
Fixed in SVN.


-- 

ubizjak at gmail dot com changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


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



[Bug target/30778] [4.3 Regression] invalid code generation for memset() with -mtune=k8

2007-02-25 Thread ubizjak at gmail dot com


--- Comment #9 from ubizjak at gmail dot com  2007-02-26 07:04 ---
Fixed in SVN.


-- 

ubizjak at gmail dot com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED


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



[Bug c++/30962] cause compile error for "const anonymous class object"

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #1 from pinskia at gcc dot gnu dot org  2007-02-26 06:46 ---
If you name the class you get:
[EMAIL PROTECTED]:~$ gcc t.cc
t.cc:8: error: uninitialized const `MyAnonymous'

This has nothing to do with const anonymous class object but just an
uninitialized class object in general.

You can do:
MyAnonymous = {};

To initialized it.


-- 

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=30962



[Bug tree-optimization/30958] [4.3 Regression] ice for legal code with -ftree-vectorize -Os (-m64)

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #3 from pinskia at gcc dot gnu dot org  2007-02-26 06:38 ---
I think this is my fault.
Reduced testcase for powerpc64-linux-gnu:
struct pwc_dec23_private
{
  unsigned int table_dc00[256];
};
void fill_table_dc00_d800(struct pwc_dec23_private *pdec)
{
 int i;
 unsigned int offset1 = (1UL << (15 - 1));
 for (i=0; i<256; i++) {
  pdec->table_dc00[i] = offset1 & ~((1UL << (15 - 1)));
  offset1 += 0x7bc4;
 }
}


We get:
  D.1689_81 = BIT_FIELD_REF <{63368}, 32, 0>;


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 CC||pinskia at gcc dot gnu dot
   ||org
 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
 GCC target triplet|x86_64-suse-linux-gnu   |
   Keywords||ice-on-valid-code
   Last reconfirmed|-00-00 00:00:00 |2007-02-26 06:38:40
   date||
Summary|ice for legal code with -   |[4.3 Regression] ice for
   |ftree-vectorize -Os -mno-sse|legal code with -ftree-
   ||vectorize -Os (-m64)
   Target Milestone|--- |4.3.0


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



[Bug middle-end/30509] [4.3 Regression] ice for legal code with -O3

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #11 from pinskia at gcc dot gnu dot org  2007-02-26 06:28 
---
Fixed.


-- 


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



[Bug middle-end/30509] [4.3 Regression] ice for legal code with -O3

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #12 from pinskia at gcc dot gnu dot org  2007-02-26 06:28 
---
Fixed I say.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


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



[Bug tree-optimization/30958] ice for legal code with -ftree-vectorize -Os -mno-sse

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #2 from pinskia at gcc dot gnu dot org  2007-02-26 06:27 ---
Reducing.


-- 


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



[Bug c++/30567] -fPIC -O3 optimizer bug (32-bit target only)

2007-02-25 Thread dberlin at gcc dot gnu dot org


--- Comment #15 from dberlin at gcc dot gnu dot org  2007-02-26 04:38 
---
I'll happily confirm I can reproduce it on my i686-pc-linux-gnu machine


-- 

dberlin at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|WAITING |NEW
 Ever Confirmed|0   |1
   Last reconfirmed|-00-00 00:00:00 |2007-02-26 04:38:22
   date||


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



[Bug c++/30567] -fPIC -O3 optimizer bug (32-bit target only)

2007-02-25 Thread rwgk at yahoo dot com


--- Comment #14 from rwgk at yahoo dot com  2007-02-26 03:37 ---
> Yes.
> http://gcc.gnu.org/ml/gcc-patches/2006-12/msg00817.html
> It also fixed vect-101 testcase, in addition to 464.h264ref from spec2006.
> It initially caused a failure in 403.gcc, but this was later found to
> be a latent bug elsewhere.

OK.

> I imagine yours is the same thing (a latent bug elsewhere).

I was thinking the same thing.

> If you want to try pointing out why you think what the patch does is
> incorrect, i'm happy to work through it with you.

I'm just a user sounding an alarm bell. Your "latent bug somewhere
else" idea makes total sense to me.

I'm a little frustrated that all my efforts haven't even lead to
confirming the bug, and I'm afraid that it gets swept under the rug
and my time was wasted. If you could at least confirm the bug
I'd be motivated to strip down my reproducer some more if that
could help resolving this problem.


-- 


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



[Bug c++/30567] -fPIC -O3 optimizer bug (32-bit target only)

2007-02-25 Thread dberlin at dberlin dot org


--- Comment #13 from dberlin at gcc dot gnu dot org  2007-02-26 02:42 
---
Subject: Re:  -fPIC -O3 optimizer bug (32-bit target only)

On 26 Feb 2007 02:26:12 -, rwgk at yahoo dot com
<[EMAIL PROTECTED]> wrote:
>
>
> --- Comment #12 from rwgk at yahoo dot com  2007-02-26 02:26 ---
> Daniel Berlin wrote:
> > This change actually made us more conservative with points-to, it certainly
> > won't cause *more* things to be optimized away.
>
> Was the change supposed to fix a certain problem?
Yes.
http://gcc.gnu.org/ml/gcc-patches/2006-12/msg00817.html
It also fixed vect-101 testcase, in addition to 464.h264ref from spec2006.
It initially caused a failure in 403.gcc, but this was later found to
be a latent bug elsewhere.
I imagine yours is the same thing (a latent bug elsewhere).

If you revert it, you will start failing these regression tests again.

> If not I suggest the two lines should be backed out since they clearly cause
> a regression on the 4.2 branch.
Then whatever backing that out papers over should be fixed.

> Here is my local patch to back out the two lines introduced in
> SVN revision 119791:

Sorry, but i'm not going to accept a patch that clearly does the wrong
thing, and will cause existing regression tests to fail, so that we
can hide some other latent bug.
If you want to try pointing out why you think what the patch does is
incorrect, i'm happy to work through it with you.


-- 


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



[Bug c++/30567] -fPIC -O3 optimizer bug (32-bit target only)

2007-02-25 Thread rwgk at yahoo dot com


--- Comment #12 from rwgk at yahoo dot com  2007-02-26 02:26 ---
Daniel Berlin wrote:
> This change actually made us more conservative with points-to, it certainly
> won't cause *more* things to be optimized away.

Was the change supposed to fix a certain problem?
If not I suggest the two lines should be backed out since they clearly cause
a regression on the 4.2 branch.
My suggestion is motivated by another experiment I did with the latest
SVN (revision 122315):

Procedure:
  configure; make bootstrap; make; make install
  followed by
  1. running all our unit tests (1700 seconds of CPU time Xeon 2.8GHz)
  2. trying the reproducer with g++ -fPIC -O3 dbg.cpp; ./a.out

Fedora 5, x86_64:
  With SVN "as is" and with the two lines in question backed out
1. all our unit tests are fine
2. ./a.out prints "1" (OK)

Fedora 6, i686:
  With SVN "as is"
1. all our unit tests are fine
2. ./a.out prints "0" (failure)
  With the two lines in question backed out
1. all our unit tests are fine
2. ./a.out prints "1" (OK)

Here is my local patch to back out the two lines introduced in
SVN revision 119791:

Index: gcc/tree-ssa-structalias.c
===
--- gcc/tree-ssa-structalias.c  (revision 122315)
+++ gcc/tree-ssa-structalias.c  (working copy)
@@ -3303,8 +3303,8 @@
 {
   rhsoffset = TREE_INT_CST_LOW (op1) * BITS_PER_UNIT;
 }
-  else
-return false;
+/*else
+return false; */

   for (i = 0; VEC_iterate (ce_s, lhsc, i, c); i++)
 for (j = 0; VEC_iterate (ce_s, temp, j, c2); j++)


-- 


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



[Bug other/30756] Daily bump in branches/gcc-4_0-branch/libstdc++-v3/include/bits/c++config

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #2 from pinskia at gcc dot gnu dot org  2007-02-26 00:25 ---
Fixed by:
http://gcc.gnu.org/ml/gcc-patches/2007-02/msg01995.html


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||FIXED


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



[Bug fortran/30964] optional arguments to random_seed

2007-02-25 Thread kargl at gcc dot gnu dot org


--- Comment #1 from kargl at gcc dot gnu dot org  2007-02-26 00:14 ---
I have a patch to permit gfc_check_random_seed to deal with arguments
with the optional attribute set.  I was waiting on pault's size0/size1
patch to hit the tree to see if it does the right thing.


-- 


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



[Bug tree-optimization/30938] Bootstrap fails on x86_64 for -ftree-vectorize

2007-02-25 Thread ubizjak at gmail dot com


--- Comment #5 from ubizjak at gmail dot com  2007-02-25 23:19 ---
Fixed on SVN for real.


-- 

ubizjak at gmail dot com changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||FIXED


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



[Bug tree-optimization/30938] Bootstrap fails on x86_64 for -ftree-vectorize

2007-02-25 Thread uros at gcc dot gnu dot org


--- Comment #4 from uros at gcc dot gnu dot org  2007-02-25 23:18 ---
Subject: Bug 30938

Author: uros
Date: Sun Feb 25 23:18:45 2007
New Revision: 122323

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=122323
Log:
PR tree-optimization/30938
* tree-vect-transform.c (vectorizable_call): Fix off-by-one error:
use &dt[nargs-1] instead of &dt[nargs] in the call to
vect_is_simple_use().


Modified:
trunk/gcc/ChangeLog
trunk/gcc/tree-vect-transform.c


-- 


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



[Bug tree-optimization/19431] missed optimization with ifs and deferencing

2007-02-25 Thread rguenth at gcc dot gnu dot org


--- Comment #16 from rguenth at gcc dot gnu dot org  2007-02-25 22:51 
---
Created an attachment (id=13109)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13109&action=view)
patch to fix testcase in comment 10


-- 


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



[Bug tree-optimization/19431] missed optimization with ifs and deferencing

2007-02-25 Thread rguenth at gcc dot gnu dot org


--- Comment #15 from rguenth at gcc dot gnu dot org  2007-02-25 22:50 
---
We start with

  D.59982_3 = variable_2(D) + 4B;
  __unary_op = __unary_op.65;
  goto  ();

:;
  D.61146_10 = __unary_op._M_arg1;
  D.61147_11 = __unary_op._M_arg2;
  D.61093_12 = D.61146_10 + D.61147_11;
  *variable_13 = D.61093_12;
  variable_14 = variable_7 + 4B;
  variable_15 = variable_13 + 4B;

  # variable_7 = PHI 
  # variable_13 = PHI 
:;
  if (D.59982_3 != variable_7) goto ; else goto ;

and loop header copying and DOM make it optimizable:

  D.59982_3 = variable_2(D) + 4B;
  __unary_op.65._M_arg2 = v_1(D);
  __unary_op.65._M_arg1 = 0;
  __unary_op = __unary_op.65;
  __unary_op$_M_arg2_54 = __unary_op._M_arg2;
  __unary_op$_M_arg1_53 = __unary_op._M_arg1;
  if (variable_2(D) != D.59982_3) goto ; else goto ;

:;
  return;

  # variable_49 = PHI 
  # variable_27 = PHI 
:;
  __unary_op$_M_arg1_25 = __unary_op$_M_arg1_53;
  __unary_op$_M_arg2_17 = __unary_op$_M_arg2_54;
  D.61093_18 = __unary_op$_M_arg1_53 + __unary_op$_M_arg2_54;
  *variable_49 = D.61093_18;
  variable_20 = variable_27 + 4B;
  variable_21 = variable_49 + 4B;
  goto  ();

so a tweaked forwprop fixes it at least before PRE.  But dunno if we want
to do tree combining on conditions here.


-- 


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



[Bug tree-optimization/19431] missed optimization with ifs and deferencing

2007-02-25 Thread rguenth at gcc dot gnu dot org


--- Comment #14 from rguenth at gcc dot gnu dot org  2007-02-25 22:23 
---
Not really as this is only exposed by TER.  Though I remember forwprop catching
similiar stuff before.  I'll have a look.


-- 


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



[Bug tree-optimization/19431] missed optimization with ifs and deferencing

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #13 from pinskia at gcc dot gnu dot org  2007-02-25 22:01 
---
>   if (variable != variable + 8B) goto ; else goto ;

That issue was fixed just yesterday by PR 30951.


-- 


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



[Bug tree-optimization/30938] Bootstrap fails on x86_64 for -ftree-vectorize

2007-02-25 Thread ubizjak at gmail dot com


--- Comment #3 from ubizjak at gmail dot com  2007-02-25 21:57 ---
Sorry, I was too quick. Please ignore comment #2, bootstrap with
BOOT_CFLAGS="-Os -g -ftree-vectorize" still fails with the same error.


-- 

ubizjak at gmail dot com changed:

   What|Removed |Added

 Status|RESOLVED|UNCONFIRMED
 Resolution|FIXED   |


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



[Bug fortran/30964] New: optional arguments to random_seed

2007-02-25 Thread tkoenig at gcc dot gnu dot org
This is similar to PR 30865.  Any of the
arguments to random_seed may be specified if they
are optional arguments to the subroutine that is called.
The following is legal:

program trs
  implicit none
  integer :: size, ierr
  integer, allocatable, dimension(:) :: seed
  call test_random_seed(size)
  allocate(seed(size), stat=ierr)
  if (ierr /= 0) stop
  call test_random_seed(get=seed)
  call test_random_seed(put=seed)
contains
  subroutine test_random_seed(size, put, get)
integer, optional :: size
integer, dimension(:), optional :: put
integer, dimension(:), optional :: get
call random_seed(size, put, get)
  end subroutine test_random_seed
end program trs


-- 
   Summary: optional arguments to random_seed
   Product: gcc
   Version: 4.3.0
Status: UNCONFIRMED
  Keywords: rejects-valid
  Severity: normal
  Priority: P3
 Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: tkoenig at gcc dot gnu dot org


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



[Bug fortran/30400] [4.2 and 4.1 only] ANY not accepted as mask in FORALL

2007-02-25 Thread sayle at gcc dot gnu dot org


--- Comment #5 from sayle at gcc dot gnu dot org  2007-02-25 21:15 ---
Subject: Bug 30400

Author: sayle
Date: Sun Feb 25 21:14:49 2007
New Revision: 122322

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=122322
Log:
2007-02-25  Roger Sayle  <[EMAIL PROTECTED]>
Paul Thomas <[EMAIL PROTECTED]>

PR fortran/30400
* match.c (match_forall_iterator): Use gfc_match_expr instead
of gfc_match_variable to match the iterator variable.  Return
MATCH_NO if not a variable.  Remove the reset of the symbol's
flavor in cleanup.

* gfortran.dg/forall_10.f90: New test case.


Added:
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/forall_10.f90
Modified:
branches/gcc-4_1-branch/gcc/fortran/ChangeLog
branches/gcc-4_1-branch/gcc/fortran/match.c
branches/gcc-4_1-branch/gcc/testsuite/ChangeLog


-- 


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



[Bug middle-end/30956] ice on final.c

2007-02-25 Thread sherpya at netfarm dot it


--- Comment #4 from sherpya at netfarm dot it  2007-02-25 20:13 ---
I've compiled other things and this messages is a warning in 4.1, but doesn't
crashes


-- 


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



[Bug tree-optimization/19431] missed optimization with ifs and deferencing

2007-02-25 Thread pluto at agmk dot net


--- Comment #12 from pluto at agmk dot net  2007-02-25 20:09 ---
(In reply to comment #11)
> Bonus points if you can make that self-contained ;)

-fdump-tree-optimized shows the same code for both variants
and there is the if-with-dereferencing :)

(...)
  if (variable != variable + 8B) goto ; else goto ;
(...)


-- 


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



[Bug tree-optimization/19431] missed optimization with ifs and deferencing

2007-02-25 Thread rguenth at gcc dot gnu dot org


--- Comment #11 from rguenth at gcc dot gnu dot org  2007-02-25 19:52 
---
Bonus points if you can make that self-contained ;)


-- 


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



[Bug tree-optimization/19431] missed optimization with ifs and deferencing

2007-02-25 Thread pluto at agmk dot net


--- Comment #10 from pluto at agmk dot net  2007-02-25 19:00 ---
one more testcase:

#include 
#include 
extern void assign( long* variable, long v )
{
std::transform( variable, variable + 1, variable,
std::tr1::bind( std::plus< long >(), 0L, v ) );
}
extern void assign( long& variable, long v )
{
std::transform( &variable, &variable + 1, &variable,
std::tr1::bind( std::plus< long >(), 0L, v ) );
}

at -O3 gcc 4.2 produces:

assign(long&, long):
movq-40(%rsp), %rax
movq%rsi, -24(%rsp)
movq$0, -32(%rsp)
movq$0, -64(%rsp)
movq%rsi, -56(%rsp)
movq%rsi, (%rdi)
movq%rax, -72(%rsp)
ret

assign(long*, long):
movq%rsi, (%rdi)
ret


-- 


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



[Bug c++/30962] New: cause compile error for "const anonymous class object"

2007-02-25 Thread gzljg at hotmail dot com
First I cannot find the exact C++ definition of "const anonymous object" so I
am not sure the below reporting is valid or not. The question to me is: why
adding 'const' to the class declaration will invalidate the code while without
'const' is ok?

The following code will compile and run without error, but if add back the
"const" declaration before 'class', it will report an error of "
 Error: uninitialized const `MyAnonymous'"
This had been tested with gcc 3.3.3 & 4.1.2.

/* const */ class
{
 public:
   int foo() const
   {
  return 1;
   }
} MyAnonymous;

int
main()
{
  return MyAnonymous.foo();
}


-- 
   Summary: cause compile error for "const anonymous class object"
   Product: gcc
   Version: 3.3.3
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: gzljg at hotmail dot com


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



[Bug tree-optimization/30938] Bootstrap fails on x86_64 for -ftree-vectorize

2007-02-25 Thread ubizjak at gmail dot com


--- Comment #2 from ubizjak at gmail dot com  2007-02-25 18:29 ---
Fixed by http://gcc.gnu.org/ml/gcc-patches/2007-02/msg01979.html.


-- 

ubizjak at gmail dot com changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||FIXED


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



[Bug middle-end/27567] [4.0/4.1 Regression] __builtin_memcpy generates redundant stores/moves.

2007-02-25 Thread pluto at agmk dot net


--- Comment #11 from pluto at agmk dot net  2007-02-25 18:27 ---
(In reply to comment #10)
> (In reply to comment #9)
> > adjust summary ( 4.2 regression status reopened ).
> That is a target specific issue really and should be filed seperately.  

filled as PR30961


-- 


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



[Bug target/30961] New: redundant reg/mem stores/moves

2007-02-25 Thread pluto at agmk dot net
float convert( unsigned in )
{
float f;
__builtin_memcpy( &f, &in, sizeof( in ) );
return f;
}

unsigned short load( void* p )
{
unsigned short v;
__builtin_memcpy( &v, p, sizeof( v ) );
return v;
}

gcc-4.2.0-20070221

$ g++ temp.cpp -O2 -S

_Z7convertj:
movl%edi, -4(%rsp)
movss   -4(%rsp), %xmm1
movaps  %xmm1, %xmm0
ret

_Z4loadPv:
movzwl  (%rdi), %eax
movw%ax, -2(%rsp)
movzwl  %ax, %eax
ret


-- 
   Summary: redundant reg/mem stores/moves
   Product: gcc
   Version: 4.2.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: target
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pluto at agmk dot net
GCC target triplet: x86_64-linux


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



[Bug middle-end/30509] [4.3 Regression] ice for legal code with -O3

2007-02-25 Thread hubicka at gcc dot gnu dot org


--- Comment #10 from hubicka at gcc dot gnu dot org  2007-02-25 18:11 
---
Subject: Bug 30509

Author: hubicka
Date: Sun Feb 25 18:11:20 2007
New Revision: 122314

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=122314
Log:
PR middle-end/30509
* tree-inline.c (copy_bb): Produce exact copy of EH info when copying
for inlining.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/tree-inline.c


-- 


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



[Bug middle-end/30509] [4.3 Regression] ice for legal code with -O3

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #9 from pinskia at gcc dot gnu dot org  2007-02-25 17:42 ---
*** Bug 30768 has been marked as a duplicate of this bug. ***


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 CC||hp at gcc dot gnu dot org


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



[Bug middle-end/30768] [4.3 regression]: ICE in ext/pb_ds/regression/list_update_data_map_rand.cc

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #31 from pinskia at gcc dot gnu dot org  2007-02-25 17:42 
---
Yes this is a dup as the patch which honza added to that bug fixes this one
also.  Plus there is a small testcase.  So closing as a dup.

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


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||DUPLICATE


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



[Bug middle-end/30509] [4.3 Regression] ice for legal code with -O3

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #8 from pinskia at gcc dot gnu dot org  2007-02-25 17:39 ---
*** Bug 30866 has been marked as a duplicate of this bug. ***


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 CC||martin at mpa-garching dot
   ||mpg dot de


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



[Bug middle-end/30866] [4.3 regression] Another ICE in calc_dfs_tree()

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #5 from pinskia at gcc dot gnu dot org  2007-02-25 17:39 ---
The patch which honza added in PR 30509 fixed this testcase so closing as a
dup.

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


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
  Component|c++ |middle-end
  GCC build triplet|x86_64-unknown-linux-gnu|
   GCC host triplet|x86_64-unknown-linux-gnu|
 Resolution||DUPLICATE


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



[Bug middle-end/30509] [4.3 Regression] ice for legal code with -O3

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #7 from pinskia at gcc dot gnu dot org  2007-02-25 17:39 ---
There is a slight error in the patch here, CB_CGE_MOVE should really be
CB_CGE_MOVE_CLONES.


-- 


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



[Bug target/30778] [4.3 Regression] invalid code generation for memset() with -mtune=k8

2007-02-25 Thread hubicka at gcc dot gnu dot org


--- Comment #8 from hubicka at gcc dot gnu dot org  2007-02-25 17:37 ---
Subject: Bug 30778

Author: hubicka
Date: Sun Feb 25 17:37:37 2007
New Revision: 122313

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=122313
Log:
PR target/30778
* i386.c (counter_mode): New function.
(expand_set_or_movmem_via_loop): Use it.
(expand_movmem_epilogue): Likewise; fix pasto.
(ix86_expand_movmem): Do emit guard even for constant counts.
(ix86_expand_setmem): Likewise.

Added:
trunk/gcc/testsuite/gcc.c-torture/execute/pr30778.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/i386/i386.c
trunk/gcc/testsuite/ChangeLog


-- 


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



[Bug c++/25950] [DR 391] Reference binding and explicit copy constructors

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #25 from pinskia at gcc dot gnu dot org  2007-02-25 16:49 
---
*** Bug 30959 has been marked as a duplicate of this bug. ***


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 CC||sl at datamyway dot de


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



[Bug c++/30959] copy consturctor influences compile errors of constructor from unrelated class

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #1 from pinskia at gcc dot gnu dot org  2007-02-25 16:49 ---
The C++ standard as written requires this error, though the intent of the C++
standards committee was not having this error message.  There was a defect
report against the C++ standards about this error and that is recorded as PR
25950.

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


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||DUPLICATE


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



[Bug fortran/30960] Failed to build gcc from trunk: configure: error: GNU Fortran is not working

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #3 from pinskia at gcc dot gnu dot org  2007-02-25 16:46 ---
This works for me and others, you just have a miss installed/configured
GMP/MPFR.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||WORKSFORME


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



[Bug c/21948] [diagnostic] enable errors on `cast from/to pointer to/from integer of different size`

2007-02-25 Thread pinskia at gcc dot gnu dot org


--- Comment #5 from pinskia at gcc dot gnu dot org  2007-02-25 16:17 ---
Fixed in 4.2.  Closing as fixed as this is a request for a new feature.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED
   Target Milestone|--- |4.2.0


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



[Bug fortran/30955] intrinsic: FGET

2007-02-25 Thread dfranke at gcc dot gnu dot org


--- Comment #2 from dfranke at gcc dot gnu dot org  2007-02-25 16:11 ---
There's is/was a discussion at the ML whether GNU extensions should allow
default integer only, fold anything into a default integer and recast
afterwards or whether the library shall provide calls for any type.

As far as I can tell, currently all of above schemes are implemented for one
intrinsic or another. There was no agreement yet, how to proceed. For more
details, see also PR30372 and the thread starting at
http://gcc.gnu.org/ml/fortran/2007-02/msg00538.html

Personally, I don't mind too much which scheme is implemented, as long as it's
consistent for ALL intrinsic procedures ...


-- 


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



[Bug c/21948] [diagnostic] enable errors on `cast from/to pointer to/from integer of different size`

2007-02-25 Thread manu at gcc dot gnu dot org


--- Comment #4 from manu at gcc dot gnu dot org  2007-02-25 16:03 ---
(In reply to comment #3)
> (In reply to comment #2)
> 
> as i have said, i need a compilation error on such casts.
> 4.2 has a nice -Werror=foo feature, but this PR is about 4.1.
> if you don't plan to backport -Werror=foo feature to 4.1
> i'll close this PR with suitable comment.
> 

OK. Thanks for the clarification. It doesn't correspond to me to decide whether
it should be backported.


-- 

manu at gcc dot gnu dot org changed:

   What|Removed |Added

  Known to work||4.2.0 4.3.0


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



[Bug fortran/30955] intrinsic: FGET

2007-02-25 Thread tkoenig at gcc dot gnu dot org


--- Comment #1 from tkoenig at gcc dot gnu dot org  2007-02-25 15:56 ---

> $> gfortran-svn fget.f90 && ./a.out
> x
>  x
> 
> I.e. the string is cleared and the first character is set to the input.
> This also "works" with substrings, e.g. s(3:6). 

> In my eyes I would consider the blanking the bug, not that a string is 
> allowed.
> Consistent behaviour should overwrite the first character, not ALL of them.
> 

This is expected behavior, and is consistent with both g77
(for which we support fget, as a legacy intrinsic)
and with the way that character assignment works.

$ cat fget.f
  character*10 s
  s = '0123456789'
  CALL fget(s)
  write(*,*) s
  s = '0123456789'
  s = 'ab'
  write (*,*) s,'x'
  end
$ g77 fget.f && ./a.out
xxx
 x
 abx

> 3. The optional status argument accepts variables of type default integer 
> only.

Fget is a legacy intrinsic, and there are now standard ways
of achieving the same result (stream I/O).  Also, g77 only
accepts default integers as well.

I'd vote for fixing the argument name, and leave the rest alone.


-- 


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



[Bug fortran/30960] Failed to build gcc from trunk: configure: error: GNU Fortran is not working

2007-02-25 Thread kargl at gcc dot gnu dot org


--- Comment #2 from kargl at gcc dot gnu dot org  2007-02-25 15:29 ---
configure:4917: /usr/gcc/host-i686-pc-linux-gnu/gcc/gfortran
-B/usr/gcc/host-i686-pc-linux-gnu/gcc/ -B/usr/local/i686-pc-linux-gnu/bin/
-B/usr/local/i686-pc-linux-gnu/lib/ -isystem
/usr/local/i686-pc-linux-gnu/include -isystem
/usr/local/i686-pc-linux-gnu/sys-include -c   conftest.f >&5
/usr/gcc/host-i686-pc-linux-gnu/gcc/f951: symbol lookup error:
/usr/gcc/host-i686-pc-linux-gnu/gcc/f951: undefined symbol:
__gmp_get_memory_functions

You need to fix your gmp/mpfr installation.

Yes, you can configure without gfortan by using the --enable-languages 
configure option.  But, the above error suggests that you may have
problems because the middle-end now uses gmp/mpfr for folding of
builtin functions.


-- 


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



[Bug fortran/30960] Failed to build gcc from trunk: configure: error: GNU Fortran is not working

2007-02-25 Thread gcc at pellmont dot dyndns dot org


--- Comment #1 from gcc at pellmont dot dyndns dot org  2007-02-25 15:11 
---
Created an attachment (id=13108)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13108&action=view)
logfile as stated in the error message


-- 


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



[Bug fortran/30960] New: Failed to build gcc from trunk: configure: error: GNU Fortran is not working

2007-02-25 Thread gcc at pellmont dot dyndns dot org
i tried to compile gcc from trunk on my ubuntu system, but i only get the
error:
checking whether the GNU Fortran compiler is working... no
configure: error: GNU Fortran is not working; please report a bug in
http://gcc.gnu.org/bugzilla, attaching
/usr/gcc/i686-pc-linux-gnu/libgfortran/config.log
make[1]: *** [configure-target-libgfortran] Error 1
make[1]: Leaving directory `/usr/gcc'
make: *** [all] Error 2

about my system:
os: Linux 2.6.15-28-386 #1 PREEMPT Thu Feb 1 15:51:56 UTC 2007 i686 GNU/Linux
gcc: SVN Revision 122311
mpfr: 2.2.1
gmp: 4.2.1

is there also a possibility to disable fortran? i just wanted to try whether
gcj now compiles java 5 code...

kind regards,
pascal


-- 
   Summary: Failed to build gcc from trunk: configure: error: GNU
Fortran is not working
   Product: gcc
   Version: unknown
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: gcc at pellmont dot dyndns dot org
  GCC host triplet: i686-pc-linux-gnu


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



[Bug rtl-optimization/30957] Misscompare with variable expansion optimization

2007-02-25 Thread eres at il dot ibm dot com


--- Comment #3 from eres at il dot ibm dot com  2007-02-25 14:52 ---
Created an attachment (id=13107)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13107&action=view)
testcase for MVE

Running the executable of the attached testcase (compiled with MVE)
succeeded.  This looks strange as it seems mzero6.c and this tetscase have
similar loop structure:

 double acc = 0.0;
   for (int i = 0; i <= n; i++)
 acc += d;
   return acc;


-- 


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



[Bug rtl-optimization/30957] Misscompare with variable expansion optimization

2007-02-25 Thread eres at il dot ibm dot com


--- Comment #2 from eres at il dot ibm dot com  2007-02-25 14:50 ---
The execution fails also when acc is float (and not double)


-- 


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



[Bug c/21948] [diagnostic] enable errors on `cast from/to pointer to/from integer of different size`

2007-02-25 Thread pluto at agmk dot net


--- Comment #3 from pluto at agmk dot net  2007-02-25 14:22 ---
(In reply to comment #2)
> Could you elaborate a litte bit more for me?
> 
> We have already -Wint-to-pointer-cast and -Wpointer-to-int-cast enabled by
> defaul in C. Don't those work for you?

as i have said, i need a compilation error on such casts.
4.2 has a nice -Werror=foo feature, but this PR is about 4.1.
if you don't plan to backport -Werror=foo feature to 4.1
i'll close this PR with suitable comment.


-- 


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



[Bug c++/30959] New: copy consturctor influences compile errors of constructor from unrelated class

2007-02-25 Thread sl at datamyway dot de
Depending on whether the copy constructor CA(const CA& a) (see following code)
is private, public or not (explicitly) defined the constructor   CA(const SA&
a) from the unrelated class SA gets compile errors.
It compiles for public and undefined, but not for private.
If CA(const CA& a) is public, the code compiles and runs as expected, and
CA(const CA& a) is not executed (but somehow needed for compilation?!).
---

on SuSe linux 10.0 with
~/wurschtel/cpp> uname -a
Linux djebe 2.6.13-15-smp #1 SMP Tue Sep 13 14:56:15 UTC 2005 i686 i686 i386
GNU/Linux
and gcc 4.0.2 (but also with 4.1.2)
the code (file y.cpp) 
-
//originally from http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13478, modified
#include 
using namespace std;

class SA
{
};

class CA
{
public:
  CA()
  {
cout << "CA()" << endl;
  };

  CA(const SA& a)
  {
cout << "CA(const SA& a)" << endl;
  };


private:
  CA(const CA& a)
  {
cout << "CA(const CA& a)" << endl;
  };


};

void foo(const SA& pa)
{
  const CA ra=CA(pa);
}

int main (int argc, char* argv[])
{
  const SA* pa = new SA();
  const CA pb(*pa);

  foo(*pa);

}


-
gives compile errors:
g++ -ansi -pedantic -Wall -o y y.cpp
y.cpp: In function ‘void foo(const SA&)’:
y.cpp:27: error: ‘CA::CA(const CA&)’ is private
y.cpp:37: error: within this context
y.cpp:27: error: ‘CA::CA(const CA&)’ is private
y.cpp:37: error: within this context
[EMAIL PROTECTED]:~/wurschtel/cpp>


-- 
   Summary: copy consturctor influences compile errors of
constructor from unrelated class
   Product: gcc
   Version: 4.0.2
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: sl at datamyway dot de


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



[Bug c/30958] ice for legal code with -ftree-vectorize -Os -mno-sse

2007-02-25 Thread dcb314 at hotmail dot com


--- Comment #1 from dcb314 at hotmail dot com  2007-02-25 12:35 ---
Created an attachment (id=13106)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13106&action=view)
C source code


-- 


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



[Bug c/30958] New: ice for legal code with -ftree-vectorize -Os -mno-sse

2007-02-25 Thread dcb314 at hotmail dot com
I just tried to compile Linux kernel 2.6.20.1
with the GNU C++ compiler version 4.3 snapshot 20070223.

The compiler said

drivers/media/video/pwc/pwc-dec23.c: In function 'pwc_dec23_init':
drivers/media/video/pwc/pwc-dec23.c:305: error: invalid reference prefix
{63368}

drivers/media/video/pwc/pwc-dec23.c:305: error: invalid reference prefix
{63368}

drivers/media/video/pwc/pwc-dec23.c:305: error: invalid reference prefix
{63368}

drivers/media/video/pwc/pwc-dec23.c:305: error: invalid reference prefix
{63368}

drivers/media/video/pwc/pwc-dec23.c:305: internal compiler error: verify_stmts
failed
Please submit a full bug report,
with preprocessed source if appropriate.
See http://gcc.gnu.org/bugs.html> for instructions.

Preprocessed source code attached. Flags -ftree-vectorize -Os -mno-sse
required.


-- 
   Summary: ice for legal code with -ftree-vectorize -Os -mno-sse
   Product: gcc
   Version: 4.3.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: dcb314 at hotmail dot com
  GCC host triplet: x86_64-suse-linux


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



[Bug rtl-optimization/30957] Misscompare with variable expansion optimization

2007-02-25 Thread eres at il dot ibm dot com


--- Comment #1 from eres at il dot ibm dot com  2007-02-25 11:33 ---
Created an attachment (id=13105)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13105&action=view)
RTL unroller's dump (compiled with -fvariable-expansion-in-unroller)

reg:DF 137 is the new variable expansion created to expand the accumulator
reg:DF 120 [ add_acc.0 ].


-- 


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



[Bug rtl-optimization/30957] New: Misscompare with variable expansion optimization

2007-02-25 Thread eres at il dot ibm dot com
Compiling mzero6.c with -fvariable-expansion-in-unroller flag causes unexpected
abortion of the executable.

testsuite/gcc.c-torture/execute/ieee/mzero6.c  -w  -O2  -fno-show-column  -lm  
-funroll-loops --fast-math -O2  -fvariable-expansion-in-unroller -o out


-- 
   Summary: Misscompare with variable expansion optimization
   Product: gcc
   Version: 4.3.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: rtl-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: eres at il dot ibm dot com


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



[Bug c++/30952] Unclear error message when callling via a function pointer

2007-02-25 Thread rguenth at gcc dot gnu dot org


--- Comment #1 from rguenth at gcc dot gnu dot org  2007-02-25 10:29 ---
Confirmed.


-- 

rguenth at gcc dot gnu dot org changed:

   What|Removed |Added

   Severity|normal  |enhancement
 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
   Keywords||diagnostic
   Last reconfirmed|-00-00 00:00:00 |2007-02-25 10:29:23
   date||


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