blond-org / BLonD-cpp

BLonD implementation in C++
GNU General Public License v3.0
2 stars 3 forks source link

Highlight where interventions shall be put in place if OMP is not available #23

Open dpiparo opened 8 years ago

dpiparo commented 8 years ago

Hi,

if OMP is not available, many issues will arise. This happens on OSx, for example. Given that compatibility with Windows is planned too, on that platform issues can arise as well. The attached patch highlights the places in the CMake configuration and in the code that need attention. NOTA BENE: this patch is not made to be applied as is, but rather as a roadmap to implement compatibility. In other words, only 50% of the work was done :) make_it_work_on_osx.txt

OlegJakushkin commented 8 years ago

On windows you get OpenMP support with MSVC from the start - no problems there.

dpiparo commented 8 years ago

I understand that: great. I do not particularly like/dislike mac and osx but if we want to be realistic lots of users have only this platform at disposal. For example the majority of HEP physicists have mac laptops and those are potential users.

kiliakis commented 8 years ago

@dpiparo based on your patch, the openmp compatibility issue is almost resolved. I could try to apply it and resolve other issues that may appear as well. The problem is that I dont have access to OSx. I tried openstack but it has only linux/ windows images. The only solution that I am aware of is to set up travis to compile/ run under Mac OS and do all the debugging there (quite inefficient).

dpiparo commented 8 years ago

Hi @kiliakis, really do not feel obliged to apply the patch as such. Ideally, one should be able to configure at CMake level something like -Dopenmp=OFF and disable everywhere the openmp usage, for example using ifdef blocks within the code. As for the testing on osx, I can take care of course.

kiliakis commented 8 years ago

Yes, I was thinking of something like that. The changes that need to be made are not so many. I am afraid that there will be other problems as well but we'll see.