This PR adds flags to enable LFS to make 32-bit builds to correctly handle 64-bit inode from the ext4/xfs file systems.
Specifically, many APIs internally uses `readdir()` for listing directory, which may crash with an `EOVERFLOW`, `Value too large for defined data type`.
See https://bugs.gentoo.org/681790#c0 for some background about this issue.
Closes https://github.com/dart-lang/sdk/pull/49179
GitOrigin-RevId: 34ff2282635ffd50cb8e5dffe57601bb0b2b18f7
Change-Id: Idd10d215f0791242fff986c18decc443609f471e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247245
Commit-Queue: Brian Quinlan <bquinlan@google.com>
Reviewed-by: Brian Quinlan <bquinlan@google.com>
- Pass options to all DataSourceReader and DataSinkWriter constructor calls.
- Add DataAndIndices to replace ClosedWorldAndIndices. Maintains the same indices as before for now.
Change-Id: I2e25d4a4c25ef12276fa808146ff8aae27da792c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247401
Reviewed-by: Joshua Litt <joshualitt@google.com>
Commit-Queue: Nate Biggs <natebiggs@google.com>
This repurposes an existing lint CorrectionProducer to handle both
the lint and the hint.
Bug: https://github.com/dart-lang/sdk/issues/49074
Change-Id: Iacd597ca2151cdb80be9ddae0847128b4cc700a3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/246989
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Janice Collins <jcollins@google.com>
``` before
$ dart isolate_exit_pause_time_test.dart
.Min(RunTimeRaw): 0.001 ms.
.Avg(RunTimeRaw): 212.399592 ms.
.Percentile50(RunTimeRaw): 49.055 ms.
.Percentile90(RunTimeRaw): 809.049 ms.
.Percentile95(RunTimeRaw): 1009.049 ms.
.Percentile99(RunTimeRaw): 1169.049 ms.
.Max(RunTimeRaw): 1208.049 ms.
```
``` after
$ dart isolate_exit_pause_time_test.dart
.Min(RunTimeRaw): 0.001 ms.
.Avg(RunTimeRaw): 53.87510125 ms.
.Percentile50(RunTimeRaw): 8.05 ms.
.Percentile90(RunTimeRaw): 174.005 ms.
.Percentile95(RunTimeRaw): 217.975 ms.
.Percentile99(RunTimeRaw): 275.033 ms.
.Max(RunTimeRaw): 314.033 ms.
```
Remaining latency after the change is due to large root set formed by pointers_to_verify_at_exit_ that have to be visited during GC.
Fixes https://github.com/dart-lang/sdk/issues/49050
TEST=ci
Change-Id: I1ed7af017f80890900b137a1514e5ffdeb63f53f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/246482
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Alexander Aprelev <aam@google.com>
This setting is already supported in VS Code but accidentally stopped working in the switch to LSP. This change prevents/removes the registration for willRenameFiles so that a client won't call the server when files are renamed if this setting is `false`.
Change-Id: Ia7b22b9fc2f119d0e7f98f4e2c5f0bac994a28af
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247544
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Dependabot doesn't update those, so it's better to remove them than keep
the stale comment. Use `git blame` to see the version number in the
upgrade CL instead.
Change-Id: I1b071db4c62154784bcdc7b4ab41f7ef95363c1f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247547
Reviewed-by: William Hesse <whesse@google.com>
This ensures the TFA doesn't tree shake Function members.
Change-Id: I23374d1bb9aec118906e2b8211d987046a3bbafb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247502
Commit-Queue: Joshua Litt <joshualitt@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Previously, Organise Imports always failed silently (since it was often run on-save). Sort Members had not been given the same treatment (but often now runs on-save).
This uses a new LSP 3.17 field to know when the command was run automatically, so both are now consistent, showing errors if invoked manually and failing silently if run automatically.
Change-Id: I48e8380fcee4e54d0f4dc3c177c9ae2362627efb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247542
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Renaming a folder with files that referenced each other would fail with edit conflicts. The pass over the first file would update the reference to the other (going from "a.dart" to "../old/a.dart" as if the other file wasn't moving too) and then then when processing the second file, it would try to update the import back.
It doesn't seem to ever make sense to update relative paths when the "other" file is also in the folder being renamed, so this skips them.
Change-Id: I14c09977aa66017eecac5922d0e3caacf59350fb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247541
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
This reverts commit abfdc3d50f.
Reason for revert: breaks on internal roll - b/235267735 and others can be fixed in advance of landing this
Original change's description:
> Remove SCREAMING dart:io networking APIs
>
> Bug: https://github.com/dart-lang/sdk/issues/49140
> Change-Id: I50c6cca26597ee4d469b776fcec412ddfed760e1
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/246962
> Reviewed-by: Paul Berry <paulberry@google.com>
> Commit-Queue: Michael Thomsen <mit@google.com>
TBR=mit@google.com,paulberry@google.com
Change-Id: I55a43cc1bd7435fe7824f7ca8098575232fdcf2f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: https://github.com/dart-lang/sdk/issues/49140
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247389
Commit-Queue: Oleh Prypin <oprypin@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Reviewed-by: Oleh Prypin <oprypin@google.com>
This gives starting or finalizing concurrent marking a chance to run not-immediately-after-a-scavenge.
TEST=ci
Change-Id: Iec1ba7b7440045cc18e01637af1f865d588b24c2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/246163
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
This change also modifies the Dart Analysis Server to default to use the LSP protocol
Change-Id: I73a1ceae9a05bc8e5af219e4f28df959c054d4c9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247461
Commit-Queue: Jaime Wren <jwren@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Following up on #49164 this PR allows rename in extensions via `dart fix`
Closes https://github.com/dart-lang/sdk/pull/49200
GitOrigin-RevId: a5af8d05f4d9bf849e8115cc780b17bce18d0d50
Change-Id: I845848901768ff48746a0438b009f631c5d03a7e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247460
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
A benchmark should be in a directory with the same name as
the benchmark main file.
Bug: https://github.com/dart-lang/sdk/issues/49050
Change-Id: I31c0a9f276d313ab43d61be8ac3833b77ae8ee47
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247387
Commit-Queue: Alexander Aprelev <aam@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
Auto-Submit: William Hesse <whesse@google.com>
The migration tool has logic to suppress some of its heuristics for
suggesting `required` in redirecting factory constructors, to account
for the fact that a redirecting factory constructor is allowed to have
a non-required non-nullable argument with no default. But that logic
was overzealous and was preventing `@required` from being turned into
`required` (which is clearly still a good idea). This pattern crops
up frequently in classes using BuiltValue.
Bug: https://b.corp.google.com/issues/234631651
Change-Id: Ic0428a878184bb837d3f5b79cb6585ec4fa30344
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247361
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
This makes it easier to extend commands in future (for example adding additional args to indicate if the command execution was automatic on-save or manually invoked, to adjust error handling).
Change-Id: I274f28109ebc0d93ed555525b4c8d1ee689b2af1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247385
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
My previous CL had a mistake - we need to unload all libraries
because we might have resynthesized some of them only to link the
requested library, but we might not need these libraries anymore.
Also includes one more test that demonstrates that we can later access
some data of a linked library without resynthesizing an imported
library (that was used for during linking).
Change-Id: I60fd880a901dacefd386d8eb8304817c14c7faf2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247334
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Let me know if there are other values you can think of related to
requests that ought to be captured, especially in LSP.
Change-Id: Id9e92f54dd9ade3541d3ca8dc11450fb6affee0b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247328
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Danny Tuppeny <danny@tuppeny.com>
The sample wasn't working for the longest time.
Fixes:
- Null safety, and late fields.
- `dart pub` instead of `pub`.
- Use the new `NativeFinalizer` and `Finalizable` features.
Change-Id: I0a397abae511ab3f6762d1b2c4047226d15e36d6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/143804
Commit-Queue: Daco Harkes <dacoharkes@google.com>
Reviewed-by: Michael Thomsen <mit@google.com>
The front-end variable initialization analysis considers a variable
definitely initialized if it's initialized in all `case` branches of an
"explicitly exhaustive" `switch` statement, i.e. a `switch` statement switching on an enum value where the `case` branches cover all variants
of the enum.
In order for the emitted Wasm code to validate according to the
flow-sensitive non-nullable locals validation scheme being discussed in
https://github.com/WebAssembly/function-references/issues/44 this
definite initialization must be reflected in the static control flow of
the Wasm code. Thus, such a switch statement must not have static
control flow exiting the switch statement through the (dynamically
unreachable) default case.
Change-Id: I53628d2c6e9690214ffb4c60498c4f2b895f33e7
Cq-Include-Trybots: luci.dart.try:dart2wasm-linux-x64-d8-try
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/245985
Reviewed-by: Ömer Ağacan <omersa@google.com>
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Tested: Added flag to text output and updated expectation files
Change-Id: I44bb82242ad608b19894e22c41d8404c5003c2d1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/245982
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Late fields start out holding a sentinel value and after they are initialized or assigned, never hold a sentinel value again.
This CL implements some removal of checks and loads based on this monotonic behaviour.
On two large Dart Angular apps, this reduces the number of late-instance-field checks by ~25%.
One app is 0.44% smaller, the other is 0.98% smaller.
The optimization_test.dart no longer forces `--disable-inlining` because that prevents the inlining that exposes the optimization opportunities.
Most tests already use `@pragma('dart2js:noInline')` to prevent inlining where relevant.
Change-Id: I2327a96e69191313ed6c07eabe94aa2962fb2648
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/246881
Reviewed-by: Joshua Litt <joshualitt@google.com>
Commit-Queue: Stephen Adams <sra@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Ensures that kernel dump info doesn't break the original dump info's behavior.
Change-Id: I9bfe22cea0d1a5597db9c98fe736f20369b80c82
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247122
Reviewed-by: Joshua Litt <joshualitt@google.com>
Commit-Queue: Mark Zhou <markzipan@google.com>
1. We cannot just discard the LibraryContext instance, if there are
linked bundles loaded, we need to release them, otherwise the
byte store will keep it forever.
2. But we don't want to release them if there is a chance that there
are no other isolates that reference it. So, we release after reload.
Change-Id: I92e01b57e83466d4679718e23eebcbfdc70d5602
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247330
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>