OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 "src/debug/debug.h" | 5 #include "src/debug/debug.h" |
6 | 6 |
7 #include "src/api.h" | 7 #include "src/api.h" |
8 #include "src/arguments.h" | 8 #include "src/arguments.h" |
9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
(...skipping 1475 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1486 // Ensures the debug information is present for shared. | 1486 // Ensures the debug information is present for shared. |
1487 bool Debug::EnsureDebugInfo(Handle<SharedFunctionInfo> shared, | 1487 bool Debug::EnsureDebugInfo(Handle<SharedFunctionInfo> shared, |
1488 Handle<JSFunction> function) { | 1488 Handle<JSFunction> function) { |
1489 if (!shared->IsSubjectToDebugging()) return false; | 1489 if (!shared->IsSubjectToDebugging()) return false; |
1490 | 1490 |
1491 // Return if we already have the debug info for shared. | 1491 // Return if we already have the debug info for shared. |
1492 if (shared->HasDebugInfo()) return true; | 1492 if (shared->HasDebugInfo()) return true; |
1493 | 1493 |
1494 if (function.is_null()) { | 1494 if (function.is_null()) { |
1495 DCHECK(shared->HasDebugCode()); | 1495 DCHECK(shared->HasDebugCode()); |
1496 } else if (!Compiler::EnsureCompiled(function, CLEAR_EXCEPTION)) { | 1496 } else if (!Compiler::Compile(function, CLEAR_EXCEPTION)) { |
1497 return false; | 1497 return false; |
1498 } | 1498 } |
1499 | 1499 |
1500 if (!PrepareFunctionForBreakPoints(shared)) return false; | 1500 if (!PrepareFunctionForBreakPoints(shared)) return false; |
1501 | 1501 |
1502 // Make sure IC state is clean. This is so that we correctly flood | 1502 // Make sure IC state is clean. This is so that we correctly flood |
1503 // accessor pairs when stepping in. | 1503 // accessor pairs when stepping in. |
1504 shared->code()->ClearInlineCaches(); | 1504 shared->code()->ClearInlineCaches(); |
1505 shared->feedback_vector()->ClearICSlots(*shared); | 1505 shared->feedback_vector()->ClearICSlots(*shared); |
1506 | 1506 |
(...skipping 1106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2613 } | 2613 } |
2614 | 2614 |
2615 | 2615 |
2616 void LockingCommandMessageQueue::Clear() { | 2616 void LockingCommandMessageQueue::Clear() { |
2617 base::LockGuard<base::Mutex> lock_guard(&mutex_); | 2617 base::LockGuard<base::Mutex> lock_guard(&mutex_); |
2618 queue_.Clear(); | 2618 queue_.Clear(); |
2619 } | 2619 } |
2620 | 2620 |
2621 } // namespace internal | 2621 } // namespace internal |
2622 } // namespace v8 | 2622 } // namespace v8 |
OLD | NEW |