| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 749 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 760 Handle<FixedArray> storage = | 760 Handle<FixedArray> storage = |
| 761 isolate->factory()->NewFixedArray(next_enumeration); | 761 isolate->factory()->NewFixedArray(next_enumeration); |
| 762 | 762 |
| 763 storage = Handle<FixedArray>(dictionary->CopyEnumKeysTo(*storage)); | 763 storage = Handle<FixedArray>(dictionary->CopyEnumKeysTo(*storage)); |
| 764 ASSERT(storage->length() == object->NumberOfLocalProperties(DONT_SHOW)); | 764 ASSERT(storage->length() == object->NumberOfLocalProperties(DONT_SHOW)); |
| 765 return storage; | 765 return storage; |
| 766 } | 766 } |
| 767 } | 767 } |
| 768 | 768 |
| 769 | 769 |
| 770 Handle<ObjectHashSet> ObjectHashSetAdd(Handle<ObjectHashSet> table, | |
| 771 Handle<Object> key) { | |
| 772 CALL_HEAP_FUNCTION(table->GetIsolate(), | |
| 773 table->Add(*key), | |
| 774 ObjectHashSet); | |
| 775 } | |
| 776 | |
| 777 | |
| 778 Handle<ObjectHashSet> ObjectHashSetRemove(Handle<ObjectHashSet> table, | |
| 779 Handle<Object> key) { | |
| 780 CALL_HEAP_FUNCTION(table->GetIsolate(), | |
| 781 table->Remove(*key), | |
| 782 ObjectHashSet); | |
| 783 } | |
| 784 | |
| 785 | |
| 786 Handle<ObjectHashTable> PutIntoObjectHashTable(Handle<ObjectHashTable> table, | |
| 787 Handle<Object> key, | |
| 788 Handle<Object> value) { | |
| 789 CALL_HEAP_FUNCTION(table->GetIsolate(), | |
| 790 table->Put(*key, *value), | |
| 791 ObjectHashTable); | |
| 792 } | |
| 793 | |
| 794 | |
| 795 DeferredHandleScope::DeferredHandleScope(Isolate* isolate) | 770 DeferredHandleScope::DeferredHandleScope(Isolate* isolate) |
| 796 : impl_(isolate->handle_scope_implementer()) { | 771 : impl_(isolate->handle_scope_implementer()) { |
| 797 impl_->BeginDeferredScope(); | 772 impl_->BeginDeferredScope(); |
| 798 v8::ImplementationUtilities::HandleScopeData* data = | 773 v8::ImplementationUtilities::HandleScopeData* data = |
| 799 impl_->isolate()->handle_scope_data(); | 774 impl_->isolate()->handle_scope_data(); |
| 800 Object** new_next = impl_->GetSpareOrNewBlock(); | 775 Object** new_next = impl_->GetSpareOrNewBlock(); |
| 801 Object** new_limit = &new_next[kHandleBlockSize]; | 776 Object** new_limit = &new_next[kHandleBlockSize]; |
| 802 ASSERT(data->limit == &impl_->blocks()->last()[kHandleBlockSize]); | 777 ASSERT(data->limit == &impl_->blocks()->last()[kHandleBlockSize]); |
| 803 impl_->blocks()->Add(new_next); | 778 impl_->blocks()->Add(new_next); |
| 804 | 779 |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 838 Handle<Code> code) { | 813 Handle<Code> code) { |
| 839 heap->EnsureWeakObjectToCodeTable(); | 814 heap->EnsureWeakObjectToCodeTable(); |
| 840 Handle<DependentCode> dep(heap->LookupWeakObjectToCodeDependency(*object)); | 815 Handle<DependentCode> dep(heap->LookupWeakObjectToCodeDependency(*object)); |
| 841 dep = DependentCode::Insert(dep, DependentCode::kWeaklyEmbeddedGroup, code); | 816 dep = DependentCode::Insert(dep, DependentCode::kWeaklyEmbeddedGroup, code); |
| 842 CALL_HEAP_FUNCTION_VOID(heap->isolate(), | 817 CALL_HEAP_FUNCTION_VOID(heap->isolate(), |
| 843 heap->AddWeakObjectToCodeDependency(*object, *dep)); | 818 heap->AddWeakObjectToCodeDependency(*object, *dep)); |
| 844 } | 819 } |
| 845 | 820 |
| 846 | 821 |
| 847 } } // namespace v8::internal | 822 } } // namespace v8::internal |
| OLD | NEW |