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

Unified Diff: src/hydrogen.cc

Issue 332673002: Introduce intrinsic to expose debug state to generated code. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/debug.h ('k') | src/hydrogen-instructions.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index 3162eb606ad687924ae6bcd9ff04d0a1e9570869..8ec05f56c406e160ee715088c1681fdce3ea6c18 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -11708,11 +11708,13 @@ void HOptimizedGraphBuilder::GenerateDebugBreakInOptimizedCode(
}
-void HOptimizedGraphBuilder::GenerateDebugCallbackSupportsStepping(
- CallRuntime* call) {
- ASSERT(call->arguments()->length() == 1);
- // Debugging is not supported in optimized code.
- return ast_context()->ReturnValue(graph()->GetConstantFalse());
+void HOptimizedGraphBuilder::GenerateDebugIsActive(CallRuntime* call) {
+ ASSERT(call->arguments()->length() == 0);
+ HValue* ref =
+ Add<HConstant>(ExternalReference::debug_is_active_address(isolate()));
+ HValue* value = Add<HLoadNamedField>(
+ ref, static_cast<HValue*>(NULL), HObjectAccess::ForExternalUInteger8());
+ return ast_context()->ReturnValue(value);
}
« no previous file with comments | « src/debug.h ('k') | src/hydrogen-instructions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698