# Julia is Eight times Slower than Go on Numerical Scheme

**URL:** https://discourse.julialang.org/t/julia-is-eight-times-slower-than-go-on-numerical-scheme/59383
**Category:** Performance
**Created:** [April 16, 2021, 5:00am UTC](https://discourse.julialang.org/t/julia-is-eight-times-slower-than-go-on-numerical-scheme/59383 "2021-04-16T05:00:13Z")
**Posts on this page:** 1
**Showing post:** 30

<div class="post-metadata">

### Author: ![Eben60](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/eben60/32/13475_2.png) [@Eben60](https://discourse.julialang.org/u/Eben60)
#### Post date: [April 17, 2021, 11:44am UTC](https://discourse.julialang.org/t/julia-is-eight-times-slower-than-go-on-numerical-scheme/59383/30 "2021-04-17T11:44:03Z")

</div>

As for using structs: Just [posted an implementation](https://discourse.julialang.org/t/write-access-to-a-variable-in-a-module/59025/6) in some other context.

> **the same code as in the link above**
>
> ```julia
> module Md2
> 
> Base.@kwdef mutable struct State
> b1::Bool = false
> b2::Bool = false
> end
> 
> const st = State()
> export st
> end
> 
> using .Md2
> 
> ```
> 
> ```julia
> julia> st.b1
> false
> julia> st.b1=true;
> julia> st.b1
> true
> 
> ```

I my use case the performance was not relevant - but it is interesting to know how this way of encapsulation of variables into `const` objects compares with using `Ref`, array etc.

---

_[View the full topic](https://discourse.julialang.org/t/julia-is-eight-times-slower-than-go-on-numerical-scheme/59383)._
