harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexey Varlamov" <alexey.v.varla...@gmail.com>
Subject Re: [drlvm] stress.Mix / MegaSpawn threading bug
Date Fri, 12 Jan 2007 06:05:20 GMT
2007/1/12, Salikh Zakirov <Salikh.Zakirov@intel.com>:
>
> >> >> 2)
> >> > >> Why not simply hard code DRLVM to throw an OOME whenever there
are
> >> > >> more than
> >> > >> 1K threads running?  I think Rana first suggested this approach.
> >> > >> My guess
> >> > >> is that 1K threads is good enough to run lots of interesting
> >> > >> workloads.  My
> >> > >> guess is that common versions of WinXP and Linux will handle the
C
> >> > >> malloc()
> >> > >> load of 1K threads successfully.  If not, how about trying 512
> >> > >> threads?
>
> I've tried a quick-and-dirty patch to limit the number of threads to 500,
> and it indeed fixes crashes on MegaSpawn.
>
> > -1 for hard coding max number of threads.
>
> Alexey's proposal to watch virtual memory availability looks feasible,
> and will let us avoid hardcoding any number.

Yes, but it will not work until exact key points for memory check-up
are specified.
And probably finding all such points is nearly equivalent to fixing
them for error conditions :)

>
> My observation is that limiting number of concurrently running threads
> is by far easier than implementing some sort of custom memory manager
> with reserve areas etc, and will allow us to get over MegaSpawn failures.
>
But, as many already pointed, what is the benefit of rounding
particular corner cases? It does not really help gaining better
reliability etc.
The easiest solution is just to put MegaSpawn in exclude list
forever^H^H^H^H^H^H^H until its' time comes ;)

Mime
View raw message