# Strange --- seemingly out-of-bounds access --- bug in Julia v1.6

Using Julia v1.6.7, I obtain

``````julia> using LinearAlgebra, FillArrays

julia> for (dv, ev) in ((Fill(2,3), Fill(6,2)), (Zeros(2), Zeros(1)))
display(Tridiagonal(ev, dv, ev))
end
3×3 Tridiagonal{Int64, Fill{Int64, 1, Tuple{Base.OneTo{Int64}}}}:
2  6  ⋅
6  2  6
⋅  6  2
140507853782720×140507853782720 Tridiagonal{Int64, Fill{Int64, 1, Tuple{Base.OneTo{Int64}}}}:
1  22    ⋅       ⋅       ⋅       ⋅     …    ⋅       ⋅       ⋅       ⋅
1   1   22       ⋅       ⋅       ⋅          ⋅       ⋅       ⋅       ⋅
⋅   1    1      22       ⋅       ⋅          ⋅       ⋅       ⋅       ⋅
⋅   ⋅  #undef    1      22       ⋅          ⋅       ⋅       ⋅       ⋅
⋅   ⋅    ⋅     #undef    1      22          ⋅       ⋅       ⋅       ⋅
⋅   ⋅    ⋅       ⋅     #undef    1     …    ⋅       ⋅       ⋅       ⋅
⋅   ⋅    ⋅       ⋅       ⋅     #undef       ⋅       ⋅       ⋅       ⋅
⋅   ⋅    ⋅       ⋅       ⋅       ⋅          ⋅       ⋅       ⋅       ⋅
⋅   ⋅    ⋅       ⋅       ⋅       ⋅          ⋅       ⋅       ⋅       ⋅
⋮                                ⋮     ⋱
⋅   ⋅    ⋅       ⋅       ⋅       ⋅          ⋅       ⋅       ⋅       ⋅
⋅   ⋅    ⋅       ⋅       ⋅       ⋅          ⋅       ⋅       ⋅       ⋅
⋅   ⋅    ⋅       ⋅       ⋅       ⋅          ⋅       ⋅       ⋅       ⋅
⋅   ⋅    ⋅       ⋅       ⋅       ⋅     …  #undef    ⋅       ⋅       ⋅
⋅   ⋅    ⋅       ⋅       ⋅       ⋅          1     #undef    ⋅       ⋅
⋅   ⋅    ⋅       ⋅       ⋅       ⋅        #undef    1     #undef    ⋅
⋅   ⋅    ⋅       ⋅       ⋅       ⋅          ⋅     #undef    1     #undef
⋅   ⋅    ⋅       ⋅       ⋅       ⋅          ⋅       ⋅     #undef    1
``````

Where’s that second result coming from? This seems fixed on recent versions of Julia. Both the values and the type are incorrect.

Seems like hardware info (included in `versioninfo()` AFAIK) might be interesting.

EDIT: I can reproduce:

``````julia> versioninfo()
Julia Version 1.6.7
Commit 3b76b25b64 (2022-07-19 15:11 UTC)
Platform Info:
OS: Linux (x86_64-pc-linux-gnu)
CPU: AMD Ryzen 3 5300U with Radeon Graphics
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-11.0.1 (ORCJIT, znver2)
julia> for (dv, ev) in ((Zeros(2), Zeros(1)),)
display(size(Tridiagonal(ev, dv, ev)))
end
(2, 2)

julia> for (dv, ev) in ((Fill(2,3), Fill(6,2)), (Zeros(2), Zeros(1)))
display(size(Tridiagonal(ev, dv, ev)))
end
(3, 3)
(140050683035328, 140050683035328)

julia> for (dv, ev) in ((Fill(2,3), Fill(6,2)), (Zeros(2), Zeros(1)))
display(size(Tridiagonal(ev, dv, ev)))
end
(3, 3)
(140050683035328, 140050683035328)
``````

The numbers change after restarting Julia:

``````julia> using LinearAlgebra, FillArrays

julia> for (dv, ev) in ((Fill(2,3), Fill(6,2)), (Zeros(2), Zeros(1)))
display(size(Tridiagonal(ev, dv, ev)))
end
(3, 3)
(140677421659760, 140677421659760)
``````