Re: New SHM server broken?
Peter Hunnisett <[email protected]>
| Newsgroups | gmane.comp.emulators.winex.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi, most likely there's a memory leak in there somewhere. A 4MB data segement, while not huge, ought to be big enough as an average game seems to require something on the order of 500KB. Although as you note, it does store the whole registry in that shared memory so it's possible that a large registry will blow it out of the water. The other possibility is that memory fragmentation is causing problems. I'd guess that it's a memory leak though. To increase the size of the shm segment just increase the define for initial_size in shm.c and recompile. Let me know if it still runs out of memory. To be able to look at the shm mallocs/frees if you recompile libwineserver with PH_TRACE you should be able to have a closer look. What application is the you're seeing this problem with? Thanks, Peter Matthijs Kooijman wrote: >Hey, > >I downloaded the CVS version yesterday, and it had some problems >running. When starting (indifferent of the application being run) it >exited with an out of memory error (In the function simple_allocator, >server/shm.c:394). >Some investigation showed me that the error occured during the loading >of the default registry entries. During the loading, every now and then >4099 bytes were allocated in the SHM segment. The allocated SHM segment >is only 4MB in size, so it quickly fills up and crashes. >To solve this, i changed server/shm.c:356 to >SERVER_GLOBAL_VARIABLE( shared_memory_server ) = NULL; >(`NULL' instead of `shm'). Consequently the SHM segment is not used and >all is well. >So, are there any others having this problem? Since this does not seem >to be very specific for my case, I think? > >The way I see it, there is too much stored is SHM, since it can only be >4M. So, maybe it should be split over multiple segments? > >Gr. > >Matthijs > > >