# Question about compilation time of the whole language

**URL:** https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882
**Category:** New to Julia
**Tags:** question
**Created:** [February 13, 2025, 11:30pm UTC](https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882 "2025-02-13T23:30:45Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![CiccioPasticcio](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/cicciopasticcio/32/215909_2.png) [@CiccioPasticcio](https://discourse.julialang.org/u/CiccioPasticcio)
#### Post date: [February 13, 2025, 11:30pm UTC](https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882/1 "2025-02-13T23:30:45Z")

</div>

Hello everyone, I was trying in these days for the first time to work on julia internals. I havea a question about the time it takes to compile the whole language. So my usual workflow is: modify some code, compile the language by running the “make” command in the julia folder. But compiling the whole language takes up to 5 minutes every time (I have a m1 macbook air), even for the smallest modification. Is there a different way to do this that is faster?

---

<div class="post-metadata">

### Author: ![d-netto](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/d-netto/32/212022_2.png) [@d-netto](https://discourse.julialang.org/u/d-netto)
#### Post date: [February 14, 2025, 12:26am UTC](https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882/2 "2025-02-14T00:26:08Z")

</div>

Depends on which part of the codebase you’re working on.

If you’re doing a minor modification in the C codebase, then just doing `make -C src -j` might do the trick – the `-C src` ensures you only recompile the C codebase (and don’t recompile Base/Core itself) and the `-j` enables multiple workers to compile your code.

If you’re working in Base or other pure-Julia part of the codebase, Revise should enable you to only trigger the recompilation of whatever method you modified.

---

<div class="post-metadata">

### Author: ![Benny](https://avatars.discourse-cdn.com/v4/letter/b/49beb7/32.png) [@Benny](https://discourse.julialang.org/u/Benny)
#### Post date: [February 14, 2025, 12:42am UTC](https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882/3 "2025-02-14T00:42:24Z")

</div>

> [@d-netto](#):
>
> only recompile the C codebase (and don’t recompile Base/Core itself)

How far can this go? Is it really generally possible to not have to rebuild the `Base` system image afterward?

> [@d-netto](#):
>
> Revise should enable you to only trigger the recompilation of whatever method you modified.

Revise.jl does inform users but it does have limitations. Interactively modifying methods goes pretty far in practice, but depending on how things are executed, an interactive modification may not have the same effect as restarting the session with the modification, and Revise can’t do interactive changes that Julia can’t e.g. `const` assignments.

---

<div class="post-metadata">

### Author: ![Keno](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/keno/32/285_2.png) [@Keno](https://discourse.julialang.org/u/Keno)
#### Post date: [February 14, 2025, 1:09am UTC](https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882/4 "2025-02-14T01:09:12Z")

</div>

> [@Benny](#):
>
> and Revise can’t do interactive changes that Julia can’t e.g. `const` assignments.

🤔

---

<div class="post-metadata">

### Author: ![Keno](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/keno/32/285_2.png) [@Keno](https://discourse.julialang.org/u/Keno)
#### Post date: [February 14, 2025, 1:10am UTC](https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882/5 "2025-02-14T01:10:50Z")

</div>

> [@Benny](#):
>
> How far can this go? Is it really generally possible to not have to rebuild the `Base` system image afterward?

Depends on exactly what you’re changing. If you’re changing anything that affects the ABI or memory layout, you’ll likely need to rebuild everything. That’s somewhat rare though.

---

<div class="post-metadata">

### Author: ![CiccioPasticcio](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/cicciopasticcio/32/215909_2.png) [@CiccioPasticcio](https://discourse.julialang.org/u/CiccioPasticcio)
#### Post date: [February 14, 2025, 12:33pm UTC](https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882/6 "2025-02-14T12:33:41Z")

</div>

> [@d-netto](#):
>
> If you’re working in Base or other pure-Julia part of the codebase, Revise should enable you to only trigger the recompilation of whatever method you modified.

how can i do that? i have seen from online documentation that revise can help me edit code of external packages. If i want to use it to edit the julia source code how do i do it? I tried calling

```julia
edit(showerror)

```

because i am working on the showerror function in the base/errorshow.jl file, but It doenst work

---

<div class="post-metadata">

### Author: ![digital\_carver](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/digital_carver/32/33818_2.png) [@digital\_carver](https://discourse.julialang.org/u/digital_carver)
#### Post date: [February 15, 2025, 1:52pm UTC](https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882/7 "2025-02-15T13:52:24Z")

</div>

`showerror` is part of `Base`:

```julia
julia> parentmodule(showerror)
Base

```

therefore you can do `Revise.track(Base)` to track and recompile in your changes to it.

---

<div class="post-metadata">

### Author: ![OmarElrefaei](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/omarelrefaei/32/43002_2.png) [@OmarElrefaei](https://discourse.julialang.org/u/OmarElrefaei)
#### Post date: [February 15, 2025, 8:56pm UTC](https://discourse.julialang.org/t/question-about-compilation-time-of-the-whole-language/125882/8 "2025-02-15T20:56:18Z")

</div>

> [@](#):
>
> therefore you can do `Revise.track(Base)` to track and recompile in your changes to it.

mentioned in docs here btw [Home · Revise.jl](https://timholy.github.io/Revise.jl/stable/#What-Revise-can-track)
