On 2026/01/16 11:30, Daniel Dickman wrote:
> Thanks for including a full dmesg. That looks helpful.
> 
> One thing is that numpy was recently updated in ports/packages. Can you 
> share which version you are using? If it is the older version or the newer 
> version?

looking at lib versions, blas is from newer lapack so almost certainly
the newer numpy too

> On gdb, I suggest using gdb from ports rather than base gdb which isn't 
> terribly useful.

https://www.openbsd.org/faq/ports/ports.html#Backtrace

(off-topic ... I wonder, can we remove gdb from base on clang archs? It
doesn't seem useful for anything much. And the old libiberty that it
uses is from before many bugs were fixed after people decided it might
be a good idea to fuzz it.)

> For the segfault, my suspicion is that numpy is compiled with fairly 

"Illegal instruction (core dumped)" != segfault

> aggressive optimizations. A good quick google search leads me to believe 
> that your Core 2 Duo E8400 only goes up to SSE 4.1, so to fix I think we 
> need an older baseline when numpy is being compiled. Maybe it is using 
> SSE4.2 or AVX features which are trippping up your box.

Stuart, if you run 'make' in py-numpy on this machine, what do you get
in the lines after 'CPU Optimization Options'? And, make sure you have
the lang/python/3/python.port.mk tweak I just committed and what do the
compiler lines look like?

Even if I add

MODPY_PYBUILD_ARGS= -Csetup-args=-Dcpu-baseline=min \
                    -Csetup-args=-Dcpu-dispatch=min

it builds with these flags:

 -O3 -fno-strict-aliasing -msse -msse2 -msse3 -mssse3 -msse4.1 -msse4.2 
-mpopcnt -msahf -mcx16 -DHWY_WANT_SSE4 -DHWY_DISABLE_PCLMUL_AES 
-DNPY_HAVE_X86_V2 -DNPY_HAVE_SSE -DNPY_HAVE_SSE2 -DNPY_HAVE_SSE3 
-DNPY_HAVE_SSSE3 -DNPY_HAVE_SSE41 -DNPY_HAVE_SSE42 -DNPY_HAVE_POPCNT 
-DNPY_HAVE_LAHF -DNPY_HAVE_CX16 -O2 -pipe -g -fPIC

which isn't what we want.

Reply via email to