Skip to content

Commit 7fa7e9d

Browse files
authored
update gitignore, benchmark readme, and macro tool output (dart-archive#143)
Some small cleanup stuff: - Add macro tool output files to gitignore. - Update benchmark readme to use `dart run`. - log the total time to re-analyze from the macro_tool (I might be misunderstanding what this is trying to report though).
1 parent 7b15d59 commit 7fa7e9d

File tree

3 files changed

+10
-8
lines changed

3 files changed

+10
-8
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
**/.dart_tool
22
**/pubspec.lock
33
goldens/foo/lib/generated/**
4+
*.macro_tool_output

pkgs/_macro_tool/lib/macro_tool.dart

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,8 @@ class MacroTool {
201201
}
202202

203203
stdout.write(
204-
'Macros ran in in ${_applyResult!.firstResultAfter.inMilliseconds}ms,'
204+
'Macros ran in ${_applyResult!.firstResultAfter.inMilliseconds}ms '
205+
'(${_applyResult!.lastResultAfter.inMilliseconds}ms total),'
205206
' watching...',
206207
);
207208
await events.first;

tool/benchmark_generator/README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22

33
Generates code that uses macros, for benchmarking.
44

5-
Example use, from the root of this package:
5+
Example use, from the root of this repo:
66

77
```
8-
dart bin/main.dart large macro 64
9-
dart ../../pkgs/_macro_tool/bin/main.dart \
10-
--workspace=../../goldens/foo \
11-
--packageConfig=../../.dart_tool/package_config.json \
12-
--script=../../goldens/foo/lib/generated/large/a0.dart \
13-
--host=analyzer --watch
8+
dart run benchmark_generator large macro 64
9+
dart run _macro_tool \
10+
--workspace=goldens/foo \
11+
--packageConfig=.dart_tool/package_config.json \
12+
--script=goldens/foo/lib/generated/large/a0.dart \
13+
--host=analyzer watch
1414
```
1515

1616
then change `goldens/foo/lib/generated/large/a0.dart` to see the refresh time.

0 commit comments

Comments
 (0)