Skip to content

Commit

Permalink
Precompiled kernels documentation update (#2402)
Browse files Browse the repository at this point in the history
* Install instructions for Kernel Cache

* Correct typo

* Nit picks

* update README
  • Loading branch information
JehandadKhan authored Apr 1, 2020
1 parent 82b61f1 commit 3a716fe
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,18 @@ For HIP backend: `apt-get install miopen-hip`

Currently both the backends cannot be installed on the same system simultaneously. If a different backend other than what currently exists on the system is desired, please uninstall the existing backend completely and then install the new backend.

## Installing MIOpen kernels package

MIOpen provides an optional pre-compiled kernels package to reduce the startup latency. To install the kernels package for your GPU architecture, use the following command:

```
apt-get install miopen-kernels-<arch>-<num cu>
```

Where `<arch>` is the GPU architecture ( for example, `gfx900`, `gfx906` ) and `<num cu>` is the number of CUs available in the GPU (for example 56 or 64 etc).

Not installing these packages would not impact the functioning of MIOpen, since MIOpen will compile these kernels on the target machine once the kernel is run. However, the compilation step may significantly increase the startup time for different operations.


## Installing the dependencies

Expand Down
10 changes: 9 additions & 1 deletion doc/src/cache.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,12 @@ The are several ways to disable the cache. This is generally useful for developm
Updating MIOpen and removing the cache
--------------------------------------
If the compiler changes, or the user modifies the kernels then the cache must be deleted for the MIOpen version in use; e.g., `rm -rf ~/.cache/miopen/<miopen-version-number>`.



Installing pre-compiled kernels
-------------------------------
GPU architecture-specific pre-compiled kernel packages are available in the ROCm package repositories, to reduce the startup latency of MIOpen kernels. In essence, these packages have the kernel cache file mentioned above and install them in the ROCm installation directory along with other MIOpen artifacts. Thus, when launching a kernel, MIOpen will first check for the existence of a kernel in the kernel cache installed in the MIOpen installation directory. If the file does not exist or the required kernel is not found, the kernel is compiled and placed in the user's kernel cache.

These packages are optional for the functioning of MIOpen and must be separately installed from MIOpen. Users who wish to conserve disk space may choose not to install these packages at the cost of higher startup latency. Users have the flexibility to only install kernel packages for installed device architecture, thus minimizing disk space usage.

Please refer to the MIOpen installation instructions for guidance on installing the MIOpen kernels package.

0 comments on commit 3a716fe

Please sign in to comment.