Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(248)

Side by Side Diff: src/mark-compact.cc

Issue 8883023: Revert 10216 Optimize the equality check case of ICCompare stubs. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/ic.cc ('k') | src/type-info.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 865 matching lines...) Expand 10 before | Expand all | Expand 10 after
876 heap->mark_compact_collector()->RecordRelocSlot(rinfo, object); 876 heap->mark_compact_collector()->RecordRelocSlot(rinfo, object);
877 MarkBit mark = Marking::MarkBitFrom(object); 877 MarkBit mark = Marking::MarkBitFrom(object);
878 heap->mark_compact_collector()->MarkObject(object, mark); 878 heap->mark_compact_collector()->MarkObject(object, mark);
879 } 879 }
880 880
881 static inline void VisitCodeTarget(Heap* heap, RelocInfo* rinfo) { 881 static inline void VisitCodeTarget(Heap* heap, RelocInfo* rinfo) {
882 ASSERT(RelocInfo::IsCodeTarget(rinfo->rmode())); 882 ASSERT(RelocInfo::IsCodeTarget(rinfo->rmode()));
883 Code* target = Code::GetCodeFromTargetAddress(rinfo->target_address()); 883 Code* target = Code::GetCodeFromTargetAddress(rinfo->target_address());
884 if (FLAG_cleanup_code_caches_at_gc && target->is_inline_cache_stub()) { 884 if (FLAG_cleanup_code_caches_at_gc && target->is_inline_cache_stub()) {
885 IC::Clear(rinfo->pc()); 885 IC::Clear(rinfo->pc());
886 // Please note targets for cleared inline cached do not have to be
887 // marked since they are contained in HEAP->non_monomorphic_cache().
886 target = Code::GetCodeFromTargetAddress(rinfo->target_address()); 888 target = Code::GetCodeFromTargetAddress(rinfo->target_address());
887 } else { 889 } else {
888 if (FLAG_cleanup_code_caches_at_gc && 890 if (FLAG_cleanup_code_caches_at_gc &&
889 target->kind() == Code::STUB && 891 target->kind() == Code::STUB &&
890 target->major_key() == CodeStub::CallFunction && 892 target->major_key() == CodeStub::CallFunction &&
891 target->has_function_cache()) { 893 target->has_function_cache()) {
892 CallFunctionStub::Clear(heap, rinfo->pc()); 894 CallFunctionStub::Clear(heap, rinfo->pc());
893 } 895 }
896 MarkBit code_mark = Marking::MarkBitFrom(target);
897 heap->mark_compact_collector()->MarkObject(target, code_mark);
894 } 898 }
895 MarkBit code_mark = Marking::MarkBitFrom(target);
896 heap->mark_compact_collector()->MarkObject(target, code_mark);
897
898 heap->mark_compact_collector()->RecordRelocSlot(rinfo, target); 899 heap->mark_compact_collector()->RecordRelocSlot(rinfo, target);
899 } 900 }
900 901
901 static inline void VisitDebugTarget(Heap* heap, RelocInfo* rinfo) { 902 static inline void VisitDebugTarget(Heap* heap, RelocInfo* rinfo) {
902 ASSERT((RelocInfo::IsJSReturn(rinfo->rmode()) && 903 ASSERT((RelocInfo::IsJSReturn(rinfo->rmode()) &&
903 rinfo->IsPatchedReturnSequence()) || 904 rinfo->IsPatchedReturnSequence()) ||
904 (RelocInfo::IsDebugBreakSlot(rinfo->rmode()) && 905 (RelocInfo::IsDebugBreakSlot(rinfo->rmode()) &&
905 rinfo->IsPatchedDebugBreakSlotSequence())); 906 rinfo->IsPatchedDebugBreakSlotSequence()));
906 Code* target = Code::GetCodeFromTargetAddress(rinfo->call_address()); 907 Code* target = Code::GetCodeFromTargetAddress(rinfo->call_address());
907 MarkBit code_mark = Marking::MarkBitFrom(target); 908 MarkBit code_mark = Marking::MarkBitFrom(target);
(...skipping 2995 matching lines...) Expand 10 before | Expand all | Expand 10 after
3903 while (buffer != NULL) { 3904 while (buffer != NULL) {
3904 SlotsBuffer* next_buffer = buffer->next(); 3905 SlotsBuffer* next_buffer = buffer->next();
3905 DeallocateBuffer(buffer); 3906 DeallocateBuffer(buffer);
3906 buffer = next_buffer; 3907 buffer = next_buffer;
3907 } 3908 }
3908 *buffer_address = NULL; 3909 *buffer_address = NULL;
3909 } 3910 }
3910 3911
3911 3912
3912 } } // namespace v8::internal 3913 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ic.cc ('k') | src/type-info.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698