# What's in the .mem files?

**URL:** <https://discourse.julialang.org/t/whats-in-the-mem-files/20592>\
**Category:** Performance\
**Created:** [February 8, 2019, 6:04pm UTC](https://discourse.julialang.org/t/whats-in-the-mem-files/20592 "2019-02-08T18:04:06Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![bennedich](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/bennedich/32/4894_2.png) [@bennedich](https://discourse.julialang.org/u/bennedich)\
**Post date:** [February 8, 2019, 9:19pm UTC](https://discourse.julialang.org/t/whats-in-the-mem-files/20592/2 "2019-02-08T21:19:02Z")

</div>

It’s supposed to be the number of bytes allocated on that line, but unfortunately it’s not super accurate, and often misses allocations. [I wrote a bit about it in this post](https://discourse.julialang.org/t/help-to-reduce-number-of-allocations/19308/17).

As for memory allocated where you think there shouldn’t be: You can verify with `@time` that memory is indeed allocated there (just put `@time` in front of those lines).

Unexpected allocations are often caused by type instability. Run `@code_warntype` for your function and look for any instabilities (i.e. “::Any” colored in red).

---

_[View the full topic](https://discourse.julialang.org/t/whats-in-the-mem-files/20592)._
