Skip to content

feat(napi): introduce AsyncBlock to let user dispose resources after future done#2338

Merged
Brooooooklyn merged 1 commit into
mainfrom
async-block
Oct 31, 2024
Merged

feat(napi): introduce AsyncBlock to let user dispose resources after future done#2338
Brooooooklyn merged 1 commit into
mainfrom
async-block

Conversation

@Brooooooklyn
Copy link
Copy Markdown
Member

No description provided.

@Brooooooklyn Brooooooklyn marked this pull request as ready for review October 31, 2024 01:00
Copy link
Copy Markdown
Member Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @Brooooooklyn and the rest of your teammates on Graphite Graphite

Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

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

Benchmark

Details
Benchmark suite Current: c9b8a9b Previous: 00a3c13 Ratio
noop#napi-rs 86844257 ops/sec (±0.12%) 86854261 ops/sec (±0.18%) 1.00
noop#JavaScript 820993498 ops/sec (±0.1%) 823070163 ops/sec (±0.07%) 1.00
Plus number#napi-rs 23032954 ops/sec (±0.27%) 23171023 ops/sec (±0.74%) 1.01
Plus number#JavaScript 821255737 ops/sec (±0.11%) 822405455 ops/sec (±0.11%) 1.00
Create buffer#napi-rs 625693 ops/sec (±12.57%) 634839 ops/sec (±12.85%) 1.01
Create buffer#JavaScript 3260278 ops/sec (±3.06%) 3381599 ops/sec (±1.88%) 1.04
createArray#createArrayJson 53535 ops/sec (±0.56%) 53917 ops/sec (±0.6%) 1.01
createArray#create array for loop 9796 ops/sec (±0.41%) 9717 ops/sec (±0.62%) 0.99
createArray#create array with serde trait 10020 ops/sec (±0.52%) 10026 ops/sec (±0.3%) 1.00
getArrayFromJs#get array from json string 24058 ops/sec (±1.41%) 23966 ops/sec (±0.49%) 1.00
getArrayFromJs#get array from serde 11847 ops/sec (±2.19%) 13708 ops/sec (±0.48%) 1.16
getArrayFromJs#get array with for loop 14394 ops/sec (±3.08%) 15934 ops/sec (±0.32%) 1.11
Get Set property#Get Set from native#u32 565487 ops/sec (±12.73%) 574471 ops/sec (±12.53%) 1.02
Get Set property#Get Set from JavaScript#u32 545193 ops/sec (±2.48%) 546939 ops/sec (±2.5%) 1.00
Get Set property#Get Set from native#string 567571 ops/sec (±12.15%) 569281 ops/sec (±11.63%) 1.00
Get Set property#Get Set from JavaScript#string 529159 ops/sec (±1.89%) 516329 ops/sec (±1.8%) 0.98
Async task#spawn task 26841 ops/sec (±0.33%) 26588 ops/sec (±0.78%) 0.99
Async task#ThreadSafeFunction 9403 ops/sec (±1.01%) 9407 ops/sec (±0.71%) 1.00
Async task#Tokio future to Promise 31725 ops/sec (±1.02%) 32961 ops/sec (±0.96%) 1.04
Query#query * 100 3597 ops/sec (±0.72%) 3583 ops/sec (±1.31%) 1.00
Query#query * 1 26466 ops/sec (±1.01%) 27093 ops/sec (±0.9%) 1.02

This comment was automatically generated by workflow using github-action-benchmark.

Copy link
Copy Markdown
Member Author

Brooooooklyn commented Oct 31, 2024

Merge activity

  • Oct 30, 9:13 PM EDT: Graphite rebased this pull request as part of a merge.
  • Oct 30, 9:24 PM EDT: A user merged this pull request with Graphite.

@Brooooooklyn Brooooooklyn merged commit f705454 into main Oct 31, 2024
@Brooooooklyn Brooooooklyn deleted the async-block branch October 31, 2024 01:24
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.

1 participant