This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: egcs-19980531, warning patches [part 1/2]
- To: "Kaveh R. Ghazi" <ghazi at caip dot rutgers dot edu>
- Subject: Re: egcs-19980531, warning patches [part 1/2]
- From: David Edelsohn <dje at watson dot ibm dot com>
- Date: Mon, 08 Jun 1998 00:20:17 -0400
- Cc: jbuck at synopsys dot com, law at cygnus dot com, egcs at cygnus dot com, martin dot kahlert at mchp dot siemens dot de
>>>>> "Kaveh R Ghazi" writes:
Kaveh> On the calloc issue, I've heard ~5 positive (including
Kaveh> meissner, martin.kahlert, jbuck, drepper, etc) but Jeff is opposed.
Kaveh> It's been asserted calloc is a simple couple of line function for
Kaveh> embedded/kernel hackers to code up if its missing. And note that
Kaveh> switching to using it removes the only appearance of bzero in
Kaveh> libgcc2.c. Seems like we would thus be requiring the same _number_ of
Kaveh> functions for embedded targets/kernels, just a different one.
I don't understand what Jeff's demonstration that the HPUX kernel
does not contain the symbol calloc proves. calloc need not be used
specifically because it is efficient on Linux, but it seems to be the
correct function for this intended purpose. I don't understand why we
should avoid it.
Many systems implement it as malloc/memset, which is our proposed
implementation if it does not exist on the system. I don't know autoconf
very well, but even I could test for calloc and provide a default
implementation if it didn't exist.
David