Commit Graph

31 Commits

Author SHA1 Message Date
Jakob Kummerow
f5ab7d38be [wasm-c-api] Add tests and fixes
In a new test suite: "wasm-api-tests", using a new binary "wasm_api_tests",
powered by gtest/gmock (like unittests).
Also fix a bunch of issues that these tests uncovered, mostly to ensure
that the stack is walkable.

Change-Id: I1d5604eea85da078ebecd4ebb7383647595f16ac
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1627539
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#61885}
2019-05-28 09:57:04 +00:00
Bill Ticehurst
f8acd898de Specify the Python executable on the command line in gm.py
Launching Python scripts can fail on Windows if the Python executable
isn't given as the first argument to the shell. This change adds the
path of the current Python executable, as per the behavior of v8gen.py

Change-Id: Iedaf57bcafc4c6aa6ebb89e945ee967cf393da04
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1497522
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#60023}
2019-03-05 03:30:30 +00:00
Z Duong Nguyen-Huu
5c4dd9f05e gm .check should work in win
currently it cannot call run-tests.py since it use Linux path

Change-Id: I15af9c7e6503e6d473611a24f5f223ff68b1dbbd
Reviewed-on: https://chromium-review.googlesource.com/c/1484110
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Z Nguyen-Huu <duongn@microsoft.com>
Cr-Commit-Position: refs/heads/master@{#59846}
2019-02-25 20:14:29 +00:00
Maciej Goszczycki
dbaa5b7b9a [gm.py] Strip carriage returns from mksnapshot arguments
Change-Id: I25a2299e5e261cc125c7ff0e1acdeddbd7f664ff
Reviewed-on: https://chromium-review.googlesource.com/c/1475753
Reviewed-by: Dan Elphick <delphick@chromium.org>
Commit-Queue: Maciej Goszczycki <goszczycki@google.com>
Cr-Commit-Position: refs/heads/master@{#59659}
2019-02-18 12:39:57 +00:00
Jakob Kummerow
0685745cf5 [gm.py] Improve mksnapshot failure detection
Dynamically process the arguments instead of hardcoding them,
which is brittle when they change.

Change-Id: I08f603dc6df6e3ed34518326b67da15f6a6d6102
Reviewed-on: https://chromium-review.googlesource.com/c/1405312
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58733}
2019-01-11 11:06:33 +00:00
Jakob Kummerow
1e461e3c5e [gm.py] Fix gm.py to work on Windows
gm.py has been careful to only use the "pty" module's functionality
on Linux, but as it turns out, the module is *so* strongly specific
to Linux that even importing it fails on Windows. Making the import
of "pty" conditional makes gm.py work on Windows.

Change-Id: I0c1fb8a9a0299fde50e252337551d9395039f14d
Reviewed-on: https://chromium-review.googlesource.com/c/1382738
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58335}
2018-12-18 17:09:10 +00:00
Igor Sheludko
f17b0d2676 [gm.py] Allow arbitrary mode suffixes
which will allow gm to work for more directories than just [<arch>].[<mode>]:
  gm.py ia32.release-nosnap.check
  gm.py x64.optdebug-ptr-compr cctest unittests

Basically the new usage is:
  gm.py [<arch>].[<mode>[-<suffix>]].[<target>] [testname...]

Once default gn configuration is created based on <arch> and <mode> the script user
may change it and then use gm as usual.

Bug: v8:8238
Change-Id: I9659b87073e815e0e4754f0a2f1056f3403c149c
Reviewed-on: https://chromium-review.googlesource.com/c/1323734
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#57328}
2018-11-07 20:02:58 +00:00
Jakob Kummerow
f5e13b2bf6 [gm.py] Support embedded builtins or missing build.ninja
This patch adds two improvements to gm.py:
(1) Fix "mksnapshot failure" detection to match the error message
    that is generated when embedded builtins are enabled.
(2) Run "gn gen" whenever build.ninja is missing. This can happen
    when out/<config>/args.gn exists already when gm.py is run for
    the first time.

Bug: v8:6666, v8:8335
Change-Id: I71836b832754fa21b6443d57a6c3c49718a9a8d1
Reviewed-on: https://chromium-review.googlesource.com/c/1294174
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56918}
2018-10-24 00:07:05 +00:00
Bangfu Tao
92d6222f89 [gm.py] Support android_arm{,64} builds
This patch adds support for "gm.py android_arm.release.check"
and similar invocations.

