44 #ifdef ENABLE_DEBUGGER_SUPPORT
45 #include "../include/v8-debug.h"
69 enum ExceptionBreakType {
71 BreakUncaughtException = 1
76 enum BreakLocatorType {
77 ALL_BREAK_LOCATIONS = 0,
78 SOURCE_BREAK_LOCATIONS = 1
84 enum BreakPositionAlignment {
85 STATEMENT_ALIGNED = 0,
86 BREAK_POSITION_ALIGNED = 1
92 class BreakLocationIterator {
94 explicit BreakLocationIterator(Handle<DebugInfo> debug_info,
95 BreakLocatorType type);
96 virtual ~BreakLocationIterator();
100 void FindBreakLocationFromAddress(
Address pc);
101 void FindBreakLocationFromPosition(
int position,
102 BreakPositionAlignment alignment);
105 void SetBreakPoint(Handle<Object> break_point_object);
106 void ClearBreakPoint(Handle<Object> break_point_object);
109 bool IsStepInLocation(Isolate* isolate);
110 void PrepareStepIn(Isolate* isolate);
112 bool HasBreakPoint();
114 Object* BreakPointObjects();
115 void ClearAllDebugBreak();
118 inline int code_position() {
119 return static_cast<int>(
pc() - debug_info_->
code()->entry());
121 inline int break_point() {
return break_point_; }
122 inline int position() {
return position_; }
123 inline int statement_position() {
return statement_position_; }
124 inline Address pc() {
return reloc_iterator_->rinfo()->pc(); }
125 inline Code*
code() {
return debug_info_->code(); }
126 inline RelocInfo* rinfo() {
return reloc_iterator_->rinfo(); }
127 inline RelocInfo::Mode rmode()
const {
128 return reloc_iterator_->rinfo()->rmode();
130 inline RelocInfo* original_rinfo() {
131 return reloc_iterator_original_->rinfo();
133 inline RelocInfo::Mode original_rmode()
const {
134 return reloc_iterator_original_->rinfo()->rmode();
137 bool IsDebuggerStatement();
140 bool RinfoDone()
const;
143 BreakLocatorType type_;
146 int statement_position_;
147 Handle<DebugInfo> debug_info_;
148 RelocIterator* reloc_iterator_;
149 RelocIterator* reloc_iterator_original_;
152 void SetDebugBreak();
153 void ClearDebugBreak();
155 void SetDebugBreakAtIC();
156 void ClearDebugBreakAtIC();
158 bool IsDebugBreakAtReturn();
159 void SetDebugBreakAtReturn();
160 void ClearDebugBreakAtReturn();
162 bool IsDebugBreakSlot();
163 bool IsDebugBreakAtSlot();
164 void SetDebugBreakAtSlot();
165 void ClearDebugBreakAtSlot();
175 class ScriptCache :
private HashMap {
177 explicit ScriptCache(Isolate* isolate)
178 :
HashMap(ScriptMatch), isolate_(isolate), collected_scripts_(10) {}
179 virtual ~ScriptCache() { Clear(); }
182 void Add(Handle<Script> script);
185 Handle<FixedArray> GetScripts();
188 void ProcessCollectedScripts();
192 static uint32_t Hash(
int key) {
197 static bool ScriptMatch(
void* key1,
void* key2) {
return key1 == key2; }
203 static void HandleWeakScript(
208 List<int> collected_scripts_;
214 class DebugInfoListNode {
216 explicit DebugInfoListNode(DebugInfo* debug_info);
217 virtual ~DebugInfoListNode();
219 DebugInfoListNode* next() {
return next_; }
220 void set_next(DebugInfoListNode* next) { next_ = next; }
221 Handle<DebugInfo> debug_info() {
return debug_info_; }
225 Handle<DebugInfo> debug_info_;
228 DebugInfoListNode* next_;
240 void SetUp(
bool create_heap_objects);
243 bool IsLoaded() {
return !debug_context_.is_null(); }
244 bool InDebugger() {
return thread_local_.debugger_entry_ !=
NULL; }
245 void PreemptionWhileInDebugger();
246 void Iterate(ObjectVisitor* v);
249 void SetBreakPoint(Handle<JSFunction>
function,
250 Handle<Object> break_point_object,
251 int* source_position);
252 bool SetBreakPointForScript(Handle<Script> script,
253 Handle<Object> break_point_object,
254 int* source_position,
255 BreakPositionAlignment alignment);
256 void ClearBreakPoint(Handle<Object> break_point_object);
257 void ClearAllBreakPoints();
258 void FloodWithOneShot(Handle<JSFunction>
function);
259 void FloodBoundFunctionWithOneShot(Handle<JSFunction>
function);
260 void FloodHandlerWithOneShot();
261 void ChangeBreakOnException(ExceptionBreakType type,
bool enable);
262 bool IsBreakOnException(ExceptionBreakType type);
263 void PrepareStep(StepAction step_action,
265 StackFrame::Id frame_id);
266 void ClearStepping();
268 bool IsStepping() {
return thread_local_.step_count_ > 0; }
269 bool StepNextContinue(BreakLocationIterator* break_location_iterator,
270 JavaScriptFrame* frame);
271 static Handle<DebugInfo> GetDebugInfo(Handle<SharedFunctionInfo> shared);
272 static bool HasDebugInfo(Handle<SharedFunctionInfo> shared);
274 void PrepareForBreakPoints();
277 Object* FindSharedFunctionInfoInScript(Handle<Script> script,
int position);
282 bool EnsureDebugInfo(Handle<SharedFunctionInfo> shared,
283 Handle<JSFunction>
function);
286 static bool IsDebugBreak(
Address addr);
289 static bool IsDebugBreakAtReturn(RelocInfo* rinfo);
293 static bool IsSourceBreakStub(Code*
code);
294 static bool IsBreakStub(Code*
code);
297 static Handle<Code> FindDebugBreak(Handle<Code>
code, RelocInfo::Mode
mode);
299 static Handle<Object> GetSourceBreakLocations(
300 Handle<SharedFunctionInfo> shared,
301 BreakPositionAlignment position_aligment);
304 inline Handle<Context> debug_context() {
return debug_context_; }
307 bool IsDebugGlobal(GlobalObject* global);
310 bool IsBreakAtReturn(JavaScriptFrame* frame);
313 inline bool has_break_points() {
return has_break_points_; }
315 void NewBreak(StackFrame::Id break_frame_id);
316 void SetBreak(StackFrame::Id break_frame_id,
int break_id);
317 StackFrame::Id break_frame_id() {
318 return thread_local_.break_frame_id_;
320 int break_id() {
return thread_local_.break_id_; }
322 bool StepInActive() {
return thread_local_.step_into_fp_ != 0; }
323 void HandleStepIn(Handle<JSFunction>
function,
324 Handle<Object> holder,
326 bool is_constructor);
327 Address step_in_fp() {
return thread_local_.step_into_fp_; }
328 Address* step_in_fp_addr() {
return &thread_local_.step_into_fp_; }
330 bool StepOutActive() {
return thread_local_.step_out_fp_ != 0; }
331 Address step_out_fp() {
return thread_local_.step_out_fp_; }
333 EnterDebugger* debugger_entry() {
334 return thread_local_.debugger_entry_;
336 void set_debugger_entry(EnterDebugger* entry) {
337 thread_local_.debugger_entry_ = entry;
342 return (thread_local_.pending_interrupts_ & what) != 0;
347 thread_local_.pending_interrupts_ |= what;
352 thread_local_.pending_interrupts_ &= ~static_cast<
int>(what);
356 bool disable_break() {
return disable_break_; }
357 void set_disable_break(
bool disable_break) {
358 disable_break_ = disable_break;
362 bool break_on_exception() {
return break_on_exception_; }
363 bool break_on_uncaught_exception() {
364 return break_on_uncaught_exception_;
368 k_after_break_target_address,
369 k_debug_break_return_address,
370 k_debug_break_slot_address,
371 k_restarter_frame_function_pointer
375 Address* after_break_target_address() {
376 return reinterpret_cast<Address*
>(&thread_local_.after_break_target_);
378 Address* restarter_frame_function_pointer_address() {
379 Object*** address = &thread_local_.restarter_frame_function_pointer_;
380 return reinterpret_cast<Address*
>(address);
384 Object** register_address(
int r) {
385 return ®isters_[r];
389 Code* debug_break_return() {
return debug_break_return_; }
390 Code** debug_break_return_address() {
391 return &debug_break_return_;
395 Code* debug_break_slot() {
return debug_break_slot_; }
396 Code** debug_break_slot_address() {
397 return &debug_break_slot_;
400 static const int kEstimatedNofDebugInfoEntries = 16;
401 static const int kEstimatedNofBreakPointsInFunction = 16;
404 static void HandleWeakDebugInfo(
407 friend class Debugger;
408 friend Handle<FixedArray> GetDebuggedFunctions();
409 friend void CheckDebuggerUnloaded(
bool check_functions);
412 char* ArchiveDebug(
char* to);
413 char* RestoreDebug(
char* from);
414 static int ArchiveSpacePerThread();
415 void FreeThreadResources() { }
418 void ClearMirrorCache();
421 void CreateScriptCache();
422 void DestroyScriptCache();
423 void AddScriptToScriptCache(Handle<Script> script);
424 Handle<FixedArray> GetLoadedScripts();
427 static void RecordEvalCaller(Handle<Script> script);
430 void AfterGarbageCollection();
433 static void GenerateSlot(MacroAssembler* masm);
434 static void GenerateLoadICDebugBreak(MacroAssembler* masm);
435 static void GenerateStoreICDebugBreak(MacroAssembler* masm);
436 static void GenerateKeyedLoadICDebugBreak(MacroAssembler* masm);
437 static void GenerateKeyedStoreICDebugBreak(MacroAssembler* masm);
438 static void GenerateCompareNilICDebugBreak(MacroAssembler* masm);
439 static void GenerateReturnDebugBreak(MacroAssembler* masm);
440 static void GenerateCallFunctionStubDebugBreak(MacroAssembler* masm);
441 static void GenerateCallFunctionStubRecordDebugBreak(MacroAssembler* masm);
442 static void GenerateCallConstructStubDebugBreak(MacroAssembler* masm);
443 static void GenerateCallConstructStubRecordDebugBreak(MacroAssembler* masm);
444 static void GenerateSlotDebugBreak(MacroAssembler* masm);
445 static void GeneratePlainReturnLiveEdit(MacroAssembler* masm);
451 static void GenerateFrameDropperLiveEdit(MacroAssembler* masm);
454 static void GenerateCallICDebugBreak(MacroAssembler* masm);
461 FRAME_DROPPED_IN_IC_CALL,
464 FRAME_DROPPED_IN_DEBUG_SLOT_CALL,
467 FRAME_DROPPED_IN_DIRECT_CALL,
468 FRAME_DROPPED_IN_RETURN_CALL,
472 void FramesHaveBeenDropped(StackFrame::Id new_break_frame_id,
474 Object** restarter_frame_function_pointer);
487 static const int kFrameDropperFrameSize;
490 static const bool kFrameDropperSupported;
519 class FramePaddingLayout :
public AllStatic {
522 static const bool kIsSupported;
526 static const int kFrameBaseSize = 4;
530 static const int kInitialSize;
533 static const int kPaddingValue;
537 explicit Debug(Isolate* isolate);
540 static bool CompileDebuggerScript(Isolate* isolate,
int index);
545 void ClearStepNext();
547 void RemoveDebugInfo(Handle<DebugInfo> debug_info);
548 void SetAfterBreakTarget(JavaScriptFrame* frame);
549 Handle<Object> CheckBreakPoints(Handle<Object> break_point);
550 bool CheckBreakPoint(Handle<Object> break_point_object);
554 Handle<Context> debug_context_;
557 bool has_break_points_;
560 ScriptCache* script_cache_;
563 DebugInfoListNode* debug_info_list_;
566 bool break_on_exception_;
567 bool break_on_uncaught_exception_;
579 StackFrame::Id break_frame_id_;
582 StepAction last_step_action_;
585 int last_statement_position_;
594 int queued_step_count_;
608 FrameDropMode frame_drop_mode_;
611 EnterDebugger* debugger_entry_;
614 int pending_interrupts_;
619 Object** restarter_frame_function_pointer_;
624 ThreadLocal thread_local_;
628 Code* debug_break_return_;
631 Code* debug_break_slot_;
635 friend class Isolate;
651 Handle<JSObject> exec_state,
652 Handle<JSObject> event_data);
655 static MessageImpl NewResponse(
DebugEvent event,
657 Handle<JSObject> exec_state,
658 Handle<JSObject> event_data,
659 Handle<String> response_json,
663 virtual bool IsEvent()
const;
664 virtual bool IsResponse()
const;
666 virtual bool WillStartRunning()
const;
675 MessageImpl(
bool is_event,
678 Handle<JSObject> exec_state,
679 Handle<JSObject> event_data,
680 Handle<String> response_json,
686 Handle<JSObject> exec_state_;
687 Handle<JSObject> event_data_;
688 Handle<String> response_json_;
697 Handle<JSObject> exec_state,
698 Handle<JSObject> event_data,
699 Handle<Object> callback_data,
709 Handle<JSObject> exec_state_;
710 Handle<JSObject> event_data_;
711 Handle<Object> callback_data_;
721 class CommandMessage {
723 static CommandMessage New(
const Vector<uint16_t>& command,
730 Vector<uint16_t> text()
const {
return text_; }
733 CommandMessage(
const Vector<uint16_t>& text,
736 Vector<uint16_t> text_;
744 explicit CommandMessageQueue(
int size);
745 ~CommandMessageQueue();
746 bool IsEmpty()
const {
return start_ ==
end_; }
747 CommandMessage Get();
748 void Put(
const CommandMessage&
message);
749 void Clear() { start_ =
end_ = 0; }
754 CommandMessage* messages_;
761 class MessageDispatchHelperThread;
770 LockingCommandMessageQueue(Logger* logger,
int size);
771 bool IsEmpty()
const;
772 CommandMessage Get();
773 void Put(
const CommandMessage&
message);
777 CommandMessageQueue queue_;
778 mutable Mutex mutex_;
787 void DebugRequest(
const uint16_t* json_request,
int length);
789 Handle<Object> MakeJSObject(Vector<const char> constructor_name,
791 Handle<Object> argv[],
792 bool* caught_exception);
793 Handle<Object> MakeExecutionState(
bool* caught_exception);
794 Handle<Object> MakeBreakEvent(Handle<Object> exec_state,
795 Handle<Object> break_points_hit,
796 bool* caught_exception);
797 Handle<Object> MakeExceptionEvent(Handle<Object> exec_state,
798 Handle<Object> exception,
800 bool* caught_exception);
801 Handle<Object> MakeNewFunctionEvent(Handle<Object> func,
802 bool* caught_exception);
803 Handle<Object> MakeCompileEvent(Handle<Script> script,
805 bool* caught_exception);
806 Handle<Object> MakeScriptCollectedEvent(
int id,
807 bool* caught_exception);
808 void OnDebugBreak(Handle<Object> break_points_hit,
bool auto_continue);
809 void OnException(Handle<Object> exception,
bool uncaught);
810 void OnBeforeCompile(Handle<Script> script);
812 enum AfterCompileFlags {
813 NO_AFTER_COMPILE_FLAGS,
816 void OnAfterCompile(Handle<Script> script,
817 AfterCompileFlags after_compile_flags);
818 void OnScriptCollected(
int id);
820 Handle<JSObject> event_data,
823 Handle<JSObject> exec_state,
824 Handle<JSObject> event_data,
826 void SetEventListener(Handle<Object> callback, Handle<Object> data);
830 void SetDebugMessageDispatchHandler(
832 bool provide_locker);
835 void InvokeMessageHandler(MessageImpl
message);
838 void ProcessCommand(Vector<const uint16_t> command,
847 Handle<Object> Call(Handle<JSFunction> fun,
849 bool* pending_exception);
852 bool StartAgent(
const char*
name,
int port,
853 bool wait_for_connection =
false);
861 void CallMessageDispatchHandler();
863 Handle<Context> GetDebugContext();
867 void UnloadDebugger();
868 friend void ForceUnloadDebugger();
871 LockGuard<RecursiveMutex> lock_guard(debugger_access_);
874 if (debugger_unload_pending_) {
875 if (isolate_->debug()->debugger_entry() ==
NULL) {
881 !FLAG_debug_compile_events) {
885 !FLAG_debug_script_collected_events) {
890 return !compiling_natives_ && Debugger::IsDebuggerActive();
893 void set_compiling_natives(
bool compiling_natives) {
894 compiling_natives_ = compiling_natives;
896 bool compiling_natives()
const {
return compiling_natives_; }
897 void set_loading_debugger(
bool v) { is_loading_debugger_ = v; }
898 bool is_loading_debugger()
const {
return is_loading_debugger_; }
899 void set_live_edit_enabled(
bool v) { live_edit_enabled_ = v; }
900 bool live_edit_enabled()
const {
901 return FLAG_enable_liveedit && live_edit_enabled_ ;
903 void set_force_debugger_active(
bool force_debugger_active) {
904 force_debugger_active_ = force_debugger_active;
906 bool force_debugger_active()
const {
return force_debugger_active_; }
908 bool IsDebuggerActive();
911 explicit Debugger(Isolate* isolate);
914 Handle<Object> exec_state,
915 Handle<Object> event_data,
918 Handle<Object> exec_state,
919 Handle<Object> event_data,
922 Handle<Object> exec_state,
923 Handle<Object> event_data);
924 void ListenersChanged();
926 RecursiveMutex* debugger_access_;
927 Handle<Object> event_listener_;
928 Handle<Object> event_listener_data_;
929 bool compiling_natives_;
930 bool is_loading_debugger_;
931 bool live_edit_enabled_;
932 bool never_unload_debugger_;
933 bool force_debugger_active_;
935 bool debugger_unload_pending_;
937 Mutex dispatch_handler_access_;
939 MessageDispatchHelperThread* message_dispatch_helper_thread_;
940 TimeDelta host_dispatch_period_;
942 DebuggerAgent* agent_;
944 static const int kQueueInitialSize = 4;
945 LockingCommandMessageQueue command_queue_;
946 Semaphore command_received_;
947 LockingCommandMessageQueue event_command_queue_;
951 friend class EnterDebugger;
952 friend class Isolate;
964 explicit EnterDebugger(Isolate* isolate);
968 inline bool FailedToEnter() {
return load_failed_; }
971 inline bool HasJavaScriptFrames() {
return has_js_frames_; }
974 inline Handle<Context> GetContext() {
return save_.context(); }
978 EnterDebugger* prev_;
979 JavaScriptFrameIterator it_;
980 const bool has_js_frames_;
981 StackFrame::Id break_frame_id_;
991 explicit DisableBreak(Isolate* isolate,
bool disable_break)
992 : isolate_(isolate) {
993 prev_disable_break_ = isolate_->debug()->disable_break();
994 isolate_->debug()->set_disable_break(disable_break);
997 isolate_->debug()->set_disable_break(prev_disable_break_);
1004 bool prev_disable_break_;
1010 class Debug_Address {
1012 explicit Debug_Address(Debug::AddressId
id) : id_(id) { }
1014 static Debug_Address AfterBreakTarget() {
1015 return Debug_Address(Debug::k_after_break_target_address);
1018 static Debug_Address DebugBreakReturn() {
1019 return Debug_Address(Debug::k_debug_break_return_address);
1022 static Debug_Address RestarterFrameFunctionPointer() {
1023 return Debug_Address(Debug::k_restarter_frame_function_pointer);
1026 Address address(Isolate* isolate)
const {
1027 Debug* debug = isolate->debug();
1029 case Debug::k_after_break_target_address:
1030 return reinterpret_cast<Address>(debug->after_break_target_address());
1031 case Debug::k_debug_break_return_address:
1032 return reinterpret_cast<Address>(debug->debug_break_return_address());
1033 case Debug::k_debug_break_slot_address:
1034 return reinterpret_cast<Address>(debug->debug_break_slot_address());
1035 case Debug::k_restarter_frame_function_pointer:
1036 return reinterpret_cast<Address>(
1037 debug->restarter_frame_function_pointer_address());
1045 Debug::AddressId id_;
1052 class MessageDispatchHelperThread:
public Thread {
1054 explicit MessageDispatchHelperThread(Isolate* isolate);
1055 ~MessageDispatchHelperThread() {}
1065 bool already_signalled_;
1073 #endif // ENABLE_DEBUGGER_SUPPORT
1075 #endif // V8_DEBUG_H_
enable upcoming ES6 features enable harmony block scoping enable harmony enable harmony proxies enable harmony generators enable harmony numeric enable harmony string enable harmony math functions harmony_scoping harmony_symbols harmony_collections harmony_iteration harmony_strings harmony_scoping harmony_maths tracks arrays with only smi values Optimize object Array DOM strings and string pretenure call new trace pretenuring decisions of HAllocate instructions track fields with only smi values track fields with heap values track_fields track_fields Enables optimizations which favor memory size over execution speed use string slices optimization filter maximum number of GVN fix point iterations use function inlining use allocation folding eliminate write barriers targeting allocations in optimized code maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining crankshaft harvests type feedback from stub cache trace check elimination phase hydrogen tracing filter NULL
kSerializedDataOffset Object
enable upcoming ES6 features enable harmony block scoping enable harmony enable harmony proxies enable harmony generators enable harmony numeric enable harmony string enable harmony math functions harmony_scoping harmony_symbols harmony_collections harmony_iteration harmony_strings harmony_scoping harmony_maths tracks arrays with only smi values Optimize object Array DOM strings and string pretenure call new trace pretenuring decisions of HAllocate instructions track fields with only smi values track fields with heap values track_fields track_fields Enables optimizations which favor memory size over execution speed use string slices optimization filter maximum number of GVN fix point iterations use function inlining use allocation folding eliminate write barriers targeting allocations in optimized code maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining crankshaft harvests type feedback from stub cache trace check elimination phase hydrogen tracing filter trace hydrogen to given file name trace inlining decisions trace store elimination trace all use positions trace global value numbering trace hydrogen escape analysis trace the tracking of allocation sites trace map generalization environment for every instruction deoptimize every n garbage collections put a break point before deoptimizing deoptimize uncommon cases use on stack replacement trace array bounds check elimination perform array index dehoisting use load elimination use store elimination use constant folding eliminate unreachable code number of stress runs when picking a function to watch for shared function not JSFunction itself flushes the cache of optimized code for closures on every GC functions with arguments object maximum number of escape analysis fix point iterations allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms concurrent on stack replacement do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes number of stack frames inspected by the profiler percentage of ICs that must have type info to allow optimization extra verbose compilation tracing generate extra emit comments in code disassembly enable use of SSE3 instructions if available enable use of CMOV instruction if available enable use of VFP3 instructions if available enable use of NEON instructions if enable use of SDIV and UDIV instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of d16 d31 registers on ARM this requires VFP3 force all emitted branches to be in long expose natives in global object expose freeBuffer extension expose gc extension under the specified name expose externalize string extension number of stack frames to capture disable builtin natives files print name of functions for which code is generated use random jit cookie to mask large constants trace lazy optimization use adaptive optimizations always try to OSR functions trace optimize function deoptimization minimum length for automatic enable preparsing maximum number of optimization attempts before giving up cache prototype transitions trace debugging JSON request response trace out of bounds accesses to external arrays trace_js_array_abuse automatically set the debug break flag when debugger commands are in the queue abort by crashing maximum length of function source code printed in a stack trace max size of the new max size of the old max size of executable always perform global GCs print one trace line following each garbage collection do not print trace line after scavenger collection print statistics of the maximum memory committed for the heap in only print modified registers Don t break for ASM_UNIMPLEMENTED_BREAK macros print stack trace when an illegal exception is thrown randomize hashes to avoid predictable hash Fixed seed to use to hash property Print the time it takes to deserialize the snapshot testing_bool_flag testing_int_flag string flag tmp file in which to serialize heap Print the time it takes to lazily compile hydrogen code stubs concurrent_recompilation concurrent_sweeping Print usage message
void(* DebugMessageDispatchHandler)()
void(* MessageHandler2)(const Message &message)
HANDLE HANDLE LPSTACKFRAME64 StackFrame
enable upcoming ES6 features enable harmony block scoping enable harmony enable harmony proxies enable harmony generators enable harmony numeric enable harmony string enable harmony math functions harmony_scoping harmony_symbols harmony_collections harmony_iteration harmony_strings harmony_scoping harmony_maths tracks arrays with only smi values Optimize object Array DOM strings and string pretenure call new trace pretenuring decisions of HAllocate instructions track fields with only smi values track fields with heap values track_fields track_fields Enables optimizations which favor memory size over execution speed use string slices optimization filter maximum number of GVN fix point iterations use function inlining use allocation folding eliminate write barriers targeting allocations in optimized code maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining crankshaft harvests type feedback from stub cache trace check elimination phase hydrogen tracing filter trace hydrogen to given file name trace inlining decisions trace store elimination trace all use positions trace global value numbering trace hydrogen escape analysis trace the tracking of allocation sites trace map generalization environment for every instruction deoptimize every n garbage collections put a break point before deoptimizing deoptimize uncommon cases use on stack replacement trace array bounds check elimination perform array index dehoisting use load elimination use store elimination use constant folding eliminate unreachable code number of stress runs when picking a function to watch for shared function not JSFunction itself flushes the cache of optimized code for closures on every GC functions with arguments object maximum number of escape analysis fix point iterations allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms concurrent on stack replacement do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes number of stack frames inspected by the profiler percentage of ICs that must have type info to allow optimization extra verbose compilation tracing generate extra emit comments in code disassembly enable use of SSE3 instructions if available enable use of CMOV instruction if available enable use of VFP3 instructions if available enable use of NEON instructions if enable use of SDIV and UDIV instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of d16 d31 registers on ARM this requires VFP3 force all emitted branches to be in long mode(MIPS only)") DEFINE_string(expose_natives_as
enable upcoming ES6 features enable harmony block scoping enable harmony enable harmony proxies enable harmony generators enable harmony numeric enable harmony string enable harmony math functions harmony_scoping harmony_symbols harmony_collections harmony_iteration harmony_strings harmony_scoping harmony_maths tracks arrays with only smi values Optimize object size
enable upcoming ES6 features enable harmony block scoping enable harmony enable harmony proxies enable harmony generators enable harmony numeric enable harmony string enable harmony math functions harmony_scoping harmony_symbols harmony_collections harmony_iteration harmony_strings harmony_scoping harmony_maths tracks arrays with only smi values Optimize object Array DOM strings and string pretenure call new trace pretenuring decisions of HAllocate instructions track fields with only smi values track fields with heap values track_fields track_fields Enables optimizations which favor memory size over execution speed use string slices optimization filter maximum number of GVN fix point iterations use function inlining use allocation folding eliminate write barriers targeting allocations in optimized code maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining crankshaft harvests type feedback from stub cache trace check elimination phase hydrogen tracing filter trace hydrogen to given file name trace inlining decisions trace store elimination trace all use positions trace global value numbering trace hydrogen escape analysis trace the tracking of allocation sites trace map generalization environment for every instruction deoptimize every n garbage collections put a break point before deoptimizing deoptimize uncommon cases use on stack replacement trace array bounds check elimination perform array index dehoisting use load elimination use store elimination use constant folding eliminate unreachable code number of stress runs when picking a function to watch for shared function not JSFunction itself flushes the cache of optimized code for closures on every GC functions with arguments object maximum number of escape analysis fix point iterations allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms concurrent on stack replacement do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes number of stack frames inspected by the profiler percentage of ICs that must have type info to allow optimization extra verbose compilation tracing generate extra code(assertions) for debugging") DEFINE_bool(code_comments
#define DISALLOW_COPY_AND_ASSIGN(TypeName)
void Load(const v8::FunctionCallbackInfo< v8::Value > &args)
void(* HostDispatchHandler)()
uint32_t ComputeIntegerHash(uint32_t key, uint32_t seed)
Object * JSCallerSavedBuffer[kNumJSCallerSaved]
DECLARE_RUNTIME_FUNCTION(MaybeObject *, KeyedLoadIC_MissFromStubFailure)
TemplateHashMapImpl< FreeStoreAllocationPolicy > HashMap
enable upcoming ES6 features enable harmony block scoping enable harmony enable harmony proxies enable harmony generators enable harmony numeric enable harmony string enable harmony math functions harmony_scoping harmony_symbols harmony_collections harmony_iteration harmony_strings harmony_scoping harmony_maths tracks arrays with only smi values Optimize object Array DOM strings and string pretenure call new trace pretenuring decisions of HAllocate instructions track fields with only smi values track fields with heap values track_fields track_fields Enables optimizations which favor memory size over execution speed use string slices optimization filter maximum number of GVN fix point iterations use function inlining use allocation folding eliminate write barriers targeting allocations in optimized code maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining crankshaft harvests type feedback from stub cache trace check elimination phase hydrogen tracing filter trace hydrogen to given file name trace inlining decisions trace store elimination trace all use positions trace global value numbering trace hydrogen escape analysis trace the tracking of allocation sites trace map generalization environment for every instruction deoptimize every n garbage collections put a break point before deoptimizing deoptimize uncommon cases use on stack replacement trace array bounds check elimination perform array index dehoisting use load elimination use store elimination use constant folding eliminate unreachable code number of stress runs when picking a function to watch for shared function not JSFunction itself flushes the cache of optimized code for closures on every GC functions with arguments object maximum number of escape analysis fix point iterations allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms concurrent on stack replacement do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes number of stack frames inspected by the profiler percentage of ICs that must have type info to allow optimization extra verbose compilation tracing generate extra emit comments in code disassembly enable use of SSE3 instructions if available enable use of CMOV instruction if available enable use of VFP3 instructions if available enable use of NEON instructions if enable use of SDIV and UDIV instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of d16 d31 registers on ARM this requires VFP3 force all emitted branches to be in long expose natives in global object expose freeBuffer extension expose gc extension under the specified name expose externalize string extension number of stack frames to capture disable builtin natives files print name of functions for which code is generated use random jit cookie to mask large constants trace lazy optimization use adaptive optimizations always try to OSR functions trace optimize function deoptimization minimum length for automatic enable preparsing maximum number of optimization attempts before giving up cache prototype transitions trace debugging JSON request response trace out of bounds accesses to external arrays trace_js_array_abuse automatically set the debug break flag when debugger commands are in the queue abort by crashing maximum length of function source code printed in a stack trace max size of the new max size of the old max size of executable always perform global GCs print one trace line following each garbage collection do not print trace line after scavenger collection print statistics of the maximum memory committed for the heap in name