[Bug c/35427] New: pointer subtraction in very big array

2008-03-03 Thread akr at m17n dot org
. -- Summary: pointer subtraction in very big array Product: gcc Version: 4.2.3 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: akr at m17n

[Bug c/35427] pointer subtraction in very big array

2008-03-03 Thread akr at m17n dot org
--- Comment #2 from akr at m17n dot org 2008-03-03 23:45 --- (In reply to comment #1) nelem*sizeof(long) Wraps so what do you expect? This is the correct behavior really. Oops. It wrapped. But changing the type of nelem to size_t doesn't change the situation. nelem * sizeof

[Bug c/35427] pointer subtraction in very big array

2008-03-03 Thread akr at m17n dot org
--- Comment #4 from akr at m17n dot org 2008-03-04 00:17 --- The result can be representable by ptrdiff_t because the result is number of longs. The array is bit larger than 2**31 bytes. So the result is bit larger than 2**29. It is representable in signed. -- http://gcc.gnu.org

[Bug target/31907] isnan builtin doesn't work

2007-11-22 Thread akr at m17n dot org
--- Comment #1 from akr at m17n dot org 2007-11-23 07:52 --- (In reply to comment #0) isnan(0.0/0.0) returns false. It returns true if -fno-builtin. I found it is a problem of FPU emulation in Linux kernel. The problem is caused by FASTFPE. NWFPE doesn't have the problem. -- akr

[Bug c/33663] New: local register variable and memcmp

2007-10-04 Thread akr at m17n dot org
Status: UNCONFIRMED Severity: normal Priority: P3 Component: c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: akr at m17n dot org GCC build triplet: i686-pc-linux-gnu GCC host triplet: i686-pc-linux-gnu GCC target triplet: i686-pc-linux

[Bug c/31907] New: isnan builtin doesn't work

2007-05-12 Thread akr at m17n dot org
Status: UNCONFIRMED Severity: normal Priority: P3 Component: c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: akr at m17n dot org GCC build triplet: armv5tejl-unknown-linux-gnu GCC host triplet: armv5tejl-unknown-linux-gnu GCC target

[Bug target/28197] longjmp and alloca cause bus error at -O0

2007-05-06 Thread akr at m17n dot org
--- Comment #4 from akr at m17n dot org 2007-05-07 06:56 --- I think the problem can be fixed by alloca or setjmp. * alloca extends a stack as the old stack backchain will not crashed, or * setjmp saves the stack backchain and longjmp restore it. I'm not sure that which should be done

[Bug c/28197] New: longjmp and alloca cause bus error

2006-06-28 Thread akr at m17n dot org
-- Summary: longjmp and alloca cause bus error Product: gcc Version: 4.1.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: akr at m17n dot

[Bug target/28197] longjmp and alloca cause bus error at -O0

2006-06-28 Thread akr at m17n dot org
--- Comment #1 from akr at m17n dot org 2006-06-29 01:49 --- I found a way to reproduce the bus error with -O2 as well as -O0. % cat z.c #include setjmp.h jmp_buf env; int i; int main() { if (setjmp(env) == 0) { char *p = __builtin_alloca(1024); for (i = 0; i 1024; i

[Bug c/22429] New: -1073741824 = n n = 1073741823 is true where n is 1073741824

2005-07-12 Thread akr at m17n dot org
Version: 4.1.0 Status: UNCONFIRMED Severity: normal Priority: P2 Component: c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: akr at m17n dot org CC: gcc-bugs at gcc dot gnu dot org GCC target triplet: i686

[Bug middle-end/21957] IA-64 register stack is not preserved after getcontext call

2005-06-28 Thread akr at m17n dot org
--- Additional Comments From akr at m17n dot org 2005-06-29 03:50 --- I think getcontext should return twice because getcontext is similar to setjmp. First, getcontext returns from usual function call. Second, getcontext returns from setcontext. -- http://gcc.gnu.org/bugzilla

[Bug c/22127] New: SPARC register window is not preserved after getcontext call

2005-06-20 Thread akr at m17n dot org
: gcc Version: 4.0.1 Status: UNCONFIRMED Severity: normal Priority: P2 Component: c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: akr at m17n dot org CC: gcc-bugs at gcc dot gnu dot org GCC build triplet

[Bug c/22127] SPARC register window is not preserved after getcontext call

2005-06-20 Thread akr at m17n dot org
--- Additional Comments From akr at m17n dot org 2005-06-20 17:22 --- It's because getcontext is similar to setjmp. Since setjmp/getcontext doesn't save registers in register window, modifications to the registers between first setjmp/getcontext return and longjmp/setcontext call

[Bug c/22127] [3.4/4.0/4.1 Regression] register window not preserved after getcontext call

2005-06-20 Thread akr at m17n dot org
--- Additional Comments From akr at m17n dot org 2005-06-20 17:36 --- Although I have no Sun's Compiler, I found some pragmas about header file in SunOS: #pragma unknown_control_flow(setjmp) #pragma unknown_control_flow(_setjmp) #pragma unknown_control_flow(sigsetjmp) #pragma

[Bug c/21957] New: IA-64 register stack is not preserved after getcontext call

2005-06-08 Thread akr at m17n dot org
: akr at m17n dot org CC: gcc-bugs at gcc dot gnu dot org GCC build triplet: ia64-unknown-linux-gnu GCC host triplet: ia64-unknown-linux-gnu GCC target triplet: ia64-unknown-linux-gnu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21957

[Bug c/21957] IA-64 register stack is not preserved after getcontext call

2005-06-08 Thread akr at m17n dot org
--- Additional Comments From akr at m17n dot org 2005-06-08 06:19 --- Oops. The newlines are squashed. I repeat the report as this comment. I found that following code causes SEGV on IA-64 Debian GNU/Linux (sarge) with gcc-4.0 -O1. The code uses getcontext and setcontext which

[Bug c/21332] New: -O2 makes a loop doesn't execute a body

2005-05-02 Thread akr at m17n dot org
: unassigned at gcc dot gnu dot org ReportedBy: akr at m17n dot org CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21332

[Bug c/21297] New: buf[i+i]=0 stores buf[i] when -O2

2005-04-30 Thread akr at m17n dot org
: normal Priority: P2 Component: c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: akr at m17n dot org CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21297