Change-Id: I6e2204cb00f574d759b9e142ecabd2582153f707
Reviewed-on: https://chromium-review.googlesource.com/c/1278629
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56659}
2018-10-15 18:46:17 +00:00
jgruber
88b53ab569 [gm] Set v8_enable_fast_mksnapshot by default
This change somehow got lost when relanding an earlier CL in
https://crrev.com/c/1118139

Bug: v8:7891
Change-Id: I31244be136322cccfb465c24356f1d0fd5e0c6d6
Reviewed-on: https://chromium-review.googlesource.com/1119786
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54104}
2018-06-29 09:30:16 +00:00
Jakob Gruber
cf66f73771 Revert "[build] Disable slow asserts for v8_enable_fast_mksnapshot"
This reverts commit 7a0d6a5000.

Reason for revert: Breaks no-slow-assert builds.

Original change's description:
> [build] Disable slow asserts for v8_enable_fast_mksnapshot
> 
> Slow asserts double the time spent in mksnapshot. While we want them
> enabled on our bot builds, local builds should be fast and don't
> necessarily need them.
> 
> This also adds v8_enable_fast_mksnapshot as default in gm.py.
> 
> Bug: v8:7891,v8:6688
> Change-Id: I5ab1491f3396c4351de30dbbb80a81e2242c5db9
> Reviewed-on: https://chromium-review.googlesource.com/1116552
> Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
> Commit-Queue: Jakob Gruber <jgruber@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#54074}

TBR=jkummerow@chromium.org,jgruber@chromium.org

Change-Id: I6b048e819846c4bd9a064f82e2f3c7609369cd33
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:7891, v8:6688
Reviewed-on: https://chromium-review.googlesource.com/1118138
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54077}
2018-06-28 09:12:25 +00:00
jgruber
7a0d6a5000 [build] Disable slow asserts for v8_enable_fast_mksnapshot
Slow asserts double the time spent in mksnapshot. While we want them
enabled on our bot builds, local builds should be fast and don't
necessarily need them.

This also adds v8_enable_fast_mksnapshot as default in gm.py.

Bug: v8:7891,v8:6688
Change-Id: I5ab1491f3396c4351de30dbbb80a81e2242c5db9
Reviewed-on: https://chromium-review.googlesource.com/1116552
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54074}
2018-06-28 06:31:59 +00:00
Peter Marshall
7f67bea468 [tools] Update gm.py to re-run mksnapshot in gdb
It seems that the output on snapshot failure has changed, so failed
snapshots were no longer being automatically re-run in gdb.

Change-Id: I321a6055b5683db31d215b9c30827f4badca3df7
Reviewed-on: https://chromium-review.googlesource.com/1066058
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Peter Marshall <petermarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53269}
2018-05-21 11:15:39 +00:00
Michael Lippautz
e5266c24c3 [gm.py] Use autoninja instead of ninja
Avoids detecting local cores and guessing remote jobs.

No-try: true
Change-Id: I4a825b8dd922802c5f539419313888fd3b21b870
Reviewed-on: https://chromium-review.googlesource.com/876009
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50733}
2018-01-19 19:31:58 +00:00
Michael Starzinger
af01d9e09d [gm] Add targets for inspector testing.
R=jkummerow@chromium.org

Change-Id: Idc29d9cfe1900554c6ecac5f170e9dea001430ca
Reviewed-on: https://chromium-review.googlesource.com/793191
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49700}
2017-11-29 09:37:17 +00:00
Jakob Kummerow
cfcdeab002 [storeic] Drop duplicate stubs for each LanguageMode
Only the error cases of overwriting readonly properties need the
language_mode to decide whether to throw or be silent. Reading it
from the feedback vector's metadata (just like the C++ code in
ic.cc does) removes the need to duplicate each stub for each
language_mode ("StoreIC" + "StoreICStrict" etc.).

Change-Id: Ic0c67f9d40ca36c65e41b4f162b2ab70d155e549
Reviewed-on: https://chromium-review.googlesource.com/647373
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#47836}
2017-09-05 18:00:39 +00:00
Jakob Kummerow
c9532eb617 [gm.py] Detect --csa-trap-on-node in failure output
And add the helpfully suggested flag to the GDB re-run of mksnapshot.

NOTRY=true

Change-Id: I52011aa580c8d3e557f869b8306b9b978c73b946
Reviewed-on: https://chromium-review.googlesource.com/647693
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#47829}
2017-09-05 16:48:59 +00:00
Jakob Kummerow
e825c4318e Remove x87 port
Bug: v8:6550
Change-Id: I888f91db1fd842d1fef8a5fb749da229dfb6ab97
Reviewed-on: https://chromium-review.googlesource.com/575756
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Daniel Clifford <danno@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#46746}
2017-07-18 18:20:40 +00:00
Michael Lippautz
61d1ad23ce [gm] Detect goma usage from args.gn
- Properly detect whether the args.gn config actually wants goma.
- Read out cpu count dynamically.

