Commit Graph

113284 Commits

Author SHA1 Message Date
Ryan Macnak 25a757da3e Reland "[build] Generate AOT snapshots in the SDK as dylibs on Mac."
Also apply code signing like we do for C++ binaries.

Cq-Include-Trybots: luci.dart.try:dart-sdk-mac-try,dart-sdk-mac-arm64-try
Change-Id: If2a379c0cde556ad3198cafc5b53a386bd265197
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504721
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2026-05-20 11:33:39 -07:00
Brian Wilkerson a16de199d7 Convert many lint tests to use markdown
This is a rediculously large CL, and if you want me to split it up I'm
willing to do so.

However, the changes were all made by running a script I wrote and then
running the formatter over the code, so hopefully a spot-check will be
sufficient.

Change-Id: Ifc59b2cc3bf9e4edf0229a130cd587dc73f95615
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/505042
Reviewed-by: Samuel Rawlins <srawlins@google.com>
SLSA-Policy-Verified: SLSA Policy Verification Service <devtools-gerritcodereview-exitgate@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2026-05-20 11:27:11 -07:00
Sam Rawlins 73b76b93b3 DAS: Make more fields final or visibleForTesting
Change-Id: I43812c53605ed722dec7f45377b5d5cfbe6ef443
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504762
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2026-05-20 10:09:44 -07:00
Danny Tuppeny da6eab18cb [analysis_server] Extract custom protocol classes to their own files
No functional changes here, it just extracts definitions of custom protocol classes that are not trivial into their own files.

Change-Id: I0194a3074d280b6423dfae8b5e522ec536ce0dab
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504560
Commit-Queue: Keerti Parthasarathy <keertip@google.com>
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2026-05-20 09:52:18 -07:00
Konstantin Shcheglov 3009984866 CQ. Replace many parseStringWithErrors() with parseTestCodeWithDiagnostics().
Change-Id: Id992c63a83bbb8eb2f2539f8735b72ee1c3a2e39
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504121
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2026-05-20 09:34:54 -07:00
Konstantin Shcheglov 29ca3eb0dd CQ. Remove assertNoErrorsInCode(), use resolveTestCodeWithDiagnostics().
Change-Id: Ifc5591e192ddf48d4c4da3ffb653cc4d0fc26b61
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504300
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2026-05-20 09:26:24 -07:00
Konstantin Shcheglov 39fcaa5d01 Augment. Allow 'static abstract' fields.
Change-Id: I42c4bbb9193c2debd3661898a8c410f76916958a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504720
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2026-05-20 08:49:01 -07:00
Konstantin Shcheglov a07da4d626 Augment. Order AST modifier tokens by the specification.
Update generated AST node metadata and token ordering so child entities,
begin tokens, and reconstructed source follow the grammar order for
modifier tokens.

Place `augment` before declaration modifiers on class type aliases and
the affected top-level and class-level declarations. Order field
modifiers as `augment external static abstract covariant`, and order
named formal parameter modifiers as `required covariant`.

Also emit the missing modifier tokens in `ToSourceVisitor` so source
reconstruction preserves augmentation syntax and the canonical modifier
order.

Change-Id: I57b4aa05f856779526bc3c8d5e3319d8c260bc49
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504682
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2026-05-20 08:41:46 -07:00
Alexander Aprelev 58047e7d94 [vm/native_api] Ensure isolate is not available for duration of native port operations.
Follow-up to 5a98fe5564.

TEST=ci

Change-Id: I62269b713968f0d0e436d86b7d7b481fc5b52cc5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/501620
Commit-Queue: Alexander Aprelev <aam@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2026-05-20 08:40:17 -07:00
Jake Macdonald 82a952f14a Fix casting of List<String> parameters in VM service generator.
Also updates special cased handling of the `scope` parameter to instead work for any Map typed parameter.

