commit | 97164b3a017122a111151417b1184b2f31fb89f6 | [log] [tgz] |
---|---|---|
author | Alexander Markov <alexmarkov@google.com> | Fri Feb 09 14:59:40 2024 +0000 |
committer | Commit Queue <dart-scoped@luci-project-accounts.iam.gserviceaccount.com> | Fri Feb 09 14:59:40 2024 +0000 |
tree | 0226f4db553fe9e9189854f205c9a5fb0c63ff62 | |
parent | e7e681264ab584812ff66bb69a1c3a4370f1d3d5 [diff] |
[vm/jit] Disable field guards for late fields Late field inialization stubs don't update field guard state which causes incorrect optimizations when they rely on that state. This change disables field guards for late fields in order to fix this bug. As an alternative, we could have added the code to update field guard state from late field initialization stubs. However, it would require duplicating and generalizing a lot of code used to implement GuardFieldClass, GuardFieldLength and GuardFieldType instructions. At the moment it is not clear if field guards provide sufficient performance improvements to justify this. Another possible approach would be to outline initializing field stores from the stubs back to the application code but that would cause either substantial increase in AOT code size or an undesired discrenacy between JIT and AOT. TEST=runtime/tests/vm/dart/regress_flutter142532_test.dart Fixes https://github.com/flutter/flutter/issues/142532 Change-Id: I15e737aa5d1b73e71e0cb935580a3b9a2dcbb77a Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/350985 Commit-Queue: Alexander Markov <alexmarkov@google.com> Reviewed-by: Slava Egorov <vegorov@google.com> Reviewed-by: Martin Kustermann <kustermann@google.com>
Dart is:
Approachable: Develop with a strongly typed programming language that is consistent, concise, and offers modern language features like null safety and patterns.
Portable: Compile to ARM, x64, or RISC-V machine code for mobile, desktop, and backend. Compile to JavaScript or WebAssembly for the web.
Productive: Make changes iteratively: use hot reload to see the result instantly in your running app. Diagnose app issues using DevTools.
Dart's flexible compiler technology lets you run Dart code in different ways, depending on your target platform and goals:
Dart Native: For programs targeting devices (mobile, desktop, server, and more), Dart Native includes both a Dart VM with JIT (just-in-time) compilation and an AOT (ahead-of-time) compiler for producing machine code.
Dart Web: For programs targeting the web, Dart Web includes both a development time compiler (dartdevc) and a production time compiler (dart2js).
Dart is free and open source.
See LICENSE and PATENT_GRANT.
Visit dart.dev to learn more about the language, tools, and to find codelabs.
Browse pub.dev for more packages and libraries contributed by the community and the Dart team.
Our API reference documentation is published at api.dart.dev, based on the stable release. (We also publish docs from our beta and dev channels, as well as from the primary development branch).
If you want to build Dart yourself, here is a guide to getting the source, preparing your machine to build the SDK, and building.
There are more documents on our wiki.
The easiest way to contribute to Dart is to file issues.
You can also contribute patches, as described in Contributing.