public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug middle-end/16187] ARRAY_REF should be used for pointers also [not found] <bug-16187-1008@http.gcc.gnu.org/bugzilla/> @ 2005-11-13 16:47 ` pinskia at gcc dot gnu dot org 2007-04-16 1:56 ` dberlin at gcc dot gnu dot org ` (2 subsequent siblings) 3 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu dot org @ 2005-11-13 16:47 UTC (permalink / raw) To: gcc-bugs ------- Comment #6 from pinskia at gcc dot gnu dot org 2005-11-13 16:47 ------- New project for 4.2: http://gcc.gnu.org/wiki/Array%20references%20on%20pointers -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16187 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/16187] ARRAY_REF should be used for pointers also [not found] <bug-16187-1008@http.gcc.gnu.org/bugzilla/> 2005-11-13 16:47 ` [Bug middle-end/16187] ARRAY_REF should be used for pointers also pinskia at gcc dot gnu dot org @ 2007-04-16 1:56 ` dberlin at gcc dot gnu dot org 2008-01-29 0:20 ` pinskia at gcc dot gnu dot org 2008-01-29 1:04 ` pinskia at gcc dot gnu dot org 3 siblings, 0 replies; 6+ messages in thread From: dberlin at gcc dot gnu dot org @ 2007-04-16 1:56 UTC (permalink / raw) To: gcc-bugs ------- Comment #7 from dberlin at gcc dot gnu dot org 2007-04-16 02:56 ------- The version I produced was turned down, and I have not had time to rewrite it to be what others wanted -- dberlin at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|dberlin at gcc dot gnu dot |unassigned at gcc dot gnu |org |dot org Status|ASSIGNED |NEW http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16187 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/16187] ARRAY_REF should be used for pointers also [not found] <bug-16187-1008@http.gcc.gnu.org/bugzilla/> 2005-11-13 16:47 ` [Bug middle-end/16187] ARRAY_REF should be used for pointers also pinskia at gcc dot gnu dot org 2007-04-16 1:56 ` dberlin at gcc dot gnu dot org @ 2008-01-29 0:20 ` pinskia at gcc dot gnu dot org 2008-01-29 1:04 ` pinskia at gcc dot gnu dot org 3 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu dot org @ 2008-01-29 0:20 UTC (permalink / raw) To: gcc-bugs ------- Comment #8 from pinskia at gcc dot gnu dot org 2008-01-29 00:17 ------- I think this is basically fixed with the pointer plus work I did. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16187 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/16187] ARRAY_REF should be used for pointers also [not found] <bug-16187-1008@http.gcc.gnu.org/bugzilla/> ` (2 preceding siblings ...) 2008-01-29 0:20 ` pinskia at gcc dot gnu dot org @ 2008-01-29 1:04 ` pinskia at gcc dot gnu dot org 3 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu dot org @ 2008-01-29 1:04 UTC (permalink / raw) To: gcc-bugs ------- Comment #9 from pinskia at gcc dot gnu dot org 2008-01-29 00:19 ------- With the trunk we get: return *(data + (long unsigned int) j * 4); Which is much better. The cast is still needed though. -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED Target Milestone|--- |4.3.0 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16187 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/16187] New: extra casts to unsigned int generated for array references @ 2004-06-25 0:52 dann at godzilla dot ics dot uci dot edu 2005-03-26 5:38 ` [Bug middle-end/16187] ARRAY_REF should be used for pointers also pinskia at gcc dot gnu dot org 2005-07-24 1:03 ` pinskia at gcc dot gnu dot org 0 siblings, 2 replies; 6+ messages in thread From: dann at godzilla dot ics dot uci dot edu @ 2004-06-25 0:52 UTC (permalink / raw) To: gcc-bugs The .vars dump for this function: int f1(int * data, int j) { return data[j]; } looks like: return *((int *)((unsigned int)j * 4) + data); The cast to "unsigned int" is probably not needed, emitting it increases the number of statements generated, so it probably increases the memory consumption and the amount of work the optimizers have to perform. -- Summary: extra casts to unsigned int generated for array references Product: gcc Version: 3.5.0 Status: UNCONFIRMED Severity: normal Priority: P2 Component: middle-end AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: dann at godzilla dot ics dot uci dot edu CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16187 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/16187] ARRAY_REF should be used for pointers also 2004-06-25 0:52 [Bug middle-end/16187] New: extra casts to unsigned int generated for array references dann at godzilla dot ics dot uci dot edu @ 2005-03-26 5:38 ` pinskia at gcc dot gnu dot org 2005-07-24 1:03 ` pinskia at gcc dot gnu dot org 1 sibling, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu dot org @ 2005-03-26 5:38 UTC (permalink / raw) To: gcc-bugs ------- Additional Comments From pinskia at gcc dot gnu dot org 2005-03-26 05:38 ------- http://gcc.gnu.org/wiki/Add%20MEM_REF%20operation -- What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|unassigned at gcc dot gnu |dberlin at gcc dot gnu dot |dot org |org Status|NEW |ASSIGNED http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16187 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/16187] ARRAY_REF should be used for pointers also 2004-06-25 0:52 [Bug middle-end/16187] New: extra casts to unsigned int generated for array references dann at godzilla dot ics dot uci dot edu 2005-03-26 5:38 ` [Bug middle-end/16187] ARRAY_REF should be used for pointers also pinskia at gcc dot gnu dot org @ 2005-07-24 1:03 ` pinskia at gcc dot gnu dot org 1 sibling, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu dot org @ 2005-07-24 1:03 UTC (permalink / raw) To: gcc-bugs ------- Additional Comments From pinskia at gcc dot gnu dot org 2005-07-24 01:00 ------- http://gcc.gnu.org/ml/gcc-patches/2005-06/msg02025.html -- What |Removed |Added ---------------------------------------------------------------------------- Last reconfirmed|2005-06-25 18:40:29 |2005-07-24 01:00:30 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16187 ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2008-01-29 0:20 UTC | newest] Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <bug-16187-1008@http.gcc.gnu.org/bugzilla/> 2005-11-13 16:47 ` [Bug middle-end/16187] ARRAY_REF should be used for pointers also pinskia at gcc dot gnu dot org 2007-04-16 1:56 ` dberlin at gcc dot gnu dot org 2008-01-29 0:20 ` pinskia at gcc dot gnu dot org 2008-01-29 1:04 ` pinskia at gcc dot gnu dot org 2004-06-25 0:52 [Bug middle-end/16187] New: extra casts to unsigned int generated for array references dann at godzilla dot ics dot uci dot edu 2005-03-26 5:38 ` [Bug middle-end/16187] ARRAY_REF should be used for pointers also pinskia at gcc dot gnu dot org 2005-07-24 1:03 ` pinskia at gcc dot gnu dot org
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).