Index: test/mjsunit/regress/regress-2374.js |
diff --git a/test/mjsunit/deopt-minus-zero.js b/test/mjsunit/regress/regress-2374.js |
similarity index 65% |
copy from test/mjsunit/deopt-minus-zero.js |
copy to test/mjsunit/regress/regress-2374.js |
index ee0983127dc3ae10311cf11a88ba40284e366dfe..b12e5f28c24f0f4e6f382703414976144eb2cb13 100644 |
--- a/test/mjsunit/deopt-minus-zero.js |
+++ b/test/mjsunit/regress/regress-2374.js |
@@ -25,32 +25,9 @@ |
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
-// Flags: --allow-natives-syntax --expose-gc |
+var msg = '{"result":{"profile":{"head":{"functionName":"(root)","url":"","lineNumber":0,"totalTime":495.7243772462511,"selfTime":0,"numberOfCalls":0,"visible":true,"callUID":2771605942,"children":[{"functionName":"(program)","url":"","lineNumber":0,"totalTime":495.7243772462511,"selfTime":495.7243772462511,"numberOfCalls":0,"visible":true,"callUID":1902715303,"children":[]}]},"bottomUpHead":{"functionName":"(root)","url":"","lineNumber":0,"totalTime":495.7243772462511,"selfTime":0,"numberOfCalls":0,"visible":true,"callUID":2771605942,"children":[{"functionName":"(program)","url":"","lineNumber":0,"totalTime":495.7243772462511,"selfTime":495.7243772462511,"numberOfCalls":0,"visible":true,"callUID":1902715303,"children":[]}]}}},"id":41}'; |
-/** |
- * The possible optimization states of a function. Must be in sync with the |
- * return values of Runtime_GetOptimizationStatus() in runtime.cc! |
- */ |
-var OptimizationState = { |
- YES: 1, |
- NO: 2, |
- ALWAYS: 3, |
- NEVER: 4 |
-}; |
- |
-function mul (a, b) { |
- return a * b; |
-} |
- |
-mul(-1, -1); |
-mul(0x80000001|0, -1); |
-mul(0x80000001|0, -1); |
-%OptimizeFunctionOnNextCall(mul); |
-mul(0, -1); |
-%OptimizeFunctionOnNextCall(mul); |
-mul(0, -1); |
- |
-var raw_optimized = %GetOptimizationStatus(mul); |
-assertFalse(raw_optimized == OptimizationState.NO); |
-gc(); |
+var obj = JSON.parse(msg); |
+var obj2 = JSON.parse(msg); |
+assertEquals(JSON.stringify(obj), JSON.stringify(obj2)); |