delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/09/25/15:30:44

From: "DeHackEd" <not DOT given AT out DOT net>
References: <Pine DOT SUN DOT 3 DOT 96 DOT 980925150738 DOT 23875A-100000 AT athenas DOT ime DOT unicamp DOT br>
Subject: Re: Memory allocation!
Date: Fri, 25 Sep 1998 15:18:28 -0400
Lines: 32
Message-ID: <OIIwDmL69GA.182@upnetnews03>
Newsgroups: comp.os.msdos.djgpp
NNTP-Posting-Host: d47-bn01-blvl-pdi.attcanada.net [142.194.131.47]
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

The MALLOC library was written to be extremely fast, not extremely efficient.
It's funny you should ask that - most people ask why memory gets lost, and the
reason is the library was made to be the fastest thing used.

As for NEW, you'd have to test it. I don't know if malloc and new are the same
thing, but I would assume so.

--
"DeHackEd"

My Email address in the header is fake (spammers). Email me at this address:

http://www.geocities.com/cgi-bin/homestead/mail.pl?dehacked
Renato F. Cantao wrote in message ...
>Hi Friends!
>
> I'm working on some mathematics implementations involving large
>amounts of memory allocation. So my questions are:
>
> 1. Operator "new" and "malloc" are speed-equivalent?
> 2. Despite the answer, does exist a better (=faster!) way to
>allocate memory?
>
> Thanks a lot!
>
> Renato Fernandes CANTAO
> State University at Campinas
> Campinas - Brazil
>
>


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019