NOTRY=true

Bug: 
Change-Id: I7a687e873ef0b009ab6eaada384378d23e1dbb1e
Reviewed-on: https://chromium-review.googlesource.com/558085
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#46362}
2017-06-30 14:12:04 +00:00
Jakob Kummerow
2bdb74f75d [cleanup] Refactor parts of builtins-number-gen.cc
Bug: v8:6474

Change-Id: I24d067ac77c2cb557d0b3f6e2c8c512761c160f1
Reviewed-on: https://chromium-review.googlesource.com/531384
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#45944}
2017-06-14 12:42:27 +00:00
Wiktor Garbacz
5ac26293f1 [tools] Make gm.py work without GOMA again.
Change-Id: I2d8f4defd465b2f9838ed002add088da5b6739ef
Reviewed-on: https://chromium-review.googlesource.com/528197
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#45815}
2017-06-09 13:04:40 +00:00
bmeurer
5005eea85a [tools] Properly handle different GOMA_DIR in gm.py.
R=jarin@chromium.org, jkummerow@chromium.org

Review-Url: https://codereview.chromium.org/2923983002
Cr-Commit-Position: refs/heads/master@{#45753}
2017-06-07 09:08:37 +00:00
Jakob Kummerow
946376aa1d [gm.py] Re-run mksnapshot in GDB on failure
NOTRY=true

Change-Id: I62ae81ef5e7439a19efbffdffd196f44c5c31349
Reviewed-on: https://chromium-review.googlesource.com/521041
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#45687}
2017-06-02 13:45:48 +00:00
Andreas Haas
34ae5a09b3 [gm] Adjust the script to support mips64el
R=jkummerow@chromium.org

Change-Id: I6fc3817410df4f070675051397a30cc1b0ca7dfe
Reviewed-on: https://chromium-review.googlesource.com/488030
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#44929}
2017-04-27 12:16:56 +00:00
jkummerow
75ce09b533 Fix HashTable growth strategy to be 2x instead of 4x
Review-Url: https://codereview.chromium.org/2827263004
Cr-Commit-Position: refs/heads/master@{#44783}
2017-04-21 17:31:29 +00:00
Michael Lippautz
7c87aeb188 [gm.py] Notify using print when notify-send is not supported
Bug:

Change-Id: I532e8894df288c81a71b08ca85742f2847f57191
Reviewed-on: https://chromium-review.googlesource.com/484339
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#44781}
2017-04-21 16:10:23 +00:00
jkummerow
0cbe645413 [gm.py] Add support for building mkgrokdump
Now you can do: "gm.py x64.release mkgrokdump"

NOTRY=true

Review-Url: https://codereview.chromium.org/2827383003
Cr-Commit-Position: refs/heads/master@{#44756}
2017-04-20 19:37:09 +00:00
Franziska Hinkelmann
148ff7394d [tools/dev/gm.py] Remove unused gdb_index.
gdb_index is not in declare_args() and has no effect.

NOTRY=true

Change-Id: I88a9558937aa8fea30ab246899bea4a123947f82
Reviewed-on: https://chromium-review.googlesource.com/475772
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#44620}
2017-04-12 15:25:53 +00:00
jkummerow
94efcfe01b [tools] gm.py: start goma when it isn't running
NOTRY=true

Review-Url: https://codereview.chromium.org/2754253002
Cr-Commit-Position: refs/heads/master@{#43904}
2017-03-17 14:10:23 +00:00
jkummerow
c478a2298d SnapshotCreator: start from existing snapshot if we have one
This requires serialized data to track the number of API-provided
external references separately.
And it flushes out a case of serialized data corruption (stored "length"
field too large) that we didn't handle without crashing.

BUG=v8:6055

Review-Url: https://codereview.chromium.org/2736923002
Cr-Commit-Position: refs/heads/master@{#43649}
2017-03-07 16:36:51 +00:00
jkummerow
b008f27f02 [tools] Introduce gm.py
Convenience wrapper around building with gn/ninja and running tests.
Follows Makefile syntax, but is more flexible; see --help.
Pro tip: alias gm="tools/dev/gm.py"

NOTRY=true

Review-Url: https://codereview.chromium.org/2713663002
Cr-Commit-Position: refs/heads/master@{#43377}
2017-02-22 15:09:28 +00:00