Commit Graph

7643 Commits

Author SHA1 Message Date
Sam Rawlins c219974ecf analyzer: Deprecate Diagnostic.errorCode in favor of diagnosticCode
Work towards https://github.com/dart-lang/sdk/issues/60635

Change-Id: I2c7d64a81bc214e64fbc3ac95cf1fe2363a6ebd0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/433242
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2025-06-09 09:22:22 -07:00
Sam Rawlins 7253f6198d infra: combine all three "analyze flutter" scripts.
The previous three scripts had some redundancies:

* Both the flutter/flutter analyzing script and the flutter/packages
  analyzing script checked out flutter/flutter. Combining them saves
  several minutes.
* The script that analyzed flutter/engine was pointing to the old
  engine repo, which was archived months ago. In pointing the script
  to the new sources at flutter/flutter, this would introduce another
  instance of cloning flutter/flutter. Combining this with the other
  scripts saves several minutes.

The only other little changes to the code are the introduction of
more echo commands, more `pushd`/`popd` vs `cd`, and isolating the
three tasks into functions for readability.

Change-Id: I08414d824c25075a8810b1aa0cc299c64328abbf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/432881
Auto-Submit: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2025-06-04 08:20:04 -07:00
Ryan Macnak cfccc2a2a8 [infra] Add arm64 back to gcc testing.
This was broken during Jammy but this builder now runs on Noble.

Cq-Include-Trybots: luci.dart.try:vm-gcc-linux-try
Change-Id: I39e4a1f924620723d36dad79383637fe5b62add7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/432760
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2025-06-03 16:06:00 -07:00
Ryan Macnak 72ee5445c3 [build] Install dartaotruntime to /usr/bin in the Debian package.
This removes a discrepancy in what is on PATH when installing the SDK via the Debian package versus unpacking the ZIP and adding dart-sdk/bin to PATH.

Bug: https://github.com/dart-lang/sdk/issues/49293
Cq-Include-Trybots: luci.dart.try:dart-sdk-linux-try
Change-Id: I57361cc090449dd4fd7a8e4ebbc60ace71af11fb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/431741
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2025-06-02 15:14:21 -07:00
Ryan Macnak 03301c9bfb [vm] Support assembly output for Windows.
The resulting DLL lacks debugging information / PDB.

TEST=ci
Bug: https://github.com/dart-lang/sdk/issues/60812
Bug: https://github.com/dart-lang/sdk/issues/60813
Cq-Include-Trybots: luci.dart.try:vm-aot-win-debug-arm64-try,vm-aot-win-debug-x64-try,vm-aot-win-release-arm64-try,vm-aot-win-release-x64-try
Change-Id: I305bad0081ec24f27249ad9b75ff8d32fa9c4893
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/428200
Reviewed-by: Tess Strickland <sstrickl@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2025-06-02 12:12:04 -07:00
Ryan Macnak 2565128cb0 [infra] Shard Mac AOT builders.
Use a combination of gen_snapshot's new ability to generate dylibs directly and the copy of llvm in buildtools to avoid using XCode, which is not available in shards.

Add definitions for debug builders now that they can complete without timing out.

Cq-Include-Trybots: luci.dart.try:vm-aot-mac-product-arm64-try,vm-aot-mac-release-arm64-try,vm-aot-mac-release-x64-try
Change-Id: I79924128f11aafab4cd74ea6e9ab5848c64557da
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/431700
Reviewed-by: Tess Strickland <sstrickl@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2025-06-02 08:21:35 -07:00
Ryan Macnak 4fb105e794 [build] Debian package test.
Compared to the old testing, this adds coverage for Debian 12, Ubuntu Jammy, Ubuntu Noble and `dart compile exe`.

Bug: https://github.com/dart-lang/sdk/issues/26953
Change-Id: I0201b206086007d6b975f4b12234bdb9dd162d5d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/431363
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Ivan Inozemtsev <iinozemtsev@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
2025-06-02 08:09:36 -07:00
Ryan Macnak 802331361f [dartfuzz] Add missing build target.
Cf. 786b6c5612

Change-Id: Ife3512577662f9b29481a1557f42aa13dc27b6f5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/431304
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2025-05-28 07:07:50 -07:00
Ryan Macnak a4e0a0b3f8 [build] Pass -Zxz to dh_builddeb instead of dpkg-buildpackage.
Passing to the later only affects source packages.

