c++.dos.16-bits - malloc() question
- Robert Riebisch <rr bttr-software.de> Sep 18 2006
- Walter Bright <newshound digitalmars.com> Sep 20 2006
- Robert Riebisch <rr bttr-software.de> Sep 21 2006
- Robert Riebisch <rr bttr-software.de> Oct 04 2006
'size_t' is defined as 'unsigned' in, e.g., stdlib.h, but is it impossible to allocate more than 32,764 bytes at once? I found a JGE instruction in malloc's code, but why do you a signed comparison?
Sep 18 2006
Robert Riebisch wrote:'size_t' is defined as 'unsigned' in, e.g., stdlib.h, but is it impossible to allocate more than 32,764 bytes at once? I found a JGE instruction in malloc's code, but why do you a signed comparison?
Which function did you find that in? _nmalloc?
Sep 20 2006
Walter Bright wrote:Which function did you find that in? _nmalloc?
Probably. ;-) I didn't debug the RTL, but the generated test executable. I use the small memory model (option '-ms') and the instruction was 'call near ptr _malloc'. Hope, this helps!
Sep 21 2006
Robert Riebisch wrote:Probably. ;-) I didn't debug the RTL, but the generated test executable. I use the small memory model (option '-ms') and the instruction was 'call near ptr _malloc'. Hope, this helps!
Um, still waiting... :-(
Oct 04 2006








Robert Riebisch <rr bttr-software.de>