New issue
Advanced search Search tips

Issue 663340 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Dec 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 1
Type: Bug

Blocking:
issue 663324



Sign in to add a comment

Difference between fullcode and ignition_staging_turbo_opt: array shift

Project Member Reported by machenb...@chromium.org, Nov 8 2016

Issue description

# Minimized program:
Array.prototype.__proto__ = {3: ""};
a = new Array(13)
a.shift()
Object.defineProperty(Array.prototype, "1", {});
[{},,0].shift();


# Compared fullcode with ignition_turbo_opt

# Flags of fullcode:
--abort_on_stack_overflow --expose-gc --allow-natives-syntax --invoke-weak-callbacks --omit-quit  --random-seed -856055094 --nocrankshaft --turbo-filter=~
# Flags of ignition_turbo_opt:
--abort_on_stack_overflow --expose-gc --allow-natives-syntax --invoke-weak-callbacks --omit-quit  --random-seed -856055094 --ignition-staging --turbo --always-opt

Difference:
Different total output lines: 0 vs. 7

### Start of configuration fullcode:

### End of configuration fullcode

### Start of configuration ignition_turbo_opt:
out11_ignition_turbo_opt2/fuzz-70987.js.minimized:6: TypeError: Cannot assign to read only property '1' of object '[object Array]'
[{},,0].shift();
        ^
TypeError: Cannot assign to read only property '1' of object '[object Array]'
    at Array.shift (<anonymous>)
    at out11_ignition_turbo_opt2/fuzz-70987.js.minimized:6:9


### End of configuration ignition_turbo_opt

 
Cc: bmeu...@chromium.org jarin@chromium.org
Labels: -Restrict-View-Google
# Similar case between fullcode and default:
Array.prototype[1] = "element 1";

function foo() {
  a = [0,,{}]
  a.shift()
  print(a);
}
foo();
foo();
%OptimizeFunctionOnNextCall(foo);
foo();


# Compared fullcode with default

# Flags of fullcode:
--abort_on_stack_overflow --expose-gc --allow-natives-syntax --invoke-weak-callbacks --omit-quit --es-staging  --random-seed 2093345467 --nocrankshaft --turbo-filter=~
# Flags of default:
--abort_on_stack_overflow --expose-gc --allow-natives-syntax --invoke-weak-callbacks --omit-quit --es-staging  --random-seed 2093345467

Difference:
- element 1,[object Object]
+ ,[object Object]

### Start of configuration fullcode:
element 1,[object Object]
element 1,[object Object]
element 1,[object Object]

### End of configuration fullcode

### Start of configuration default:
element 1,[object Object]
element 1,[object Object]
,[object Object]

### End of configuration default

Owner: ishell@chromium.org
Status: Assigned (was: Untriaged)
Igor, please take a look. ArrayShift inlining seems wrong.
Labels: v8-foozzie-failure

Comment 5 by ishell@chromium.org, Dec 20 2016

Status: Fixed (was: Assigned)
 Issue 679886  has been merged into this issue.

Sign in to add a comment