Revision: 15392
Author: [email protected]
Date: Fri Jun 28 08:48:38 2013
Log: Add %_DebugBreakInOptimizedCode() pseudo function call to insert
int3/stop instructions into optimized code
[email protected]
Review URL: https://codereview.chromium.org/17870002
http://code.google.com/p/v8/source/detail?r=15392
Modified:
/branches/bleeding_edge/src/full-codegen.cc
/branches/bleeding_edge/src/hydrogen.cc
/branches/bleeding_edge/src/runtime.h
/branches/bleeding_edge/test/mjsunit/fuzz-natives-part1.js
/branches/bleeding_edge/test/mjsunit/fuzz-natives-part2.js
/branches/bleeding_edge/test/mjsunit/fuzz-natives-part3.js
/branches/bleeding_edge/test/mjsunit/fuzz-natives-part4.js
=======================================
--- /branches/bleeding_edge/src/full-codegen.cc Mon Jun 24 03:37:59 2013
+++ /branches/bleeding_edge/src/full-codegen.cc Fri Jun 28 08:48:38 2013
@@ -938,6 +938,11 @@
ASSERT(args->length() == 2);
EmitGeneratorResume(args->at(0), args->at(1), JSGeneratorObject::THROW);
}
+
+
+void FullCodeGenerator::EmitDebugBreakInOptimizedCode(CallRuntime* expr) {
+ context()->Plug(handle(Smi::FromInt(0), isolate()));
+}
void FullCodeGenerator::VisitBinaryOperation(BinaryOperation* expr) {
=======================================
--- /branches/bleeding_edge/src/hydrogen.cc Fri Jun 28 08:34:48 2013
+++ /branches/bleeding_edge/src/hydrogen.cc Fri Jun 28 08:48:38 2013
@@ -10633,6 +10633,13 @@
void HOptimizedGraphBuilder::GenerateGeneratorThrow(CallRuntime* call) {
return Bailout("inlined runtime function: GeneratorThrow");
}
+
+
+void HOptimizedGraphBuilder::GenerateDebugBreakInOptimizedCode(
+ CallRuntime* call) {
+ AddInstruction(new(zone()) HDebugBreak());
+ return ast_context()->ReturnValue(graph()->GetConstant0());
+}
#undef CHECK_BAILOUT
=======================================
--- /branches/bleeding_edge/src/runtime.h Tue Jun 25 06:42:44 2013
+++ /branches/bleeding_edge/src/runtime.h Fri Jun 28 08:48:38 2013
@@ -597,7 +597,8 @@
F(GetCachedArrayIndex, 1,
1) \
F(FastAsciiArrayJoin, 2,
1) \
F(GeneratorNext, 2,
1) \
- F(GeneratorThrow, 2, 1)
+ F(GeneratorThrow, 2,
1) \
+ F(DebugBreakInOptimizedCode, 0, 1)
//
----------------------------------------------------------------------------
=======================================
--- /branches/bleeding_edge/test/mjsunit/fuzz-natives-part1.js Fri Jun 21
06:02:38 2013
+++ /branches/bleeding_edge/test/mjsunit/fuzz-natives-part1.js Fri Jun 28
08:48:38 2013
@@ -163,6 +163,8 @@
"ResolvePossiblyDirectEval": true,
"Log": true,
"DeclareGlobals": true,
+ "ArrayConstructor": true,
+ "InternalArrayConstructor": true,
"PromoteScheduledException": true,
"DeleteHandleScopeExtensions": true,
@@ -214,7 +216,9 @@
var currentlyUncallable = {
// We need to find a way to test this without breaking the system.
- "SystemBreak": true
+ "SystemBreak": true,
+ // Inserts an int3/stop instruction when run with --always-opt.
+ "_DebugBreakInOptimizedCode": true
};
function testNatives() {
=======================================
--- /branches/bleeding_edge/test/mjsunit/fuzz-natives-part2.js Fri Jun 21
06:02:38 2013
+++ /branches/bleeding_edge/test/mjsunit/fuzz-natives-part2.js Fri Jun 28
08:48:38 2013
@@ -153,6 +153,7 @@
"ParallelRecompile": true,
"InstallRecompiledCode": true,
"NotifyDeoptimized": true,
+ "NotifyStubFailure": true,
"NotifyOSR": true,
"CreateObjectLiteralBoilerplate": true,
"CloneLiteralBoilerplate": true,
@@ -215,7 +216,9 @@
var currentlyUncallable = {
// We need to find a way to test this without breaking the system.
- "SystemBreak": true
+ "SystemBreak": true,
+ // Inserts an int3/stop instruction when run with --always-opt.
+ "_DebugBreakInOptimizedCode": true
};
function testNatives() {
=======================================
--- /branches/bleeding_edge/test/mjsunit/fuzz-natives-part3.js Fri Jun 21
06:02:38 2013
+++ /branches/bleeding_edge/test/mjsunit/fuzz-natives-part3.js Fri Jun 28
08:48:38 2013
@@ -153,6 +153,7 @@
"ParallelRecompile": true,
"InstallRecompiledCode": true,
"NotifyDeoptimized": true,
+ "NotifyStubFailure": true,
"NotifyOSR": true,
"CreateObjectLiteralBoilerplate": true,
"CloneLiteralBoilerplate": true,
@@ -162,6 +163,8 @@
"ResolvePossiblyDirectEval": true,
"Log": true,
"DeclareGlobals": true,
+ "ArrayConstructor": true,
+ "InternalArrayConstructor": true,
"PromoteScheduledException": true,
"DeleteHandleScopeExtensions": true,
@@ -213,7 +216,9 @@
var currentlyUncallable = {
// We need to find a way to test this without breaking the system.
- "SystemBreak": true
+ "SystemBreak": true,
+ // Inserts an int3/stop instruction when run with --always-opt.
+ "_DebugBreakInOptimizedCode": true
};
function testNatives() {
=======================================
--- /branches/bleeding_edge/test/mjsunit/fuzz-natives-part4.js Fri Jun 21
06:02:38 2013
+++ /branches/bleeding_edge/test/mjsunit/fuzz-natives-part4.js Fri Jun 28
08:48:38 2013
@@ -153,6 +153,7 @@
"ParallelRecompile": true,
"InstallRecompiledCode": true,
"NotifyDeoptimized": true,
+ "NotifyStubFailure": true,
"NotifyOSR": true,
"CreateObjectLiteralBoilerplate": true,
"CloneLiteralBoilerplate": true,
@@ -162,6 +163,8 @@
"ResolvePossiblyDirectEval": true,
"Log": true,
"DeclareGlobals": true,
+ "ArrayConstructor": true,
+ "InternalArrayConstructor": true,
"PromoteScheduledException": true,
"DeleteHandleScopeExtensions": true,
@@ -213,7 +216,9 @@
var currentlyUncallable = {
// We need to find a way to test this without breaking the system.
- "SystemBreak": true
+ "SystemBreak": true,
+ // Inserts an int3/stop instruction when run with --always-opt.
+ "_DebugBreakInOptimizedCode": true
};
function testNatives() {
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.