Changes between Version 18 and Version 19 of GPUApp


Ignore:
Timestamp:
Jul 19, 2010, 4:46:46 PM (14 years ago)
Author:
TuanLe
Comment:

add NVIDIA OpenCL and ATIStream OpenCL for Mac OS X

Legend:

Unmodified
Added
Removed
Modified
  • GPUApp

    v18 v19  
    1717Note that NVIDIA Cuda SDK 3.0 or older supports device emulation mode.
    1818If your machine doesn't have a CUDA-enabled GPU,
    19 then you should build the sample app in the device emulation mode.
     19then you should build the sample application in the device emulation mode.
    2020Do so by setting "Build -> Configuration Manger -> Configuration" to either Emudebug or Emurelease.
    2121
     
    6868On my Linux machine, for example, it would be "$(ROOT)/home/tuanle/NVIDIA_GPU_Computing_SDK/".
    6969Since the absolute path is used in Makefile,
    70 you will probably need to edit file "common.mk" before compiling the sample app.
     70you will probably need to edit file "common.mk" before compiling the sample application.
    7171Do so by looking for "/home/tuanle/NVIDIA_GPU_Computing_SDK" in file "common.mk"
    7272and replace this path with an appropriate path on your machine.
     
    8383As far as we know, NVIDIA Cuda SDK 3.1 no longer supports emulation mode.
    8484Thus, you will need to install an older Cuda SDK version, like version 3.0, on your machine.
    85 To make an executable file in emulation mode, simply type:
     85To build the sample application in emulation mode, simply type:
    8686{{{
    8787make emu=1
    8888}}}
    89 
     89The executable file is created in "/boinc/samples/nvcuda/linux/build_mode/" (build_mode could be release or emurelease).
    9090Also, note that you will need to define some environment variables before running the executable file.
    9191{{{
     
    9797./example_app_nvcuda: error while loading shared libraries: libcudart.so.3: cannot open shared object file: No such file or directory
    9898}}}
    99 The executable file is created in "/boinc/samples/nvcuda/linux/build_mode/" (build_mode could be release or emurelease).
    10099
    101100=== NVIDIA OpenCL ===
     
    112111On my Linux machine, for example, it would be "$(ROOT)/home/tuanle/NVIDIA_GPU_Computing_SDK/".
    113112Since the absolute path is used in Makefile, you will probably need to edit file "common_opencl.mk" before
    114 compiling the sample app. Do so by looking for "/home/tuanle/NVIDIA_GPU_Computing_SDK" in file
     113compiling the sample application. Do so by looking for "/home/tuanle/NVIDIA_GPU_Computing_SDK" in file
    115114"common_opencl.mk" and replace this path with an appropriate path on your machine.
    116115
     
    216215As far as we know, NVIDIA Cuda SDK 3.1 no longer supports emulation mode.
    217216Thus, you will need to install an older Cuda SDK version, like version 3.0, on your machine.
    218 To make an executable file in emulation mode, simply type:
    219 {{{
    220 make -f Makefile_mac emu=1
    221 }}}
    222 
    223 Also, note that you will need to define some environment variables before running the executable file.
    224 {{{
    225 export PATH=/usr/local/cuda/bin:$PATH
    226 export DYLD_LIBRARY_PATH=/usr/local/cuda/lib:$DYLD_LIBRARY_PATH
    227 }}}
    228217
    229218The makefile for Mac is made with the assumption that the NVIDIA Cuda SDK is installed at the default location:
    230219"$ROOT/Developer/GPU Computing/" on Mac. If it is installed at a different location on your machine,
    231220then you will need to edit file "common_mac.mk". Do so by looking for "ROOTDIR  ?= /Developer/GPU\ Computing"
    232 and replace this path with an appropriate path on your machine.
    233 
    234 The executable file is created in "/boinc/samples/nvcuda/darwin/build_mode/" (build_mode could be release or emurelease).
     221in file "common_mac.mk" and replace this path with an appropriate path on your machine.
     222
     223To build the sample application in emulation mode, simply type:
     224{{{
     225make -f Makefile_mac emu=1
     226}}}
     227The executable file is created in "/boinc/samples/nvcuda/darwin/build_mode/" (build_mode could be release or emurelease).
     228Also, note that you will need to define some environment variables before running the executable file.
     229{{{
     230export PATH=/usr/local/cuda/bin:$PATH
     231export DYLD_LIBRARY_PATH=/usr/local/cuda/lib:$DYLD_LIBRARY_PATH
     232}}}
    235233
    236234=== NVIDIA OpenCL ===
     
    243241"$ROOT/Developer/GPU Computing/" on Mac. If it is installed at a different location on your machine,
    244242then you will need to edit file "common_opencl_mac.mk". Do so by looking for "ROOTDIR ?= /Developer/GPU\ Computing"
    245 and replace this path with an appropriate path on your machine.
    246 
    247 The executable is created in "/boinc/samples/nvopencl/darwin/release/".
     243in file "common_opencl_mac.mk" and replace this path with an appropriate path on your machine.
     244
     245To build the sample application, simply type:
     246{{{
     247make -f Makefile_mac
     248}}}
     249The executable is then created in "/boinc/samples/nvopencl/darwin/release/".
     250
     251=== ATI Stream OpenCL ===
     252
     253ATI Stream does not have a separate OpenCL SDK for MacOS users to download. Thus, the only way to build OpenCL
     254applications on your Mac is to have Mac OS X 10.6 version (which supports OpenCL) installed on your machine.
     255
     256To build the sample application, simply type:
     257{{{
     258make -f Makefile_mac
     259}}}
     260The executable file is then created in "/boinc/samples/atiopencl/".