Bug: https://github.com/dart-lang/sdk/issues/26953
Change-Id: I3ca94c3ddbed4493536d3db52df6ec92c2e72bbf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/431302
Reviewed-by: Brian Quinlan <bquinlan@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2025-05-27 16:54:19 -07:00
Ryan Macnak 323b247ba9 [build] Explicitly build the Debian package using xz compression.
Newer versions dpkg-buildpackage default to zstd, which is not supported by older versions of dpkg.

Bug: https://github.com/dart-lang/sdk/issues/26953
Change-Id: I67fdb8ab5c3b560c1687a38cb83bcd8f022e9e84
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/431321
Reviewed-by: Brian Quinlan <bquinlan@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2025-05-27 14:55:19 -07:00
Ryan Macnak 786b6c5612 [dartfuzz] Extend VM flag fuzzing to dartfuzz and iso-stress.
Extend fuzzing to run dart2wasm.

Increase flag fuzzing timeout to equal generated program fuzzing timeout.

Adjust dartfuzz_test and iso-stress to use relative paths for ease of copy-pasting commands for reproduction.

Cq-Include-Trybots: luci.dart.try:iso-stress-linux-arm64-try,iso-stress-linux-x64-try
Bug: https://github.com/dart-lang/sdk/issues/60804
Bug: https://github.com/dart-lang/sdk/issues/60805
Change-Id: I6898f30b710f26f2c624726f7affee3187804334
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/430280
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
2025-05-27 13:22:18 -07:00
Danny Tuppeny 15f49c9da0 [deps] rev tools
+ update `rev_sdk_deps.dart` to work on Windows

Revisions updated by `dart tools/rev_sdk_deps.dart`.

