Intel AMX and feature detection

Robert Muir rcmuir at gmail.com
Wed Jun 26 02:18:27 UTC 2024


On Tue, Jun 25, 2024 at 10:05 PM John Rose <john.r.rose at oracle.com> wrote:
>
> On 25 Jun 2024, at 18:51, Robert Muir wrote:
>
> > Java VM knows the cpu flags and cpu family, but won't give up the
> > goods to users like us :)
>
> I hear you on this, but is the VM really your only hope?
>
> If you were programming in C wouldn’t you grab some C header
> file and ask a function in there somewhere?  And if that’s the
> case surely there is a way to spin up a Panama FFM access to
> the same API.  Or is that already one of Uwe’s “too hacky”
> solutions?

Or we could parse /proc/cpuinfo like some other java projects are
doing for these issues, but then it only works on linux, and Uwe won't
approve!

I'm just trying to communicate the struggle to get good performance
and still try to be "portable", it is not easy.

The vector API could theoretically solve it for us too, maybe by
making SPECIES_PREFERRED more fine-grained, rather than just set to
"512" for everything. On such machines, for some vector operations,
"512" is really not the "preferred" size because it causes bad
performance side effects.


More information about the panama-dev mailing list