Skip to content

Latest commit

 

History

History
32 lines (23 loc) · 883 Bytes

README.md

File metadata and controls

32 lines (23 loc) · 883 Bytes

GPU tests

Some tests on Nvidia GPUs.

Summary

This code uses two types of 3D textures.

Both of them contain unsigned short (16 bits) values.

  • The first one will output normalized float. Output values are interpolated by the hardware.
  • The second one will output unsigned short values. We don't use the hardware interpolation : we "manually" compute the interpolation by reading the 8 needed texels.

Then we compare both results. The software interpolation is more precise so we can evaluate the loss of precision when using hardware interpolation.

Supported languages

  • C
  • CUDA

Example

Here are the output you should expect on an Nvidia GTX580.

$ make all
$ make run
./compareHardwareSoftwareTexInterp
L2 norm of difference : 0.015639.
$ make clean

Remark

You can also profile both kernels to compare performance between the two approachs.