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

Side by Side Diff: src/liveedit.cc

Issue 24791002: Thumb2 Backend: Thumb2 changes for Deoptimization and Code Aging Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 2 months 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-inl.h ('k') | src/mark-compact.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 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 1016 matching lines...) Expand 10 before | Expand all | Expand 10 after
1027 virtual void VisitPointers(Object** start, Object** end) { 1027 virtual void VisitPointers(Object** start, Object** end) {
1028 for (Object** p = start; p < end; p++) { 1028 for (Object** p = start; p < end; p++) {
1029 if (*p == original_) { 1029 if (*p == original_) {
1030 *p = substitution_; 1030 *p = substitution_;
1031 } 1031 }
1032 } 1032 }
1033 } 1033 }
1034 1034
1035 virtual void VisitCodeEntry(Address entry) { 1035 virtual void VisitCodeEntry(Address entry) {
1036 if (Code::GetObjectFromEntryAddress(entry) == original_) { 1036 if (Code::GetObjectFromEntryAddress(entry) == original_) {
1037 Address substitution_entry = substitution_->instruction_start(); 1037 Address substitution_entry = substitution_->entry();
1038 Memory::Address_at(entry) = substitution_entry; 1038 Memory::Address_at(entry) = substitution_entry;
1039 } 1039 }
1040 } 1040 }
1041 1041
1042 virtual void VisitCodeTarget(RelocInfo* rinfo) { 1042 virtual void VisitCodeTarget(RelocInfo* rinfo) {
1043 if (RelocInfo::IsCodeTarget(rinfo->rmode()) && 1043 if (RelocInfo::IsCodeTarget(rinfo->rmode()) &&
1044 Code::GetCodeFromTargetAddress(rinfo->target_address()) == original_) { 1044 Code::GetCodeFromTargetAddress(rinfo->target_address()) == original_) {
1045 Address substitution_entry = substitution_->instruction_start(); 1045 Address substitution_entry = substitution_->entry();
1046 rinfo->set_target_address(substitution_entry); 1046 rinfo->set_target_address(substitution_entry);
1047 } 1047 }
1048 } 1048 }
1049 1049
1050 virtual void VisitDebugTarget(RelocInfo* rinfo) { 1050 virtual void VisitDebugTarget(RelocInfo* rinfo) {
1051 VisitCodeTarget(rinfo); 1051 VisitCodeTarget(rinfo);
1052 } 1052 }
1053 1053
1054 private: 1054 private:
1055 Code* original_; 1055 Code* original_;
(...skipping 728 matching lines...) Expand 10 before | Expand all | Expand 10 after
1784 } 1784 }
1785 } 1785 }
1786 1786
1787 // Committing now. After this point we should return only NULL value. 1787 // Committing now. After this point we should return only NULL value.
1788 1788
1789 FixTryCatchHandler(pre_top_frame, bottom_js_frame); 1789 FixTryCatchHandler(pre_top_frame, bottom_js_frame);
1790 // Make sure FixTryCatchHandler is idempotent. 1790 // Make sure FixTryCatchHandler is idempotent.
1791 ASSERT(!FixTryCatchHandler(pre_top_frame, bottom_js_frame)); 1791 ASSERT(!FixTryCatchHandler(pre_top_frame, bottom_js_frame));
1792 1792
1793 Handle<Code> code = Isolate::Current()->builtins()->FrameDropper_LiveEdit(); 1793 Handle<Code> code = Isolate::Current()->builtins()->FrameDropper_LiveEdit();
1794 *top_frame_pc_address = code->entry(); 1794 *top_frame_pc_address = code->instruction_start();
1795 pre_top_frame->SetCallerFp(bottom_js_frame->fp()); 1795 pre_top_frame->SetCallerFp(bottom_js_frame->fp());
1796 1796
1797 *restarter_frame_function_pointer = 1797 *restarter_frame_function_pointer =
1798 Debug::SetUpFrameDropperFrame(bottom_js_frame, code); 1798 Debug::SetUpFrameDropperFrame(bottom_js_frame, code);
1799 1799
1800 ASSERT((**restarter_frame_function_pointer)->IsJSFunction()); 1800 ASSERT((**restarter_frame_function_pointer)->IsJSFunction());
1801 1801
1802 for (Address a = unused_stack_top; 1802 for (Address a = unused_stack_top;
1803 a < unused_stack_bottom; 1803 a < unused_stack_bottom;
1804 a += kPointerSize) { 1804 a += kPointerSize) {
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after
2128 2128
2129 bool LiveEditFunctionTracker::IsActive(Isolate* isolate) { 2129 bool LiveEditFunctionTracker::IsActive(Isolate* isolate) {
2130 return false; 2130 return false;
2131 } 2131 }
2132 2132
2133 #endif // ENABLE_DEBUGGER_SUPPORT 2133 #endif // ENABLE_DEBUGGER_SUPPORT
2134 2134
2135 2135
2136 2136
2137 } } // namespace v8::internal 2137 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ic-inl.h ('k') | src/mark-compact.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698