4 ms·
This is actually a brilliant idea. If you change the pitch by the allocated chunk size (maybe in log scale) or use different sound for free(), someone could be
by euske 6y ago
This is actually a brilliant idea.
If you change the pitch by the allocated chunk size (maybe in log scale) or use different sound for free(), someone could be actually detecting memory leaks just by listening to the app.
- dkersten 6y agoI was thinking that it’s useful in games or other applications where you don’t want to malloc at arbitrary times (eg in games you might malloc once in startup or on level start and then reuse that memory instead). Many applications with real-time requirements often work similarly (eg high frequency trading), so this would be a fun check to make sure your application is well behaved. I like the idea of changing pitch by size and also representing frees, but I’m not sure it would be useful to find memory leaks since there’s no real way of matching them up in any non trivial application.