warning: array subscript is below array bounds

2009-06-10 Thread George Kirpichev
Hi, I would like to ask a question about array bounds checking feature in gcc. My question is the following: There is a code like: /* put message in buffer */ (void) memcpy(sockFact_p-sockBuffer_p + sockFact_p-usedSize, (char*)mqp_sp-msg.data - MSG_HEADER_LENGTH,

[Bug libfortran/40330] [4.4 Regression] incorrect IO

2009-06-10 Thread burnus at gcc dot gnu dot org
--- Comment #18 from burnus at gcc dot gnu dot org 2009-06-10 06:45 --- I was able to do a regression hunt. Going to r145209 just before the big I/O patch eliminates the error. I then moved forward to r145636 and confirmed the breakage. Is 4.5 also affected? --

[Bug libfortran/40330] [4.4, 4.5 Regression] incorrect IO

2009-06-10 Thread jv244 at cam dot ac dot uk
--- Comment #19 from jv244 at cam dot ac dot uk 2009-06-10 07:22 --- (In reply to comment #18) I was able to do a regression hunt. Going to r145209 just before the big I/O patch eliminates the error. I then moved forward to r145636 and confirmed the breakage. Is 4.5

[Bug libfortran/40330] [4.4, 4.5 Regression] incorrect IO

2009-06-10 Thread jv244 at cam dot ac dot uk
--- Comment #20 from jv244 at cam dot ac dot uk 2009-06-10 07:24 --- (In reply to comment #16) Joost, can you explain what the following means? CP2K| condition FAILED at line 195 CP2K| Abnormal program termination, stopped by process number 0 Aborted In this case it means that

[Bug middle-end/40388] [4.5 Regression] another null pointer in remove_unreachable_regions

2009-06-10 Thread dcb314 at hotmail dot com
--- Comment #2 from dcb314 at hotmail dot com 2009-06-10 08:28 --- Created an attachment (id=17973) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17973action=view) C++ source code -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40388

[Bug libfortran/40330] [4.4, 4.5 Regression] incorrect IO

2009-06-10 Thread jv244 at cam dot ac dot uk
--- Comment #21 from jv244 at cam dot ac dot uk 2009-06-10 09:25 --- reduced testcase: MODULE M1 IMPLICIT NONE CONTAINS SUBROUTINE S1(I) INTEGER :: I,K CHARACTER(LEN=100) :: a,b write(a,'(I0,A)') I,X write(b,*) I write(6,FMT='('//TRIM(a)//,a,' '), ADVANCE=NO) TRIM(b)

[Bug middle-end/40391] Segfault with -O, iostream, anonymous namespace on PPC

2009-06-10 Thread jwakely dot gcc at gmail dot com
--- Comment #4 from jwakely dot gcc at gmail dot com 2009-06-10 10:33 --- The code is invalid MyStream:: MyStream () : std::iostream (m_buf), m_buf () { } m_buf has not been cosntructed when you pass it to the base constructor, so m_buf.init() is called on an uncosntructed

[Bug c/40394] New: Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
/* CODE EXAMPLE ***/ #include stdio.h #include string.h typedef unsigned int U32; typedef unsigned short U16; typedef unsigned char U8; #ifndef __GNUC__ #define __attribute__(a) #endif /* __GNUC__ */ #define APP6DR_PACK_STRUCT __attribute__((packed)) #define

[Bug middle-end/40391] Segfault with -O, iostream, anonymous namespace on PPC

2009-06-10 Thread jwakely dot gcc at gmail dot com
--- Comment #5 from jwakely dot gcc at gmail dot com 2009-06-10 10:42 --- (In reply to comment #4) You shoudl either pass a null pointer to the base class, then call m_buf.init() Oops, I got that a bit wrong, don't pass a null pointer to the base constructor. You should either

[Bug c/40395] New: Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
/* CODE EXAMPLE ***/ #include stdio.h #include string.h typedef unsigned int U32; typedef unsigned short U16; typedef unsigned char U8; #ifndef __GNUC__ #define __attribute__(a) #endif /* __GNUC__ */ #define APP6DR_PACK_STRUCT __attribute__((packed)) #define

[Bug c/40396] New: Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
/* CODE EXAMPLE ***/ #include stdio.h #include string.h typedef unsigned int U32; typedef unsigned short U16; typedef unsigned char U8; #ifndef __GNUC__ #define __attribute__(a) #endif /* __GNUC__ */ #define APP6DR_PACK_STRUCT __attribute__((packed)) #define

[Bug c/40397] New: Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
/* CODE EXAMPLE ***/ #include stdio.h #include string.h typedef unsigned int U32; typedef unsigned short U16; typedef unsigned char U8; #ifndef __GNUC__ #define __attribute__(a) #endif /* __GNUC__ */ #define APP6DR_PACK_STRUCT __attribute__((packed)) #define

[Bug c/40398] New: Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
/* CODE EXAMPLE ***/ #include stdio.h #include string.h typedef unsigned int U32; typedef unsigned short U16; typedef unsigned char U8; #ifndef __GNUC__ #define __attribute__(a) #endif /* __GNUC__ */ #define APP6DR_PACK_STRUCT __attribute__((packed)) #define

[Bug c/40399] New: Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
/* CODE EXAMPLE ***/ #include stdio.h #include string.h typedef unsigned int U32; typedef unsigned short U16; typedef unsigned char U8; #ifndef __GNUC__ #define __attribute__(a) #endif /* __GNUC__ */ #define APP6DR_PACK_STRUCT __attribute__((packed)) #define

[Bug target/26397] Program crashes when rethrowing exception

2009-06-10 Thread jwakely dot gcc at gmail dot com
--- Comment #13 from jwakely dot gcc at gmail dot com 2009-06-10 11:45 --- (In reply to comment #12) Subject: Bug 26397 Author: dje Date: Thu Nov 6 15:32:40 2008 New Revision: 141646 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=141646 Log: PR target/26397

[Bug middle-end/40388] [4.5 Regression] another null pointer in remove_unreachable_regions

2009-06-10 Thread hjl dot tools at gmail dot com
--- Comment #3 from hjl dot tools at gmail dot com 2009-06-10 12:00 --- It is caused by revision 146776: http://gcc.gnu.org/ml/gcc-cvs/2009-04/msg01418.html -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40388

[Bug fortran/40383] [4.5 Regression] incorrect bounds checking with optional character arguments

2009-06-10 Thread burnus at gcc dot gnu dot org
--- Comment #4 from burnus at gcc dot gnu dot org 2009-06-10 12:02 --- Patch -- I believe it does the right thing; especially, it preserves backend_decl. If one copied the type earlier, the backend_decl would be different and the backend does not like it, when the same type has

[Bug fortran/40383] [4.5 Regression] incorrect bounds checking with optional character arguments

2009-06-10 Thread burnus at gcc dot gnu dot org
--- Comment #5 from burnus at gcc dot gnu dot org 2009-06-10 12:05 --- Forgot to mention: I will not be able to regtest/submit the patch before Monday evening. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40383

[Bug libfortran/40330] [4.4, 4.5 Regression] incorrect IO

2009-06-10 Thread jvdelisle at gcc dot gnu dot org
--- Comment #22 from jvdelisle at gcc dot gnu dot org 2009-06-10 12:32 --- Thanks for reduced test. $ ./a.out badfile $ xxd badfile 000: 2020 2020 2020 2020 2020 2020 2020 33203 010: 2020 2020 2020 2020 2020 2020 2020 33003. The NULL in the

[Bug c/40400] New: Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
/* CODE EXAMPLE ***/ #include stdio.h #include string.h typedef unsigned int U32; typedef unsigned short U16; typedef unsigned char U8; #ifndef __GNUC__ #define __attribute__(a) #endif /* __GNUC__ */ #define APP6DR_PACK_STRUCT __attribute__((packed)) #define

[Bug c/40395] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #1 from goran dot steen at enea dot com 2009-06-10 12:42 --- *** This bug has been marked as a duplicate of 40394 *** -- goran dot steen at enea dot com changed: What|Removed |Added

[Bug c/40394] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #1 from goran dot steen at enea dot com 2009-06-10 12:42 --- *** Bug 40395 has been marked as a duplicate of this bug. *** -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40394

[Bug c/40396] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #1 from goran dot steen at enea dot com 2009-06-10 12:42 --- *** This bug has been marked as a duplicate of 40394 *** -- goran dot steen at enea dot com changed: What|Removed |Added

[Bug c/40394] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #2 from goran dot steen at enea dot com 2009-06-10 12:42 --- *** Bug 40396 has been marked as a duplicate of this bug. *** -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40394

[Bug c/40394] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #3 from goran dot steen at enea dot com 2009-06-10 12:42 --- *** Bug 40397 has been marked as a duplicate of this bug. *** -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40394

[Bug c/40397] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #1 from goran dot steen at enea dot com 2009-06-10 12:42 --- *** This bug has been marked as a duplicate of 40394 *** -- goran dot steen at enea dot com changed: What|Removed |Added

[Bug c/40394] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #4 from goran dot steen at enea dot com 2009-06-10 12:43 --- *** Bug 40398 has been marked as a duplicate of this bug. *** -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40394

[Bug c/40398] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #1 from goran dot steen at enea dot com 2009-06-10 12:43 --- *** This bug has been marked as a duplicate of 40394 *** -- goran dot steen at enea dot com changed: What|Removed |Added

[Bug c/40394] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #5 from goran dot steen at enea dot com 2009-06-10 12:43 --- *** Bug 40399 has been marked as a duplicate of this bug. *** -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40394

[Bug c/40399] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #1 from goran dot steen at enea dot com 2009-06-10 12:43 --- *** This bug has been marked as a duplicate of 40394 *** -- goran dot steen at enea dot com changed: What|Removed |Added

[Bug c/40400] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #1 from goran dot steen at enea dot com 2009-06-10 12:43 --- *** This bug has been marked as a duplicate of 40394 *** -- goran dot steen at enea dot com changed: What|Removed |Added

[Bug c/40394] Variable values calculated differently depending on storage class

2009-06-10 Thread goran dot steen at enea dot com
--- Comment #6 from goran dot steen at enea dot com 2009-06-10 12:43 --- *** Bug 40400 has been marked as a duplicate of this bug. *** -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40394

[Bug middle-end/40391] Segfault with -O, iostream, anonymous namespace on PPC

2009-06-10 Thread fp at mc dot com
--- Comment #6 from fp at mc dot com 2009-06-10 12:50 --- Jonathan, thank you for identifying the bug in my original code. According to my copy of ISO 14992:1998, std::iostream does not have a default constructor. However, my reading of the standard leads me to believe that it is

[Bug middle-end/40391] Segfault with -O, iostream, anonymous namespace on PPC

2009-06-10 Thread fp at mc dot com
--- Comment #7 from fp at mc dot com 2009-06-10 12:51 --- Created an attachment (id=17974) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17974action=view) iostest.zip Fixes test case to avoid invalid code. (Passes null pointer to base class then calls this-init(m_buf).) -- fp

[Bug middle-end/40391] Segfault with -O, iostream, anonymous namespace on PPC

2009-06-10 Thread jwakely dot gcc at gmail dot com
--- Comment #8 from jwakely dot gcc at gmail dot com 2009-06-10 13:09 --- (In reply to comment #6) According to my copy of ISO 14992:1998, std::iostream does not have a default constructor. However, my reading of the standard leads me to believe that it is valid to pass a null

[Bug libfortran/40330] [4.4, 4.5 Regression] incorrect IO

2009-06-10 Thread jv244 at cam dot ac dot uk
--- Comment #23 from jv244 at cam dot ac dot uk 2009-06-10 13:18 --- (In reply to comment #22) Thanks for reduced test. $ ./a.out badfile $ xxd badfile 000: 2020 2020 2020 2020 2020 2020 2020 33203 010: 2020 2020 2020 2020 2020 2020 2020 3300

[Bug middle-end/40391] Segfault with -O, iostream, anonymous namespace on PPC

2009-06-10 Thread fp at mc dot com
--- Comment #9 from fp at mc dot com 2009-06-10 13:18 --- gdb reports Program received signal SIGSEGV, Segmentation fault. 0x10001384 in make () at /opt/timesys/toolchains/lib/gcc/powerpc-timesys-linux-gnu/4.2.1/../../../../powerpc-timesys-linux-gnu/include/c++/4.2.1/ostream:366

[Bug middle-end/40391] Segfault with -O, iostream, anonymous namespace on PPC

2009-06-10 Thread fp at mc dot com
--- Comment #10 from fp at mc dot com 2009-06-10 13:20 --- Created an attachment (id=17975) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17975action=view) disassemble.txt Assembly dump of the function that crashes. gdb reports that the crash occurs at address 0x10001384. --

[Bug middle-end/40401] New: ICE: verify_gimple failed

2009-06-10 Thread rmansfield at qnx dot com
. $ ./xgcc -B. -v Reading specs from ./specs Target: i686-pc-linux-gnu Configured with: ../configure --enable-languages=c --disable-bootstrap Thread model: posix gcc version 4.5.0 20090610 (experimental) [trunk revision 148341] (GCC) -- Summary: ICE: verify_gimple failed Product

[Bug c/40394] Variable values calculated differently depending on storage class

2009-06-10 Thread rguenth at gcc dot gnu dot org
--- Comment #7 from rguenth at gcc dot gnu dot org 2009-06-10 14:02 --- You are violating C aliasing rules. Use -fno-strict-aliasing. -- rguenth at gcc dot gnu dot org changed: What|Removed |Added

[Bug middle-end/40401] [4.5 Regression] ICE: verify_gimple failed

2009-06-10 Thread rguenth at gcc dot gnu dot org
-- rguenth at gcc dot gnu dot org changed: What|Removed |Added CC||rguenth at gcc dot gnu dot |

[Bug fortran/40402] New: Problem with data statement involving structure constructors

2009-06-10 Thread philippe dot marguinaud at meteo dot fr
The code: TYPE POINT REAL :: X ENDTYPE TYPE(POINT) :: P != POINT(1.+X) DATA P / POINT(1.+X) / END [phi...@dune tmp]$ gfortran -c t.F t.F: In function ‘MAIN__’: t.F:1: erreur interne du compilateur: dans gfc_conv_constant, à fortran/trans-const.c:348

[Bug fortran/40402] Problem with data statement involving structure constructors containing non-initialisation expressions

2009-06-10 Thread jv244 at cam dot ac dot uk
--- Comment #1 from jv244 at cam dot ac dot uk 2009-06-10 14:10 --- this is not valid code, but a gfortran bug nevertheless. line 5: X is not permitted in an initialisation expression -- jv244 at cam dot ac dot uk changed: What|Removed |Added

[Bug middle-end/40388] [4.5 Regression] another null pointer in remove_unreachable_regions

2009-06-10 Thread reichelt at gcc dot gnu dot org
--- Comment #4 from reichelt at gcc dot gnu dot org 2009-06-10 14:43 --- Confirmed. Reduced testcase (already crashes with -O): == struct A { ~A(); }; struct B { A* p; ~B() { if (p) delete p; delete p; } }; struct C { B*

[Bug middle-end/40388] [4.5 Regression] another null pointer in remove_unreachable_regions

2009-06-10 Thread reichelt at gcc dot gnu dot org
--- Comment #5 from reichelt at gcc dot gnu dot org 2009-06-10 15:50 --- Even shorter testcase: == void foo(); struct A { ~A() { try { foo(); foo(); } catch (...) { } } }; void bar() { A a1, a2; } == --

[Bug lto/40403] New: lto: misalignment after cgraph section

2009-06-10 Thread rmansfield at qnx dot com
$ cat t.i __asm__ ( .globl\t_start_\n \t _start_:\n \tnop\n ); $ ./xgcc -B. t.i -c $ ./xgcc -B. -flto t.i -c /tmp/ccPizQGw.s: Assembler messages: /tmp/ccPizQGw.s:47: Error: instruction address is not a multiple of 4 .section.gnu.lto_.opts,,@progbits .align 2

[Bug lto/40403] lto: misalignment after cgraph section

2009-06-10 Thread pinskia at gcc dot gnu dot org
--- Comment #1 from pinskia at gcc dot gnu dot org 2009-06-10 16:32 --- This code is invalid There is a duplicate of the same bug for -g3. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40403

[Bug inline-asm/33932] miscalculation of asm labels with -g3

2009-06-10 Thread pinskia at gcc dot gnu dot org
--- Comment #23 from pinskia at gcc dot gnu dot org 2009-06-10 16:32 --- *** Bug 40403 has been marked as a duplicate of this bug. *** -- pinskia at gcc dot gnu dot org changed: What|Removed |Added

[Bug lto/40403] lto: misalignment after cgraph section

2009-06-10 Thread pinskia at gcc dot gnu dot org
--- Comment #2 from pinskia at gcc dot gnu dot org 2009-06-10 16:32 --- *** This bug has been marked as a duplicate of 33932 *** -- pinskia at gcc dot gnu dot org changed: What|Removed |Added

[Bug tree-optimization/28632] VRP should understand bitwise OR and AND

2009-06-10 Thread aldot at gcc dot gnu dot org
-- aldot at gcc dot gnu dot org changed: What|Removed |Added AssignedTo|unassigned at gcc dot gnu |aldot at gcc dot gnu dot org |dot org

[Bug tree-optimization/40210] gcc byte swap builtins inadequately optimized

2009-06-10 Thread hp at gcc dot gnu dot org
--- Comment #8 from hp at gcc dot gnu dot org 2009-06-10 17:36 --- (In reply to comment #7) I do think that bit operations in general could be handled a lot better, and that would help out a whole lot of code. If you add (compilable) test-cases with enhancement requests, carefully

[Bug c/40404] New: Comparison involving unsigned int:17 bitfield seems wrong

2009-06-10 Thread foo at mailinator dot com
#include stdio.h struct S { unsigned int ui17 : 17; } s; int main() { s.ui17 = 0x1; printf(%x\n, (unsigned int)s.ui17); if (s.ui17 = 0xfffeu) puts(FAIL); return 0; } Maybe I don't understand GCC's rules for the promotion of bitfields, but it seems to me that

[Bug c/40404] Comparison involving unsigned int:17 bitfield seems wrong

2009-06-10 Thread pinskia at gcc dot gnu dot org
--- Comment #1 from pinskia at gcc dot gnu dot org 2009-06-10 18:41 --- unsigned int:17 gets promoted to int IIRC. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40404

[Bug fortran/38718] some simplifiers for elemental intrinsics missing; required for init expressions

2009-06-10 Thread fxcoudert at gcc dot gnu dot org
--- Comment #3 from fxcoudert at gcc dot gnu dot org 2009-06-10 19:35 --- (In reply to comment #2) Commit in #1 added a simplifier for MERGE. Having a closer look at IS_IOSTAT_{END, EOR}, I think they won't make much sense in init expr anyway. IS_IOSTAT_{END,EOR} are allowed by the

[Bug c++/40389] optimizer bug (possibly)

2009-06-10 Thread jason at gcc dot gnu dot org
--- Comment #8 from jason at gcc dot gnu dot org 2009-06-10 19:37 --- As Jakub says, it's not a problem to take the address of a local variable as long as that address is only used during the variable's lifetime; the destructor for the temporary removes all references to its address, so

[Bug c++/40389] optimizer bug (possibly)

2009-06-10 Thread jason at gcc dot gnu dot org
--- Comment #9 from jason at gcc dot gnu dot org 2009-06-10 19:40 --- Actually, I'm not sure I'm the right person to work on this bug, as we might want this analysis to happen more in the optimizer. That is, we see that this escapes in one of the H constructors, so all H must be

[Bug c++/40389] optimizer bug (possibly)

2009-06-10 Thread rguenth at gcc dot gnu dot org
--- Comment #10 from rguenth at gcc dot gnu dot org 2009-06-10 19:47 --- Can we have a less convoluted C-only testcase? I still don't see what is going on ... -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40389

[Bug c++/40405] New: [4.3/4.4/4.5 Regression] ICE with invalid initialization of template member

2009-06-10 Thread reichelt at gcc dot gnu dot org
The following invalid code snippet triggers an ICE sincd GCC 3.4.5 (with the exception of GCC 4.0.0 and 4.0.1): = templateint, int struct A { static int i; }; templateint int A0,0::i = 0; int j = A0,0::i; =

[Bug c++/40405] [4.3/4.4/4.5 Regression] ICE with invalid initialization of template member

2009-06-10 Thread reichelt at gcc dot gnu dot org
-- reichelt at gcc dot gnu dot org changed: What|Removed |Added Target Milestone|--- |4.3.4 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40405

[Bug c++/40406] New: ICE with broken template member declaration

2009-06-10 Thread reichelt at gcc dot gnu dot org
The following invalid code snippet triggers an ICE since at least GCC 2.95.3: templateint struct A { templateint templateint void A::foo() {} }; bug.cc:3:36: error: extra qualification 'Aanonymous

[Bug c++/40389] optimizer bug (possibly)

2009-06-10 Thread jason at gcc dot gnu dot org
--- Comment #11 from jason at gcc dot gnu dot org 2009-06-10 20:12 --- I don't think it's possible to reproduce this in C because C doesn't have constructors, so it's obvious when the address is taken. Here's what's happening: baz uses new to allocate an A with f=0,l=0, call it A' baz

[Bug tree-optimization/40384] [4.5 regression] Revision 148277 failed gcc.dg/tree-ssa/prefetch-5.c

2009-06-10 Thread hjl dot tools at gmail dot com
--- Comment #3 from hjl dot tools at gmail dot com 2009-06-10 20:14 --- (In reply to comment #2) The new cost model added in revision 148277 supresses prefetching in a loop when it is unlikely to be profitable. One such non-profitable case is a loop with an unknown trip count and a

[Bug c/40404] Comparison involving unsigned int:17 bitfield seems wrong

2009-06-10 Thread rguenth at gcc dot gnu dot org
--- Comment #2 from rguenth at gcc dot gnu dot org 2009-06-10 20:15 --- This has been fixed in GCC 4.4, likely by removing some shorten-compare stuff in the frontend. -- rguenth at gcc dot gnu dot org changed: What|Removed |Added

[Bug c/40404] Comparison involving unsigned int:17 bitfield seems wrong

2009-06-10 Thread rguenth at gcc dot gnu dot org
--- Comment #3 from rguenth at gcc dot gnu dot org 2009-06-10 20:25 --- Can someone identify the patch that fixed that on the trunk? -- rguenth at gcc dot gnu dot org changed: What|Removed |Added

[Bug c++/40407] New: Value increment problems

2009-06-10 Thread ivranos at freemail dot gr
The produced value is not the expected. The code: #include iostream #include limits int main() { using namespace std; long double x= numeric_limitsunsigned long::max(); cout fixed; for(unsigned i= 0; i 10; ++i) { cout x endl; ++x; } cout endl x

[Bug c++/40407] Value increment problems

2009-06-10 Thread ivranos at freemail dot gr
--- Comment #1 from ivranos at freemail dot gr 2009-06-10 20:30 --- Created an attachment (id=17976) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17976action=view) The main.ii file produced with g++ -ansi -pedantic-errors -Wall -save-temps main.cc -o foobar --

[Bug c++/40407] Value increment problems

2009-06-10 Thread pinskia at gcc dot gnu dot org
--- Comment #2 from pinskia at gcc dot gnu dot org 2009-06-10 20:35 --- This is called rounding. I think you need to look at the hex values of the long double to see what happens rather than printing out the value. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40407

[Bug bootstrap/40408] New: [4.5 Regression] bootstrap boken again!

2009-06-10 Thread dominiq at lps dot ens dot fr
At revision 148352 bootstrapping is broken again on *-apple-darwin9 with: ... /opt/gcc/i686-darwin/./prev-gcc/xgcc -B/opt/gcc/i686-darwin/./prev-gcc/ -B/opt/gcc/gcc4.5w/i686-apple-darwin9/bin/ -B/opt/gcc/gcc4.5w/i686-apple-darwin9/bin/ -B/opt/gcc/gcc4.5w/i686-apple-darwin9/lib/ -isystem

[Bug bootstrap/40408] [4.5 Regression] bootstrap boken again!

2009-06-10 Thread pinskia at gcc dot gnu dot org
--- Comment #1 from pinskia at gcc dot gnu dot org 2009-06-10 20:45 --- case SWITCH_EXPR: Should be changed to: case GIMPLE_SWITCH: that will fix at least one warning/error. -- pinskia at gcc dot gnu dot org changed: What|Removed

[Bug c++/40389] optimizer bug (possibly)

2009-06-10 Thread jason at gcc dot gnu dot org
--- Comment #12 from jason at gcc dot gnu dot org 2009-06-10 20:58 --- Incidentally, the testcase can be simplified by removing the body of the copy constructor, i.e. reducing it to just the declaration H (const H h); since it isn't actually called. --

[Bug c++/40389] optimizer bug (possibly)

2009-06-10 Thread rguenth at gcc dot gnu dot org
--- Comment #13 from rguenth at gcc dot gnu dot org 2009-06-10 20:58 --- Well. I see as final difference (no SRA vs. with SRA) bb 2: D.2249 = baz (); [return slot optimization] - D.2417_8 = D.2249.a; - g.a = D.2417_8; - D.2415_10 = D.2417_8-k; + SR.101_9 = D.2249.a; +

[Bug libfortran/40330] [4.4, 4.5 Regression] incorrect IO

2009-06-10 Thread jb at gcc dot gnu dot org
--- Comment #24 from jb at gcc dot gnu dot org 2009-06-10 21:17 --- Further reduced testcase: program pr40330 implicit none call s1() call s1() contains subroutine s1() character(LEN=100) :: a a = (3X) write(*,FMT='('//trim(a)//,a,' '), ADVANCE=NO) 3 end subroutine s1

[Bug lto/40409] New: [LTO] ICE in expand_shift, at expmed.c:2263

2009-06-10 Thread rmansfield at qnx dot com
$ ./xgcc -v Using built-in specs. COLLECT_GCC=./xgcc Target: powerpc-unknown-linux-gnu Configured with: ../configure --target=powerpc-unknown-linux-gnu --prefix=/home/ryan/cross/powerpc-unknown-linux-gnu/

[Bug c++/40389] optimizer bug (possibly)

2009-06-10 Thread jakub at gcc dot gnu dot org
--- Comment #14 from jakub at gcc dot gnu dot org 2009-06-10 21:27 --- The gimplifier sees: TARGET_EXPR D.2252, Unknown tree: aggr_init_expr 3 baz D.2252 ; and: arg 0 var_decl 0x72d7f280 D.2252 type record_type 0x72d61780 H addressable ignored BLK file

[Bug c++/40389] optimizer bug (possibly)

2009-06-10 Thread jakub at gcc dot gnu dot org
--- Comment #15 from jakub at gcc dot gnu dot org 2009-06-10 21:28 --- Shorter testcase: template typename V struct S { V *f, *l; __attribute__ ((noinline)) S (void) { f = 0, l = 0; } void foo (V *x) { if (x-p != 0) x-p-n = x-n; else f = x-n; if (x-n !=

[Bug c++/40389] optimizer bug (possibly)

2009-06-10 Thread rguenth at gcc dot gnu dot org
--- Comment #16 from rguenth at gcc dot gnu dot org 2009-06-10 21:29 --- In which case the following will fix it (provided the C++ FE sets the TREE_ADDRESSABLE flag) Index: gimple.c === --- gimple.c(revision 148325)

[Bug middle-end/40401] [4.5 Regression] ICE: verify_gimple failed

2009-06-10 Thread reichelt at gcc dot gnu dot org
--- Comment #1 from reichelt at gcc dot gnu dot org 2009-06-10 21:35 --- Confirmed. Even shorter testcase: void (*fp)(const int i); void (*fp)(int i); void foo() { (*fp)(0); } The regression appeared between 2009-04-24 and

[Bug lto/40409] [LTO] ICE in expand_shift, at expmed.c:2263

2009-06-10 Thread rmansfield at gmail dot com
--- Comment #1 from rmansfield at gmail dot com 2009-06-10 21:53 --- Created an attachment (id=17977) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17977action=view) testcase -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40409

[Bug lto/40410] New: [LTO] ICE verify_stmts failed

2009-06-10 Thread rmansfield at qnx dot com
$ ./xgcc -v Using built-in specs. COLLECT_GCC=./xgcc Target: powerpc-unknown-linux-gnu Configured with: ../configure --target=powerpc-unknown-linux-gnu --prefix=/home/ryan/cross/powerpc-unknown-linux-gnu/

[Bug lto/40410] [LTO] ICE verify_stmts failed

2009-06-10 Thread rmansfield at qnx dot com
--- Comment #1 from rmansfield at qnx dot com 2009-06-10 22:08 --- Created an attachment (id=17978) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17978action=view) testcase -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40410

[Bug c/40411] New: -std=c99 does not enable c99 mode in Solaris C library

2009-06-10 Thread heydowns at borg dot com
On Solaris, the C library does not operate in c99 compliant mode by default. If c99 compliant operation is desired, the object file /usr/lib/{32,64}/values-xpg6.o needs to be linked. The details are in the Solaris standards(5) manpage. When linking using gcc -std=c99, gcc does not instruct the

[Bug bootstrap/40408] [4.5 Regression] bootstrap boken again!

2009-06-10 Thread ian at gcc dot gnu dot org
--- Comment #2 from ian at gcc dot gnu dot org 2009-06-10 22:46 --- Subject: Bug 40408 Author: ian Date: Wed Jun 10 22:46:38 2009 New Revision: 148356 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=148356 Log: PR bootstrap/40408 * graphite.c

[Bug bootstrap/40408] [4.5 Regression] bootstrap boken again!

2009-06-10 Thread ian at airs dot com
--- Comment #3 from ian at airs dot com 2009-06-10 22:48 --- Fixed. Thanks for the bug report. -- ian at airs dot com changed: What|Removed |Added

[Bug libstdc++/40289] [4.5 Regression] share/libstdc++/python/ pollutes common namespace

2009-06-10 Thread tromey at gcc dot gnu dot org
--- Comment #3 from tromey at gcc dot gnu dot org 2009-06-10 22:58 --- Subject: Bug 40289 Author: tromey Date: Wed Jun 10 22:58:22 2009 New Revision: 148357 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=148357 Log: PR libstdc++/40289: * python/Makefile.in:

[Bug libstdc++/40289] [4.5 Regression] share/libstdc++/python/ pollutes common namespace

2009-06-10 Thread tromey at gcc dot gnu dot org
--- Comment #4 from tromey at gcc dot gnu dot org 2009-06-10 23:06 --- I changed this to install the code in a versioned directory. I think this fixes the problem; reopen this PR if not. -- tromey at gcc dot gnu dot org changed: What|Removed

[Bug bootstrap/37739] [4.4 Regression] bootstrap broken with core gcc gcc-4.2.x

2009-06-10 Thread mikpe at it dot uu dot se
--- Comment #13 from mikpe at it dot uu dot se 2009-06-11 00:01 --- (In reply to comment #11) Fixed. Not quite. I'm trying to build gcc-4.4-20090609 on powerpc64-unknown-linux-gnu, with binutils 2.17.50.0.6-6, configured with --enable-languages=c,ada --with-cpu=default32

[Bug rtl-optimization/25972] pack and unpack of long doubles via union generates poor code

2009-06-10 Thread bje at gcc dot gnu dot org
--- Comment #4 from bje at gcc dot gnu dot org 2009-06-11 01:07 --- Subject: Bug 25972 Author: bje Date: Thu Jun 11 01:06:53 2009 New Revision: 148363 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=148363 Log: 2009-06-11 Alan Modra amo...@au.ibm.com PR target/25972

[Bug libfortran/40330] [4.4, 4.5 Regression] incorrect IO

2009-06-10 Thread jvdelisle at gcc dot gnu dot org
--- Comment #25 from jvdelisle at gcc dot gnu dot org 2009-06-11 01:29 --- Changing priority to normal. I have a patch that fixes the reduced test case. Testing CP2K now. -- jvdelisle at gcc dot gnu dot org changed: What|Removed |Added

[Bug libfortran/40330] [4.4, 4.5 Regression] incorrect IO

2009-06-10 Thread jvdelisle at gcc dot gnu dot org
--- Comment #26 from jvdelisle at gcc dot gnu dot org 2009-06-11 02:25 --- CP2K still fails. However, I think I have discovered the root cause. String constants in formats are saved in the fnode at sting.p which is a pointer. When we use cached parsed string data, those constant

[Bug lto/40409] [LTO] ICE in expand_shift, at expmed.c:2263

2009-06-10 Thread rmansfield at qnx dot com
--- Comment #2 from rmansfield at qnx dot com 2009-06-11 02:58 --- I reproduced this on a i686-pc-linux-gnu target: $ ./xgcc -v Using built-in specs. COLLECT_GCC=./xgcc Target: i686-pc-linux-gnu Configured with: ../configure --enable-languages=c --enable-lto --disable-bootstrap Thread

[Bug lto/40409] [LTO] ICE in expand_shift, at expmed.c:2263

2009-06-10 Thread rmansfield at qnx dot com
--- Comment #3 from rmansfield at qnx dot com 2009-06-11 03:01 --- Created an attachment (id=17979) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17979action=view) x86 testcase -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40409

[Bug fortran/40402] Problem with data statement involving structure constructors containing non-initialisation expressions

2009-06-10 Thread pault at gcc dot gnu dot org
--- Comment #2 from pault at gcc dot gnu dot org 2009-06-11 05:27 --- Created an attachment (id=17980) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17980action=view) Fix for the problem This regtests and bootstraps on trunk. Paul -- pault at gcc dot gnu dot org changed: