[Bug fortran/54833] New: Don't wrap __builtin_free(a) in if (a != NULL)
tkoenig at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sat Oct 6 10:13:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54833
Bug #: 54833
Summary: Don't wrap __builtin_free(a) in if (a != NULL)
Classification: Unclassified
Product: gcc
Version: 4.8.0
Status: UNCONFIRMED
Severity: enhancement
Priority: P3
Component: fortran
AssignedTo: tkoenig@gcc.gnu.org
ReportedBy: tkoenig@gcc.gnu.org
The Fortran front end at the moment generates many calls
to __builtin_free with
if (a.data != 0B)
{
__builtin_free ((void *) a.data);
}
a.data = 0B;
This is not necessary, because free(NULL) is well-defined no-op.
More information about the Gcc-bugs
mailing list