Rate This Document
Findability
Accuracy
Completeness
Readability

Running and Verification

Procedure

  1. Use PuTTY to log in to the server as the root user.
  2. Verify the Thrust version.
    1. Go to the directory.
      cd /path/to/thrust/include
    2. Create a version.cu file.
      vim version.cu
    3. Press i to enter the insert mode and add the following content:
      #include <thrust/version.h>
      #include <iostream>
      int main(void)
      {
      int major = THRUST_MAJOR_VERSION;
      int minor = THRUST_MINOR_VERSION;
      std::cout << "Thrust v" << major << "." << minor << std::endl;
      return 0;
      }
    4. Press Esc, type :wq!, and press Enter to save the file and exit.
    5. Perform the verification.
      nvcc version.cu -o version
      ./version

      Information similar to the following is displayed:

  3. Verify the built-in test case.
    cd /path/to/thrust/thrust/build/
    ctest

    Information similar to the following is displayed: