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

Side by Side Diff: src/factory.cc

Issue 297303006: Some more debugger-related refactorings. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: fix Created 6 years, 6 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/execution.cc ('k') | src/liveedit.cc » ('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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "factory.h" 5 #include "factory.h"
6 6
7 #include "conversions.h" 7 #include "conversions.h"
8 #include "isolate-inl.h" 8 #include "isolate-inl.h"
9 #include "macro-assembler.h" 9 #include "macro-assembler.h"
10 10
(...skipping 2021 matching lines...) Expand 10 before | Expand all | Expand 10 after
2032 Handle<Code> code(shared->code()); 2032 Handle<Code> code(shared->code());
2033 2033
2034 // Create a copy of the code before allocating the debug info object to avoid 2034 // Create a copy of the code before allocating the debug info object to avoid
2035 // allocation while setting up the debug info object. 2035 // allocation while setting up the debug info object.
2036 Handle<Code> original_code(*Factory::CopyCode(code)); 2036 Handle<Code> original_code(*Factory::CopyCode(code));
2037 2037
2038 // Allocate initial fixed array for active break points before allocating the 2038 // Allocate initial fixed array for active break points before allocating the
2039 // debug info object to avoid allocation while setting up the debug info 2039 // debug info object to avoid allocation while setting up the debug info
2040 // object. 2040 // object.
2041 Handle<FixedArray> break_points( 2041 Handle<FixedArray> break_points(
2042 NewFixedArray(Debug::kEstimatedNofBreakPointsInFunction)); 2042 NewFixedArray(DebugInfo::kEstimatedNofBreakPointsInFunction));
2043 2043
2044 // Create and set up the debug info object. Debug info contains function, a 2044 // Create and set up the debug info object. Debug info contains function, a
2045 // copy of the original code, the executing code and initial fixed array for 2045 // copy of the original code, the executing code and initial fixed array for
2046 // active break points. 2046 // active break points.
2047 Handle<DebugInfo> debug_info = 2047 Handle<DebugInfo> debug_info =
2048 Handle<DebugInfo>::cast(NewStruct(DEBUG_INFO_TYPE)); 2048 Handle<DebugInfo>::cast(NewStruct(DEBUG_INFO_TYPE));
2049 debug_info->set_shared(*shared); 2049 debug_info->set_shared(*shared);
2050 debug_info->set_original_code(*original_code); 2050 debug_info->set_original_code(*original_code);
2051 debug_info->set_code(*code); 2051 debug_info->set_code(*code);
2052 debug_info->set_break_points(*break_points); 2052 debug_info->set_break_points(*break_points);
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
2331 return Handle<Object>::null(); 2331 return Handle<Object>::null();
2332 } 2332 }
2333 2333
2334 2334
2335 Handle<Object> Factory::ToBoolean(bool value) { 2335 Handle<Object> Factory::ToBoolean(bool value) {
2336 return value ? true_value() : false_value(); 2336 return value ? true_value() : false_value();
2337 } 2337 }
2338 2338
2339 2339
2340 } } // namespace v8::internal 2340 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/execution.cc ('k') | src/liveedit.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698