Skip to content

Instantly share code, notes, and snippets.

@csullivan
Created August 8, 2018 18:17
Show Gist options
  • Save csullivan/e552d677090f4a0bcc1c8a0772233cbc to your computer and use it in GitHub Desktop.
Save csullivan/e552d677090f4a0bcc1c8a0772233cbc to your computer and use it in GitHub Desktop.
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ sudo apt install clinfo
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ sudo apt install clinfo
[sudo] password for chrissul:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
libnvidia-container-tools libnvidia-container1 nvidia-container-runtime nvidia-container-runtime-hook pigz
Use 'sudo apt autoremove' to remove them.
The following NEW packages will be installed:
clinfo
0 upgraded, 1 newly installed, 0 to remove and 194 not upgraded.
Need to get 30.0 kB of archives.
After this operation, 88.1 kB of additional disk space will be used.
Get:1 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 clinfo amd64 2.1.16.01.12-1 [30.0 kB]
Fetched 30.0 kB in 0s (111 kB/s)
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
Selecting previously unselected package clinfo.
(Reading database ... 319052 files and directories currently installed.)
Preparing to unpack .../clinfo_2.1.16.01.12-1_amd64.deb ...
Unpacking clinfo (2.1.16.01.12-1) ...
Processing triggers for man-db (2.7.5-1) ...
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
Setting up clinfo (2.1.16.01.12-1) ...
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ clinfo
Number of platforms 1
Platform Name NVIDIA CUDA
Platform Vendor NVIDIA Corporation
Platform Version OpenCL 1.2 CUDA 9.2.106
Platform Profile FULL_PROFILE
Platform Extensions cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_fp64 cl_khr_byte_addressable_store cl_khr_icd cl_khr_gl_sharing cl_nv_compiler_options cl_nv_device_attribute_query cl_nv_pragma_unroll cl_nv_copy_opts cl_nv_create_buffer
Platform Extensions function suffix NV
Platform Name NVIDIA CUDA
Number of devices 1
Device Name TITAN Xp
Device Vendor NVIDIA Corporation
Device Vendor ID 0x10de
Device Version OpenCL 1.2 CUDA
Driver Version 396.26
Device OpenCL C Version OpenCL C 1.2
Device Type GPU
Device Profile FULL_PROFILE
Device Topology (NV) PCI-E, 0f:00.0
Max compute units 30
Max clock frequency 1582MHz
Compute Capability (NV) 6.1
Device Partition (core)
Max number of sub-devices 1
Supported partition types None
Max work item dimensions 3
Max work item sizes 1024x1024x64
Max work group size 1024
Preferred work group size multiple 32
Warp size (NV) 32
Preferred / native vector sizes
char 1 / 1
short 1 / 1
int 1 / 1
long 1 / 1
half 0 / 0 (n/a)
float 1 / 1
double 1 / 1 (cl_khr_fp64)
Half-precision Floating-point support (n/a)
Single-precision Floating-point support (core)
Denormals Yes
Infinity and NANs Yes
Round to nearest Yes
Round to zero Yes
Round to infinity Yes
IEEE754-2008 fused multiply-add Yes
Support is emulated in software No
Correctly-rounded divide and sqrt operations Yes
Double-precision Floating-point support (cl_khr_fp64)
Denormals Yes
Infinity and NANs Yes
Round to nearest Yes
Round to zero Yes
Round to infinity Yes
IEEE754-2008 fused multiply-add Yes
Support is emulated in software No
Correctly-rounded divide and sqrt operations No
Address bits 64, Little-Endian
Global memory size 12788498432 (11.91GiB)
Error Correction support No
Max memory allocation 3197124608 (2.978GiB)
Unified memory for Host and Device No
Integrated memory (NV) No
Minimum alignment for any data type 128 bytes
Alignment of base address 4096 bits (512 bytes)
Global Memory cache type Read/Write
Global Memory cache size 491520
Global Memory cache line 128 bytes
Image support Yes
Max number of samplers per kernel 32
Max size for 1D images from buffer 134217728 pixels
Max 1D or 2D image array size 2048 images
Max 2D image size 16384x32768 pixels
Max 3D image size 16384x16384x16384 pixels
Max number of read image args 256
Max number of write image args 16
Local memory type Local
Local memory size 49152 (48KiB)
Registers per block (NV) 65536
Max constant buffer size 65536 (64KiB)
Max number of constant args 9
Max size of kernel argument 4352 (4.25KiB)
Queue properties
Out-of-order execution Yes
Profiling Yes
Prefer user sync for interop No
Profiling timer resolution 1000ns
Execution capabilities
Run OpenCL kernels Yes
Run native kernels No
Kernel execution timeout (NV) No
Concurrent copy and kernel execution (NV) Yes
Number of async copy engines 2
printf() buffer size 1048576 (1024KiB)
Built-in kernels
Device Available Yes
Compiler Available Yes
Linker Available Yes
Device Extensions cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_fp64 cl_khr_byte_addressable_store cl_khr_icd cl_khr_gl_sharing cl_nv_compiler_options cl_nv_device_attribute_query cl_nv_pragma_unroll cl_nv_copy_opts cl_nv_create_buffer
NULL platform behavior
clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...) No platform
clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...) No platform
clCreateContext(NULL, ...) [default] No platform
clCreateContext(NULL, ...) [other] Success [NV]
clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU) No platform
clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU) No platform
clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR) No platform
clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM) No platform
clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL) No platform
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ sudo add-apt-repository ppa:graphics-drivers/ppa && sudo apt update
Fresh drivers from upstream, currently shipping Nvidia.
## Current Status
Current short-lived branch release: `nvidia-396` (396.24)
Dropped support for Fermi series (https://nvidia.custhelp.com/app/answers/detail/a_id/4656)
Current long-lived branch release: `nvidia-390` (390.48)
Old long-lived branch release: `nvidia-384` (384.130)
For G8x, G9x and GT2xx GPUs use `nvidia-340` (340.106)
For NV4x and G7x GPUs use `nvidia-304` (304.137) End-Of-Life!
Support timeframes for Unix legacy GPU releases:
https://nvidia.custhelp.com/app/answers/detail/a_id/3142
## What we're working on right now:
- Normal driver updates
- Help Wanted: Mesa Updates for Intel/AMD users, ping us if you want to help do this work, we're shorthanded.
## WARNINGS:
This PPA is currently in testing, you should be experienced with packaging before you dive in here:
Volunteers welcome! See also: https://github.com/mamarley/nvidia-graphics-drivers/
### How you can help:
## Install PTS and benchmark your gear:
    sudo apt-get install phoronix-test-suite
Run the benchmark:
    phoronix-test-suite default-benchmark openarena xonotic tesseract gputest unigine-valley
and then say yes when it asks you to submit your results to openbechmarking.org. Then grab a cup of coffee, it takes a bit for the benchmarks to run. Depending on the version of Ubuntu you're using it might preferable for you to grabs PTS from upstream directly: http://www.phoronix-test-suite.com/?k=downloads
## Share your results with the community:
Post a link to your results (or any other feedback to): https://launchpad.net/~graphics-drivers-testers
Remember to rerun and resubmit the benchmarks after driver upgrades, this will allow us to gather a bunch of data on performance that we can share with everybody.
If you run into old documentation referring to other PPAs, you can help us by consolidating references to this PPA.
If someone wants to go ahead and start prototyping on `software-properties-gtk` on what the GUI should look like, please start hacking!
## Help us Help You!
We use the donation funds to get the developers hardware to test and upload these drivers, please consider donating to the "community" slider on the donation page if you're loving this PPA:
http://www.ubuntu.com/download/desktop/contribute
More info: https://launchpad.net/~graphics-drivers/+archive/ubuntu/ppa
Press [ENTER] to continue or ctrl-c to cancel adding it
gpg: keyring `/tmp/tmpp8m01qas/secring.gpg' created
gpg: keyring `/tmp/tmpp8m01qas/pubring.gpg' created
gpg: requesting key 1118213C from hkp server keyserver.ubuntu.com
gpg: /tmp/tmpp8m01qas/trustdb.gpg: trustdb created
gpg: key 1118213C: public key "Launchpad PPA for Graphics Drivers Team" imported
gpg: no ultimately trusted keys found
gpg: Total number processed: 1
gpg: imported: 1 (RSA: 1)
OK
Get:1 http://apt.llvm.org/xenial llvm-toolchain-xenial-3.9 InRelease [4,207 B]
Hit:3 http://archive.canonical.com/ubuntu xenial InRelease
Get:4 http://us.archive.ubuntu.com/ubuntu xenial InRelease [247 kB]
Hit:5 https://nvidia.github.io/libnvidia-container/ubuntu16.04/amd64 InRelease
Hit:6 https://nvidia.github.io/nvidia-container-runtime/ubuntu16.04/amd64 InRelease
Hit:7 https://download.docker.com/linux/ubuntu xenial InRelease
Hit:8 https://nvidia.github.io/nvidia-docker/ubuntu16.04/amd64 InRelease
Hit:9 https://apt.dockerproject.org/repo ubuntu-xenial InRelease
Ign:10 https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 InRelease
Hit:11 https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 Release
Get:12 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu xenial InRelease [24.3 kB]
Get:13 http://archive.ubuntu.com/ubuntu xenial InRelease [247 kB]
Ign:14 https://artifacts.elastic.co/packages/6.x/apt stable InRelease
Hit:2 https://packages.cloud.google.com/apt kubernetes-xenial InRelease
Hit:15 https://artifacts.elastic.co/packages/6.x/apt stable Release
Get:16 http://us.archive.ubuntu.com/ubuntu xenial-security InRelease [107 kB]
Hit:17 http://ppa.launchpad.net/mystic-mirage/pycharm/ubuntu xenial InRelease
Get:18 http://us.archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB]
Hit:20 http://ppa.launchpad.net/git-core/ppa/ubuntu xenial InRelease
Get:21 http://archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB]
Hit:23 http://ppa.launchpad.net/ubuntu-toolchain-r/test/ubuntu xenial InRelease
Get:24 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu xenial/main amd64 Packages [12.5 kB]
Get:25 http://us.archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages [825 kB]
Get:26 http://us.archive.ubuntu.com/ubuntu xenial-updates/main i386 Packages [751 kB]
Get:27 http://us.archive.ubuntu.com/ubuntu xenial-updates/universe amd64 Packages [679 kB]
Get:28 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu xenial/main i386 Packages [11.8 kB]
Get:29 http://us.archive.ubuntu.com/ubuntu xenial-updates/universe i386 Packages [619 kB]
Get:30 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages [825 kB]
Get:31 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu xenial/main Translation-en [4,344 B]
Get:32 http://archive.ubuntu.com/ubuntu xenial-updates/main i386 Packages [751 kB]
Get:33 http://archive.ubuntu.com/ubuntu xenial-updates/universe amd64 Packages [679 kB]
Get:34 http://archive.ubuntu.com/ubuntu xenial-updates/universe i386 Packages [619 kB]
Fetched 6,622 kB in 2s (2,513 kB/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
194 packages can be upgraded. Run 'apt list --upgradable' to see them.
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ nvidia-smi
Wed Aug 8 08:34:41 2018
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 396.26 Driver Version: 396.26 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
|===============================+======================+======================|
| 0 TITAN Xp Off | 00000000:06:00.0 Off | N/A |
| 23% 28C P8 17W / 250W | 588MiB / 12196MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 1 TITAN Xp Off | 00000000:07:00.0 Off | N/A |
| 23% 28C P8 16W / 250W | 444MiB / 12196MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 2 TITAN Xp Off | 00000000:0C:00.0 Off | N/A |
| 35% 58C P2 85W / 250W | 8973MiB / 12196MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 3 TITAN Xp Off | 00000000:0F:00.0 Off | N/A |
| 23% 28C P8 16W / 250W | 442MiB / 12196MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: GPU Memory |
| GPU PID Type Process name Usage |
|=============================================================================|
| 0 6048 C python 363MiB |
| 0 78093 C ...te/home/abhiwand/tensorflow/bin/python3 215MiB |
| 1 6048 C python 217MiB |
| 1 78093 C ...te/home/abhiwand/tensorflow/bin/python3 215MiB |
| 2 6048 C python 217MiB |
| 2 75389 C python 8529MiB |
| 2 78093 C ...te/home/abhiwand/tensorflow/bin/python3 215MiB |
| 3 6048 C python 217MiB |
| 3 78093 C ...te/home/abhiwand/tensorflow/bin/python3 215MiB |
+-----------------------------------------------------------------------------+
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ nvidia-modprobe
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ nvidia-modprobe -h
nvidia-modprobe: version 396.26 (root@eris-linux-build008) Mon Apr 30 16:01:56 PDT 2018
This setuid program is used to create, in a Linux distribution-independent way, NVIDIA Linux device files and load the NVIDIA kernel module, on behalf of NVIDIA Linux driver components which may not have sufficient privileges to perform these actions on their own.
nvidia-modprobe [options]
-v, --version
Print the utility version and exit.
-h, --help
Print usage information for the command line options and exit.
-c MINOR-NUMBER, --create-nvidia-device-file=MINOR-NUMBER
Create the NVIDIA device file with the given minor number; this option can be specified multiple times to create multiple NVIDIA device files.
-i MODULE-INSTANCE, --module-instance=MODULE-INSTANCE
Load the required NVIDIA kernel module that corresponds to the specified MODULE-INSTANCE value. The value should be between 0 and 7.
-u, --unified-memory
Load the NVIDIA Unified Memory kernel module or create device files for it, instead of the NVIDIA kernel module.
-m, --modeset
Load the NVIDIA modeset kernel module and create its device file.
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ sudo apt install nvidia-opencl-icd-396
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
libnvidia-container-tools libnvidia-container1 nvidia-container-runtime nvidia-container-runtime-hook pigz
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
nvidia-396
The following packages will be upgraded:
nvidia-396 nvidia-opencl-icd-396
2 upgraded, 0 newly installed, 0 to remove and 192 not upgraded.
Need to get 81.5 MB of archives.
After this operation, 1,481 kB of additional disk space will be used.
Do you want to continue? [Y/n] n
Abort.
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ sudo apt install nvidia-opencl-icd-396 libcuda1-396
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
libnvidia-container-tools libnvidia-container1 nvidia-container-runtime nvidia-container-runtime-hook pigz
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
nvidia-396
The following packages will be upgraded:
libcuda1-396 nvidia-396 nvidia-opencl-icd-396
3 upgraded, 0 newly installed, 0 to remove and 191 not upgraded.
Need to get 84.9 MB of archives.
After this operation, 1,436 kB of additional disk space will be used.
Do you want to continue? [Y/n] ^C
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ sudo apt install nvidia-opencl-icd-396
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
libnvidia-container-tools libnvidia-container1 nvidia-container-runtime nvidia-container-runtime-hook pigz
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
nvidia-396
The following packages will be upgraded:
nvidia-396 nvidia-opencl-icd-396
2 upgraded, 0 newly installed, 0 to remove and 192 not upgraded.
Need to get 81.5 MB of archives.
After this operation, 1,481 kB of additional disk space will be used.
Do you want to continue? [Y/n]
Get:1 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu xenial/main amd64 nvidia-396 amd64 396.51-0ubuntu0~gpu16.04.1 [78.0 MB]
Get:2 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu xenial/main amd64 nvidia-opencl-icd-396 amd64 396.51-0ubuntu0~gpu16.04.1 [3,544 kB]
Fetched 81.5 MB in 3min 44s (364 kB/s)
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
(Reading database ... 319057 files and directories currently installed.)
Preparing to unpack .../nvidia-396_396.51-0ubuntu0~gpu16.04.1_amd64.deb ...
Removing all DKMS Modules
Done.
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
Unpacking nvidia-396 (396.51-0ubuntu0~gpu16.04.1) over (396.26-0ubuntu1) ...
Preparing to unpack .../nvidia-opencl-icd-396_396.51-0ubuntu0~gpu16.04.1_amd64.deb ...
Unpacking nvidia-opencl-icd-396 (396.51-0ubuntu0~gpu16.04.1) over (396.26-0ubuntu1) ...
Processing triggers for libc-bin (2.23-0ubuntu10) ...
Processing triggers for ureadahead (0.100.0-19) ...
Processing triggers for man-db (2.7.5-1) ...
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
Setting up nvidia-396 (396.51-0ubuntu0~gpu16.04.1) ...
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
update-alternatives: renaming x86_64-linux-gnu_nvidia_app_profile slave link from /usr/share/nvidia/nvidia-application-profiles-396.26-rc to /usr/share/nvidia/nvidia-application-profiles-396.51-rc
update-alternatives: renaming x86_64-linux-gnu_nvidia_app_profile_keys slave link from /usr/share/nvidia/nvidia-application-profiles-396.26-key-documentation to /usr/share/nvidia/nvidia-application-profiles-396.51-key-documentation
update-alternatives: warning: forcing reinstallation of alternative /usr/lib/nvidia-396/ld.so.conf because link group x86_64-linux-gnu_gl_conf is broken
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
update-initramfs: deferring update (trigger activated)
INFO:Enable nvidia-396
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/dell_latitude
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/lenovo_thinkpad
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/put_your_quirks_here
Loading new nvidia-396-396.51 DKMS files...
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
Building only for 4.4.0-128-generic
Building for architecture x86_64
Building initial module for 4.4.0-128-generic
Done.
nvidia_396:
Running module version sanity check.
- Original module
- No original module exists within this kernel
- Installation
- Installing to /lib/modules/4.4.0-128-generic/updates/dkms/
nvidia_396_modeset.ko:
Running module version sanity check.
- Original module
- No original module exists within this kernel
- Installation
- Installing to /lib/modules/4.4.0-128-generic/updates/dkms/
nvidia_396_drm.ko:
Running module version sanity check.
- Original module
- No original module exists within this kernel
- Installation
- Installing to /lib/modules/4.4.0-128-generic/updates/dkms/
nvidia_396_uvm.ko:
Running module version sanity check.
- Original module
- No original module exists within this kernel
- Installation
- Installing to /lib/modules/4.4.0-128-generic/updates/dkms/
depmod....
DKMS: install completed.
Setting up nvidia-opencl-icd-396 (396.51-0ubuntu0~gpu16.04.1) ...
Processing triggers for libc-bin (2.23-0ubuntu10) ...
Processing triggers for initramfs-tools (0.122ubuntu8.11) ...
update-initramfs: Generating /boot/initrd.img-4.4.0-128-generic
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
W: Possible missing firmware /lib/firmware/ast_dp501_fw.bin for module ast
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
W: mdadm: /etc/mdadm/mdadm.conf defines no arrays.
dpkg: warning: failed to open configuration file '/nfs/site/home/chrissul/.dpkg.cfg' for reading: Permission denied
chrissul@nervana-titanxp22 /localdisk/sullivan/projects $ nvidia-smi
Failed to initialize NVML: Driver/library version mismatch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment