Skip to content

Commit 2f4e343

Browse files
Merge pull request #223 from ChrisRackauckas-Claude/fix-double64-julia110-and-downgrade
fix: restore Julia 1.10 support for Double64 intlog2 path + re-enable downgrade CI
2 parents 7ab1c9c + 83edb51 commit 2f4e343

3 files changed

Lines changed: 7 additions & 4 deletions

File tree

.github/workflows/Downgrade.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ on:
1212
- 'docs/**'
1313
jobs:
1414
downgrade:
15-
if: false # Disabled pending fix - see #208 for tracking re-enablement
1615
name: "Downgrade"
1716
strategy:
1817
matrix:

Project.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ ExponentialUtilitiesStaticArraysExt = "StaticArrays"
2424
Adapt = "3.4.0, 4"
2525
Aqua = "0.8"
2626
ArrayInterface = "7.1"
27-
DoubleFloats = "1"
27+
DoubleFloats = "1.1.14"
2828
ForwardDiff = "0.10.13"
2929
GPUArraysCore = "0.1, 0.2"
3030
GenericSchur = "0.5.3"
@@ -35,7 +35,7 @@ Printf = "1.10"
3535
Random = "1"
3636
SafeTestsets = "0.1"
3737
SparseArrays = "1.10"
38-
StaticArrays = "1.2"
38+
StaticArrays = "1.9.8"
3939
Test = "1"
4040
julia = "1.10"
4141

src/exp_generic.jl

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
intlog2(x::T) where {T <: Integer} = T(8 * sizeof(T) - leading_zeros(x - one(T)))
2-
intlog2(x) = x > typemax(UInt) ? ceil(Int, log2(x)) : intlog2(ceil(UInt, x)) % Int
2+
# `ceil(Int, x)` rather than `ceil(UInt, x)` so the integer-conversion path only needs
3+
# `trunc(::Type{Int}, ::AbstractFloat)`, which extended-precision types such as
4+
# DoubleFloats.Double64 define, whereas `trunc(::Type{<:Unsigned}, ::AbstractFloat)` is
5+
# unavailable on Julia 1.10. `x` here is a positive norm, so the signed conversion matches.
6+
intlog2(x) = x > typemax(Int) ? ceil(Int, log2(x)) : intlog2(ceil(Int, x))
37

48
function naivemul!(
59
C::StridedMatrix{T}, A::StridedMatrix{T},

0 commit comments

Comments
 (0)