简体   繁体   中英

Running Command in a shell script

I am trying to execute a opencl program by running the command in a shell script. When , I run the command on the command line it runs without any errors. But when I run it in a shell script it throws error -

icpc command not found

Here is my shell script

#!/bin/csh

foreach t (1024 4096 8192 32768 50000 100000 500000 1000000 2000000 3000000 4000000 5000000 6000000 7000000 8000000)
        foreach l (8 16 32 64 128 256 512)
                icpc -o first first.cpp  -no-vec /scratch/cuda-7.0/lib64/libOpenCL.so -lm -openmp -DNMB=$t -DLOCAL_SIZE=$l
                ./first
        end
end

Can anyone please help me fix it

在您的Shell脚本中指定icpc的完整路径-算法

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM