本文档主要讲述的是OpenMP并行程序设计;OpenMP是一个编译器指令和库函数的集合,主要是为共享式存储计算机上的并行程序设计使用的。目前支持OpenMP的语言主要有Fortran,C/C++。 OpenMP在并行执行程序时,采用的是fork/join式并行模式,共享存储式并行程序就是使用fork/join式并行的。希望本文档会给有需要的朋友带来帮助;感兴趣的朋友可以过来看看
function getmicrotime(){
list($usec, $sec) = explode(" ",microtime());
return ((float)$usec (float)$sec);
}
$time_start = getmicrotime();//开始计时, 放在程序头
for ($i=0; $i
//do nothing, 1000 times
}
$time_end = getmicrotime();//结束计时, 放在尾部
$time = $time_end - $time_start;
echo "Did nothing in $time seconds";










