Return descriptor ownership after TrimDescriptorArray to allow resharing of descriptor arrays

BUG=None
R=mstarzinger@chromium.org

Review URL: https://codereview.chromium.org/27197002

Patch from Ross McIlroy <rmcilroy@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@17237 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
mstarzinger@chromium.org 2013-10-16 11:16:49 +00:00
parent 100ab91013
commit 5eae41e518

View File

@ -9381,6 +9381,7 @@ void Map::ClearNonLiveTransitions(Heap* heap) {
if (number_of_own_descriptors > 0) {
TrimDescriptorArray(heap, this, descriptors, number_of_own_descriptors);
ASSERT(descriptors->number_of_descriptors() == number_of_own_descriptors);
set_owns_descriptors(true);
} else {
ASSERT(descriptors == GetHeap()->empty_descriptor_array());
}