Skip to content

Commit

Permalink
Checked the eigenevolution, add mcluster_ssegpu option to include SSE…
Browse files Browse the repository at this point in the history
… for gpu version
  • Loading branch information
Long Wang committed Mar 5, 2018
1 parent a5c2c41 commit db01ec3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,14 @@ mcluster_sse: $(OBJECTS) $(LFLAGS)
$(CC) -c main.c -D SSE -lm
$(CC) $(OBJECTS) main.o -o mcluster_sse -lm $(CFLAGS)

mcluster_gpu: $(OBJECTS) $(LFLAGS) gpupot.gpu.o main.c
mcluster_ssegpu: $(OBJECTS) $(LFLAGS) gpupot.gpu.o main.c
$(CC) -c main.c -D SSE -D GPU -lm -I$(CUDA_PATH)/include
$(CC) $(OBJECTS) main.o gpupot.gpu.o -o mcluster_gpu -L$(CUDA_PATH)/lib64 -lcudart -lstdc++ -lm $(CFLAGS)

mcluster_gpu: gpupot.gpu.o main.c
$(CC) -c main.c -D GPU -I$(CUDA_PATH)/include
$(CC) main.o gpupot.gpu.o -o mcluster_gpu -L$(CUDA_PATH)/lib64 -lcudart -lstdc++ -lm

mcluster:
$(CC) -o mcluster main.c -lm

Expand Down
3 changes: 3 additions & 0 deletions main.c
Original file line number Diff line number Diff line change
Expand Up @@ -3922,6 +3922,9 @@ int order(double **star, int N, double M, double msort, int pairing){
else dm=mk;
} while(dm<mk);
k = k1;
//printf("mass_ratio(true,real): %f %f\n",mpair/masses[i][0], masses[k][0]/masses[i][0]);
if(dm/mpair>1e-2)
printf("Warning: dm too large: m1=%F, mp=%f, m2=%f, dm=%f, i=%d, k=%d\n",masses[i][0],mpair,masses[k][0],i,k);
}
//printf("mpair =%f, k=%d, i=%d, mass[k]=%f\n",mpair,k,i,masses[k][0]);
/*
Expand Down

0 comments on commit db01ec3

Please sign in to comment.