OpenMathLib / OpenMathLib/OpenBLAS

AMD Zen 5 architecture is misidentified

Open
#6,029 21 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
7.6k
Forks
1.7k
Avg merge
1d 3h
Merged PRs (30d)
42

Description

The attached reproducer crashes on AMD Zen 5, but succeeds when run with OPENBLAS_CORETYPE=HASWELL or OPENBLAS_CORETYPE=SKYLAKEX. It also fails with OPENBLAS_CORETYPE=GENERIC which doesn't make sense to me.

The offending instruction is: movaps %xmm0,0x0(%r13)

reproducer.c

openblas-0.3.34
clang version 21.1.8
OS: FreeBSD 15.1

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the attached reproducer.c and run it on AMD Zen 5 using OpenBLAS 0.3.34, comparing the HASWELL, SKYLAKEX, and GENERIC OPENBLAS_CORETYPE settings. Trace the failing movaps instruction and the architecture identification path; done means Zen 5 is identified correctly and the reproducer no longer crashes under the default and GENERIC settings.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.