I'm pretty new to ubuntu. I am running a .sh file which is very CPU intensive. I have a computer with 8 cores and I want to use at least four. From my research, I tried using
mpirun -np 4
I could see four CPU's running but it didn't seem to make the program run any faster. So I tried
taskset -c 0,1,2,3
The program was running alright but it seemed to be using just one core.
What can I do to speed up my program?