angular-cn/packages/core/test/render3/perf
Pawel Kozlowski 172bb76964 docs(ivy): update micro-benchmark instructions (#32190)
PR Close #32190
2019-08-19 10:10:39 -07:00
..
interpolation test(ivy): add style binding node-based micro benchmark (#32104) 2019-08-15 09:55:03 -07:00
noop_change_detection test(ivy): add style binding node-based micro benchmark (#32104) 2019-08-15 09:55:03 -07:00
property_binding test(ivy): add style binding node-based micro benchmark (#32104) 2019-08-15 09:55:03 -07:00
style_binding test(ivy): add style binding node-based micro benchmark (#32104) 2019-08-15 09:55:03 -07:00
BUILD.bazel test(ivy): add style binding node-based micro benchmark (#32104) 2019-08-15 09:55:03 -07:00
README.md docs(ivy): update micro-benchmark instructions (#32190) 2019-08-19 10:10:39 -07:00
noop_renderer.ts test(ivy): add style binding node-based micro benchmark (#32104) 2019-08-15 09:55:03 -07:00
setup.ts test(ivy): add style binding node-based micro benchmark (#32104) 2019-08-15 09:55:03 -07:00

README.md

Build

yarn bazel build //packages/core/test/render3/perf:{name}.min_debug.es2015.js --define=compile=aot

Run

time node dist/bin/packages/core/test/render3/perf/{name}.min_debug.es2015.js

Profile

node --no-turbo-inlining --inspect-brk dist/bin/packages/core/test/render3/perf/{name}.min_debug.es2015.js

then connect with a debugger (the --inspect-brk option will make sure that benchmark execution doesn't start until a debugger is connected and the code execution is manually resumed).

The actual benchmark code has calls that will start (console.profile) and stop (console.profileEnd) a profiling session.

Notes

In all the above commands {name} should be replaced with the actual benchmark (folder) name, ex.:

  • build: yarn bazel build //packages/core/test/render3/perf:noop_change_detection.min_debug.es2015.js --define=compile=aot
  • run: time node dist/bin/packages/core/test/render3/perf/noop_change_detection.min_debug.es2015.js
  • profile: node --no-turbo-inlining --inspect-brk dist/bin/packages/core/test/render3/perf/noop_change_detection.min_debug.es2015.js