louisabraham / pydivsufsort

Python package for string algorithms ➰
MIT License
38 stars 4 forks source link

How can we support OpenMP? #8

Closed louisabraham closed 4 years ago

louisabraham commented 4 years ago

Compiling with -D​USE_OPENMP is easy. However if we use it in the bdist_wheel the people without OpenMP will have an error. Compiling both (thus having 4 dll) is possible, even though it adds some bloat.

seanlaw commented 4 years ago

At this point, I don't think I'm too concerned. The lib files look pretty small. Maybe you have a different idea but anything less than 1MB is perfectly fine (I'm guessing that we'll come in at under 250-500 KB even with wheels included). It's certainly worth the convenience if it isn't too much work to handle

louisabraham commented 4 years ago

After checking, I think OpenMP is almost always present so I activated it.

Computations are faster for large strings but slower for small. However, setting OMP_NUM_THREADS=1 yields the same performance as the version without OpenMP so it's a win-win.

Le jeu. 27 févr. 2020 à 13:50, Sean M. Law notifications@github.com a écrit :

At this point, I don't think I'm too concerned. The lib files look pretty small. Maybe you have a different idea but anything less than 1MB is perfectly fine (I'm guessing that we'll come in at under 250-500 KB even with wheels included). It's certainly worth the convenience if it isn't too much work to handle

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/louisabraham/pydivsufsort/issues/8?email_source=notifications&email_token=ADEQQFL7DKWJVASFERC2TBDRE6ZHPA5CNFSM4K42LHTKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOENEIACA#issuecomment-591953928, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADEQQFOMDGJXZHNJZXK6MSDRE6ZHPANCNFSM4K42LHTA .