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

Report allocations #286

Open
jtrakk opened this issue Dec 6, 2021 · 4 comments
Open

Report allocations #286

jtrakk opened this issue Dec 6, 2021 · 4 comments

Comments

@jtrakk
Copy link

jtrakk commented Dec 6, 2021

Julia docs say

One of the most common techniques to improve performance is to reduce memory allocation.

Julia has some memory-allocation analysis but it would be useful to have in JET.

@timholy
Copy link
Collaborator

timholy commented Dec 6, 2021

JET is a static analyzer. There's no reasonable way that it could predict the amount of memory required, but it might be able to address whether memory would be allocated at all.

ProfileView makes it pretty easy to find "serious" allocation: just look for yellow bars.

@jtrakk
Copy link
Author

jtrakk commented Dec 7, 2021

it might be able to address whether memory would be allocated at all.

Right. In some places I may want to ensure there will be no allocation. Highlighting those locations, just like @report_opt, would be helpful for this.

@jtrakk
Copy link
Author

jtrakk commented Jan 1, 2022

The relevant Julia issue is "A macro that forbids allocation – turning allocation into error" JuliaLang/julia#34248

@kbarros
Copy link

kbarros commented Nov 25, 2023

See the related package: https://github.com/JuliaLang/AllocCheck.jl

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

No branches or pull requests

3 participants