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

Side by Side Diff: src/debug.cc

Issue 1255803004: Debugger: fix deoptimizing inlined function. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 5 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
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-4320.js » ('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 // 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/v8.h" 5 #include "src/v8.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 1443 matching lines...) Expand 10 before | Expand all | Expand 10 after
1454 HeapObject* obj; 1454 HeapObject* obj;
1455 bool include_generators = shared->is_generator(); 1455 bool include_generators = shared->is_generator();
1456 1456
1457 while ((obj = iterator.next())) { 1457 while ((obj = iterator.next())) {
1458 if (obj->IsJSFunction()) { 1458 if (obj->IsJSFunction()) {
1459 JSFunction* function = JSFunction::cast(obj); 1459 JSFunction* function = JSFunction::cast(obj);
1460 if (!function->Inlines(*shared)) continue; 1460 if (!function->Inlines(*shared)) continue;
1461 if (function->code()->kind() == Code::OPTIMIZED_FUNCTION) { 1461 if (function->code()->kind() == Code::OPTIMIZED_FUNCTION) {
1462 Deoptimizer::DeoptimizeFunction(function); 1462 Deoptimizer::DeoptimizeFunction(function);
1463 } 1463 }
1464 functions.Add(handle(function)); 1464 if (function->shared() == *shared) functions.Add(handle(function));
1465 } else if (include_generators && obj->IsJSGeneratorObject()) { 1465 } else if (include_generators && obj->IsJSGeneratorObject()) {
1466 JSGeneratorObject* generator_obj = JSGeneratorObject::cast(obj); 1466 JSGeneratorObject* generator_obj = JSGeneratorObject::cast(obj);
1467 if (!generator_obj->is_suspended()) continue; 1467 if (!generator_obj->is_suspended()) continue;
1468 JSFunction* function = generator_obj->function(); 1468 JSFunction* function = generator_obj->function();
1469 if (!function->Inlines(*shared)) continue; 1469 if (!function->Inlines(*shared)) continue;
1470 int pc_offset = generator_obj->continuation(); 1470 int pc_offset = generator_obj->continuation();
1471 int index = 1471 int index =
1472 ComputeContinuationIndexFromPcOffset(function->code(), pc_offset); 1472 ComputeContinuationIndexFromPcOffset(function->code(), pc_offset);
1473 generator_obj->set_continuation(index); 1473 generator_obj->set_continuation(index);
1474 suspended_generators.Add(handle(generator_obj)); 1474 suspended_generators.Add(handle(generator_obj));
(...skipping 1350 matching lines...) Expand 10 before | Expand all | Expand 10 after
2825 } 2825 }
2826 2826
2827 2827
2828 void LockingCommandMessageQueue::Clear() { 2828 void LockingCommandMessageQueue::Clear() {
2829 base::LockGuard<base::Mutex> lock_guard(&mutex_); 2829 base::LockGuard<base::Mutex> lock_guard(&mutex_);
2830 queue_.Clear(); 2830 queue_.Clear();
2831 } 2831 }
2832 2832
2833 } // namespace internal 2833 } // namespace internal
2834 } // namespace v8 2834 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-4320.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698