Conversation
Contributor
|
Your PR requires formatting changes to meet the project's style guidelines. Click here to view the suggested changes.diff --git a/src/absint.jl b/src/absint.jl
index e51578b..d5f6d6d 100644
--- a/src/absint.jl
+++ b/src/absint.jl
@@ -255,7 +255,7 @@ function should_recurse(@nospecialize(typ2), @nospecialize(arg_t::LLVM.LLVMType)
end
end
-function get_base_and_offset(@nospecialize(larg::LLVM.Value); offsetAllowed::Bool = true, inttoptr::Bool = false, inst::Union{LLVM.Instruction, Nothing} = nothing, addrcast::Bool=true)::Tuple{LLVM.Value, Int}
+function get_base_and_offset(@nospecialize(larg::LLVM.Value); offsetAllowed::Bool = true, inttoptr::Bool = false, inst::Union{LLVM.Instruction, Nothing} = nothing, addrcast::Bool = true)::Tuple{LLVM.Value, Int}
offset = 0
pinst = isa(larg, LLVM.Instruction) ? larg::LLVM.Instruction : inst
while true
@@ -340,7 +340,7 @@ function abs_typeof(
)::Union{Tuple{Bool, Type, GPUCompiler.ArgumentCC}, Tuple{Bool, Nothing, Nothing}}
if (value_type(arg) == LLVM.PointerType(LLVM.StructType(LLVMType[]), Tracked)) || (value_type(arg) == LLVM.PointerType(LLVM.StructType(LLVMType[]), Derived))
ce, _ = get_base_and_offset(arg; offsetAllowed = false, inttoptr = true)
- if isa(ce, GlobalVariable)
+ if isa(ce, GlobalVariable)
gname = LLVM.name(ce)
for (k, v) in JuliaGlobalNameMap
if gname == k
@@ -786,7 +786,7 @@ function abs_typeof(
end
push!(seen, cur)
for (v, _) in LLVM.incoming(cur)
- v2, off = get_base_and_offset(v, inttoptr=false, addrcast=false)
+ v2, off = get_base_and_offset(v, inttoptr = false, addrcast = false)
if off != 0
if isa(v, LLVM.Instruction) && arg in collect(operands(v))
legal = false
diff --git a/test/runtests.jl b/test/runtests.jl
index 37a42dd..703e188 100644
--- a/test/runtests.jl
+++ b/test/runtests.jl
@@ -819,13 +819,13 @@ end
@testset "1.11 vcat" begin
- function fcat(x)
- r = vcat(Any[1])
- return x
- end
+ function fcat(x)
+ r = vcat(Any[1])
+ return x
+ end
- res = Enzyme.autodiff(Reverse, fcat, Active(2.0))
- @test res[1][1] ≈ 1.0
+ res = Enzyme.autodiff(Reverse, fcat, Active(2.0))
+ @test res[1][1] ≈ 1.0
end
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2602 +/- ##
=======================================
Coverage 75.22% 75.23%
=======================================
Files 56 56
Lines 17742 17748 +6
=======================================
+ Hits 13347 13352 +5
- Misses 4395 4396 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Contributor
Benchmark Results
Benchmark PlotsA plot of the benchmark results has been uploaded as an artifact at https://github.com/EnzymeAD/Enzyme.jl/actions/runs/17897829927/artifacts/4066779511. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.