Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cblas.h has incorrect declarations when using #4771

Closed
mattip opened this issue Jun 28, 2024 · 4 comments · Fixed by #4772
Closed

cblas.h has incorrect declarations when using #4771

mattip opened this issue Jun 28, 2024 · 4 comments · Fixed by #4772

Comments

@mattip
Copy link
Contributor

mattip commented Jun 28, 2024

From MacPython/openblas-libs#163:

cblas.h contains

typedef void (*scipy_openblas_dojob_callback)64_(int thread_num, void *jobdata, int dojob_data);
typedef void (*scipy_openblas_threads_callback)64_(int sync, ...

Note the stray 64_, which should be follow the callback and not the ). This build is defining these arguments to make:

SYMBOLSUFFIX=64_ LIBNAMESUFFIX=64_ SYMBOLPREFIX=scipy_ LIBNAMEPREFIX=scipy_ FIXED_LIBNAME=1

I am not sure how those headers are getting generated. cc @serge-sans-paille

@martin-frbg
Copy link
Collaborator

I note the complete lack of a function name, and the scipy...callback cast must have been created by a script downstream from me - could this be a regex replace going wrong on your side ?

@mattip
Copy link
Contributor Author

mattip commented Jun 28, 2024

The beginning of this is in this repo here

typedef void (*openblas_dojob_callback)(int thread_num, void *jobdata, int dojob_data);

I think the function names are *openblas_dojob_callback and *openblas_threads_callback, the suffix is being applied before the ( (which is correct) but after the ) (which is wrong). Ahh, is this renaming done in my repo, and you only do library renaming in this repo?

@isuruf
Copy link
Contributor

isuruf commented Jun 28, 2024

@sed 's/openblas[^( ]*/&$(SYMBOLSUFFIX)/g' cblas.tmp2 > cblas.tmp
is probably the culprit

@martin-frbg
Copy link
Collaborator

apologies for that - I had not even realized that this was about current develop and fallout from #4577 - indeed the sed logic was not yet ready for parenthesized expressions as introduced by that PR.
I will try to resume normal work tomorrow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants