| OLD | NEW | 
|---|
| 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 12009 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 12020   return isolate->heap()->undefined_value(); | 12020   return isolate->heap()->undefined_value(); | 
| 12021 #endif | 12021 #endif | 
| 12022 } | 12022 } | 
| 12023 | 12023 | 
| 12024 #endif  // ENABLE_DEBUGGER_SUPPORT | 12024 #endif  // ENABLE_DEBUGGER_SUPPORT | 
| 12025 | 12025 | 
| 12026 | 12026 | 
| 12027 #ifdef ENABLE_LOGGING_AND_PROFILING | 12027 #ifdef ENABLE_LOGGING_AND_PROFILING | 
| 12028 RUNTIME_FUNCTION(MaybeObject*, Runtime_ProfilerResume) { | 12028 RUNTIME_FUNCTION(MaybeObject*, Runtime_ProfilerResume) { | 
| 12029   NoHandleAllocation ha; | 12029   NoHandleAllocation ha; | 
| 12030   ASSERT(args.length() == 2); | 12030   v8::V8::ResumeProfiler(); | 
| 12031 |  | 
| 12032   CONVERT_CHECKED(Smi, smi_modules, args[0]); |  | 
| 12033   CONVERT_CHECKED(Smi, smi_tag, args[1]); |  | 
| 12034   v8::V8::ResumeProfilerEx(smi_modules->value(), smi_tag->value()); |  | 
| 12035   return isolate->heap()->undefined_value(); | 12031   return isolate->heap()->undefined_value(); | 
| 12036 } | 12032 } | 
| 12037 | 12033 | 
| 12038 | 12034 | 
| 12039 RUNTIME_FUNCTION(MaybeObject*, Runtime_ProfilerPause) { | 12035 RUNTIME_FUNCTION(MaybeObject*, Runtime_ProfilerPause) { | 
| 12040   NoHandleAllocation ha; | 12036   NoHandleAllocation ha; | 
| 12041   ASSERT(args.length() == 2); | 12037   v8::V8::PauseProfiler(); | 
| 12042 |  | 
| 12043   CONVERT_CHECKED(Smi, smi_modules, args[0]); |  | 
| 12044   CONVERT_CHECKED(Smi, smi_tag, args[1]); |  | 
| 12045   v8::V8::PauseProfilerEx(smi_modules->value(), smi_tag->value()); |  | 
| 12046   return isolate->heap()->undefined_value(); | 12038   return isolate->heap()->undefined_value(); | 
| 12047 } | 12039 } | 
| 12048 | 12040 | 
| 12049 #endif  // ENABLE_LOGGING_AND_PROFILING | 12041 #endif  // ENABLE_LOGGING_AND_PROFILING | 
| 12050 | 12042 | 
| 12051 // Finds the script object from the script data. NOTE: This operation uses | 12043 // Finds the script object from the script data. NOTE: This operation uses | 
| 12052 // heap traversal to find the function generated for the source position | 12044 // heap traversal to find the function generated for the source position | 
| 12053 // for the requested break point. For lazily compiled functions several heap | 12045 // for the requested break point. For lazily compiled functions several heap | 
| 12054 // traversals might be required rendering this operation as a rather slow | 12046 // traversals might be required rendering this operation as a rather slow | 
| 12055 // operation. However for setting break points which is normally done through | 12047 // operation. However for setting break points which is normally done through | 
| (...skipping 421 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 12477   } else { | 12469   } else { | 
| 12478     // Handle last resort GC and make sure to allow future allocations | 12470     // Handle last resort GC and make sure to allow future allocations | 
| 12479     // to grow the heap without causing GCs (if possible). | 12471     // to grow the heap without causing GCs (if possible). | 
| 12480     isolate->counters()->gc_last_resort_from_js()->Increment(); | 12472     isolate->counters()->gc_last_resort_from_js()->Increment(); | 
| 12481     isolate->heap()->CollectAllGarbage(false); | 12473     isolate->heap()->CollectAllGarbage(false); | 
| 12482   } | 12474   } | 
| 12483 } | 12475 } | 
| 12484 | 12476 | 
| 12485 | 12477 | 
| 12486 } }  // namespace v8::internal | 12478 } }  // namespace v8::internal | 
| OLD | NEW | 
|---|