-
Notifications
You must be signed in to change notification settings - Fork 28.7k
Add more entry-point annotations for test-only code. #160421
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption, contact "@test-exemption-reviewer" in the #hackers channel in Discord (don't just cc them here, they won't see it!). If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix? Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. The test exemption team is a small volunteer group, so all reviewers should feel empowered to ask for tests, without delegating that responsibility entirely to the test exemption group. |
The examples where the annotations are added are used in separately written tests under |
Now that Flutter tests that access entry points from native code have been annotated[1], we can turn on entry point checking in JIT mode. This CL also removes the A flag category from flag_list.h and the AOT_FLAG_MACRO definitions and uses from flags.[cc,h], as they were created as a temporary measure until this flag could be unconditionally defaulted to true. [1] See the following PRs: * flutter/engine#57158 * flutter/flutter#160158 * flutter/flutter#160421 TEST=vm/dart/entrypoints_verification_test vm/cc/IRTest vm/cc/StreamingFlowGraphBuilder vm/cc/STC vm/cc/TTS Issue: #50649 Issue: flutter/flutter#118608 Cq-Include-Trybots: luci.dart.try:vm-aot-linux-product-x64-try,vm-aot-linux-debug-x64-try,vm-aot-mac-release-arm64-try,vm-aot-mac-product-arm64-try,vm-aot-dwarf-linux-product-x64-try,vm-linux-debug-x64-try,vm-linux-release-x64-try,vm-appjit-linux-product-x64-try Change-Id: Ibe5b21bb74f1a6fb88824b71ff87b9e555216dbf Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/400301 Reviewed-by: Martin Kustermann <[email protected]> Commit-Queue: Tess Strickland <[email protected]>
This reverts commit 982b9fa. Reason for revert: b/385114574 Original change's description: > [vm] Turn on entry point checking in JIT mode. > > Now that Flutter tests that access entry points from native code > have been annotated[1], we can turn on entry point checking in JIT > mode. > > This CL also removes the A flag category from flag_list.h and the > AOT_FLAG_MACRO definitions and uses from flags.[cc,h], as they were > created as a temporary measure until this flag could be unconditionally > defaulted to true. > > [1] See the following PRs: > * flutter/engine#57158 > * flutter/flutter#160158 > * flutter/flutter#160421 > > TEST=vm/dart/entrypoints_verification_test vm/cc/IRTest > vm/cc/StreamingFlowGraphBuilder vm/cc/STC vm/cc/TTS > > Issue: #50649 > Issue: flutter/flutter#118608 > > Cq-Include-Trybots: luci.dart.try:vm-aot-linux-product-x64-try,vm-aot-linux-debug-x64-try,vm-aot-mac-release-arm64-try,vm-aot-mac-product-arm64-try,vm-aot-dwarf-linux-product-x64-try,vm-linux-debug-x64-try,vm-linux-release-x64-try,vm-appjit-linux-product-x64-try > Change-Id: Ibe5b21bb74f1a6fb88824b71ff87b9e555216dbf > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/400301 > Reviewed-by: Martin Kustermann <[email protected]> > Commit-Queue: Tess Strickland <[email protected]> Issue: #50649 Issue: flutter/flutter#118608 Change-Id: Id403cd0832807e417202e17dac57c2224cab09e7 Cq-Include-Trybots: luci.dart.try:vm-aot-linux-product-x64-try,vm-aot-linux-debug-x64-try,vm-aot-mac-release-arm64-try,vm-aot-mac-product-arm64-try,vm-aot-dwarf-linux-product-x64-try,vm-linux-debug-x64-try,vm-linux-release-x64-try,vm-appjit-linux-product-x64-try Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/401880 Bot-Commit: Rubber Stamper <[email protected]> Reviewed-by: Martin Kustermann <[email protected]> Commit-Queue: Ivan Inozemtsev <[email protected]>
This is a reland of commit 982b9fa Original change's description: > [vm] Turn on entry point checking in JIT mode. > > Now that Flutter tests that access entry points from native code > have been annotated[1], we can turn on entry point checking in JIT > mode. > > This CL also removes the A flag category from flag_list.h and the > AOT_FLAG_MACRO definitions and uses from flags.[cc,h], as they were > created as a temporary measure until this flag could be unconditionally > defaulted to true. > > [1] See the following PRs: > * flutter/engine#57158 > * flutter/flutter#160158 > * flutter/flutter#160421 > > TEST=vm/dart/entrypoints_verification_test vm/cc/IRTest > vm/cc/StreamingFlowGraphBuilder vm/cc/STC vm/cc/TTS > > Issue: #50649 > Issue: flutter/flutter#118608 > > Cq-Include-Trybots: luci.dart.try:vm-aot-linux-product-x64-try,vm-aot-linux-debug-x64-try,vm-aot-mac-release-arm64-try,vm-aot-mac-product-arm64-try,vm-aot-dwarf-linux-product-x64-try,vm-linux-debug-x64-try,vm-linux-release-x64-try,vm-appjit-linux-product-x64-try > Change-Id: Ibe5b21bb74f1a6fb88824b71ff87b9e555216dbf > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/400301 > Reviewed-by: Martin Kustermann <[email protected]> > Commit-Queue: Tess Strickland <[email protected]> TEST=vm/dart/entrypoints_verification_test vm/cc/IRTest vm/cc/StreamingFlowGraphBuilder vm/cc/STC vm/cc/TTS Change-Id: Ibd5f362f908b4aaa68cda870a387c081537bbc16 Cq-Include-Trybots: luci.dart.try:vm-aot-linux-product-x64-try,vm-aot-linux-debug-x64-try,vm-aot-mac-release-arm64-try,vm-aot-mac-product-arm64-try,vm-aot-dwarf-linux-product-x64-try,vm-linux-debug-x64-try,vm-linux-release-x64-try,vm-appjit-linux-product-x64-try Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/403360 Auto-Submit: Ivan Inozemtsev <[email protected]> Commit-Queue: Ivan Inozemtsev <[email protected]> Reviewed-by: Martin Kustermann <[email protected]>
This change adds entry-point annotations to methods and classes accessed by native code during Flutter tests. Currently, entry point annotations are not checked by the Dart VM when running in JIT mode, only in AOT mode. In order to also enforce entry point annotations in JIT mode, first tests in Flutter must be appropriately annotated to avoid roll failures.
Related issues:
Pre-launch Checklist
///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.