Format benchmarks/.

Change-Id: I1362ada67a02b0ed352612fc29c727e94d8cd254
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/394901
Commit-Queue: Daco Harkes <dacoharkes@google.com>
Auto-Submit: Bob Nystrom <rnystrom@google.com>
Reviewed-by: Daco Harkes <dacoharkes@google.com>
This commit is contained in:
Robert Nystrom
2024-11-18 10:06:01 +00:00
committed by Commit Queue
parent 54b3ca9ea0
commit e4c8b49dcc
106 changed files with 3873 additions and 2405 deletions
@@ -39,8 +39,11 @@ class SendReceiveHelper {
final port = ReceivePort();
inbox = StreamIterator<dynamic>(port);
workerExitedPort = ReceivePort();
await Isolate.spawn(isolate, port.sendPort,
onExit: workerExitedPort.sendPort);
await Isolate.spawn(
isolate,
port.sendPort,
onExit: workerExitedPort.sendPort,
);
await inbox.moveNext();
outbox = inbox.current;
}
@@ -88,7 +91,8 @@ Future<void> isolate(SendPort sendPort) async {
Future<void> main() async {
await SendReceiveRegExp('IsolateRegExp.MatchFast', RegExp('h?h')).report();
await SendReceiveRegExp('IsolateRegExp.MatchSlow',
RegExp(r'(?<=\W|\b|^)(a.? b c.?) ?(\(.*\))?$'))
.report();
await SendReceiveRegExp(
'IsolateRegExp.MatchSlow',
RegExp(r'(?<=\W|\b|^)(a.? b c.?) ?(\(.*\))?$'),
).report();
}