Skip to content

Commit

Permalink
enable LLVM6 (#917)
Browse files Browse the repository at this point in the history
* initial attempt at LLVM6

* fix up older julia

* another <1.9 fix

* fix 1.6

* remove redundant ctx

* fix for older julia

* typo

* bit more ctx work

* workaround do bug

* WIP

* wip

* WIP

* spurious ctx

* take out Metal for older julia

* fix for older julia

* cleanup context mess

* fixes for older julia

* Only test Metal on macOS aarch64

* WIP

* WIP

* move context stuff to top level calls

* clean tests

* older julia compat

* fix up old julia

* reset test tolerance

* changes to indent

* idents

* rm stray ctx

* don't mention ThreadSafeContext without has_orc_v2

* rm stray ctx

* move all ctx to @generated and trampoline

* orcv1 support

* bump enzyme

* cleanup formatting and JuliaContext removal

* revert Apple arm-specific test changes

* Delete Manifest.toml

* Update .gitignore
  • Loading branch information
motabbara authored Jul 12, 2023
1 parent 07ca881 commit a40e790
Show file tree
Hide file tree
Showing 17 changed files with 1,194 additions and 1,259 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
*.jl.cov
*.jl.mem
/Manifest.toml
/test/Manifest.toml
/docs/Manifest.toml
/docs/build/

Expand Down
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
CEnum = "0.4"
EnzymeCore = "0.5"
Enzyme_jll = "0.0.74"
GPUCompiler = "0.20, 0.21.0"
LLVM = "5"
GPUCompiler = "0.21.3"
LLVM = "6"
ObjectFile = "0.4"
julia = "1.6"
8 changes: 4 additions & 4 deletions src/api.jl
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@ IntList() = IntList(Ptr{Int64}(0),0)
DT_Unknown = 6
)

function EnzymeConcreteTypeIsFloat(cc::CConcreteType, ctx)
function EnzymeConcreteTypeIsFloat(cc::CConcreteType)
if cc == DT_Half
return LLVM.HalfType(ctx)
return LLVM.HalfType()
elseif cc == DT_Float
return LLVM.FloatType(ctx)
return LLVM.FloatType()
elseif cc == DT_Double
return LLVM.DoubleType(ctx)
return LLVM.DoubleType()
else
return nothing
end
Expand Down
Loading

0 comments on commit a40e790

Please sign in to comment.