Commit graph

4 commits

Author SHA1 Message Date
Regis Crelier 63cf56d925 Roll benchmarks-internal to 02695da98bcf006b95630d3c386f4169d7ec4ecf
Ignore invariant_booleans lint rule when analyzing benchmarks.

Change-Id: I6071d3c1407e9c67689204e4ceb50cc1c0c8e109
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/152598
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Régis Crelier <regis@google.com>
2020-06-26 01:56:03 +00:00
Martin Kustermann 177511aa17 [benchmarks] Disable literal_only_boolean_expressions/unnecessary_await_in_return analyzer hints
The literal_only_boolean_expressions analyzer hint flags this code:

   while (true) {
     ...
     if (cond) break;
     ...
   }

=> This is very common code.

The unnecessary_await_in_return analyzer hint flags this code:

    Future foo() async {
      ...
      return await foo();
    }

=> Addressing this hint by removing the `await` changes semantics,
performance characteristics and async stack traces.

Change-Id: I3c126123bfba7386b01033084e954267af21ba13
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/152001
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
2020-06-23 06:02:07 +00:00
Martin Kustermann a1416976c0 [benchmarks] Disable omit_local_variable_types analyzer hint
This hint flags code such as
   int time = watch.elapsedMillisecond;
and encourages using `var` everywhere:
   var time = watch.elapsedMillisecond;

Though if the type is not obvious to a developer, we should be allowed
to write it.

Furthermore it copies the rules from
`package:pedantic/analysis_options-1.9.0.yaml` to avoid being
automatically opted-in to new rules when a new package:pedantic
gets rolled into the SDK.

Change-Id: I45c72584885c608a56745685e9068ba83dfbed47
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/151526
Commit-Queue: Martin Kustermann <kustermann@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2020-06-19 13:43:23 +00:00
Alexander Aprelev 5f198ae1c8 [vm/benchmarks] Add IsolateSpawn spawn latency and memory benchmarks.
The benchmark spawns an isolate that compiles hello world app with dart2js, measures time it takes for spawned isolate to get up and running, measures delta rss when isolate is spawned.

This also adds analysis_options.yaml that helps with keeping the code lint-free.

Change-Id: I5f1ffa9706766cd00bf1ea3fdad76957952de8a1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/119538
Reviewed-by: Jonas Termansen <sortie@google.com>
Commit-Queue: Alexander Aprelev <aam@google.com>
2019-10-11 19:52:12 +00:00