* Use dartk as the default compiler for runtime=vm.
* Status file entries for checking for the `none` compiler now either
use dartk or are deleted.
Tested: Standard CQ and local testing.
Fixes: https://github.com/dart-lang/sdk/issues/50241
Change-Id: I7a08d3e491ae1c82a0348fb66ea7b557398f97e5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/264682
Reviewed-by: Siva Annamalai <asiva@google.com>
Reviewed-by: Lasse Nielsen <lrn@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
Change-Id: I3eb11e4eb2d3f2db5329df7245fbca969e2956f5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/263660
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
This CL introduces a new kernel-to-kernel pass in Wasm backend to
compile `FfiNative`-annotated external functions to external functions
with `wasm:import` pragmas.
The new pass `WasmFfiNativeTransformer` extends `FfiNativeTransformer`.
Some `FfiNativeTransformer` methods made public to allow reuse in the
pass.
The conversion works like this: when we see a member like:
@FfiNative<Int8 Function(Int8, Int8)>("ffi.addInt8")
external int addInt8(int a, int b);
We generate a Wasm import using Wasm ABI types according to emscripten
calling conventions:
@pragma('wasm:import', 'ffi.addInt8')
external static WasmI32 addInt8_$import(WasmI32 a, WasmI32 b);
and convert the original member (`addInt8()`) to a wrapper function that
calls the Wasm import, converting the arguments and return values to
Dart types:
static int addInt8(int a, int b) {
return WasmI32.toIntSigned(
addInt8_$import(
WasmI32::int8FromInt(a),
WasmI32::int8FromInt(b),
));
}
Build, test, and CI changes:
- Test runner now uses `// SharedObjects=...` lines in dart2wasm tests
to pass extra Wasm modules to d8 command used to run the tests.
Support for `// SharedObjects=...` lines were already used in
native/AOT FFI tests, not added in this CL. We just start to use those
lines in dart2wasm tests.
- dart2wasm gn file updated with a target "test_wasm_modules" that
builds FFI test Wasm modules to Wasm using emcc (emscripten C
compiler).
- CI dart2wasm_hostasserts configuration updated to copy the Wasm files
generated by the "test_wasm_modules" target to the shards.
TEST=tests/web/wasm/ffi_native_test
Change-Id: I6527fe4e2ca2b582e16d84fee244e9cbe6dee307
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/252822
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Ömer Ağacan <omersa@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Change-Id: I7cb158d2e30e999564c11454783082837c7e5984
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/259901
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
A few co19 tests are marked as skipped for now, as they are hanging
due to https://github.com/dart-lang/sdk/issues/50026
Increase the number of shards to match the increased number of tests.
Change-Id: Ib91127986d13140164c357a22f2d1d9b7b2b7636
Cq-Include-Trybots: luci.dart.try:dart2wasm-linux-x64-d8-try
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/260361
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Both the production and try builders for the Windows SDK have been
migrated to the new recipe that doesn't use the test matrix.
Bug: b/247507699
Change-Id: I7a603e716492ffa272a43eea959b721c8c4a8f1d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/259842
Commit-Queue: Jonas Termansen <sortie@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Both the production and try builders for the macOS SDK have been
migrated to the new recipe that doesn't use the test matrix.
Bug: b/236109661
Change-Id: I4f578a162c866da6673b228023adb5966f1ca505
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/259423
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Jonas Termansen <sortie@google.com>
This reverts commit 1acf5dea46.
Reason for revert: Broke gclient sync for users.
Original change's description:
> [infra] Add dart_ci scripts to Dart SDK DEPS
>
> * Remove find_base_commit.dart script, this script will be supplied via
> the CIPD package instead.
> * The packages use "latest", to stay in sync with the current
> infrastructure rather than pinning them to an old version.
>
> Bug: b/242960194
> Change-Id: Iafa229e26b8926bc406758a79d22fe1410e1db96
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/255681
> Commit-Queue: Alexander Thomas <athom@google.com>
> Reviewed-by: William Hesse <whesse@google.com>
TBR=whesse@google.com,athom@google.com
Change-Id: I1d17b47f72527e46e117420b9d816a5a1dce711c
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: b/242960194
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/256502
Reviewed-by: Alexander Thomas <athom@google.com>
Auto-Submit: Alexander Thomas <athom@google.com>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
* Remove find_base_commit.dart script, this script will be supplied via
the CIPD package instead.
* The packages use "latest", to stay in sync with the current
infrastructure rather than pinning them to an old version.
Bug: b/242960194
Change-Id: Iafa229e26b8926bc406758a79d22fe1410e1db96
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/255681
Commit-Queue: Alexander Thomas <athom@google.com>
Reviewed-by: William Hesse <whesse@google.com>
This is faster than Goma's local fallback.
Change-Id: Ieedfaf773279270ed6138d189d3b6b5ab6bbc8d4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/256242
Reviewed-by: William Hesse <whesse@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Also cleans up and unifies some behavior across the backends:
- avoiding reinstantiating JsInteropChecks for every library
- having the native classes as a member instead of recomputing on dart2js
Now that these checks exist, we can add lib/js/static_interop_test to
the test directories the wasm trybot runs.
Change-Id: I912aae988afe7915e80cc13d00b8c47818dfa520
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/255760
Commit-Queue: Srujan Gaddam <srujzs@google.com>
Reviewed-by: Joshua Litt <joshualitt@google.com>
Reviewed-by: William Hesse <whesse@google.com>
Fixes: b/237755665
Change-Id: I11c066e8db7665ccd15ee671e2a706759cb1ef5e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250386
Auto-Submit: Alexander Thomas <athom@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: William Hesse <whesse@google.com>
Bug: b/237755665
Cq-Include-Trybots: luci.dart.try:analyzer-linux-release-try,analyzer-mac-release-try,analyzer-win-release-try
Change-Id: Ia48331d6fd6bf00df9dbe1b895e157a0957064f2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/249608
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
- Add new versions of exisiting configurations to support the arm64
architecture. The current DDC configurations don't name one but
default to x64. In the future I would like to remove the default
and simply specify (x64|arm64) but I'm not making this change now
because I don't want to break the history in the test database.
- Add new "canary" named test configurations that rely on a
specific builder to pass a build time flag
`--gn-args ddc_canary=true`.
Change-Id: I675899ea2e952e2183b8379b60ddaa67e8b864a5
Issue: https://github.com/dart-lang/sdk/issues/48950
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/243562
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Nicholas Shahan <nshahan@google.com>
* Use lowercase-with-hyphens for option names
* Add backwards compatible aliases_with_underscores.
* Deny list `reset-browser-configuration`.
* Add more tests.
Bug: b/232495224
Change-Id: Ife56c48450b5e15577c4aec859355e80c2f57bdc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/245366
Reviewed-by: Bob Nystrom <rnystrom@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
This matches previous changes to the build process for dart2wasm.
Change-Id: Ib55b78fccd6c400edab15758e68d74af15a58d55
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/245164
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
.dart_tool/package_config.json is already present in each fileset.
Bug: https://github.com/dart-lang/sdk/issues/48275
Change-Id: Ib75fd91060f0b9eaeb1446cf65cb8678b2ddc63c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/240842
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Jonas Termansen <sortie@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
This adds a --platform= option to dart2wasm to read the SDK libraries
from that dill file instead of compiling them from source every time.
If the option is not given, the SDK libraries are compiled, like before.
Also adds a "dart2wasm" build target, which will build the dart2wasm
platform dill and compile dart2wasm to two AOT snapshots (with and
without asserts). The dart2wasm scripts in sdk/bin are updated to run
via these snapshots and use this platform dill.
This speeds up test runs for the dart2wasm-hostasserts-linux-x64-d8
configuration by approximately 45x.
Change-Id: If2c7750a6eb39725310745f887792784d0dfc583
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/243624
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: William Hesse <whesse@google.com>
Reviewed-by: Joshua Litt <joshualitt@google.com>
This configuration is used by some of our benchmarking bots
but it wasn't tested explicitly here.
Change-Id: I913b54863c10ededeff179b7cd1adee1577470a6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/242960
Reviewed-by: Jonas Termansen <sortie@google.com>
Commit-Queue: Jonas Termansen <sortie@google.com>
This is a fork of `js_util` to support the needs of Wasm. It is very
much a WIP. We're landing this now to facilitate prototyping, and so we
can get a sense of what the right JS interop API might look like for
Wasm.
Change-Id: I8b2ddda07e906f1938d4cd5fe0e63203e9cdd6d5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/230120
Reviewed-by: Srujan Gaddam <srujzs@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Jonas Termansen <sortie@google.com>
Commit-Queue: Joshua Litt <joshualitt@google.com>
Change-Id: Ib8272650c7c468127c00a54e6bab679131deff5f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/237366
Auto-Submit: William Hesse <whesse@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
Includes precompiled build targets to ensure we try to build most of the
C++ code.
Does not include any tests. We assume that if the build succeeds the
executables will behave the same. If this turns out to not be the case,
we could add a tests later.
Bug: https://github.com/dart-lang/sdk/issues/48544
Change-Id: I5f6b74676d9bb705d29303c8597d4f420f9030d5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/237340
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Daco Harkes <dacoharkes@google.com>
Change-Id: Ib424a6a96b48e241667f9d7c9cbe1afe6920b5ae
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/234902
Auto-Submit: Joshua Litt <joshualitt@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
This reverts commit 92868580b4.
Reason for revert: I'm seeing failures in golem:
ninja: error: '../../third_party/dart/.dart_tool/package_config.json', needed by 'vm_outline_strong.dill', missing and no known rule to make it
Original change's description:
> Auto-generate the package_config.json file on gclient sync.
>
> Change-Id: Ibb5e548c0738e7dd0061433cf054af8336a0683b
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/234320
> Reviewed-by: Alexander Thomas <athom@google.com>
> Reviewed-by: Lasse Nielsen <lrn@google.com>
> Commit-Queue: Devon Carew <devoncarew@google.com>
TBR=lrn@google.com,devoncarew@google.com,athom@google.com
Change-Id: Ic2b7ae3feedfa064ddbbdb0b36f0e3db088bf177
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/234802
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
Change-Id: I2388f92a4300e5ee691182e7380091499bb02865
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/233503
Reviewed-by: Alexander Thomas <athom@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Commit-Queue: Joshua Litt <joshualitt@google.com>
This is work in progress. Several language features are still
unimplemented or only partially implemented.
Instructions for running the compiler and its output can be found in
pkg/dart2wasm/dart2wasm.md. These procedures are preliminary and
expected to change.
The best version of d8 to use for this version of dart2wasm is 10.0.40,
as explained here: https://dart-review.googlesource.com/c/sdk/+/232097
This commit also adds a dart2wasm-hostasserts-linux-x64-d8 testing
configuration to run the compiler over the test suite.
The history of the prototype that this is based on can be seen here:
https://github.com/askeksa-google/sdk/tree/wasm_prototype
Issue: https://github.com/dart-lang/sdk/issues/32894
Change-Id: I910b6ff239ef9c5f66863e4ca97b39b8202cce85
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/175728
Reviewed-by: Joshua Litt <joshualitt@google.com>
Commit-Queue: Aske Simon Christensen <askesc@google.com>