This repository has been archived by the owner on Mar 25, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merged: [turbofan] Fix deopt check for storing into constant field.
Revision: 1900760 BUG=chromium:626986 LOG=N NOTRY=true NOPRESUBMIT=true NOTREECHECKS=true R=bmeurer@chromium.org Review URL: https://codereview.chromium.org/2517543002 . Cr-Commit-Position: refs/branch-heads/5.5@{v8#48} Cr-Branched-From: 3cbd583-refs/heads/5.5.372@{#1} Cr-Branched-From: b3c8b0c-refs/heads/master@{#40015}
- Loading branch information
1 parent
a8eb87a
commit e7cacef
Showing
2 changed files
with
27 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
// Copyright 2016 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 g() { | ||
return 42; | ||
} | ||
|
||
var o = {}; | ||
|
||
function f(o, x) { | ||
o.f = x; | ||
} | ||
|
||
f(o, g); | ||
f(o, g); | ||
f(o, g); | ||
assertEquals(42, o.f()); | ||
%OptimizeFunctionOnNextCall(f); | ||
f(o, function() { return 0; }); | ||
assertEquals(0, o.f()); |