--- Additional Comments From falk at debian dot org 2005-09-24 09:39
---
(In reply to comment #21)
> There have been lots of messages exchanged on this topic. It was just
> pointed to me that the C++ standard -- unlike the C99 standard -- has the
> following wording 5.7/7:
Hmm, I miss
--- Additional Comments From gdr at gcc dot gnu dot org 2005-09-24 05:37
---
(In reply to comment #0)
> The code
>
> void stuff(void);
> void f(int *p, int x)
> {
> int *q = p + x;
> if (!q)
> stuff();
> }
>
> should never call stuff() - the test is unne
--- Additional Comments From mattias at virtutech dot se 2005-07-15 15:29
---
(In reply to comment #18)
> The "side" notes were written by people who know what they
> intend. Therefore their inputs are completely relevant here.
Even if you could show that these optimisations would contr
--- Additional Comments From falk at debian dot org 2005-07-15 15:05
---
(In reply to comment #18)
> The "side" notes were written by people who know what they
> intend. Therefore their inputs are completely relevant here.
This is going nowhere. I give up.
--
http://gcc.gnu.org/bu
--- Additional Comments From gdr at integrable-solutions dot net
2005-07-15 14:43 ---
Subject: Re: pointer +- integer is never NULL
"falk at debian dot org" <[EMAIL PROTECTED]> writes:
| (In reply to comment #13)
| > Subject: Re: pointer +- integer is never NULL
| >
| > "falk at deb
--- Additional Comments From falk at debian dot org 2005-07-15 14:22
---
(In reply to comment #13)
> Subject: Re: pointer +- integer is never NULL
>
> "falk at debian dot org" <[EMAIL PROTECTED]> writes:
> | Sorry, I cannot follow you. I'd find it massively unsurprising if
> | reinterp
--- Additional Comments From pluto at agmk dot net 2005-07-15 10:35 ---
minor comment:
e.g. on ARM7 i can read data from address 0x (-> exception vector
table).
int* p = (int*)0x0004;
int d = -1;
int *m = *p + d;// it's valid for ARM arch.
--
http://gcc.gnu.org/bugz
--- Additional Comments From gdr at integrable-solutions dot net
2005-07-15 10:26 ---
Subject: Re: pointer +- integer is never NULL
"mattias at virtutech dot se" <[EMAIL PROTECTED]> writes:
| --- Additional Comments From mattias at virtutech dot se 2005-07-15
09:12 ---
| It
--- Additional Comments From mattias at virtutech dot se 2005-07-15 09:12
---
It could be made an option so the user can tell GCC whether to make
standard-conforming code go as fast as possible or if arithmetic on null
pointers (as a gcc extension, say) is needed. -fnull-pointer-arith?
--- Additional Comments From gdr at integrable-solutions dot net
2005-07-15 08:10 ---
Subject: Re: pointer +- integer is never NULL
"falk at debian dot org" <[EMAIL PROTECTED]> writes:
| --- Additional Comments From falk at debian dot org 2005-07-15 06:41
---
| Subject: Re:
--- Additional Comments From falk at debian dot org 2005-07-15 06:41
---
Subject: Re: pointer +- integer is never NULL
"gdr at integrable-solutions dot net" <[EMAIL PROTECTED]> writes:
> My indirect observation was that reinterpret_cast is intended for
> specific needs that cannot ade
--- Additional Comments From gdr at integrable-solutions dot net
2005-07-14 23:03 ---
Subject: Re: pointer +- integer is never NULL
"falk at debian dot org" <[EMAIL PROTECTED]> writes:
[...]
| > | (In reply to comment #7)
| > |
| > | > I'm failing to find anything in the C++ standar
--- Additional Comments From falk at debian dot org 2005-07-14 21:47
---
Subject: Re: pointer +- integer is never NULL
Gabriel Dos Reis <[EMAIL PROTECTED]> writes:
> "falk at debian dot org" <[EMAIL PROTECTED]> writes:
>
> | --- Additional Comments From falk at debian dot org 200
Gabriel Dos Reis <[EMAIL PROTECTED]> writes:
> "falk at debian dot org" <[EMAIL PROTECTED]> writes:
>
> | --- Additional Comments From falk at debian dot org 2005-07-14 15:37
> ---
> | (In reply to comment #7)
> |
> | > I'm failing to find anything in the C++ standard that suggests that
--- Additional Comments From gdr at integrable-solutions dot net
2005-07-14 19:38 ---
Subject: Re: pointer +- integer is never NULL
"falk at debian dot org" <[EMAIL PROTECTED]> writes:
| --- Additional Comments From falk at debian dot org 2005-07-14 15:37
---
| (In reply to
"falk at debian dot org" <[EMAIL PROTECTED]> writes:
| --- Additional Comments From falk at debian dot org 2005-07-14 15:37
---
| (In reply to comment #7)
|
| > I'm failing to find anything in the C++ standard that suggests that the
| > following shall be undefined
| >
| >(reinterp
--- Additional Comments From falk at debian dot org 2005-07-14 15:37
---
(In reply to comment #7)
> I'm failing to find anything in the C++ standard that suggests that the
> following shall be undefined
>
>(reinterpret_cast(0) + 5) - 5
If (reinterpret_cast(0) + 5) - 5 is not undef
--- Additional Comments From gdr at integrable-solutions dot net
2005-07-14 15:19 ---
Subject: Re: pointer +- integer is never NULL
"falk at debian dot org" <[EMAIL PROTECTED]> writes:
| (In reply to comment #4)
| > H.
| > I swear we just had this discussion for VRP purposes, and
--- Additional Comments From gdr at integrable-solutions dot net
2005-07-14 15:17 ---
Subject: Re: pointer +- integer is never NULL
"dberlin at gcc dot gnu dot org" <[EMAIL PROTECTED]> writes:
| H.
| I swear we just had this discussion for VRP purposes, and that a bug was
| recent
--- Additional Comments From falk at debian dot org 2005-07-14 13:45
---
(In reply to comment #4)
> H.
> I swear we just had this discussion for VRP purposes, and that a bug was
> recently fixed so that we don't assume that pointer + - integer is NULL.
Well, I checked C99 and C++,
--- Additional Comments From dberlin at gcc dot gnu dot org 2005-07-14
13:38 ---
H.
I swear we just had this discussion for VRP purposes, and that a bug was
recently fixed so that we don't assume that pointer + - integer is NULL.
But if it's really undefined, maybe we should optimi
--- Additional Comments From falk at debian dot org 2005-07-14 13:19
---
(In reply to comment #2)
> This is invalid and here is why, if both p and x are NULL/0, then p+x will
always be NULL so in this is
> invalid optimization.
Huh? nullpointer + 0 is undefined, it doesn't matter what
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-07-14
13:14 ---
This is invalid and here is why, if both p and x are NULL/0, then p+x will
always be NULL so in this is
invalid optimization.
--
What|Removed |Added
---
--- Additional Comments From mattias at virtutech dot se 2005-07-14 13:13
---
I forgot to state the version (4.0.0), but I have not seen any gcc version
optimising this case.
--
What|Removed |Added
24 matches
Mail list logo