GPU-to-CPU Callbacks

  • Jeff A. Stuart
  • Michael Cox
  • John D. Owens
Part of the Lecture Notes in Computer Science book series (LNCS, volume 6586)


We present GPU-to-CPU callbacks, a new mechanism and abstraction for GPUs that offers them more independence in a heterogeneous computing environment. Specifically, we provide a method for GPUs to issue callback requests to the CPU. These requests serve as a tool for ease-of-use, future proofing of code, and new functionality. We classify the types of these requests into three categories: System calls (e.g. network and file I/O), device/host memory transfers, and CPU compute, and provide motivation as to why all are important. We show how to implement such a mechanism in CUDA using pinned system memory and discuss possible GPU-driver features to alleviate the need for polling, thus making callbacks more efficient with CPU usage and power consumption. We implement several examples demonstrating the use of callbacks for file I/O, network I/O, memory allocation, and debugging.


System Call Memory Allocation Memory Transfer Thread Processor Software Advancement 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. 1.
    Advanced Micro Devices. Coming soon: The AMD fusion family of APUsGoogle Scholar
  2. 2.
    Hou, Q., Zhou, K., Guo, B.: Debugging GPU stream programs through automatic dataflow recording and visualization. ACM Transactions on Graphics 153(5), 153:1–153:11 (2009)CrossRefGoogle Scholar
  3. 3.
    NVIDIA Corporation. CUDA-GDB: The NVIDIA CUDA debugger (2008),
  4. 4.
    NVIDIA Corporation. NVIDIA CUDA compute unified device architecture programming guide (February 2010),
  5. 5.
    Stuart, J.A., Owens, J.D.: Message passing on data-parallel architectures. In: Proceedings of the 23rd IEEE International Parallel and Distributed Processing Symposium (May 2009)Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2011

Authors and Affiliations

  • Jeff A. Stuart
    • 1
  • Michael Cox
    • 2
  • John D. Owens
    • 1
  1. 1.University of CaliforniaDavisUSA
  2. 2.NVIDIA CorporationUSA

Personalised recommendations