public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/19831] New: Missing DSE/malloc/free optimization
@ 2005-02-09 7:20 pinskia at gcc dot gnu dot org
2005-02-09 9:44 ` [Bug tree-optimization/19831] " dberlin at dberlin dot org
2005-02-09 12:43 ` pinskia at gcc dot gnu dot org
0 siblings, 2 replies; 3+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-02-09 7:20 UTC (permalink / raw)
To: gcc-bugs
The following function really should be compiled to an empty function (DSE should first remove the
store and then free of a malloc with no change inbetween and we should remove both calls).
void *malloc(__SIZE_TYPE__);
void free(void*);
int f(void)
{
char *i = malloc(1);
*i = 1;
free (i);
}
This is something which is useful when we want to much higer level optimizations.
--
Summary: Missing DSE/malloc/free optimization
Product: gcc
Version: 4.0.0
Status: UNCONFIRMED
Keywords: missed-optimization
Severity: enhancement
Priority: P2
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pinskia at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19831
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug tree-optimization/19831] Missing DSE/malloc/free optimization
2005-02-09 7:20 [Bug tree-optimization/19831] New: Missing DSE/malloc/free optimization pinskia at gcc dot gnu dot org
@ 2005-02-09 9:44 ` dberlin at dberlin dot org
2005-02-09 12:43 ` pinskia at gcc dot gnu dot org
1 sibling, 0 replies; 3+ messages in thread
From: dberlin at dberlin dot org @ 2005-02-09 9:44 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From dberlin at gcc dot gnu dot org 2005-02-09 03:42 -------
Subject: Re: New: Missing DSE/malloc/free
optimization
> void *malloc(__SIZE_TYPE__);
> void free(void*);
> int f(void)
> {
> char *i = malloc(1);
> *i = 1;
> free (i);
> }
>
> This is something which is useful when we want to much higer level optimizations.
This would require an attribute free, which is on the tree-profiling
branch
Otherwise, you wouldn't know that free is really "free"
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19831
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug tree-optimization/19831] Missing DSE/malloc/free optimization
2005-02-09 7:20 [Bug tree-optimization/19831] New: Missing DSE/malloc/free optimization pinskia at gcc dot gnu dot org
2005-02-09 9:44 ` [Bug tree-optimization/19831] " dberlin at dberlin dot org
@ 2005-02-09 12:43 ` pinskia at gcc dot gnu dot org
1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-02-09 12:43 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2005-02-09 06:51:15
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19831
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2005-02-09 6:51 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-02-09 7:20 [Bug tree-optimization/19831] New: Missing DSE/malloc/free optimization pinskia at gcc dot gnu dot org
2005-02-09 9:44 ` [Bug tree-optimization/19831] " dberlin at dberlin dot org
2005-02-09 12:43 ` 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).