Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove RecordSpanFromParent from general tracing api #3791

Merged
merged 1 commit into from
Jan 11, 2023

Conversation

pattyshack
Copy link
Contributor

The record span logic is moved into fvm's program logger (It's only used for cadence tracing)

The record span logic is moved into fvm's program logger (It's only used for
cadence tracing)
@github-actions
Copy link
Contributor

github-actions bot commented Jan 9, 2023

FVM Benchstat comparison

This branch with compared with the base branch onflow:master commit 8efd216

The command (for i in {1..7}; do go test ./fvm ./engine/execution/computation --bench . --tags relic -shuffle=on --benchmem --run ^$; done) was used.

Collapsed results for better readability

old.txtnew.txt
time/opdelta
pkg:github.com/onflow/flow-go/fvm goos:linux goarch:amd64
RuntimeTransaction/convert_int_to_string-230.2ms ± 3%31.1ms ± 2%+2.86%(p=0.009 n=6+6)
RuntimeTransaction/reference_tx-229.5ms ± 5%28.9ms ± 4%~(p=0.138 n=7+6)
RuntimeTransaction/convert_int_to_string_and_concatenate_it-231.9ms ± 2%34.1ms ±16%~(p=0.051 n=6+7)
RuntimeTransaction/get_signer_address-229.5ms ± 3%29.8ms ± 3%~(p=0.310 n=6+6)
RuntimeTransaction/get_public_account-232.2ms ± 4%32.0ms ± 5%~(p=0.731 n=7+6)
RuntimeTransaction/get_account_and_get_balance-2259ms ± 2%261ms ± 2%~(p=0.259 n=7+7)
RuntimeTransaction/get_account_and_get_available_balance-2235ms ± 1%238ms ± 1%~(p=0.053 n=7+7)
RuntimeTransaction/get_account_and_get_storage_used-234.3ms ± 3%33.9ms ± 5%~(p=0.456 n=7+7)
RuntimeTransaction/get_account_and_get_storage_capacity-2213ms ± 1%213ms ± 3%~(p=0.836 n=6+7)
RuntimeTransaction/get_signer_vault-236.1ms ± 4%36.1ms ± 3%~(p=0.710 n=7+7)
RuntimeTransaction/get_signer_receiver-247.0ms ± 5%46.2ms ± 3%~(p=0.209 n=7+7)
RuntimeTransaction/transfer_tokens-2189ms ± 2%188ms ± 2%~(p=0.620 n=7+7)
RuntimeTransaction/load_and_save_empty_string_on_signers_address-235.4ms ± 2%35.7ms ± 1%~(p=0.318 n=7+7)
RuntimeTransaction/load_and_save_long_string_on_signers_address-276.0ms ± 6%76.2ms ± 3%~(p=0.805 n=7+7)
RuntimeTransaction/create_new_account-2802ms ± 2%801ms ± 0%~(p=0.432 n=7+5)
RuntimeTransaction/call_empty_contract_function-232.2ms ± 2%32.7ms ± 5%~(p=0.620 n=7+7)
RuntimeTransaction/emit_event-247.2ms ± 4%46.1ms ± 5%~(p=0.456 n=7+7)
RuntimeTransaction/borrow_array_from_storage-2128ms ± 3%127ms ± 2%~(p=0.209 n=7+7)
RuntimeTransaction/copy_array_from_storage-2126ms ± 2%127ms ± 2%~(p=0.805 n=7+7)
RuntimeNFTBatchTransfer-2115ms ± 3%115ms ± 5%~(p=0.710 n=7+7)
pkg:github.com/onflow/flow-go/engine/execution/computation goos:linux goarch:amd64
ComputeBlock/16/cols/128/txes-24.29s ± 1%4.28s ± 1%~(p=0.383 n=7+7)
 
