# Can the threads in the :interactive pool also undertake heavy computing tasks?

**URL:** <https://discourse.julialang.org/t/can-the-threads-in-the-interactive-pool-also-undertake-heavy-computing-tasks/133725>\
**Category:** General Usage\
**Tags:** question, async\
**Created:** [November 7, 2025, 5:52am UTC](https://discourse.julialang.org/t/can-the-threads-in-the-interactive-pool-also-undertake-heavy-computing-tasks/133725 "2025-11-07T05:52:03Z")\
**Posts on this page:** 1\
**Showing post:** 9

<div class="post-metadata">

**Author:** ![WalterMadelim](https://avatars.discourse-cdn.com/v4/letter/w/3e96dc/32.png) [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Post date:** [November 8, 2025, 1:15am UTC](https://discourse.julialang.org/t/can-the-threads-in-the-interactive-pool-also-undertake-heavy-computing-tasks/133725/9 "2025-11-08T01:15:17Z")

</div>

I’m curious that why the “early exit” behavior doesn’t happen here, since I didn’t wait the async task

#### s.jl

```julia
println("$PROGRAM_FILE> " *
"threads_setting = $((Threads.nthreads(), Threads.nthreads(:interactive))), " *
"id = $(Threads.threadid()), " *
"pool = $(Threads.threadpool())"
)
function bzwt(t)
    tdue = time_ns() + 1e9t
    while true
        try
            time_ns() < tdue || error()
        catch
            return
        end
    end
end;
function a()
    @ccall printf("a> begins... \n"::Cstring)::Cint
    bzwt(1.5)
    @ccall printf("a> 1.5s... \n"::Cstring)::Cint
    bzwt(1.4)
    @ccall printf("a> 1.4s... \n"::Cstring)::Cint
    bzwt(1.3)
    @ccall printf("a> 1.3s... \n"::Cstring)::Cint
    bzwt(1.2)
    @ccall printf("a> 1.2s... \n"::Cstring)::Cint
    bzwt(1.1)
    @ccall printf("a> 1.1s... \n"::Cstring)::Cint
end;
@ccall printf("s.jl> begins... \n"::Cstring)::Cint
const t0 = time_ns()
Threads.@spawn(a())
bzwt(3.6)
@ccall printf("s.jl> 3.6s... \n"::Cstring)::Cint
(3.59e9 < time_ns() - t0 < 3.8e9) || error()

```

#### in the shell

```julia-auto
❯ julia --threads=1,1 s.jl
s.jl> threads_setting = (1, 1), id = 1, pool = interactive
s.jl> begins... 
a> begins... 
a> 1.5s... 
a> 1.4s... 
s.jl> 3.6s... 
a> 1.3s... 
a> 1.2s... 
a> 1.1s... 
~/somedir 7s some@some
❯ 

```

Why didn’t the `s.jl` early return to the shell? (i.e. why can I still see the `a> 1.3s...` and its subsequent lines)

* * *

Edit: Let’s create a new topic to discuss this sort of behavior.

---

_[View the full topic](https://discourse.julialang.org/t/can-the-threads-in-the-interactive-pool-also-undertake-heavy-computing-tasks/133725)._