Simplified things in general here by casting values to the correct collection type and then relying on `.cast()` to fill in the proper generic types instead of explicitly filling them in.

Change-Id: I7fef91105ca73ee9726780abd76e92817a9e46c0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504780
Commit-Queue: Jake Macdonald <jakemac@google.com>
Auto-Submit: Jake Macdonald <jakemac@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
2026-05-20 08:28:31 -07:00
Ryan Macnak b2911c0bf1 Fix GCC build.
TEST=ci
Bug: https://github.com/dart-lang/sdk/issues/63406
Change-Id: I3bb3963fcc182777c5d2c0e062ae4bbf3c5aae75
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504800
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2026-05-20 08:21:30 -07:00
Sam Rawlins 5f2c7f7ef0 DAS: Replace RequestConverter with extensions
Preliminary work before introducing a 'setAnalysisRoots' request

Also remove inferred types, in the tests. Very old style.

Change-Id: Id4495702419f1e219f758c509fdc617f6d411d54
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504761
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2026-05-20 07:36:29 -07:00
Tess Strickland 2b9e597980 [vm] Fix CanonicalizeHash for TypedData.
Previously, the loop threw away the calculated hash value, so the
finalized hash was only the combined hash from the length plus last
byte.

Fix this, and also use 32-bit chunks as much as possible to reduce the
number of iterations for larger typed data objects.

TEST=ci

Change-Id: I0c033701232f1a1299356cab0b09079f9f86c026
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504980
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Tess Strickland <sstrickl@google.com>
2026-05-20 06:38:42 -07:00
Chloe Stefantsova e7461ea9e7 [cfe] Adjust initializer's parent in ConstantsTransformer
The parent of the initializer is set to the `VariableInitialization`
node, while previously it was set to the corresponding variable. There
is no observable change for the ouptut for the old variables. For the
new variables, the adjustments restores the expected parent relation
and addresses some verification issues.

Part of https://github.com/dart-lang/sdk/issues/61572

Change-Id: Ie81b1a06078867076c4aad42fb213fd09e4a3f73
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504960
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Chloe Stefantsova <cstefantsova@google.com>
2026-05-20 06:22:16 -07:00
Slava Egorov bc16ca4d51 [vm] Preserve ThreadLocal value if dart::Thread is reclaimed
dart::Thread object representing Isolate's mutator can be reclaimed when
thread is suspended, so we need to preserve thread_locals on Isolate
itself.

TEST=vm/dart/thread_local_test

Fixes https://github.com/dart-lang/sdk/issues/63408

Change-Id: I7502b9bc67a07fb2e82479d3052740516a6a6964
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504921
Commit-Queue: Slava Egorov <vegorov@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
2026-05-20 06:21:29 -07:00
Chloe Stefantsova cbb94bc140 [cfe] Add SourceLoader.isClosureContextLoweringEnabled
This is a follow-up to
https://dart-review.googlesource.com/c/sdk/+/497240/comment/275b2e79_902b4da9/

Part of https://github.com/dart-lang/sdk/issues/61572

Change-Id: I476d3ed9a5e02bc639c5848c064d89ee0d4f742e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504520
Commit-Queue: Chloe Stefantsova <cstefantsova@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2026-05-20 06:07:28 -07:00
Tess Strickland 58e0b77bd6 [vm,dyn_modules] Fix source reports for enhanced enums with bytecode.
Coverage information for enhanced enums should not include initializer
functions for enum elements or the values field, so skip over these when
the enum is defined in bytecode.

TEST=vm/cc/SourceReport_Coverage_IssueCov386_EnhancedEnums

Cq-Include-Trybots: luci.dart.try:vm-dyn-linux-debug-x64-try,vm-aot-dyn-linux-debug-x64-try,vm-aot-dyn-linux-product-x64-try
Change-Id: I1dba3c87fdfcc39762bba5f0c35cfd061ec76371
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504240
Commit-Queue: Tess Strickland <sstrickl@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2026-05-20 06:04:16 -07:00
Martin Kustermann 84704290ab [vm] Change various external FFI declarations from Object to Object?
The C side can return any object, including `null`, we should therefore
change those declarations to return top type / `Object?`.