computationdelta
pkg:github.com/onflow/flow-go/fvm goos:linux goarch:amd64
RuntimeTransaction/reference_tx-2202 ± 0%202 ± 0%~(all equal)
RuntimeTransaction/convert_int_to_string-2402 ± 0%402 ± 0%~(all equal)
RuntimeTransaction/convert_int_to_string_and_concatenate_it-2502 ± 0%502 ± 0%~(all equal)
RuntimeTransaction/get_signer_address-2302 ± 0%302 ± 0%~(all equal)
RuntimeTransaction/get_public_account-2402 ± 0%402 ± 0%~(all equal)
RuntimeTransaction/get_account_and_get_balance-21.00k ± 0%1.00k ± 0%~(all equal)
RuntimeTransaction/get_account_and_get_available_balance-23.10k ± 0%3.10k ± 0%~(all equal)
RuntimeTransaction/get_account_and_get_storage_used-2402 ± 0%402 ± 0%~(all equal)
RuntimeTransaction/get_account_and_get_storage_capacity-21.70k ± 0%1.70k ± 0%~(all equal)
RuntimeTransaction/get_signer_vault-2402 ± 0%402 ± 0%~(all equal)
RuntimeTransaction/get_signer_receiver-2602 ± 0%602 ± 0%~(all equal)
RuntimeTransaction/transfer_tokens-23.50k ± 0%3.50k ± 0%~(all equal)
RuntimeTransaction/load_and_save_empty_string_on_signers_address-2602 ± 0%602 ± 0%~(all equal)
RuntimeTransaction/load_and_save_long_string_on_signers_address-2602 ± 0%602 ± 0%~(all equal)
RuntimeTransaction/create_new_account-2202 ± 0%202 ± 0%~(all equal)
RuntimeTransaction/call_empty_contract_function-2402 ± 0%402 ± 0%~(all equal)
RuntimeTransaction/emit_event-2602 ± 0%602 ± 0%~(all equal)
RuntimeTransaction/borrow_array_from_storage-22.60k ± 0%2.60k ± 0%~(all equal)
RuntimeTransaction/copy_array_from_storage-22.60k ± 0%2.60k ± 0%~(all equal)
 
interactionsdelta
pkg:github.com/onflow/flow-go/fvm goos:linux goarch:amd64
RuntimeTransaction/reference_tx-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/convert_int_to_string-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/convert_int_to_string_and_concatenate_it-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/get_signer_address-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/get_public_account-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/get_account_and_get_balance-224.3M ± 0%24.3M ± 0%~(all equal)
RuntimeTransaction/get_account_and_get_available_balance-25.64M ± 0%5.64M ± 0%~(all equal)
RuntimeTransaction/get_account_and_get_storage_used-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/get_account_and_get_storage_capacity-25.64M ± 0%5.64M ± 0%~(all equal)
RuntimeTransaction/get_signer_vault-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/get_signer_receiver-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/transfer_tokens-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/load_and_save_empty_string_on_signers_address-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/load_and_save_long_string_on_signers_address-2334k ± 0%334k ± 0%~(all equal)
RuntimeTransaction/create_new_account-212.3M ± 0%12.3M ± 0%~(all equal)
RuntimeTransaction/call_empty_contract_function-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/emit_event-2331k ± 0%331k ± 0%~(all equal)
RuntimeTransaction/borrow_array_from_storage-2336k ± 0%336k ± 0%~(all equal)
RuntimeTransaction/copy_array_from_storage-2336k ± 0%336k ± 0%~(all equal)
 
alloc/opdelta
pkg:github.com/onflow/flow-go/fvm goos:linux goarch:amd64
RuntimeTransaction/get_account_and_get_available_balance-2104MB ± 3%107MB ± 1%+2.97%(p=0.001 n=7+6)
RuntimeTransaction/convert_int_to_string_and_concatenate_it-235.2MB ± 1%35.7MB ± 1%+1.58%(p=0.007 n=7+7)
pkg:github.com/onflow/flow-go/engine/execution/computation goos:linux goarch:amd64
ComputeBlock/16/cols/128/txes-21.20GB ± 0%1.21GB ± 1%+0.66%(p=0.026 n=7+7)
pkg:github.com/onflow/flow-go/fvm goos:linux goarch:amd64
RuntimeTransaction/reference_tx-234.9MB ± 3%34.5MB ± 2%~(p=0.383 n=7+7)
RuntimeTransaction/convert_int_to_string-234.7MB ± 0%35.4MB ± 2%~(p=0.149 n=5+7)
RuntimeTransaction/get_signer_address-235.0MB ± 1%35.3MB ± 1%~(p=0.138 n=6+7)
RuntimeTransaction/get_public_account-236.2MB ± 4%36.7MB ± 2%~(p=0.534 n=7+6)
RuntimeTransaction/get_account_and_get_balance-2120MB ± 3%122MB ± 1%~(p=0.128 n=7+7)
RuntimeTransaction/get_account_and_get_storage_used-236.8MB ± 3%36.6MB ± 5%~(p=0.805 n=7+7)
RuntimeTransaction/get_account_and_get_storage_capacity-2103MB ± 0%103MB ± 0%~(p=0.151 n=5+5)
RuntimeTransaction/get_signer_vault-236.5MB ± 4%36.2MB ± 2%~(p=0.456 n=7+7)
RuntimeTransaction/get_signer_receiver-241.1MB ± 5%40.4MB ± 2%~(p=0.456 n=7+7)
RuntimeTransaction/transfer_tokens-283.5MB ± 4%83.6MB ± 3%~(p=1.000 n=7+6)
RuntimeTransaction/load_and_save_empty_string_on_signers_address-236.1MB ± 3%35.9MB ± 1%~(p=0.628 n=6+7)
RuntimeTransaction/load_and_save_long_string_on_signers_address-251.6MB ± 2%52.8MB ± 4%~(p=0.234 n=6+7)
RuntimeTransaction/create_new_account-2182MB ± 3%182MB ± 3%~(p=0.805 n=7+7)
RuntimeTransaction/call_empty_contract_function-235.6MB ± 3%35.9MB ± 3%~(p=0.383 n=7+7)
RuntimeTransaction/emit_event-241.0MB ± 3%40.3MB ± 5%~(p=0.445 n=6+7)
RuntimeTransaction/borrow_array_from_storage-270.5MB ± 4%69.5MB ± 3%~(p=0.209 n=7+7)
RuntimeTransaction/copy_array_from_storage-281.4MB ± 3%81.7MB ± 1%~(p=0.383 n=7+7)
RuntimeNFTBatchTransfer-253.9MB ± 2%53.7MB ± 4%~(p=0.805 n=7+7)
 
