Cuda cudaprintf Use

Source: Internet
Author: User

  • Cudaprintfinit and Cudaprintfend only need to be called once in your entire project's use. The display results are not automatically displayed on the screen, but are stored in the cache and are cleared and displayed when Cudaprintfdisplay is called. The size of this cache can be specified by the optional parameters of the function cudaprintfinit (size_t bufferlen).
  • Cudaprintfend simply frees up the storage space requested by Cudaprintfinit. When Cudaprintfdisplay is called, it is stored in cache buffer.the outputOutputwill be displayed in the controlsystem tableConsole. The second parameter in this call is used to control the display (true) Current threadThreadstill not show (false). The first parameter, in this example, is specified as astdout, used to definecuprintfthe log fileLogbe sent to where (stdoutstandard output).
  • Another area to be aware of is that I have found that using cuprintf affects my kernels performance, presumably because each call to cuprintf will perform the data "transfer" Data Transfer .

Above from "Cuprintf.cuh"

Cuda cudaprintf Use

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.