We were calling functions, performing GC if they failed, and then retrying.
If the second try failed, the VM failed with out of memory

Unfortunately we have very many such functions that perform multiple
allocations (I think I counted 21 and there may be more).  This leads to a
situation where we can have the first allocation fail in the young
generation, perform a scavenge collection, retry the function and have a
different allocation fail in the old generation.  At that point, we were
giving up and reporting a (false) out of memory failure.

One solution is to try three times and set a flag to make heroic efforts to
have all allocations succeed on the third try.

On Thu, Oct 30, 2008 at 7:12 PM, Feng Qian <[EMAIL PROTECTED]> wrote:

> Kasper, can you explain why need 3 GC's? I probably missed some
> changes in GC and policy.
>
> On Wed, Oct 29, 2008 at 4:43 AM,  <[EMAIL PROTECTED]> wrote:
> >
> > Reviewers: Erik Corry, Kevin Millikin,
> >
> > Description:
> > Allow three runtime call attempts before throwing an out of
> > memory exception. Still needs work in Runtime_PerformGC to
> > make sure we'll allow future allocations.
> >
> > Please review this at http://codereview.chromium.org/8873
> >
> > SVN Base: http://v8.googlecode.com/svn/branches/bleeding_edge/
> >
> > Affected files:
> >   M     src/codegen-arm.cc
> >   M     src/codegen-ia32.cc
> >   M     src/handles.cc
> >   M     src/runtime.cc
> >
> >
> >
> > > >
> >
>

--~--~---------~--~----~------------~-------~--~----~
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
-~----------~----~----~----~------~----~------~--~---

Reply via email to