Send Feedback
Skip to content

GPU Module in KDB-X

This page explains what the GPU module is in KDB-X and when to use it.

If you would like to evaluate KDB-X GPU acceleration, please email devrel@kx.com with your request.

Key features

The GPU module:

  • Supports moving data to and from the GPU with the ability to append data in batches.
  • Supports a restricted set of qSQL queries on the GPU using standard q syntax.
  • Supports sorting of in-memory tables on the GPU using standard q syntax.
  • Supports as-of joins with attributes on the GPU using standard q syntax.

When to use the GPU module

Use the GPU module whenever you:

  • Have workflows that benefit from parallelization across many threads.
  • Have data resident in memory on the GPU and want improved performance.

Key terms

The following terms describe how data is stored, moved, and interpreted between the CPU and GPU:

  • On-device: Data resident in GPU VRAM, represented in q as foreign.
  • On-host: Data resident in CPU RAM, accessible to standard q operations.
  • Foreign: The q representation of an on-device object.
  • Mixed residency: A table where some columns are on-device and others on-host.
  • Grouped attribute: A q attribute (`g#) required for certain GPU operations such as .gpu.bin and .gpu.aj.
  • VRAM: GPU memory, distinct from system RAM.
  • CUDA kernel: A function executed in parallel across GPU threads, distinct from the OS kernel.

Next steps

  • To get started with the GPU module, refer to the Quickstart.