Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > openwatcom.users.c_cpp > #3460
| From | Frank Beythien <nospam_2015@efbe.prima.de> |
|---|---|
| Newsgroups | openwatcom.users.c_cpp |
| Subject | Re: Using function "_bheapseg" under OS/2 (use of high memory) |
| Date | 2015-12-14 09:51 +0100 |
| Message-ID | <dd7e8oFsnnaU1@mid.individual.net> (permalink) |
| References | <n4lp4s$2k9$1@solani.org> <n4lpj8$41k$1@solani.org> <11p86vVJT4Oe-pn2-d8Y0M1Bb9KwY@slat60-1> |
Am 14.12.2015 um 16:07 schrieb Steven Levine: > On Mon, 14 Dec 2015 07:03:03 UTC, Lars Erdmann <lars.erdmann@arcor.de> > wrote: > > Hi Lars, > >> how do you convert (under OS/2 and using high memory if possible) a >> based address (which _bmalloc returns) into a full 32-bit linear address ? > > You don't. _bmalloc is supported only by wcc. Check the docs or the > malloc.h #ifdefs. > >> If all of this does not work under 32-bit OS/2, does anyone know any >> other functions in the Watcom RTL that would allow me to manage a heap >> in high memory ? > > I implemented high memory support so that we could link the Mozilla > apps. > > See malloc.h for: > > #if defined(__OS2__) && defined(__386__) > _WCRTLINK int _use_os2_high_mem( int fUseHighMem ); /* Returns prior > setting */ > _WCRTLINK void *_os2lmalloc( size_t amount ); > _WCRTLINK void *_os2hmalloc( size_t amount ); > #endif > > It's on my list to update the runtime library docs. That said, usage > is pretty straightforward. _use_os2_high_mem sets the global > allocation strategy used by malloc and friends. The default is low > memory only for backwards compatibility. _os2lmalloc and _os2hmalloc > override the global strategy for the current call. > > This all works similar to the gcc libc implementation. However, there > are no os2safe wrappers yet. > > Of course you will need an OpenWatcom built from the current depot > sources to use these functions. You can try http://efbe.musca.uberspace.de for an OS/2 build from current perforce data. > > Have fun, > > Steven CU/2 Frank
Back to openwatcom.users.c_cpp | Previous | Next — Previous in thread | Next in thread | Find similar
Using function "_bheapseg" under OS/2 (use of high memory) Lars Erdmann <lars.erdmann@arcor.de> - 2015-12-14 07:55 +0100
Re: Using function "_bheapseg" under OS/2 (use of high memory) Lars Erdmann <lars.erdmann@arcor.de> - 2015-12-14 08:03 +0100
Re: Using function "_bheapseg" under OS/2 (use of high memory) "Steven Levine" <steve53@nomail.earthlink.net> - 2015-12-14 15:07 +0000
Re: Using function "_bheapseg" under OS/2 (use of high memory) Frank Beythien <nospam_2015@efbe.prima.de> - 2015-12-14 09:51 +0100
Re: Using function "_bheapseg" under OS/2 (use of high memory) Lars Erdmann <lars.erdmann@arcor.de> - 2015-12-14 20:36 +0100
Re: Using function "_bheapseg" under OS/2 (use of high memory) Lars Erdmann <lars.erdmann@arcor.de> - 2015-12-14 20:34 +0100
csiph-web