Skip to content

Commit

Permalink
[boehm] Use managed allocator only for objects with known jit compile…
Browse files Browse the repository at this point in the history
… time size.

The allocator always expects to receive two arguments.
  • Loading branch information
BrzVlad committed May 28, 2015
1 parent 280b98a commit 98d7ad4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions mono/metadata/boehm-gc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1062,6 +1062,8 @@ mono_gc_get_managed_allocator (MonoClass *klass, gboolean for_box, gboolean know
return NULL;
if (klass->byval_arg.type == MONO_TYPE_STRING) {
atype = ATYPE_STRING;
} else if (!known_instance_size) {
return NULL;
} else if (!klass->has_references) {
if (for_box)
atype = ATYPE_FREEPTR_FOR_BOX;
Expand Down

0 comments on commit 98d7ad4

Please sign in to comment.