--- Comment #8 from cyprien+gccbug at cypou dot net 2008-05-04 20:13
---
On some embedded machines, the SDRAM lays on 0x address. So it is not
so meaningless to increment or decrement from/to NULL pointer.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36124
--- Comment #7 from cyprien+gccbug at cypou dot net 2008-05-04 17:31
---
it's right, using --foo unstead of foo-- gives a better result.
But it does not make me happy (about the possibility of a bug)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36124
--- Comment #5 from cyprien+gccbug at cypou dot net 2008-05-04 17:03
---
Now, this code should not rely on undefined behaviour:
extern void func(int,void*);
void test()
{
register long *foo = (long*) (4*sizeof(*foo)) - 1;
register int index;
for(index=0;index<4;in
--- Comment #2 from cyprien+gccbug at cypou dot net 2008-05-04 16:41
---
shouldn't gcc report a warning in this case ?
because silently entering an infinite loop is not very kind...
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36124
regression)
Product: gcc
Version: 4.3.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: cyprien+gccbug at cypou dot net
GCC build triplet: x86_64-unkn