Skip to content

start newpm migration#2475

Closed
oscardssmith wants to merge 2 commits intoEnzymeAD:mainfrom
oscardssmith:os/newpm
Closed

start newpm migration#2475
oscardssmith wants to merge 2 commits intoEnzymeAD:mainfrom
oscardssmith:os/newpm

Conversation

@oscardssmith
Copy link
Collaborator

No description provided.

@github-actions
Copy link
Contributor

github-actions bot commented Jul 14, 2025

Your PR requires formatting changes to meet the project's style guidelines.
Please consider running Runic (git runic main) to apply these changes.

Click here to view the suggested changes.
diff --git a/src/compiler.jl b/src/compiler.jl
index 82a11400..24e45a4c 100644
--- a/src/compiler.jl
+++ b/src/compiler.jl
@@ -4375,9 +4375,9 @@ function GPUCompiler.compile_unhooked(output::Symbol, job::CompilerJob{<:EnzymeT
         permit_inlining!(f)
     end
 
-    LLVM.@dispose pb=LLVM.NewPMPassBuilder() begin
+    LLVM.@dispose pb = LLVM.NewPMPassBuilder() begin
         @ccall libEnzyme.registerEnzymeAndPassPipeline(pb::Ptr{Cvoid}, 0::UInt8)::Cvoid
-        
+
         LLVM.add!(pb, LLVM.NewPMModulePassManager()) do mpm
             LLVM.add!(mpm, PreserveNVVMPass(true))
         end
diff --git a/src/compiler/optimize.jl b/src/compiler/optimize.jl
index d966d087..046bd4b7 100644
--- a/src/compiler/optimize.jl
+++ b/src/compiler/optimize.jl
@@ -66,7 +66,7 @@ function run_jl_pipeline(pm::ModulePassManager, tm::LLVM.TargetMachine; kwargs..
         end
         return true
     end
-    add!(pm, NewPMModulePass("JLPipeline", jl_pipeline))
+    return add!(pm, NewPMModulePass("JLPipeline", jl_pipeline))
 end
 
 @static if VERSION < v"1.11.0-DEV.428"
@@ -365,7 +365,7 @@ else
             end
             return true
         end
-        add!(pm, NewPMModulePass("CombineMulAdd", combine_mul_add))
+            add!(pm, NewPMModulePass("CombineMulAdd", combine_mul_add))
 end
     end
 end

@codecov
Copy link

codecov bot commented Jul 14, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 30.23%. Comparing base (df2a49a) to head (2d70da2).
⚠️ Report is 49 commits behind head on main.

❗ There is a different number of reports uploaded between BASE (df2a49a) and HEAD (2d70da2). Click for more details.

HEAD has 14 uploads less than BASE
Flag BASE (df2a49a) HEAD (2d70da2)
17 3
Additional details and impacted files
@@             Coverage Diff             @@
##             main    #2475       +/-   ##
===========================================
- Coverage   75.16%   30.23%   -44.94%     
===========================================
  Files          57        2       -55     
  Lines       17821      215    -17606     
===========================================
- Hits        13395       65    -13330     
+ Misses       4426      150     -4276     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

end

LLVM.ModulePassManager() do pm
LLVM.@dispose pb=LLVM.NewPMPassBuilder() begin
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's start to begin with just the preservenvvm being moved over (and leave the others the same, to confirm)

@giordano giordano added the Julia v1.12 Related to compatibility with Julia v1.12 label Oct 12, 2025
@vchuravy
Copy link
Member

replaced by #2675

@vchuravy vchuravy closed this Oct 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Julia v1.12 Related to compatibility with Julia v1.12

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants