Revision: 23803
Author: [email protected]
Date: Tue Sep 9 12:58:34 2014 UTC
Log: Handle non-object constants in
HConstant::GetMonomorphicJSObjectMap.
[email protected]
BUG=chromium:412162
LOG=N
Review URL: https://codereview.chromium.org/552243002
https://code.google.com/p/v8/source/detail?r=23803
Added:
/branches/bleeding_edge/test/mjsunit/regress/regress-412162.js
Modified:
/branches/bleeding_edge/src/hydrogen-instructions.h
=======================================
--- /dev/null
+++ /branches/bleeding_edge/test/mjsunit/regress/regress-412162.js Tue Sep
9 12:58:34 2014 UTC
@@ -0,0 +1,14 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function test() {
+ Math.abs(-NaN).toString();
+}
+
+test();
+test();
+%OptimizeFunctionOnNextCall(test);
+test();
=======================================
--- /branches/bleeding_edge/src/hydrogen-instructions.h Mon Sep 8 12:51:29
2014 UTC
+++ /branches/bleeding_edge/src/hydrogen-instructions.h Tue Sep 9 12:58:34
2014 UTC
@@ -3493,7 +3493,7 @@
virtual Handle<Map> GetMonomorphicJSObjectMap() OVERRIDE {
Handle<Object> object = object_.handle();
- if (object->IsHeapObject()) {
+ if (!object.is_null() && object->IsHeapObject()) {
return v8::internal::handle(HeapObject::cast(*object)->map());
}
return Handle<Map>();
--
--
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/d/optout.