Skip to content

Conversation

@ibraheemdev
Copy link
Member

@ibraheemdev ibraheemdev commented Jun 24, 2025

#[salsa::tracked(heap_size)] will require the return type of a tracked function to implement the get_size2::GetSize trait, and include the heap size in the new memory usage APIs. I'm not sure get-size2 is the best crate to use, but it seems relatively comprehensive, and integrating it into ty was relatively simple with its derive macros. Note that it's not actually a dependency of salsa, it's just called by the generated proc-macro code.

@netlify
Copy link

netlify bot commented Jun 24, 2025

Deploy Preview for salsa-rs canceled.

Name Link
🔨 Latest commit 5f33cd3
🔍 Latest deploy log https://app.netlify.com/projects/salsa-rs/deploys/685c52db0c4879000837e266

@codspeed-hq
Copy link

codspeed-hq bot commented Jun 24, 2025

CodSpeed Performance Report

Merging #925 will not alter performance

Comparing ibraheemdev:ibraheem/memory-usage-dump (5f33cd3) with master (8d14c02)

Summary

✅ 12 untouched benchmarks

Copy link
Contributor

@MichaReiser MichaReiser left a comment

Choose a reason for hiding this comment

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

Thanks this is great. I've only one recommendation on how we could possibly remove the get_size dependency entirely (in tests and in the generated macro)

@ibraheemdev ibraheemdev force-pushed the ibraheem/memory-usage-dump branch 2 times, most recently from e53c2ab to 18f5cc0 Compare June 25, 2025 19:48
@ibraheemdev ibraheemdev force-pushed the ibraheem/memory-usage-dump branch from 18f5cc0 to 5f33cd3 Compare June 25, 2025 19:49
@MichaReiser MichaReiser added this pull request to the merge queue Jun 25, 2025
Merged via the queue into salsa-rs:master with commit 0666e20 Jun 25, 2025
12 checks passed
This was referenced Jun 25, 2025
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.

2 participants