# Allocations of @threads

**URL:** <https://discourse.julialang.org/t/allocations-of-threads/67047>\
**Category:** Performance\
**Tags:** memory-allocation\
**Created:** [August 26, 2021, 4:25pm UTC](https://discourse.julialang.org/t/allocations-of-threads/67047 "2021-08-26T16:25:52Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![ranocha](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ranocha/32/35588_2.png) [@ranocha](https://discourse.julialang.org/u/ranocha)\
**Post date:** [August 28, 2021, 3:28pm UTC](https://discourse.julialang.org/t/allocations-of-threads/67047/7 "2021-08-28T15:28:41Z")

</div>

Alternatively, you could also use a custom macro such as `@threaded` from  
[Overhead of `Threads.@threads` - #23 by ranocha](https://discourse.julialang.org/t/overhead-of-threads-threads/53964/23) for development. Then, you will basically run the serial code without further allocations when starting Julia with a single thread, which can be helpful for development. We did that before switching to `@batch` in Trixi.jl.

---

_[View the full topic](https://discourse.julialang.org/t/allocations-of-threads/67047)._
