Skip to content

Conversation

@tonybaloney
Copy link
Contributor

Introduces a pytest extension "pytest-benchmark" and runs microbenchmarks of key functions within the worker process.

This PR will also include some optimizations.

Fork of #1039 - so that should be merged first

@tonybaloney
Copy link
Contributor Author

screenshot 2022-05-23 at 13 44 42

Comparison of first patch 699bbbc refactoring the build_binding_protos() function with 0-9 bindings shows a consistent 10-15% reduction in execution time.

@tonybaloney
Copy link
Contributor Author

screenshot 2022-05-23 at 15 59 51

screenshot 2022-05-23 at 16 01 27

Profiles for loader.index_function_app() are showing the function is relatively slow because:

  • the standard library inspect module is notoriously slow
  • The clean nones wrapper is quite inefficient
  • The JSON dumps happening on the function metadata is done eagerly (and not cached)?

Copy link

@JoseIvanHernandez JoseIvanHernandez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants