Implement oom handling for MS.
* sgen-gc.c (collect_nursery): If any object was pinned
after initial pinning, sort the queue so build_nursery_fragments
will see the aditional objects.
If pinning due to OOM happened ask for a major collection.
* sgen-gc.c (major_do_collection): Adjust the pin queue if
OOM happened. Here we have to clean discarded entries before
optimizing the queue or we might end with interior pointers
in the mix.
* sgen-gc.c (sgen_collect_major_no_lock): New function so
major collectors can trigger a collection. They can't
use public API since the gc lock is not meant to be reentrant.
* sgen-major-copy-object.h (copy_object_no_checks): Pin
the object if we can't promote it.
* sgen-marksweep.c (alloc_obj): Return null if we fail
to allocate a block for a given freelist size.
* sgen-marksweep.c (major_alloc_degraded): Ditto.
* sgen-marksweep.c (major_copy_or_mark_object): Handle OOM.
* sgen-marksweep.c (major_alloc_small_pinned_obj): If allocation
fails, try a major collection since this is memory requested by
the runtime and it's much harder to handle failure.