tools (https://github.com/dart-lang/tools/compare/be0bd20..a433200c):
  a433200c  Thu May 22 16:53:40 2025 +0100  Danny Tuppeny  [test_reflective_loader] Pass test locations to `pkg:test` to improve IDE navigation (dart-lang/tools#2090)

Change-Id: I9706a72ac850b3cd43bdeed671431cf836dcd860
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/430501
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2025-05-27 09:27:38 -07:00
Tess Strickland af5221f442 [test_runner] Convert boolean use-elf to an enum gen-snapshot-format.
Currently, the configuration code only has a boolean option, 'use-elf'
for specifying the output format for gen_snapshot. If false, then the
output format is assumed to be assembly.

Add a new GenSnapshotFormat enum and replace the old 'use-elf' option
with a new 'gen-snapshot-format' option. The new enum has two getters:

* snapshotType returns the appropriate string to pass to gen_snapshot
  via the '--snapshot-type' option.
* fileOption returns the name of the option used to specify the
  output path for the given format.

In addition, make it so the Configuration only has a non-null
genSnapshotFormat field if the compiler is Compiler.dartkp to avoid
spurious differences in Configurations that are created with different
GenSnapshotFormat values when the configurations in question don't
actually call gen_snapshot.

TEST=pkg/smith/test/configuration_test.dart (and the CI in general)

Change-Id: I7f17dc8d3a1bb6d4bf57750bc5ef4a16b8a78c11
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/429980
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Tess Strickland <sstrickl@google.com>
2025-05-26 08:53:03 -07:00
Chloe Stefantsova 6fa858cfe8 Enable 'getter-setter-error' flag in 3.9
TEST=existing

Change-Id: Ic4a5735adda7cf8ef1565b9356ca277d9b62b064
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/430720
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Michael Thomsen <mit@google.com>
Reviewed-by: Erik Ernst <eernst@google.com>
Commit-Queue: Chloe Stefantsova <cstefantsova@google.com>
2025-05-26 08:08:31 -07:00
Ben Konyi d7cef28bee [ Observatory ] Create fork of runtime/observatory at pkg/observatory
This change further prepares for the removal of Observatory from the
shipped Dart SDK by creating a fork to be used by the remaining
Observatory users.

This is basically a straight copy of the contents from
runtime/observatory with the exception of two new scripts:

- `bin/observatory.dart`, a utility to launch Observatory
- `bin/activate.dart`, which globally activates `bin/observatory.dart`
  as `observatory`

This change also updates the presubmits to ensure that
`runtime/observatory` is effectively placed in read-only mode to prevent
any divergences with the fork.

Work towards https://github.com/dart-lang/sdk/issues/50233

Change-Id: Iff3a7512058f36afa2a96d45d94a1dff424401d6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/429800
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2025-05-22 07:19:03 -07:00
Alexander Markov 57174f5f87 Add vm-aot-dyn-linux-product-x64 builder
Change-Id: Ie404ccf9bad906ee4e93dcb153ff6c117494fc69
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/430200
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2025-05-21 12:10:53 -07:00
Ryan Macnak 9907c35974 [infra] Accept RBE setting from the builder config for Windows ARM64.
Remove dead IA32 builders.

Change-Id: Ie9ef8510f5431ed3fee4945b9d420b9b3984c9e4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/429827
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2025-05-21 09:18:20 -07:00
Daco Harkes 8ac2279b07 [native assets] Graduate to preview
This PR enables native assets on the main and dev channel by default,
and make native assets available on the beta channel.

This PR removes the flag from invocations.

The helper packages (`package:hooks` and `package:code_assets`) will
stay 0.x for now, until the SDK constraint can be bumped to a beta
release and we're happy with the Dart API.

`dart build` is also made available as preview (without a flag on
the main, dev, and beta channels). We're still finalizing the spec for
this command. (https://github.com/dart-lang/sdk/issues/60730)

`dart test` will need https://github.com/dart-lang/test/pull/2501.
This means users will need to update their `package:test` dependency.

This PR refactors the way that invalid `package_config.json`s are
handled: they are now loaded in the dartdev commands and handled there.

Bug: https://github.com/dart-lang/sdk/issues/50565
Project: https://github.com/orgs/dart-lang/projects/99/

Change-Id: I7db9ff6d7196750cab9379a4605c6bbf89a974d7
Cq-Include-Trybots: luci.dart.try:pkg-linux-debug-try,pkg-linux-release-arm64-try,pkg-linux-release-try,pkg-mac-release-arm64-try,pkg-win-release-arm64-try,pkg-mac-release-try,pkg-win-release-try
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/429920
Commit-Queue: Daco Harkes <dacoharkes@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
2025-05-21 06:10:19 -07:00
Ryan Macnak 1d53d28e96 [infra] Setup for x64 reclient on Linux ARM64.
Change-Id: I2ff065c8b962d768f93ea3304544ceb527f9c266
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/429466
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
2025-05-20 13:43:11 -07:00
Ben Konyi a067d75f8f [ Observatory ] Remove legacy Observatory VM service tests
Clean up test_runner and the test matrix to remove all references to
the service test suite and delete the tests.

Work towards https://github.com/dart-lang/sdk/issues/50233

TEST=N/A

Change-Id: Ie3adb0d007d71f9a223843d739e57cbdb5be0d59
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/429140
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Ivan Inozemtsev <iinozemtsev@google.com>
2025-05-20 10:33:53 -07:00
Ryan Macnak f4fa8b7ca6 [infra] Use x64 reclient on Windows ARM64.
Switch build to use Clang. This somewhat degrades FFI testing, but reduces build time by roughly half or one hour.

Cq-Include-Trybots: luci.dart.try:pkg-win-release-arm64-try,vm-aot-win-debug-arm64-try,vm-aot-win-release-arm64-try,vm-win-debug-arm64-try,vm-win-release-arm64-try
Change-Id: Ie267942e99934312b228cfadcd6d5b8477f855c8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/429421
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
2025-05-19 17:31:29 -07:00
Devon Carew 40323dfaaf [deps] rev protobuf, test
Revisions updated by `dart tools/rev_sdk_deps.dart`.

protobuf (https://github.com/dart-lang/protobuf/compare/b7753f6..deda288):
  deda288  2025-05-19  Devon Carew  address a merge issue with the protoc_plugin changelog (dart-lang/protobuf#1002)
  5ed4611  2025-05-19  Devon Carew  shorten the deprecation messages for clone() and copyWith() (dart-lang/protobuf#999)
  4960b92  2025-05-19  Ömer Sinan Ağacan  Switch to pub workspace (dart-lang/protobuf#1001)

test (https://github.com/dart-lang/test/compare/b9c59ea..5ffcb36):
  5ffcb36f  2025-05-19  Danny Tuppeny  Fix an issue with failed assertions using setUpAll/tearDownAll (dart-lang/test#2499)

Change-Id: Idc43e2f2fd9dc38b80917b25b45bb954076dc1c9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/429480
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2025-05-19 14:45:22 -07:00
Ryan Macnak ecfce50b5d [infra] Remove IA32 from dartfuzz, GCC and MSVC testing.
Bug: https://github.com/dart-lang/sdk/issues/49969
Cq-Include-Trybots: luci.dart.try:vm-gcc-linux-try,vm-msvc-windows-try
Change-Id: Idf24c48fee5fc5bb757b49bd8941573822496090
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/429223
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2025-05-19 10:28:00 -07:00
Ryan Macnak 1b1418416c [infra] Stop testing IA32 on benchmark-linux.
Golem no longer runs benchmarks for IA32.

Change-Id: Ia3a84a7d21e7d9d13394cd114760a38fbb36600f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/428160
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
2025-05-12 13:15:45 -07:00
Ryan Macnak aa0a29c966 [infra] More setup for Mac and Windows ASAN.
Change-Id: I7cec0e5823410ee9dea2074c32f2ccb6f0aabceb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/427960
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2025-05-12 10:31:34 -07:00
Paul Berry a757d2af41 Enable sound-flow-analysis for Dart 3.9.
Bug: https://github.com/dart-lang/sdk/issues/60438
Change-Id: I908d4e4a9143142281d8198870f40eba6cf6f67f
Tested: trybots
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/427500
Reviewed-by: Ivan Inozemtsev <iinozemtsev@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Morgan :) <davidmorgan@google.com>
Reviewed-by: Daco Harkes <dacoharkes@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
2025-05-09 14:50:26 -07:00
Sam Rawlins 8a17ad9f05 analyzer: Deprecate AnalysisError in favor of Diagnostic
Work towards https://github.com/dart-lang/sdk/issues/60635

Change-Id: If9bbc96beed95129b099588c5bd9728afda8e392
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/426902
Reviewed-by: Nate Bosch <nbosch@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Bob Nystrom <rnystrom@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
2025-05-08 14:02:16 -07:00
Ryan Macnak 6dc7c6480a [infra] Refactor X64 sanitizer builders to match ARM64.
Add builder definitions for ASAN on Mac and Windows.

Combine reload and reload rollback into one builder.

Change-Id: If464f82d1d8c0560f4e7f1e341f59e5f29301a30
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/427303
Reviewed-by: Alexander Aprelev <aam@google.com>
2025-05-07 14:28:20 -07:00
Ryan Macnak ee16e3625e Rebalance isolate stress testing shards.
Cq-Include-Trybots: luci.dart.try:iso-stress-linux-x64-try,iso-stress-linux-arm64-try
Change-Id: Ie47b15116053870b04ad95eba0efb6f36d7a35cb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/424341
Reviewed-by: Alexander Aprelev <aam@google.com>
2025-05-07 07:49:51 -07:00
Sam Rawlins 7431e885e8 analyzer_testing: Move in the mock packages.
Work towards https://github.com/dart-lang/sdk/issues/55660

Change-Id: Ic789b8347d3bfc71a02af423fbb1a8c58da7b32d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/424921
Reviewed-by: Ivan Inozemtsev <iinozemtsev@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2025-05-06 11:32:22 -07:00
Alexander Markov cce62d31ea [dyn_modules] Enable pkg/dynamic_modules tests in VM/JIT configuration
Change-Id: Ic7d9ed514969eb72066812f442b51129e4d27204
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/426680
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2025-05-05 16:18:30 -07:00
Ryan Macnak 32c11b5686 Extend ARM64 sanitizer coverage.
Cq-Include-Trybots: luci.dart.try:vm-msan-linux-release-arm64-try,vm-asan-linux-release-arm64-try,vm-ubsan-linux-release-arm64-try,vm-tsan-linux-release-arm64-try
Change-Id: I16d5113e49435b168a27fbf8de94bc487006893f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/426541
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2025-05-05 14:53:53 -07:00
Alexander Markov d07c0cdc88 [dyn_modules] Add vm-dyn-linux-debug-x64 builder
Change-Id: I53b631931b600c1c22ee538a70b30b5ec9263d1c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/426520
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2025-05-05 11:28:18 -07:00
Ivan Inozemtsev 29e33b00d0 Reland "watchOS target os"
This is a reland of commit 7ae1d75869

TEST=manual, no watchOS SDK on bots yet.

Original change's description:
> watchOS target os
>
> - add support for --os=watchos | --os=watchos_simulator
> - do not depend on perfetto if dart_support_perfetto is false
> - change the default value for dart_support_perfetto to !is_watchos
>
> To minimize changes and to avoid modifying third-party zlib BUILD file, is_watchos implies is_ios for now.
>
> TEST=manual, no watchOS SDK on bots yet.
>
> Cq-Include-Trybots: luci.dart.try:vm-mac-debug-arm64-try,vm-mac-release-arm64-try
> Change-Id: If2130068ef546162a07a9ba53f94b11ff25fb565
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/415021
> Reviewed-by: Ryan Macnak <rmacnak@google.com>
> Commit-Queue: Ivan Inozemtsev <iinozemtsev@google.com>

Cq-Include-Trybots: luci.dart.try:vm-mac-debug-arm64-try,vm-mac-release-arm64-try
Change-Id: I2b50f7eb4da173627aeb4833b88a08712b278d9f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/425523
Commit-Queue: Ivan Inozemtsev <iinozemtsev@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2025-05-05 06:40:30 -07:00
Martin Kustermann c9e3c3324c [dart2wasm] Allow running dart2wasm tests on safari on Mac
This doesn't add a builder yet, but allows running tests locally on a Mac.

Change-Id: I1e1d1158d7d443df5896a759a669db47b1eb420f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/426461
Reviewed-by: Slava Egorov <vegorov@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
2025-05-05 03:18:29 -07:00
Daco Harkes 245498232c [deps] Roll dart-lang/native
`package:native_assets_cli` has been split up and
`package:native_assets_builder` has been renamed.

Change-Id: Ic9d5c21bb3c7ecf7924fdee6b4281153ad37fac5
Cq-Include-Trybots: luci.dart.try:pkg-linux-debug-try,pkg-linux-release-arm64-try,pkg-linux-release-try,pkg-mac-release-arm64-try,pkg-win-release-arm64-try,pkg-mac-release-try,pkg-win-release-try
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/425504
Reviewed-by: Ivan Inozemtsev <iinozemtsev@google.com>
Commit-Queue: Daco Harkes <dacoharkes@google.com>
2025-05-01 02:18:11 -07:00
Ivan Inozemtsev 4bf9353574 Add myself to OWNERS_INFRA
Change-Id: Ia709f21e49f6bed5bbc3a3af96d4174225866e6b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/425820
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Ivan Inozemtsev <iinozemtsev@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
Auto-Submit: Ivan Inozemtsev <iinozemtsev@google.com>
2025-05-01 00:34:24 -07:00
Sam Rawlins 35e8b9ba0b analyzer: Deprecate ErrorType in favor of new name, DiagnosticType
Change-Id: I552e816de6d526e3476cac9dd3ee2919fc7ec499
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/425720
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Reviewed-by: Kevin Moore <kevmoo@google.com>
2025-04-30 19:07:42 -07:00
Kevin Moore 67a24ea983 [pkg] drop lints already covered by the included lint file
Change-Id: I84fdee27e3e28576187896502e5ffed487ee232f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/425408
Reviewed-by: Moritz Sümmermann <mosum@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Auto-Submit: Kevin Moore <kevmoo@google.com>
Reviewed-by: Tess Strickland <sstrickl@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Kenzie Davisson <kenzieschmoll@google.com>
2025-04-30 11:58:24 -07:00
Alexander Markov c23ed7aabe [lib/web_gl] Workaround to Flutter license script choking on web_gl_dart2js.dart
Flutter license script (which collects various licenses) processes only
the first N number of bytes.

Unfortunately, https://dart-review.googlesource.com/c/sdk/+/424741
increased size of the header in sdk/lib/web_gl/dart2js/web_gl_dart2js.dart
so copyright notice in the middle of the file was cut in half and
no longer recognized by the Flutter license script.

Issue: https://github.com/flutter/flutter/issues/168065
CoreLibraryReviewExempt: comment change
Change-Id: I694066223b7fd4724c4856ce7875d64e870ab723
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/425560
Commit-Queue: Srujan Gaddam <srujzs@google.com>
Reviewed-by: Srujan Gaddam <srujzs@google.com>
Auto-Submit: Alexander Markov <alexmarkov@google.com>
2025-04-30 09:05:11 -07:00
Robert Nystrom e5194dae87 Reformat tools/ and utils/ using the 3.8 style.
Change-Id: I7b28583eb928f60a45d1f476194d197b4df88062
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/425184
Auto-Submit: Bob Nystrom <rnystrom@google.com>
Reviewed-by: Lasse Nielsen <lrn@google.com>
Reviewed-by: Nate Bosch <nbosch@google.com>
Commit-Queue: Nate Bosch <nbosch@google.com>
2025-04-29 10:40:59 -07:00
Ivan Inozemtsev 10c579c7e8 Revert "watchOS target os"
This reverts commit 7ae1d75869.

Reason for revert: breaks flutter build

Original change's description:
> watchOS target os
>
> - add support for --os=watchos | --os=watchos_simulator
> - do not depend on perfetto if dart_support_perfetto is false
> - change the default value for dart_support_perfetto to !is_watchos
>
> To minimize changes and to avoid modifying third-party zlib BUILD file, is_watchos implies is_ios for now.
>
> TEST=manual, no watchOS SDK on bots yet.
>
> Cq-Include-Trybots: luci.dart.try:vm-mac-debug-arm64-try,vm-mac-release-arm64-try
> Change-Id: If2130068ef546162a07a9ba53f94b11ff25fb565
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/415021
> Reviewed-by: Ryan Macnak <rmacnak@google.com>
> Commit-Queue: Ivan Inozemtsev <iinozemtsev@google.com>

Cq-Include-Trybots: luci.dart.try:vm-mac-debug-arm64-try,vm-mac-release-arm64-try
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Change-Id: I4bede9ede04ac3c533b8ff7ae2f1adbd84eb2397
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/425262
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
Auto-Submit: Ivan Inozemtsev <iinozemtsev@google.com>
2025-04-29 03:21:37 -07:00
Ivan Inozemtsev 7ae1d75869 watchOS target os
- add support for --os=watchos | --os=watchos_simulator
- do not depend on perfetto if dart_support_perfetto is false
- change the default value for dart_support_perfetto to !is_watchos

To minimize changes and to avoid modifying third-party zlib BUILD file, is_watchos implies is_ios for now.

TEST=manual, no watchOS SDK on bots yet.

Cq-Include-Trybots: luci.dart.try:vm-mac-debug-arm64-try,vm-mac-release-arm64-try
Change-Id: If2130068ef546162a07a9ba53f94b11ff25fb565
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/415021
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Ivan Inozemtsev <iinozemtsev@google.com>
2025-04-29 02:28:52 -07:00
Michael Thomsen cf717accfb Update deprecation notice for web libraries
Change-Id: I4f6a9619ecf3aba16b215e401aa0fad7d07bd0ac
CoreLibraryReviewExempt: Small tweak to DartDoc only.
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/424741
Reviewed-by: Kevin Moore <kevmoo@google.com>
Reviewed-by: Srujan Gaddam <srujzs@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Michael Thomsen <mit@google.com>
2025-04-28 13:24:29 -07:00
Alexander Aprelev 9a31095181 [build] Introduce 'arch' parameter for stress test script.
Fixes https://ci.chromium.org/ui/p/dart/builders/try/iso-stress-linux-arm64-try/4

Change-Id: Iba64548fb3396a3536e3669992d6c778ae9c90cb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/424700
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Alexander Aprelev <aam@google.com>
2025-04-25 08:46:28 -07:00
Ryan Macnak 8308d6553c Extend isolate stress testing to ARM64.
Cq-Include-Trybots: luci.dart.try:iso-stress-linux-try
Change-Id: Ie0c2a281a4edc570b6532faadf01f06be259fd18
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/400144
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2025-04-23 13:05:53 -07:00
Sam Rawlins 8d62a1f104 Support the analysis server compiled as AOT.
This change adds a build target (see utils/analysis_server/BUILD.gn)
called 'analysis_server_aot'. This new target is _not_ included in the
Dart SDK (the create_sdk target). It's "opt-in" "for development."

The name of the new output file matches that of other snapshots (see
the dartdevc snapshots).

Then we do special work in the plugin manager if "we are AOT." An
analysis server running as AOT cannot spawn Isolates from a dart
source files; we must first compile a dart source file to AOT as well,
then we can spawn an Isolate to that AOT file.

_Then_ when we run pub, we can no longer rely on using
`Platform.executable`. `dartaotruntime pub get` is not a thing. We
must instead find the `dart` tool on disk. To do that, we copy some
complex discovery code from dartdev.

Work towards https://github.com/dart-lang/sdk/issues/53402

Work towards https://github.com/dart-lang/sdk/issues/53576

Work towards https://github.com/dart-lang/sdk/issues/50498

Manually tested:

* [+] analysis_server JIT snapshot works in IDE.
* [+] analysis_server JIT snapshot works in IDE, with a legacy
      plugin (custom_lint).
* [+] analysis_server JIT snapshot works at commandline.
* [+] analysis_server AOT snapshot works in IDE.
* [x] analysis_server AOT snapshot works in IDE, with a legacy
      plugin (custom_lint) - BROKEN. Need similar work that is done
      for new plugins.
* [x] analysis_server AOT snapshot works at commandline - BROKEN.
      I think a fair bit of refactoring is required in dartdev
      lib/src/analysis_server.dart to use `VmInteropHandler.run` or
      similar.

Change-Id: I53173c716fa2a763331ef524a96304f62165810e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/417942
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2025-04-23 11:45:19 -07:00
Vyacheslav Egorov 5f32e78a09 [vm] Fix running under HWASAN
HWASAN tags stack regions (and stack pointers) with 0,
but also selectively tags some stack allocations with
non-zero tags. These tags need to be cleared when
allocation goes out of scope so that stack can be
later safely reused - otherwise stale tags confuse
HWASAN instrumentation later.

This CL teaches Exceptions::JumpToFrame to do that.

CL also adds basic build changes to support building
with HWASAN, though I don't wire it into CI for now
as it can only really run on Android ARM64

TEST=manually on Android phone and on internal tests

Bug: b/374433249
Change-Id: I678443dc1de693c999a226bee0d71a6f3582d4f9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/421180
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Auto-Submit: Slava Egorov <vegorov@google.com>
2025-04-14 10:14:54 -07:00
Ivan Inozemtsev 09f467b557 Update prebuilt Dart SDK to 3.9.0-3.0.dev
Revert changes to experimental_features.yaml.

Change-Id: Ic0ee592d8ceb72cf9c450b8bb898e01e93e6dbdb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/421840
Commit-Queue: Alexander Thomas <athom@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Auto-Submit: Ivan Inozemtsev <iinozemtsev@google.com>
2025-04-10 09:50:11 -07:00
Lasse R.H. Nielsen b2f0b8d083 Accept IPvFuture syntax in Uri.
The RFC 3986 grammar for `[...]` addresses accepts
IPv6 addresses  and IPvFuture addresses, where the latter
have the form `'v' <hexDigit>+ '.' (<unreserved>|<sub-delim>|':')+`.

This allows the IPvFuture syntax, with no interpretation,
as the `host` of a `Uri`.

For now, the `Uri(host: ...)` constructor argument only allows
IPvFuture addresses that are already wrapped in `[...]` brackets,
and the `Uri.host` gette returns IPvFuture addresses including
brackets.
The `Uri(host:...)` still allows unbracketed IPv6 addresses
(distinguished from plain host-names by containing a `:`),
and `Uri.host` returns IPv6 addresses without brackets.
`Uri.parse` only accept IPv6 and IPvFuture in brackets.
(Only IPv6 can have a zone.)

Fixes #60483.

CoreLibraryReviewExempt: Local implementation only, no API.
Bug: https://dartbug.com/60483
Change-Id: Id369ba1316b34f443edfe5b0f56864c32beddccc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/421081
Reviewed-by: Nate Bosch <nbosch@google.com>
Commit-Queue: Lasse Nielsen <lrn@google.com>
2025-04-09 03:56:37 -07:00