我正在尝试理解pthread,我正在做这个项目,在这个项目中,我必须通过pthread将一个二维数组传递给一个函数,该函数稍后将对该数组进行一些处理。][colums] ...
{ int array[rows][colums]; pthread_t} printf("give number of threads\n");
s
你好,我编写了下面使用线程进行矩阵乘法的代码,因此每个线程都应该计算一行,然后当我运行该代码时,它只给出第一行的正确结果,而其他行--它们的大部分元素都是零。M*M!我找不到错误的地方了!!谢谢 # include <stdio.h> # include <pthread.h> # include <stdlib.h> #include <sys\_t tid; pthread\_attr\_t attr