Issue https://github.com/dart-lang/sdk/issues/63411

TEST=https://dartbug.com/63411

CoreLibraryReviewExempt: Internal only changes
Change-Id: I6478e39113fba5d422059de62b88fe738ddbfc05
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504920
Commit-Queue: Martin Kustermann <kustermann@google.com>
Reviewed-by: Slava Egorov <vegorov@google.com>
2026-05-20 02:28:18 -07:00
Simon Binder 58f9d88fb2 [dart2wasm, standalone] Migrate String
This migrates the `String` implementation from using JS interop to
explicit host imports for the standalone target.

This moves a few helper methods shared between the JS and standalone
targets to `dart:_string_helper`. This also moves the embedder regexp
implementation to `dart:_string` to be able to access internals in some
string methods (similar to how the JS implementation special-cases
`JSSyntaxRegExp`).

This removes the final real use of JS-interop in the standalone target.
So, we can:

 - Remove internal JS helper libraries from the target.
 - Skip JS-interop transformations in the compiler.
 - Stop emitting a helper module and support script.

Because `js_interop` is imported in `dart:_wasm`, we can't remove the
library entirely. This replaces it with a stub to avoid compilation
errors, a proper removal is tracked in dartbug.com/63166.

Change-Id: Ide495c210c3a272438deebf8fe4f3f44ba314ffa
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/501960
Reviewed-by: Martin Kustermann <kustermann@google.com>
Reviewed-by: Kevin Moore <kevmoo@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
2026-05-20 00:22:27 -07:00
Sam Rawlins 3de2ddee09 Reapply "Switch on building devtools from source when building the Dart SDK"
This reverts commit 2a93a26d91, which a change to use `defined` so that the GN script does not crash in
Flutter.

Fixes flutter/devtools#9786

See go/moving-devtools-to-dart-sdk-2025.

In this change, we make the source of devtools be configurable, in
actions like build_sdk.

If `build_devtools_from_sources` is true, we build local devtools,
and if false, we continue to use the prebuilt sources.

This may be an intermediate step, while we test out building devtools
from source. Or it may be permanently be a choice, if we keep building
with CIPD.

Change-Id: I9d509b07971942f2c4884224a6efda9001522bd4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/502120
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2026-05-19 20:55:22 -07:00
Kallen Tu efd30a2de0 [migrate] Initial implementation of SDK constraint bumping.
Uses the pubspec util `computeVersionBumpEdit` that bumps the pubspec
file's `sdk:` one minor version up.

Very basic iteration through the given pubspec files to bump all of
them. We'll very likely have to refactor this as we get the pre/post
migrations involved, but I wanted to get there in small (reviewable)
steps.

Bug: https://github.com/dart-lang/sdk/issues/63268
Change-Id: I2a7abeacdc76b114dfef7888cd6db6bc8973d01a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504381
Commit-Queue: Kallen Tu <kallentu@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2026-05-19 14:11:50 -07:00
Danny Tuppeny 0888111999 [analysis_server] Add protocol classes for new interactive forms
Change-Id: Iefb251c2a4982bf4118430e0f2885f248e1b5a57
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504540
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Commit-Queue: Keerti Parthasarathy <keertip@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2026-05-19 12:23:39 -07:00
Danny Tuppeny ddeb964d80 [analysis_server] Handle some reserved names ("default", "new") in LSP codegen
Both of these names are used in the JSON in the Go-spec'd refactoring support, so we need to map them to new names.

We had some existing code for mapping some kinds of names (like enums), but not for JSON fields in interface classes.

See https://github.com/dart-lang/sdk/issues/63371

