- 24 Mar, 2017 5 commits
-
-
Michael Achenbach authored
This reverts commit 15898daf. Reason for revert: Bunch of custom snapshot check failures: https://build.chromium.org/p/client.v8/builders/V8%20Linux64%20GC%20Stress%20-%20custom%20snapshot/builds/11887 https://build.chromium.org/p/client.v8/builders/V8%20Linux64%20-%20custom%20snapshot%20-%20debug/builds/13603 Original change's description: > [asm.js] Switch test coverage to --fast-validate-asm. > > R=machenbach@chromium.org > BUG=v8:6127 > > Change-Id: I65a6905e57ff47195503b37118c279d22f0baba0 > Reviewed-on: https://chromium-review.googlesource.com/459536 > Commit-Queue: Michael Starzinger <mstarzinger@chromium.org> > Reviewed-by: Michael Achenbach <machenbach@chromium.org> > Cr-Commit-Position: refs/heads/master@{#44099} TBR=bradnelson@chromium.org,machenbach@chromium.org,mstarzinger@chromium.org,v8-reviews@googlegroups.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=v8:6127 Change-Id: Iecbd29d8ee31b49e553048c6f59670167cd22d9d Reviewed-on: https://chromium-review.googlesource.com/459497Reviewed-by:
Michael Achenbach <machenbach@chromium.org> Commit-Queue: Michael Achenbach <machenbach@chromium.org> Cr-Commit-Position: refs/heads/master@{#44103}
-
Michael Starzinger authored
R=machenbach@chromium.org BUG=v8:6127 Change-Id: I65a6905e57ff47195503b37118c279d22f0baba0 Reviewed-on: https://chromium-review.googlesource.com/459536 Commit-Queue: Michael Starzinger <mstarzinger@chromium.org> Reviewed-by:
Michael Achenbach <machenbach@chromium.org> Cr-Commit-Position: refs/heads/master@{#44099}
-
Michael Achenbach authored
Bug: v8:6132 NOTRY=true TBR=jgruber@chromium.org,eholk@chromium.org Change-Id: Idd706e5bb08f1890f6edc69792238114aadf220b Reviewed-on: https://chromium-review.googlesource.com/459517Reviewed-by:
Michael Achenbach <machenbach@chromium.org> Commit-Queue: Michael Achenbach <machenbach@chromium.org> Cr-Commit-Position: refs/heads/master@{#44098}
-
tebbi authored
BUG=chromium:699251 R=bmeurer@chromium.org Review-Url: https://codereview.chromium.org/2766383003 Cr-Commit-Position: refs/heads/master@{#44095}
-
bradnelson authored
Add the --fast-validate-asm option, which directs asm.js code to a new parser + validator + wasm code generator, which is then compiled using WebAssembly. This parser takes advantage of asm.js structure to linearly parse asm.js code, keeping a scope stack + a few additional tables to track varibles. BUG=v8:6090 BUG=v8:4203 R=mstarzinger@chromium.org,marja@chromium.org,vogelheim@chromium.org,kschimpf@chromium.org Review-Url: https://codereview.chromium.org/2757693003 Cr-Commit-Position: refs/heads/master@{#44084}
-
- 23 Mar, 2017 7 commits
-
-
Bradley.Meck authored
There was a security issue from allowing WindowProxy to have its prototype mutated in https://bugs.chromium.org/p/chromium/issues/detail?id=399951 . This has since been resolved by making `window`, `location`, and `Object.prototype.__proto__` immutable. This change was fixed in https://bugs.chromium.org/p/v8/issues/detail?id=5149 . Reverts https://codereview.chromium.org/1529303003 R=littledan@chromium.org R=verwaest@chromium.org Review-Url: https://codereview.chromium.org/2671553006 Cr-Commit-Position: refs/heads/master@{#44078}
-
binji authored
BUG=v8:5897 Review-Url: https://codereview.chromium.org/2741413006 Cr-Commit-Position: refs/heads/master@{#44075}
-
yangguo authored
With precise binary code coverage, the reported count is either 0 or 1. We only report 1 the first time we collect coverage data after the function has been executed. Since we do not care about the accurate execution count, we can optimize the function once it has been executed once. Also change best effort coverage to be implicitly binary. R=caseq@chromium.org, jgruber@chromium.org, pfeldman@chromium.org BUG=v8:5808 Review-Url: https://codereview.chromium.org/2766573003 Cr-Commit-Position: refs/heads/master@{#44074}
-
jgruber authored
This is just an update to reflect the current spec proposal. https://tc39.github.io/proposal-regexp-named-groups/ BUG=v8:5437 Review-Url: https://codereview.chromium.org/2769143002 Cr-Commit-Position: refs/heads/master@{#44067}
-
Michael Starzinger authored
R=machenbach@chromium.org BUG=v8:6127 Change-Id: Iced2bd9e71006077aca4bd1de8dd14b6c771ec86 Reviewed-on: https://chromium-review.googlesource.com/458222Reviewed-by:
Michael Achenbach <machenbach@chromium.org> Commit-Queue: Michael Starzinger <mstarzinger@chromium.org> Cr-Commit-Position: refs/heads/master@{#44062}
-
Clemens Hammacher authored
This CL adds support for indirect function calls to the interpreter. It can indirectly call other wasm function in the same instance, which are then executed in the interpreter, or call imported functions. Implementing this required some refactoring: - The wasm interpreter now unwraps import wrappers on demand, instead of unwrapping all of them on instantiation and storing a vector of handles. This also avoids the DeferredHandleScope completely, instead we just store two global handles in the code map. - The interpreter gets the code table, function tables and signature tables directly from the attached wasm instance object. This ensures that the interpreter sees all updates to tables that might have been performed by external code. - There is now common functionality for calling a code object. This is used for direct calls to imported functions and for all indirect calls. As these code objects can also be wasm functions which should be executed in the interpreter itself, I introduce a struct to hold the outcome of calling the code object, or a pointer to InterpreterCode to be called in the interpreter. R=ahaas@chromium.org BUG=v8:5822 Change-Id: I20fb2ea007e79e5fcff9afb4b1ca31739ebcb83f Reviewed-on: https://chromium-review.googlesource.com/458417 Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Reviewed-by:
Andreas Haas <ahaas@chromium.org> Cr-Commit-Position: refs/heads/master@{#44059}
-
Michael Starzinger authored
This adds a --stress-validate-asm flag intended to stress test the validator by running against every single function, independent of whether a "use asm" directive is present. It mainly tests negative cases because barely any function in our test corpus will be a valid module according to the asm.js spec. R=bradnelson@chromium.org BUG=v8:6127 Change-Id: Id04b0440628134d4e81c9bb4d71039f940fc9a83 Reviewed-on: https://chromium-review.googlesource.com/457039Reviewed-by:
Brad Nelson <bradnelson@chromium.org> Reviewed-by:
Michael Achenbach <machenbach@chromium.org> Commit-Queue: Michael Starzinger <mstarzinger@chromium.org> Cr-Commit-Position: refs/heads/master@{#44055}
-
- 22 Mar, 2017 8 commits
-
-
Caitlin Potter authored
The AssignmentExpressions can legally contain destructuring assignments. BUG=v8:6098 R=marja@chromium.org, adamk@chromium.org Change-Id: I99b3a0f4c8d103edfb1dda943ec3e2ab2a5969f7 Reviewed-on: https://chromium-review.googlesource.com/455221 Commit-Queue: Caitlin Potter <caitp@igalia.com> Reviewed-by:
Adam Klein <adamk@chromium.org> Cr-Commit-Position: refs/heads/master@{#44049}
-
Clemens Hammacher authored
The stack check at the beginning of each function maps to the wasm byte offset 0. For asm.js functions, this byte offset is mapped further to an asm.js source position. For most functions, we explicitly add an entry to this side table for offset 0. This was missing for the start function. R=ahaas@chromium.org BUG=v8:4203,chromium:703568 Change-Id: I05bc4a8cfa666864bb7a0b23f75186abe0be9bee Reviewed-on: https://chromium-review.googlesource.com/458437 Commit-Queue: Brad Nelson <bradnelson@chromium.org> Reviewed-by:
Brad Nelson <bradnelson@chromium.org> Cr-Commit-Position: refs/heads/master@{#44037}
-
jarin authored
BUG=v8:6077 Review-Url: https://codereview.chromium.org/2765323002 Cr-Commit-Position: refs/heads/master@{#44035}
-
jarin authored
This adds optimization and deoptimization counts to the Web UI. Also, the function timeline now shows optimization and deoptimization marks. Review-Url: https://codereview.chromium.org/2753543006 Cr-Commit-Position: refs/heads/master@{#44033}
-
Clemens Hammacher authored
Add a check to appendToTable to catch illegal input, and fix a test case triggering this check. Also removing unused variables and fix indentation. R=ahaas@chromium.org Change-Id: I0eaa48ab95ef710530a3cfbe94ed4dd419618cda Reviewed-on: https://chromium-review.googlesource.com/458436 Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Reviewed-by:
Andreas Haas <ahaas@chromium.org> Cr-Commit-Position: refs/heads/master@{#44027}
-
cwhan.tunz authored
Review-Url: https://codereview.chromium.org/2760313002 Cr-Commit-Position: refs/heads/master@{#44017}
-
Michael Starzinger authored
This fixes a corner case where the "instance prototype" diverges from the "non-instance prototype" that we store on the initial map of a constructor function. R=bmeurer@chromium.org TEST=mjsunit/regress/regress-crbug-703610 BUG=chromium:703610 Change-Id: I30a19ae621e10b512215ffb191ce00d030941440 Reviewed-on: https://chromium-review.googlesource.com/458396Reviewed-by:
Benedikt Meurer <bmeurer@chromium.org> Commit-Queue: Michael Starzinger <mstarzinger@chromium.org> Cr-Commit-Position: refs/heads/master@{#44008}
-
Michael Achenbach authored
BUG=v8:5193,v8:6113,v8:6132,v8:6133 TBR=hablich@chromium.org NOTRY=true Change-Id: I2293a6978006e3b00cfd6a438ba81be23df2620d Reviewed-on: https://chromium-review.googlesource.com/457997Reviewed-by:
Michael Achenbach <machenbach@chromium.org> Commit-Queue: Michael Achenbach <machenbach@chromium.org> Cr-Commit-Position: refs/heads/master@{#44001}
-
- 21 Mar, 2017 2 commits
-
-
danno authored
BUG=v8:1956 Review-Url: https://codereview.chromium.org/2752273003 Cr-Commit-Position: refs/heads/master@{#43987}
-
Clemens Hammacher authored
This CL makes the interpreter reentrant by allowing different activations to be live at the same time. The wasm interpreter keeps a list of activations and stores the stack height at the start of each activation. This information is used to unwind just one activation, or show the right portion of the interpreter stack for each interpreter entry frame. The WasmDebugInfo object stores a mapping from frame pointer (of the interpreter entry) to the activation id in order to identify the activation based on the physical interpreter entry frame. R=titzer@chromium.org, ahaas@chromium.org BUG=v8:5822 Change-Id: Ibbf93f077f907213173a92e0a2f7f3556515e8eb Reviewed-on: https://chromium-review.googlesource.com/453958 Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Reviewed-by:
Andreas Haas <ahaas@chromium.org> Cr-Commit-Position: refs/heads/master@{#43976}
-
- 20 Mar, 2017 9 commits
-
-
franzih authored
Collect type information of return values. Use *one* feedback slot per function for all its return statements. For assignments, we currently use several slots per function, because not all assignments refer to the same variable. Instead of the variable names, pass the source location and print the function name. Add an integration test for --type-profile that checks for crashes. Remove type feedback for assignments for now as it convolutes the output. ************ Function with 2 return statements ******** function testFunction(param, flag) { // We want to test 2 different return positions in one function. if (flag) { var first_var = param; return first_var; } var second_var = param; return second_var; } testFunction({}); testFunction(123, true); testFunction('hello'); testFunction(undefined); ******************************************************* ************* Sample Output *************************** Function: testFunction 424: Object 374: number 424: string 424: undefined ******************************************************* Missing work: * Handle fall-off returns * Collect types for parameters * Remove duplicates from the list of collected types and use a common base class. BUG=v8:5935 Review-Url: https://codereview.chromium.org/2755973002 Cr-Commit-Position: refs/heads/master@{#43956}
-
Clemens Hammacher authored
Before: Failure: expected <true> found <false> After: Failure: expected <0.4 +- 0.001> found <0.3> R=ahaas@chromium.org Change-Id: I304fd90112cb7131103863813e7b0920be2b5c04 Reviewed-on: https://chromium-review.googlesource.com/456284Reviewed-by:
Andreas Haas <ahaas@chromium.org> Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Cr-Commit-Position: refs/heads/master@{#43950}
-
Clemens Hammacher authored
When instantiating the wasm interpreter, pass the start address of the global variables. This was nullptr before, leading to a crash if debugging a program which accesses globals. With test. R=ahaas@chromium.org, titzer@chromium.org BUG=v8:5822 Change-Id: I5f419790042ef9a00787df093a07e5e5835d55bd Reviewed-on: https://chromium-review.googlesource.com/456219 Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Reviewed-by:
Andreas Haas <ahaas@chromium.org> Cr-Commit-Position: refs/heads/master@{#43948}
-
Clemens Hammacher authored
This fixes a bug where an exported function is being specialized, but the callsite inside the JS_TO_WASM function was patched to call an interpreter entry instead. We would not identify the call site as the one to be patched during specialization, and would thus fail a DCHECK. R=ahaas@chromium.org BUG=v8:5822, chromium:702839 Change-Id: I148d98333051c399a4cb11bd9620b396f4eb261d Reviewed-on: https://chromium-review.googlesource.com/456282 Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Reviewed-by:
Andreas Haas <ahaas@chromium.org> Cr-Commit-Position: refs/heads/master@{#43942}
-
Clemens Hammacher authored
If an exception is thrown and the wasm interpreter entry frame is unwound, also the internal frames in the interpreter need to be unwound. We did not do so before, leaving a corrupted internal state of the wasm interpreter. Thus reusing it would fail. This CL fixes this and adds a test which reenters a previously unwound wasm interpreter. It checks that this works and the correct stack is returned. This test also requires support for calling an imported function which throws, so this change is also included here. R=ahaas@chromium.org, titzer@chromium.org BUG=v8:5822 Change-Id: I12fb843f7a371a4e618b4ac63ed3299667a03a82 Reviewed-on: https://chromium-review.googlesource.com/453938 Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Reviewed-by:
Andreas Haas <ahaas@chromium.org> Cr-Commit-Position: refs/heads/master@{#43937}
-
Toon Verwaest authored
We use LoadFromPrototype also for direct global loads. InitPrototypeChecks did not support this though, and would create a prototype chain check for objects beyond the direct global. This tries to ensure the property on the global itself doesn't exist, which is invalid. Additionally this CL deletes duplicate code. BUG=chromium:702798,v8:5561 Change-Id: I318a5b6cd5f7c3efdb3a003e34edd37d5d3f880b Reviewed-on: https://chromium-review.googlesource.com/457369 Commit-Queue: Toon Verwaest <verwaest@chromium.org> Reviewed-by:
Jakob Kummerow <jkummerow@chromium.org> Cr-Commit-Position: refs/heads/master@{#43935}
-
loorongjie authored
BUG=v8:5929 R=adamk@chromium.org,bmeurer@chromium.org Review-Url: https://codereview.chromium.org/2735563002 Cr-Commit-Position: refs/heads/master@{#43934}
-
ahaas authored
Without the check it happened that the builtin call in the trap code was too far away from the constant pool and therefore crashed. BUG=v8:6054 R=bmeurer@chromium.org, v8-arm-ports@googlegroups.com Review-Url: https://codereview.chromium.org/2738683003 Cr-Commit-Position: refs/heads/master@{#43928}
-
bmeurer authored
Don't ignore IfException (and IfSuccess) projections on JSForInNext nodes during JSTypedLowering::ReduceJSForInNext, but instead rewrire the IfException projection to the ForInFilter stub call, which can throw exceptions in case of proxies. R=yangguo@chromium.org BUG=v8:6121 Review-Url: https://codereview.chromium.org/2761703002 Cr-Commit-Position: refs/heads/master@{#43925}
-
- 18 Mar, 2017 1 commit
-
-
Jakob Kummerow authored
BUG=chromium:702793 Change-Id: Ia52823968a757f8f7fc8802deab60f570ffdb58c Reviewed-on: https://chromium-review.googlesource.com/456280Reviewed-by:
Adam Klein <adamk@chromium.org> Commit-Queue: Jakob Kummerow <jkummerow@chromium.org> Cr-Commit-Position: refs/heads/master@{#43920}
-
- 17 Mar, 2017 2 commits
-
-
Marja Hölttä authored
There are at least 3 mechanisms for detecting duplicate parameters. - ExpressionClassifier - Scope::DeclareParameter checking IsDeclaredParameter - PatternRewriter::VisitVariableProxy failing to declare a duplicate parameter The conditions for when duplicate parameters are allowed and when not are pretty involved too. They are allowed when - the function is not an arrow function and not a concise method *and* - when the parameter list is simple *and* - we're in sloppy mode (incl. the function doesn't declare itself strict). In addition, we don't recognize some of the early errors, and it's non-trivial to see which ones are recognized and which not (see bug v8:6108). E.g., (dup, dup) => {}; is recognized but (dup, [dup]) => {} is not. And (dup, [dup]) => 1; is. We do have tests for some aspects of duplicate parameters (e.g., arrow function duplicate parameters are included in arrow function tests), but it's hard to see whether all combinations of the relevant conditions are tested. This CL adds more structured tests which hopefully enables reducing the duplicate parameter detection mechanisms to 2 or maybe even to 1. BUG=v8:6092 Change-Id: Idd3db43b380aae4b9a89be5f1ed0755d39bfb36d Reviewed-on: https://chromium-review.googlesource.com/456336 Commit-Queue: Marja Hölttä <marja@chromium.org> Reviewed-by:
Daniel Vogelheim <vogelheim@chromium.org> Cr-Commit-Position: refs/heads/master@{#43895}
-
Andreas Haas authored
Since TrapIf has been implemented on all platforms, there is no need anymore for the old WasmTrapHelper code. This CL also removes TrapIf-specific tests. R=titzer@chromium.org, clemensh@chromium.org Change-Id: Ic069598441b7bd63bde2e66f4e536abea5ecebe6 Reviewed-on: https://chromium-review.googlesource.com/452380 Commit-Queue: Andreas Haas <ahaas@chromium.org> Reviewed-by:
Ben Titzer <titzer@chromium.org> Reviewed-by:
Clemens Hammacher <clemensh@chromium.org> Cr-Commit-Position: refs/heads/master@{#43887}
-
- 16 Mar, 2017 5 commits
-
-
titzer authored
Note that this also modifies mjsunit.js to allow the {failWithMessage} method to be monkey-patched by a test. This is necessary because assertions which fail in a promise's then-clause would normally only throw an exception, which is swallowed by the promise, causing the test to silently pass. Instead, patching this {failWithMessage} functionality allows then clauses to use the full assertion machinery of mjsunit.js. R=ulan@chromium.org, gsathya@chromium.org BUG= Review-Url: https://codereview.chromium.org/2752043002 Cr-Commit-Position: refs/heads/master@{#43875}
-
cwhan.tunz authored
- Implement C++ builtins and ElementsAccessor for %TypedArray%.prototype.lastIndexOf - Remove TypedArrayLastIndexOf in src/js/typedarray.js - Combine InnerArrayLastIndexOf and ArrayLastIndexOf in src/js/array.js BUG=v8:5929 Review-Url: https://codereview.chromium.org/2744283002 Cr-Commit-Position: refs/heads/master@{#43870}
-
Clemens Hammacher authored
This behaviour was missing before. If a trap is encountered in the interpreter, we now throw the right error. With test. R=titzer@chromium.org, ahaas@chromium.org BUG=v8:5822 Change-Id: I09c23d15fcde32ec586fb6d3094a5ec49155a9a2 Reviewed-on: https://chromium-review.googlesource.com/453839 Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Reviewed-by:
Andreas Haas <ahaas@chromium.org> Cr-Commit-Position: refs/heads/master@{#43859}
-
Clemens Hammacher authored
When instantiating the wasm interpreter for debugging, we unwrap all wasm-to-js wrappers and store the callable objects. The handles are stored in a DeferredHandleScope and deleted when the InterpreterHandle (store in WasmDebugInfo) is freed. A call to an imported function reads the arguments from the stack, converts them to JS objects, calls the callable, converts back the return value and pushes it onto the stack. Reentering the interpreter from the calles JS code is not permitted yet, but will be in a follow-up CL. Also, indirect calls to imported functions will have to follow. R=titzer@chromium.org, ahaas@chromium.org BUG=v8:5822 Change-Id: I66c35053bccb6cf8d416606e4f840d888ccb3b65 Reviewed-on: https://chromium-review.googlesource.com/453838 Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Reviewed-by:
Ben Titzer <titzer@chromium.org> Reviewed-by:
Andreas Haas <ahaas@chromium.org> Cr-Commit-Position: refs/heads/master@{#43855}
-
bmeurer authored
The fast-path for Array.prototype.indexOf first checks whether the receiver is a fast-mode JSArray (and there are no elements in the prototype chain in case of holey arrays), then loads the known JSArray::length, and afterwards calls ToInteger on the fromIndex. But this ToInteger(fromIndex) call can cause arbitrary side effects if the fromIndex is a JSReceiver, in particular it can invalidate the assumptions about the fast-mode of the receiver and the length. In the worst case this leads to OOB memory access. Quick-fix is to bailout to the runtime if the fromIndex is neither a Smi nor undefined, which represents the common cases. R=jarin@chromium.org BUG=chromium:702058 Review-Url: https://codereview.chromium.org/2756663002 Cr-Commit-Position: refs/heads/master@{#43843}
-
- 15 Mar, 2017 1 commit
-
-
Clemens Hammacher authored
When generating the code for an illegal (non-js-compliant) wrapper for a js function, we were generating a zero constant of the return type. This failed on ia32 if the return type is i64. The correct thing to do is to return two i32 zero constants. R=titzer@chromium.org BUG=v8:6104, v8:6096 Change-Id: Idc0dd8d3eef901c22d5278d97f1879b000a18588 Reviewed-on: https://chromium-review.googlesource.com/455857Reviewed-by:
Ben Titzer <titzer@chromium.org> Commit-Queue: Clemens Hammacher <clemensh@chromium.org> Cr-Commit-Position: refs/heads/master@{#43835}
-