forked from JuliaGPU/CUDA.jl
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
215 additions
and
317 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
# This file is machine-generated - editing it directly is not advised | ||
|
||
[[Base64]] | ||
uuid = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f" | ||
|
||
[[Dates]] | ||
deps = ["Printf"] | ||
uuid = "ade2ca70-3891-5945-98fb-dc099432e06a" | ||
|
||
[[Distributed]] | ||
deps = ["Random", "Serialization", "Sockets"] | ||
uuid = "8ba89e20-285c-5b6f-9357-94700520ee1b" | ||
|
||
[[DocStringExtensions]] | ||
deps = ["LibGit2", "Markdown", "Pkg", "Test"] | ||
git-tree-sha1 = "88bb0edb352b16608036faadcc071adda068582a" | ||
uuid = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae" | ||
version = "0.8.1" | ||
|
||
[[Documenter]] | ||
deps = ["Base64", "Dates", "DocStringExtensions", "InteractiveUtils", "JSON", "LibGit2", "Logging", "Markdown", "REPL", "Test", "Unicode"] | ||
git-tree-sha1 = "885467cebde4639a3d81953652cc53ff5a73cb87" | ||
uuid = "e30172f5-a6a5-5a46-863b-614d45cd2de4" | ||
version = "0.24.3" | ||
|
||
[[InteractiveUtils]] | ||
deps = ["Markdown"] | ||
uuid = "b77e0a4c-d291-57a0-90e8-8db25a27a240" | ||
|
||
[[JSON]] | ||
deps = ["Dates", "Mmap", "Parsers", "Unicode"] | ||
git-tree-sha1 = "b34d7cef7b337321e97d22242c3c2b91f476748e" | ||
uuid = "682c06a0-de6a-54ab-a142-c8b1cf79cde6" | ||
version = "0.21.0" | ||
|
||
[[LibGit2]] | ||
uuid = "76f85450-5226-5b5a-8eaa-529ad045b433" | ||
|
||
[[Libdl]] | ||
uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb" | ||
|
||
[[Logging]] | ||
uuid = "56ddb016-857b-54e1-b83d-db4d58db5568" | ||
|
||
[[Markdown]] | ||
deps = ["Base64"] | ||
uuid = "d6f4376e-aef5-505a-96c1-9c027394607a" | ||
|
||
[[Mmap]] | ||
uuid = "a63ad114-7e13-5084-954f-fe012c677804" | ||
|
||
[[Parsers]] | ||
deps = ["Dates", "Test"] | ||
git-tree-sha1 = "0139ba59ce9bc680e2925aec5b7db79065d60556" | ||
uuid = "69de0a69-1ddd-5017-9359-2bf0b02dc9f0" | ||
version = "0.3.10" | ||
|
||
[[Pkg]] | ||
deps = ["Dates", "LibGit2", "Libdl", "Logging", "Markdown", "Printf", "REPL", "Random", "SHA", "UUIDs"] | ||
uuid = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f" | ||
|
||
[[Printf]] | ||
deps = ["Unicode"] | ||
uuid = "de0858da-6303-5e67-8744-51eddeeeb8d7" | ||
|
||
[[REPL]] | ||
deps = ["InteractiveUtils", "Markdown", "Sockets"] | ||
uuid = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb" | ||
|
||
[[Random]] | ||
deps = ["Serialization"] | ||
uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" | ||
|
||
[[SHA]] | ||
uuid = "ea8e919c-243c-51af-8825-aaa63cd721ce" | ||
|
||
[[Serialization]] | ||
uuid = "9e88b42a-f829-5b0c-bbe9-9e923198166b" | ||
|
||
[[Sockets]] | ||
uuid = "6462fe0b-24de-5631-8697-dd941f90decc" | ||
|
||
[[Test]] | ||
deps = ["Distributed", "InteractiveUtils", "Logging", "Random"] | ||
uuid = "8dfed614-e22c-5e08-85e1-65c5234f0b40" | ||
|
||
[[UUIDs]] | ||
deps = ["Random", "SHA"] | ||
uuid = "cf7118a7-6976-5b1a-9a39-7adc72f591a4" | ||
|
||
[[Unicode]] | ||
uuid = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5" |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,28 @@ | ||
using Documenter, CUDAdrv | ||
|
||
makedocs( | ||
modules = [CUDAdrv], | ||
format = Documenter.HTML(prettyurls = get(ENV, "CI", nothing) == "true"), | ||
sitename = "CUDAdrv.jl", | ||
pages = [ | ||
"Home" => "index.md", | ||
"Manual" => [ | ||
"man/usage.md" | ||
], | ||
"Library" => [ | ||
"lib/api.md", | ||
const src = "https://github.com/JuliaGPU/CUDAdrv.jl" | ||
const dst = "https://juliagpu.gitlab.io/CUDAdrv.jl/" | ||
|
||
function main() | ||
makedocs( | ||
sitename = "CUDAdrv.jl", | ||
authors = "Tim Besard", | ||
repo = "$src/blob/{commit}{path}#{line}", | ||
format = Documenter.HTML( | ||
# Use clean URLs on CI | ||
prettyurls = get(ENV, "CI", nothing) == "true", | ||
canonical = dst, | ||
assets = ["assets/favicon.ico"], | ||
analytics = "UA-154489943-5", | ||
), | ||
doctest = false, | ||
pages = Any[ | ||
"Home" => "index.md", | ||
"APIs" => [ | ||
"driver.md", | ||
] | ||
] | ||
], | ||
doctest = true | ||
) | ||
) | ||
end | ||
|
||
isinteractive() || main() |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,56 +1,10 @@ | ||
# CUDAdrv.jl | ||
|
||
*A Julia wrapper for the CUDA driver API.* | ||
|
||
This package aims to provide high-level wrappers for the functionality exposed by the CUDA | ||
driver API, and is meant for users who need high- or low-level access to the CUDA toolkit or | ||
the underlying hardware. | ||
|
||
The package is built upon the [low-level CUDA driver | ||
API](http:https://docs.nvidia.com/cuda/cuda-driver-api/), but that shouldn't make the Julia | ||
wrapper any harder to use. That said, it is a work-in-progress and does not offer the same | ||
functionality or convenience as the more popular | ||
[CUDArt](https://github.com/JuliaGPU/CUDArt.jl) package, which is built upon the | ||
[higher-level CUDA runtime API](http:https://docs.nvidia.com/cuda/cuda-runtime-api/). | ||
|
||
|
||
## Installation | ||
|
||
Requirements: | ||
|
||
* Julia 0.5 or higher (use | ||
[v0.1.0](https://github.com/JuliaGPU/CUDAdrv.jl/releases/tag/v0.1.0) of this package | ||
for compatibility with Julia 0.4) | ||
* NVIDIA driver, providing `libcuda.so` (the full CUDA toolkit is not required) | ||
* CUDA hardware | ||
|
||
At the Julia REPL: | ||
|
||
```julia | ||
Pkg.add("CUDAdrv") | ||
using CUDAdrv | ||
|
||
# optionally | ||
Pkg.test("CUDAdrv") | ||
``` | ||
|
||
Loading CUDAdrv might display error messages, indicating issues with your set-up. These | ||
messages can be cryptic as they happen too early for decent error handling to be loaded. | ||
However, please pay close attention to them as they might prevent CUDAdrv.jl from working | ||
properly! Some common issues: | ||
|
||
* unknown error (code 999): this often indicates that your set-up is broken, eg. because you | ||
didn't load the correct, or any, kernel module. Please verify your set-up, on Linux by | ||
executing `nvidia-smi` or on other platforms by compiling and running CUDA C code using | ||
`nvcc`. | ||
* no device (code 100): CUDA didn't detect your device, because it is not supported by CUDA | ||
or because you loaded the wrong kernel driver (eg. legacy when you need regular, or | ||
vice-versa). CUDAdrv.jl cannot work in this case, because CUDA does not allow us to query | ||
the driver version without a valid device, something we need in order to version the API | ||
calls. | ||
* using library stubs (code -1): if any API call returns -1, you're probably using the CUDA | ||
driver library stubs which return this value for every function call. This is not | ||
supported by CUDAdrv.jl, and is only intended to be used when compiling C or C++ code to | ||
be linked with `libcuda.so` at a time when that library isn't available yet. Unless you | ||
purposefully added the stub libraries to the search path, please run the build script with | ||
`JULIA_DEBUG=CUDAdrv` and file a bug report. | ||
Welcome to the API reference documentation of CUDAdrv.jl. This documentation is a work in | ||
progress. For general usage instructions of CUDAdrv.jl and the rest of the Julia CUDA | ||
toolchain, please refer to the [CUDA.jl documentation](https://juliagpu.gitlab.io/CUDA.jl/). | ||
|
||
Even though this package is built on the [low-level CUDA driver | ||
API](http:https://docs.nvidia.com/cuda/cuda-driver-api/), that should not scare you: The wrappers | ||
provided by CUDAdrv.jl are high level, and generally work similar to the higher-level CUDA | ||
runtime API. |
Oops, something went wrong.