Change-Id: Ic223a783be9170774444844bb1934a3733ddf446
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504261
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Commit-Queue: Keerti Parthasarathy <keertip@google.com>
2026-05-19 12:12:02 -07:00
pq 04c6612781 [analytics] propagate analytics environment variables to subtools
Updates the main `dartdev` command runner to read and propagate the unified analytics environment variables (`DASH__SUPPRESS_ANALYTICS` and `DASH__TOOL`) to all spawned isolates and child processes using the handy new `VmInteropHandler.setEnvironmentVariable` support (see: https://dart-review.googlesource.com/c/sdk/+/499300).

Fixes: https://github.com/dart-lang/sdk/issues/62876



Change-Id: Iae68790a2cf861dd01edbea81f9faf7d7529f5f2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504321
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2026-05-19 11:57:42 -07:00
Ryan Macnak 039aef728a [standalone] Remove the fallback root certificates.
The discovery of the system root certificates is more robust after 2142d8e148.

TEST=ci
Change-Id: I8215cb92f98e620b82f21261c13e061a2b488b5d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/433923
Reviewed-by: Slava Egorov <vegorov@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2026-05-19 11:20:48 -07:00
Ryan Macnak 1b850ae2be Revert "[build] Generate AOT snapshots in the SDK as dylibs on Mac."
This reverts commit 7cc84b94b3.

Reason for revert: fail to launch, need to setup code signing

Original change's description:
> [build] Generate AOT snapshots in the SDK as dylibs on Mac.
>
> Change-Id: I95efe7342e595b44bfce1a15229b926a721aea82
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/499480
> Reviewed-by: Alexander Markov <alexmarkov@google.com>
> Commit-Queue: Ryan Macnak <rmacnak@google.com>

Change-Id: I4a2742ddc4a39166ea4b642ee12661a8217e7417
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504681
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
2026-05-19 11:10:25 -07:00
Nicholas Shahan 68a3d4e688 [ddc] Allow blocks to appear in scope offset test
With the addition of the const constructors in extension types there
are now blocks appearing in SDK outline .dills.

The missing file offsets were added in
https://dart-review.googlesource.com/c/sdk/+/497842.

Fixes: https://github.com/dart-lang/sdk/issues/63226
Change-Id: I7e40578927008f39c54366f39bef300dbcb45e27
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504400
Reviewed-by: Nate Biggs <natebiggs@google.com>
Commit-Queue: Nicholas Shahan <nshahan@google.com>
Auto-Submit: Nicholas Shahan <nshahan@google.com>
Commit-Queue: Nate Biggs <natebiggs@google.com>
2026-05-19 10:26:05 -07:00
Nate Biggs db2d7531f3 Update chrome, firefox, d8, jsc, and jsshell versions.
Change-Id: I139bf9985bf447e9c6abd09024fb80e8b6b7f625
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504660
Reviewed-by: Nicholas Shahan <nshahan@google.com>
Commit-Queue: Nate Biggs <natebiggs@google.com>
2026-05-19 10:12:11 -07:00
Konstantin Shcheglov eba2982bc8 Augment. Report augmentationInducedGetterReturnTypeMismatch.
Report a dedicated diagnostic when an augmenting field or top-level
variable induces a getter whose return type differs from the getter
being augmented.

Previously, augmentation return type checking only covered executable
declarations with explicit return type annotations. Variable
augmentations that induced getters could therefore miss this mismatch,
or would not describe the induced getter case directly.

Add the new diagnostic code and use it for getter fragments induced by
variables. Keep the existing augmentation return type mismatch
diagnostic for methods and explicitly declared getters, and report the
induced getter diagnostic on the variable name so that mismatches in
multi-variable declarations are attributed to the specific variable.

Change-Id: Ifb421112d659815070110834702f68616e360a10
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504181
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2026-05-19 09:48:27 -07:00
dart-autoroll@skia-public.iam.gserviceaccount.com 416ce754cb Roll Fuchsia Test Scripts from R2EllDf4DgBXVNuiN... to dQ4PjIJB5kZFU8Y32...
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/fuchsia-test-scripts-dart-sdk
Please CC fuchsia-3p-engprod@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Fuchsia Test Scripts: https://bugs.fuchsia.dev/p/fuchsia/issues/list
To file a bug in Dart SDK: https://github.com/dart-lang/sdk/issues

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Cq-Include-Trybots: luci.dart.try:vm-fuchsia-release-x64-try;luci.dart.try:vm-fuchsia-release-arm64-try
Change-Id: Ia383ffdacc942b074e3c78c43a778b5003104d46
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/496204
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Zijie He <zijiehe@google.com>
Commit-Queue: Zijie He <zijiehe@google.com>
2026-05-19 09:13:46 -07:00
Ryan Macnak 6a9b9b331c [vm, compiler] Fix calculation to find the beginning of the FFI callback stub on ARM32.
TEST=ci
Bug: https://github.com/dart-lang/sdk/issues/63402
Change-Id: I4aff8d6dca9aa71fd68275fd495b7dba2e119df5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504401
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2026-05-19 09:06:20 -07:00
Keerti Parthasarathy c4ce9dbdfd Add a skill for finding obsolete issues in the Analysis Server open issues.
This is an initial commit. Plan to add
- if repro is available, agent to test it out
- add failing tests where possible


Change-Id: I35c63a0e4183b7609643fb7d851f1b25a2025c74
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/503623
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Keerti Parthasarathy <keertip@google.com>
2026-05-19 08:06:14 -07:00
Sigurd Meldgaard e1c29b6381 Bump pub to ec276d10a7fa0f6c6ec005340fb9ad29f3b012d0
Changes:
```
> git log --format="%C(auto) %h %s" 7440821..ec276d1
 https://dart.googlesource.com/pub.git/+/ec276d10 Remove unintended `-v` flag from binstub template (4821)
 https://dart.googlesource.com/pub.git/+/d5fca3ae Quiet warning instead of stack trace when failing to parse advisories (4817)
 https://dart.googlesource.com/pub.git/+/b5263b3f Separate state for sources (4811)
 https://dart.googlesource.com/pub.git/+/764c4b3e add: when no descriptor given, use descriptor from existing resolution if present (4801)
 https://dart.googlesource.com/pub.git/+/1bceb7ac Bump test from 1.29.0 to 1.31.0 (4799)
 https://dart.googlesource.com/pub.git/+/64f18711 Add dependency constraints natively to `pub deps --json` (4797)
 https://dart.googlesource.com/pub.git/+/5ebb0f11 `outdated` Include replacement text in --json output (4793)
 https://dart.googlesource.com/pub.git/+/c5275713 Avoid flaky replacements when filtering for goldens (4794)
 https://dart.googlesource.com/pub.git/+/2dda3a3e Bump analyzer from 10.0.2 to 10.2.0 (4777)
 https://dart.googlesource.com/pub.git/+/03d73494 Bump source_span from 1.10.1 to 1.10.2 (4753)
 https://dart.googlesource.com/pub.git/+/1ec99bf1 Bump checks from 0.3.0 to 0.3.1 (4618)
 https://dart.googlesource.com/pub.git/+/b00da1e0 Use kernel to compile tests (4795)
 https://dart.googlesource.com/pub.git/+/7bd9ac74 Don't download via the cache in `pub unpack` (4785)
 https://dart.googlesource.com/pub.git/+/72d16f60 Support safe.bareRepository=explicit (4776)

```

Diff: https://dart.googlesource.com/pub.git/+/74408212b5348003381bc63f3b59274aaa23cfa3..ec276d10a7fa0f6c6ec005340fb9ad29f3b012d0/
Change-Id: I4682a8de2bdb2bec8cfabe9e64957bba90ccc2e1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504640
Commit-Queue: Jonas Jensen <jonasfj@google.com>
Reviewed-by: Jonas Jensen <jonasfj@google.com>
Auto-Submit: Sigurd Meldgaard <sigurdm@google.com>
2026-05-19 07:54:41 -07:00
Ryan Macnak a8419fb546 [build] Fix building the Debian package on Resolute.
dpkg-buildpackage now wants a timestamp in the changelog.

Also remove --git-revision-file and --git-timestamp-file, which were part of the previous way to build Debian packages.

Change-Id: Idbcf418571889ad7588424e6d8ae6e81ec79942b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504280
Reviewed-by: Ivan Inozemtsev <iinozemtsev@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2026-05-19 07:18:47 -07:00
Ryan Macnak 6613ac694e [infra] Fix wasted parent machine time on vm-mac-{debug,release}-arm64.
A test shard will run on the parent only if the tests are the last step.

Change-Id: Ib251abe84c631330432b1cdd75897cb0f540a6fc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504281
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Ivan Inozemtsev <iinozemtsev@google.com>
2026-05-19 07:17:52 -07:00
Chloe Stefantsova 10dd51ee4c [cfe] Verify new variables have contexts
Part of https://github.com/dart-lang/sdk/issues/61572

Change-Id: I01295904c8fd5f76574e8979eb40e4cd174f9e09
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504202
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Chloe Stefantsova <cstefantsova@google.com>
2026-05-19 04:29:29 -07:00
Tess Strickland 52cfd29cbb [vm,dynamic_modules] Add RecordCoverage instruction.
The RecordCoverage instruction has an A/E encoding. The A argument
is the type of coverage being recorded, whereas the E argument is
the logical index into the coverage array for updating whether that
source position has been hit.

Also adds new metadata to the bytecode component for the coverage
arrays associated with bytecode containing RecordCoverage instructions
and a new runtime entry for lazily allocate the coverage array for
an interpreted function when needed.

The type of coverage is encoded in the RecordCoverage instruction,
despite being redundant with the information in the coverage array, so that checking whether that type of coverage is currently enabled at
runtime doesn't require either accessing the coverage array (which may
be lazily allocated), forcing allocation of the coverage array just to
discover that type of coverage is currently disabled, or reading the
serialized bytecode component to avoid that forced allocation.

------

Other changes:

Source reporting now treats unexecuted interpreted functions when
not forcing compilation as if they were uncompiled native functions,
so that the source report from running the same code gives the same
result whether using the interpreter or the native compiler.

Bytecode closures are no longer skipped in source reports. Previously
any closure without a context scope was skipped, but bytecode closures
don't have those.

TEST=vm/cc/SourceReport_Coverage

Cq-Include-Trybots: luci.dart.try:vm-dyn-linux-debug-x64-try,vm-aot-dyn-linux-debug-x64-try,vm-aot-dyn-linux-product-x64-try
Change-Id: I7557e5dd4c98331c7ca2f5c867dd5f6d03e9d756
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/501520
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2026-05-19 04:27:39 -07:00
dependabot[bot] d2b5c1a81e Bump the github-actions group with 2 updates
Closes https://github.com/dart-lang/sdk/pull/63297

GitOrigin-RevId: ad81d11f023ab9dd49b7a67f893631372c29e723
Change-Id: Ib6059e1bb9e73ba0b49d31306f66de8c1892a1a6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/499900
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
2026-05-18 23:59:33 -07:00
Sam Rawlins dffae54f02 linter: Treat index assignment as setter in many lint rules
Work towards https://github.com/dart-lang/sdk/issues/62621

Change-Id: Ic8669042da9b159698849a627f84a050751ffdcf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504000
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2026-05-18 19:44:41 -07:00
Konstantin Shcheglov 76011f9fe0 Augment. Report augmentationWithoutGetterDeclaration or augmentationWithoutSetterDeclaration.
Add diagnostics for augmenting fields and top-level variables when the
augmentation induces an accessor that has no corresponding declaration
to augment.

Report these errors on each variable name rather than on the augment
keyword, so multi-variable declarations can report missing augmentation
targets independently. Include context pointing to the matching declared
or induced accessor when only one side of the getter/setter pair exists.

Register the getter- and setter-specific diagnostics in the generated
diagnostic tables and correction status metadata.

Change-Id: I78393a6e8bffe8748eb0fbc5182a0d01770771d8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504180
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2026-05-18 18:42:53 -07:00
dart-autoroll@skia-public.iam.gserviceaccount.com 86aa98d815 Roll BoringSSL from d03dbc3e5d7d to f92821595453 (3 revisions)
https://boringssl.googlesource.com/boringssl.git/+log/d03dbc3e5d7d..f92821595453

2026-05-14 xfding@google.com crypto/evp: Eliminate `operator delete` from EVP_PKEY_CTX destructor
2026-05-13 davidben@google.com Correctly handle max_early_data_size over 2^16
2026-05-13 chlily@google.com Alert on ClientHello with only one of key_share and supported_groups

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/boringssl-dart-sdk
Please CC dart-engprod@google.com,dart-vm-gardener@rotations.google.com,dart-vm-team@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in BoringSSL: https://crbug.com/boringssl/new
To file a bug in Dart SDK: https://github.com/dart-lang/sdk/issues

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Tbr: dart-vm-gardener@rotations.google.com
Change-Id: I5e748b03597a3a48f1d4c1749200d01b5d8a8347
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/503640
Reviewed-by: Liam Appelbe <liama@google.com>
Reviewed-by: Brian Quinlan <bquinlan@google.com>
Commit-Queue: Liam Appelbe <liama@google.com>
2026-05-18 18:23:24 -07:00
Kallen Tu 7ca32bdbbf [migrate] Refactor version bumping from update_sdk_constraints to a util file.
This is a prerequisite CL to the next one that will add version bumping
to the dart migrate tool: https://dart-review.googlesource.com/c/sdk/+/504381

Refactoring the version bumping logic out of `update_sdk_constraints` so
it can be shared between the correction producer and the migrate tool.

`PubspecEdit` also contains the old and new versions so the migrate tool
can refer to those in its summary text.

Bug: https://github.com/dart-lang/sdk/issues/63268
Change-Id: I488cf10694b89df1ed770ee0f27f13a00d1dd3be
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504340
Commit-Queue: Kallen Tu <kallentu@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2026-05-18 14:40:27 -07:00
Ryan Macnak d36adbacaf [vm] Remove the VM isolate.
The former contents of the VM isolate are now included into each isolate group. This makes each isolate group's heap independent, and in particular allows each heap to be allocated to a separate pointer cage (not done in this CL).

The duplicated stubs that allowed PC relative calls are removed, since the originals can now be the target of PC relative calls.

The bootstrapping needing to load an AppJIT or AppAOT snapshot is reduced to allocating the oddballs. The code is entirely dropped in the AOT runtime, but the JIT runtime still has it to allow for flags to affect the compilation of the stub code. Further refactoring might be able to remove this for the JIT runtime too, with only gen_snapshot knowing how to bootstrap.

Class serialization no longer distinguishes predefined classes.

The page containing null is marked as never-evacuate. null, false and true must not move because the compiler relies on their low bits having certain patterns for some optimizations. (Previously, the entire VM isolate heap never moved.)

Compaction is disabled for IA32. Due to register pressure, some stub calls must not use a scratch register and embed the address of Code.

The page containing the call-through-safepoint stub is frozen when running with --write-protect-code and the stub is created at runtime (instead of loaded from an AppJIT or AppAOT snapshot). This stub must remain executable even during a safepoint, as a foreign call might during return during a safepoint and only block after the stub directs it to the runtime.

The snapshot symbols are renamed to kDartSnapshotData and kDartSnapshotText. There is no need to distinguish the VM isolate's snapshot, and snaphots are per isolate group not per isolate. Aliases with the old names are added to ease migration.

Some global flags that were automatically set based on the VM isolate's snapshot are now isolate group flags and automatically set by the isolate group's snapshot.

TEST=ci
Change-Id: Iee82016057d609112e9b021d178fc3d4d18b5044
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/500621
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Tess Strickland <sstrickl@google.com>
SLSA-Policy-Verified: SLSA Policy Verification Service <devtools-gerritcodereview-exitgate@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2026-05-18 11:35:03 -07:00
Alexander Markov ca9c12f1b6 [modular_aot] Support more cases of parallel moves and double immediates
Issue: https://github.com/dart-lang/sdk/issues/61635
Change-Id: I8b167ea819d4247ca748f5200b5509e99a68d56e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/503560
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Slava Egorov <vegorov@google.com>
2026-05-18 10:10:21 -07:00
Kallen Tu 2edcad4892 [tests] Primary constructors: Format and generate errors for all tests.
Cleaned up and formatted the tests, regenerated some errors where they were "unspecified", and removed the experiment flag enabling in each test.

Bug: https://github.com/dart-lang/sdk/issues/61687
Change-Id: Ic5b652af660cbc4f71731b1547c7a58c7726faca
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/503500
Reviewed-by: Erik Ernst <eernst@google.com>
Commit-Queue: Kallen Tu <kallentu@google.com>
2026-05-18 10:00:37 -07:00
Adil Burak Şen a93e065e54 fix: prevent path traversal in sourceMapViewer /file endpoint
Closes https://github.com/dart-lang/sdk/pull/63389

GitOrigin-RevId: 882cfd8dcdbd2d615bd0f7da40d3d83105924fbc
Change-Id: If510820433729765a09c9784f0364bbb52e703c8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504020
Reviewed-by: Nate Biggs <natebiggs@google.com>
Commit-Queue: Nate Biggs <natebiggs@google.com>
2026-05-18 08:42:05 -07:00
Danny Tuppeny 9a48747a61 [analysis_server] Fix hover on enum constant declaration
Fixes https://github.com/dart-lang/sdk/issues/63223

Change-Id: I42c75520ce11932bd1c894783cbfc27ac3c8ebd2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504260
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Keerti Parthasarathy <keertip@google.com>
2026-05-18 08:37:16 -07:00
Konstantin Shcheglov 57eb6d720c CQ. Migrate resolution tests to resolveTestCodeWithDiagnostics. NY.
Change-Id: I715ca29fa7110a2094dca16ce57e8687c392f49f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504080
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2026-05-18 08:28:13 -07:00
Konstantin Shcheglov 8a7276fb4d CQ. Migrate resolution tests to resolveTestCodeWithDiagnostics. CD.
Change-Id: I621af89bafde3fc8b3e492482cfe33ece11ad844
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/503702
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2026-05-18 08:27:45 -07:00
Konstantin Shcheglov 948e52a768 Augment. Build accessors induced by variable augmentations.
Property-inducing augmentations were linked to the existing field or
top-level variable element before creating the getter and setter
fragments that the augmentation itself induces. This left augmentation
fragments without their corresponding accessor fragments.

Create induced getter and setter fragments for every field and top-level
variable fragment, including augmentations. When an accessor element
already exists, append the new fragment to it; otherwise, create the
accessor element independently so that augmenting getter-only and
setter-only properties works correctly.

Track the relationship at the fragment level in both directions, from
each property-inducing fragment to its induced accessors and from each
accessor fragment back to its inducing variable. Serialize these links
in summaries, expose them through the analyzer element API, and bump the
summary data version for the format change.

Change-Id: Iede43515564326182d8195bd872abf83345bbd72
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/504040
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2026-05-18 08:20:07 -07:00