[geeks] Prolog for network configuration

Joshua D Boyd jdboyd at cs.millersville.edu
Thu Aug 8 14:44:12 CDT 2002


On Thu, Aug 08, 2002 at 03:35:19PM -0400, Tom Borton wrote:
> >From what I've seen of the Windows heap handlers, the problem is not so much
> that MS makes it difficult - their new() and malloc() routines simply call the
> Win32 API - but that the other compilers choose to have internal heap managers
> that don't hit the Win32 API as often.  The heap-related API calls are
> relatively slow, and it's easier to recover the heap memory if the application
> has just allocated one or two large chunks internally at startup and can
> de-allocate them from the RTL during an exit.
> 
> That's why you have to worry about .DLLs - if they allocate straight from the
> Windows heap and the process aborts, that memory gets lost because the RTL in
> the main program knows nothing about it.

I was trying to not dive too deep into it, but since we are anyway...

My understanding, from the article was that the problem was just the
memory getting lost.  It was also memory being deallocated by a DLL
without the application realizing it.  Under NT, all that would happen
would be a segfault.  But under win9x, it could potentially corrupt
numerous other DLLs.

However, I try to avoid doing any such thing under windows.  I try to
stick to straight win32 apps, and/or using non-native toolkits like
wxwindows, glut, gtk, etc.  And of course, most recently all my windows
work has been either console mode, or through WTK (bletch).

Oh, and BTW, it seems that despite working at a hyperthreading enabled
dual xeon machine, Windows 2k Pro only lets me use the first logical
processor from each chip.  From the sounds of it, only .NET server (and
linux) properly support hyperthreading (which basically means this
machines potential is more or less cut in half).


-- 
Joshua D. Boyd



More information about the geeks mailing list