提交 28d30f12 编写于 作者: R Rodrigo Kumpera

Use new atomis with allocated_heap.

上级 ef2138e7
......@@ -72,8 +72,7 @@ sgen_memgov_adjust_allowance (mword allowance_estimate, mword new_heap_size)
void
sgen_memgov_release_space (mword size, int space)
{
/*FIXME CAS*/
allocated_heap -= size;
SGEN_ATOMIC_ADD_P (allocated_heap, -size);
}
gboolean
......@@ -82,8 +81,7 @@ sgen_memgov_try_alloc_space (mword size, int space)
if (sgen_memgov_available_free_space () < size)
return FALSE;
/*FIXME CAS*/
allocated_heap += size;
SGEN_ATOMIC_ADD_P (allocated_heap, size);
mono_runtime_resource_check_limit (MONO_RESOURCE_GC_HEAP, allocated_heap);
return TRUE;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册