| Commit message (Collapse) | Author | Age | Files | Lines |
| |\
| |
| | |
MAINT: Use with statement to open/close files to fix LGTM alerts
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| |\ \
| | |
| | | |
BLD: Allow users to specify BLAS and LAPACK library link order
|
| | | |
| | |
| | |
| | | |
Signed-off-by: Nick Papior <nickpapior@gmail.com>
|
| | | |
| | |
| | |
| | | |
Signed-off-by: Nick Papior <nickpapior@gmail.com>
|
| | | |
| | |
| | |
| | | |
Signed-off-by: Nick Papior <nickpapior@gmail.com>
|
| | | |
| | |
| | |
| | | |
Signed-off-by: Nick Papior <nickpapior@gmail.com>
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When a user requests NPY_BLAS/LAPACK_ORDER they can omit Netlib
BLAS/LAPACK. In that case there will not be raised anything.
This commit fixes this issue so that there will always be
issues raised if the user hasn't requested the basic libraries.
Signed-off-by: Nick Papior <nickpapior@gmail.com>
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | | |
Also added a test to travis (apparently ATLAS=None... is not tested
on circleCI).
Signed-off-by: Nick Papior <nickpapior@gmail.com>
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Prior to this enhancement compiling numpy would forcefully check BLAS/LAPACK
libraries in the following order:
BLAS:
- mkl
- blis
- openblas
- atlas
- accelerate
- NetLIB BLAS
- LAPACK
- mkl
- openblas
- atlas
- accelerate
- NetLIB LAPACK
This is problematic if a user want to build using, say, OpenBLAS but MKL is installed.
Even populating the site.cfg correspondingly one would get a successfull build, but
using MKL, if present.
The same applies to OpenBLAS vs. ATLAS etc.
Especially for developers this may be desirable to check performance with various
BLAS/LAPACK libraries.
This fixes the above issues by enabling users to forcefully set the order of loads
via environment variables:
$> export NUMPY_BLAS_ORDER=openblas,mkl,atlas
$> python setup.py config ...
would first try OpenBLAS (if existing), then MKL, and finally ATLAS.
In this case the build would fail if neither of OpenBLAS, MKL or ATLAS is present.
I.e. this can also be easierly used to test whether a linking would work. This
is because specifying a single library forces only one library check and has
no fall-back procedure (as requested by the user!).
The same applies to:
NUMPY_LAPACK_ORDER=openblas,mkl,atlas
This has meant that the blas_opt_info and lapack_opt_info classes in
system_info.py has *completely* changed.
Effectively there is only ONE change:
A fall-back of LAPACK was previously using get_info('blas') to get
the BLAS library to correctly link LAPACK. However, this may be undesirable
when the user has OpenBLAS/BLIS/ATLAS in a BLAS only installation but wants
to use the NetLIB LAPACK. Hence now lapack_opt_info uses get_info('blas_opt')
which does change the fall-back routine slightly. But perhaps for an easier build?
Signed-off-by: Nick Papior <nickpapior@gmail.com>
|
| | |/
|/|
| | |
* BLD: use libraries as a key consistently in all site.cfg sections
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
1) use __builtin_cpu_supports("avx512f") only for gcc ver >= 5
2) Introduced two new macro's:
HAVE_ATTRIBUTE_TARGET_@ISA@_WITH_INTRINSICS for ensuring compiler can
compile functions that use intrinsics and are compiled with avx2/avx512f
attributes
|
| | | |
|
| |/
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This makes CBLAS testing a bit easier since it checks 5 cases:
- user-defined libraries
- cblas + user-defined libraries
- blas + user-defined libraries
- cblas
- blas
In given order.
Since the has_cblas changed API it also changed name
to get_cblas_libs.
|
| | |
|
| |
|
|
| |
inexistent, avoiding unhandled exception.
|
| | |
|
| |\
| |
| | |
Convert fortran flags from environment variable
|
| | | |
|
| | |
| |
| | |
Co-Authored-By: rainwoodman <rainwoodman@gmail.com>
|
| | | |
|
| | |
| |
| | |
This PR fixes #13074.
|
| |/
|
|
|
|
|
|
| |
workaround for our broken `exec_command`.
This was removed in gh-1217, but then added back in gh-1321.
Now that we've fixed exec_command, I believe we can finally take it out for good.
|
| |
|
|
|
|
| |
Not super important, but saves some lines. Only the low-hanging ones here.
Found while tracking down an unrelated ResourceWarning
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* BUG: Use subprocess.check_output to avoid leaking file handles
This emitted a ResourceWarning as previously written, as the streams never got closed.
This change also detects errors in `svnversion` and `hg`, rather than ignoring the error code and hoping stdout contains a revision anyway.
* BUG: Fix distutils.get_version on python 3
Previously, this would throw `TypeError: cannot use a string pattern on a bytes-like object`, which would then be silenced and never seen.
The previous commit stopped silencing this error, so now everything is visibly broken rather than silently broken
Changing the strings to raw strings fixes the problem
* BUG: Don't use `close_fds`, which fails on windows
This argument was introduced along with subprocess in f5afa7836d56640f25ff3fbd2c59b8dcf016e26f to replace `popen4`, and probably wasn't necessary in the first place.
|
| |\
| |
| | |
BUG: parse shell escaping in extra_compile_args and extra_link_args
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Thanks to a change in exec_command, these strings are no longer passed onto the shell.
Since config files do not support list values, our best bet is to perform shell-splitting immediately.
This brings the behavior back in line a little to how it was before.
On windows systems, the behavior has changed. Previously it was treated as a single argument unless it contained quotes, resulting in the following weird behavior:
# passes as one argument, preserving spaces
extra_link_args=-Wl,rpath=A:/path/with spaces
# passes as two arguments, preserving spaces
extra_link_args="-Wl,rpath=A:\path\with spaces" -lgfortran
# passes as one long quoted argument (surprising and undesirable)
extra_link_args=-Wl,rpath=A:\path\without_spaces -lgfortran
Now it behaves as windows escaping via subprocess (but _not_ via cmd) normally would:
# Passed as two separate arguments (probably not as intended, but should be expected)
extra_link_args=-Wl,rpath=A:/path/with spaces
# passes as two arguments, preserving spaces
extra_link_args="-Wl,rpath=A:\path\with spaces" -lgfortran
# passes as two arguments
extra_link_args=-Wl,rpath=A:\path\without_spaces -lgfortran
Fixes gh-12659
|
| | |
| |
| |
| |
| |
| | |
Fixes gh-12979
Among other things, this means setting the `F90` environment variable to `"path to/f90" --coverage` works again.
|
| |\ \
| |/
| | |
BUG: Changes to string-to-shell parsing behavior broke paths with quotes
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
There are places in distutils where we accept a single string from the user, and interpret it as a set of command line arguments.
Previously, these were passed on as a string unmodified to exec_command, and interpreted by subprocess in a platform-specific way.
Recent changes to distutils now pass a list of arguments to subprocess, meaning we have to split the strings ourselves.
While `shlex.split` is perfect on posix systems, it is not a good approximation of either the old or the expected behavior on windows.
Provides the building blocks needed to fix gh-12979
|
| |\ \
| | |
| | | |
BUG: do not catch stderr when checking compiler version
|
| | | |
| | |
| | | |
which used to fail for ifort
|
| |\ \ \
| | | |
| | | | |
MAINT: Removed unused and confusingly indirect imports from mingw32ccompiler
|
| | | | |
| | | |
| | | |
| | | | |
Both of these functions are better exposed through `distutils.ccompiler`, but neither are used anyway
|
| |\ \ \ \
| | |_|/
| |/| | |
BUG: Do not insert extra double quote into preprocessor macros
|
| | |/ /
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
These are not used by our code, but it's possible downstream users are using them - without this patch, they would get a syntax error in their C code.
This also correctly handles version strings that contain embedded quotes, although probably still fails on non-ascii data.
Fixes gh-12893, on the probably correct assumption it was broken in the first place.
|
| |\ \ \
| | | |
| | | | |
BUG: Do not double-quote arguments passed on to the linker
|
| | |/ /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
After the recent patch to CCompiler.spawn, the file-paths no longer need manual quoting - that's handled as needed within subprocess.
This also states our assumption that our paths do not contain commas.
If we care about this, we could adopt the approach used by https://github.com/rust-lang/rust/issues/38795.
Tested for gcc locally by looking at the error messages of `subprocess.check_call(["gcc", r'-Wl,spaces and no quotes'])`
Other fortran compiler changes not tested, but assumed to be broken in the same way.
Fixes #12882
|
| | |/
|/|
| |
| |
| |
| |
| | |
`shlex.split` will try to read stdin if `None` is passed,
so change to check before apply it.
see #12823
|
| |\ \
| | |
| | | |
BUG: fix f2py problem to build wrappers using PGI's Fortran
|
| | | | |
|
| | | | |
|
| |/ /
| |
| |
| | |
See gh-7427
|
| | |
| |
| |
| |
| |
| | |
console
Previously this would show `b'first_line\nsecond_line'`
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
(#12448)
* Review F401,F841,F842 flake8 errors (unused variables, imports)
* Review comments
* More tests in test_installed_npymath_ini
* Review comments
|
| |\ \
| | |
| | | |
MAINT Use set litterals
|