-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Closed
Description
When building OpenBLAS with CMake and using a custom prefix (e.g., scipy_), the build fails with undefined symbol errors:
lld-link: error: <root>: undefined symbol: shgemm_
lld-link: error: <root>: undefined symbol: shgemv_
lld-link: error: <root>: undefined symbol: cblas_shgemm
Observed behavior:
These symbols (shgemm_, shgemv_, cblas_shgemm) are conditionally compiled only when BUILD_HFLOAT16=ON. However, even when this flag is OFF, the generated renamesys.def file still contains entries like:
scipy_shgemm=shgemm_ @XX
scipy_shgemv=shgemv_ @YY
scipy_cblas_shgemm=cblas_shgemm @ZZ
Because the corresponding object files (shgemm.obj, etc.) are not built, the linker fails to find these symbols, resulting in the errors above.
When BUILD_HFLOAT16=ON, the objects are built and the build completes successfully.
Expected behavior:
When BUILD_HFLOAT16=OFF, the .def file should not include the shgemm, shgemv, or cblas_shgemm symbols.
Metadata
Metadata
Assignees
Labels
No labels