[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2018-07-18 Thread STINNER Victor
STINNER Victor added the comment: (Ah, Benjamin restarted the discussion, so I reopen this issue.) > I understand the desire to compile Python with OpenMP. I'm not sure that I understood the use case. Do you want to only compile Python core ("python3" binary") or just stdlib C extensions, or

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2018-07-17 Thread Benjamin Peterson
Benjamin Peterson added the comment: Yes, why not fix this by putting the offending code under "#ifndef _OPENMP"? What would be even better if is pyatomic.h wasn't included in Python.h, which should be fine since pyatomic.h doesn't have any public APIs. Maybe we can do that for 3.8. ---

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2018-07-17 Thread STINNER Victor
STINNER Victor added the comment: This issue is closed. Would you mind to either reopen it or create a new issue? -- ___ Python tracker ___ ___

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2018-07-17 Thread Antoine Pitrou
Antoine Pitrou added the comment: (see issue34128 for context) -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscr

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2018-07-17 Thread Antoine Pitrou
Antoine Pitrou added the comment: Case in point: if I want to include "internal/pystate.h" from _pickle.c, I get the following error: """ In file included from ./Include/internal/pystate.h:12:0, from /home/antoine/cpython/default/Modules/_pickle.c:10: ./Include/internal/ceval.

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2018-07-17 Thread Antoine Pitrou
Antoine Pitrou added the comment: I think this should be reconsidered. I understand the desire to compile Python with OpenMP. But the resolution here is hiding _Py_atomic symbols all the time, even when OpenMP isn't involved, and even when building a standard extension module. --

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-11-23 Thread STINNER Victor
STINNER Victor added the comment: cool 2015-11-23 22:19 GMT+01:00 Alexander Heger : > > Alexander Heger added the comment: > > seems to work now with 3.5.1rc1 > > On 5 November 2015 at 23:01, STINNER Victor wrote: >> >> STINNER Victor added the comment: >> >> "Pyatomic-2.patch solved the proble

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-11-23 Thread Alexander Heger
Alexander Heger added the comment: seems to work now with 3.5.1rc1 On 5 November 2015 at 23:01, STINNER Victor wrote: > > STINNER Victor added the comment: > > "Pyatomic-2.patch solved the problem." > > Great! The good news is that the Python 3.5.1 release has now a schedule: > https://www.pyt

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-11-05 Thread STINNER Victor
STINNER Victor added the comment: "Pyatomic-2.patch solved the problem." Great! The good news is that the Python 3.5.1 release has now a schedule: https://www.python.org/dev/peps/pep-0478/ "3.5.1 final: December 6, 2015" -- ___ Python tracker

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-11-05 Thread gul916
gul916 added the comment: Hi, Just a few words to tell you that I had the same problem to compile scipy 0.16.0 with mkl libraries under python 3.5 and linux fedora 22. Pyatomic-2.patch solved the problem. Thanks -- nosy: +gul916 ___ Python tracker

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-10-30 Thread Arkadiusz Miskiewicz Arkadiusz Miskiewicz
Arkadiusz MiskiewiczArkadiusz Miskiewicz added the comment: Same for 3.5 branch from hg (git mirror actually). -- ___ Python tracker ___

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-10-30 Thread Arkadiusz Miskiewicz Arkadiusz Miskiewicz
Arkadiusz MiskiewiczArkadiusz Miskiewicz added the comment: Should it work with /configure '--with-cxx-main=g++' && make? Because currently it doesn't: g++ -c -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-21 Thread STINNER Victor
Changes by STINNER Victor : -- keywords: +3.5regression ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-20 Thread STINNER Victor
STINNER Victor added the comment: Yes my fix will be part of Python 3.5.1 release. -- ___ Python tracker ___ ___ Python-bugs-list mail

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-20 Thread Alexander Heger
Alexander Heger added the comment: Dear Victor, yes, you patch seems to fix the yt install. Thank you very much! I hope this can be included in 3.5.1. Best wishes, Alexander -- ___ Python tracker __

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-18 Thread STINNER Victor
Changes by STINNER Victor : -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-18 Thread STINNER Victor
STINNER Victor added the comment: I pushed my fix pyatomic-2.patch to Python 3.5 and 3.6. Thanks for the bug report Alexander Heger! -- ___ Python tracker ___ __

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-18 Thread Roundup Robot
Roundup Robot added the comment: New changeset d4fcb362f7c6 by Victor Stinner in branch '3.5': Issue #25150: Hide the private _Py_atomic_xxx symbols from the public https://hg.python.org/cpython/rev/d4fcb362f7c6 -- nosy: +python-dev ___ Python tracker

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-18 Thread Stefan Behnel
Stefan Behnel added the comment: Understood and agreed. Second patch looks good to me. Cython calls PyThreadState_GET() in pretty much every helper function that deals with exceptions, but I doubt that the potential speed difference is going to be relevant in the real world. And we target CPyt

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-18 Thread STINNER Victor
STINNER Victor added the comment: > Would there be a way to expose these internals rather than hiding them? Here is the issue is that pyatomic.h cannot be compiled on OpenMP. We had the same issue with C++. In fact, it doesn't make sense to compile pyatomic.h differently to access an atomic va

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-18 Thread Stefan Behnel
Stefan Behnel added the comment: Would there be a way to expose these internals rather than hiding them? -- nosy: +scoder ___ Python tracker ___ _

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-18 Thread STINNER Victor
STINNER Victor added the comment: I created a venv with a Python patched with pyatomic-2.patch: I successfully installed yt. yt depends on numpy & Cython: good news, numpy & Cython were compiled correctly. These two libraries are well known users of the Python C API. It's not enough to check i

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-17 Thread STINNER Victor
STINNER Victor added the comment: /home/alex/Python-3.5.0/Modules/_ctypes/_ctypes.c:2062:15: error: ‘_PyThreadState_Current’ undeclared (first use in this function) if (Py_EnterRecursiveCall("while processing _as_parameter_")) { ^ Ah yes, if you check the fix for C++ (ch

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-17 Thread Alexander Heger
Alexander Heger added the comment: So, apparently, more than just one spot needs to be fixed. I also tried just modifying the Python.h after install, but that does not do the trick either. -- ___ Python tracker _

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-17 Thread Alexander Heger
Alexander Heger added the comment: if I just include this patch, some modules don't build: (...) gcc -pthread -fPIC -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Werror=declaration-after-statement -Ibuild/temp.linux-x86_64-3.5/libffi/

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-17 Thread Brett Cannon
Brett Cannon added the comment: If everything in the header is a _Py definition then I agree we should hide it in Python.h from the public. -- nosy: +brett.cannon ___ Python tracker ___

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-17 Thread STINNER Victor
STINNER Victor added the comment: "When I just comment out the << #include "pyatomic.h" >> line, python 3.5.0 will no longer compile" Sure. My idea is to "disable" the header with we are not building Python itself. There is a nice define for that: Py_BUILD_CORE. See attached patch. Since all

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-17 Thread Alexander Heger
Alexander Heger added the comment: When I just comment out the #include "pyatomic.h" line, python 3.5.0 will no longer compile gcc -pthread -c -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes-Werror=declaration-after-statement -I.

[issue25150] 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5)

2015-09-17 Thread STINNER Victor
Changes by STINNER Victor : -- title: yt package pip compile/install error -> 3.5: Include/pyatomic.h is incompatible with OpenMP (compilation of the third-party yt module fails on Python 3.5) versions: +Python 3.6 ___ Python tracker