allocs/opdelta
pkg:github.com/onflow/flow-go/fvm goos:linux goarch:amd64
RuntimeTransaction/reference_tx-282.4k ± 0%82.7k ± 0%+0.41%(p=0.001 n=7+7)
RuntimeTransaction/get_signer_address-286.5k ± 0%86.9k ± 0%+0.40%(p=0.001 n=7+7)
RuntimeTransaction/get_account_and_get_storage_capacity-21.10M ± 0%1.11M ± 0%+0.39%(p=0.001 n=7+7)
RuntimeTransaction/convert_int_to_string-294.5k ± 0%94.9k ± 0%+0.37%(p=0.001 n=7+7)
RuntimeTransaction/call_empty_contract_function-297.8k ± 0%98.2k ± 0%+0.36%(p=0.001 n=7+6)
RuntimeTransaction/get_account_and_get_available_balance-21.23M ± 0%1.23M ± 0%+0.35%(p=0.001 n=7+7)
RuntimeTransaction/get_account_and_get_balance-21.30M ± 0%1.30M ± 0%+0.33%(p=0.001 n=7+7)
RuntimeTransaction/convert_int_to_string_and_concatenate_it-2106k ± 0%106k ± 0%+0.32%(p=0.001 n=6+7)
RuntimeTransaction/get_public_account-2109k ± 0%109k ± 0%+0.31%(p=0.001 n=7+6)
RuntimeTransaction/get_account_and_get_storage_used-2119k ± 0%119k ± 0%+0.29%(p=0.001 n=7+7)
RuntimeTransaction/load_and_save_empty_string_on_signers_address-2121k ± 0%122k ± 0%+0.28%(p=0.001 n=7+7)
pkg:github.com/onflow/flow-go/engine/execution/computation goos:linux goarch:amd64
ComputeBlock/16/cols/128/txes-217.2M ± 0%17.2M ± 0%+0.28%(p=0.001 n=7+7)
pkg:github.com/onflow/flow-go/fvm goos:linux goarch:amd64
RuntimeTransaction/get_signer_vault-2123k ± 0%123k ± 0%+0.28%(p=0.003 n=7+5)
RuntimeTransaction/emit_event-2137k ± 0%138k ± 0%+0.23%(p=0.001 n=6+7)
RuntimeTransaction/load_and_save_long_string_on_signers_address-2193k ± 0%194k ± 0%+0.18%(p=0.001 n=7+6)
RuntimeTransaction/get_signer_receiver-2197k ± 0%198k ± 0%+0.17%(p=0.001 n=7+7)
RuntimeNFTBatchTransfer-2268k ± 0%268k ± 0%+0.14%(p=0.004 n=6+5)
RuntimeTransaction/copy_array_from_storage-2292k ± 0%292k ± 0%+0.11%(p=0.001 n=7+7)
RuntimeTransaction/create_new_account-22.27M ± 0%2.27M ± 0%+0.11%(p=0.004 n=5+6)
RuntimeTransaction/borrow_array_from_storage-2336k ± 0%336k ± 0%+0.10%(p=0.001 n=7+7)
RuntimeTransaction/transfer_tokens-2842k ± 0%842k ± 0%+0.04%(p=0.001 n=7+7)
 
us/txdelta
pkg:github.com/onflow/flow-go/engine/execution/computation goos:linux goarch:amd64
ComputeBlock/16/cols/128/txes-22.09k ± 1%2.09k ± 1%~(p=0.383 n=7+7)
 

@pattyshack
Copy link
Contributor Author

bors merge

@bors bors bot merged commit 54b48ce into master Jan 11, 2023
@bors bors bot deleted the patrick/rm-record-span-from-parent branch January 11, 2023 18:00
This pull request was closed.
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