vector math routine implementation for Linux (with .s files)
Kandu, Rahul
rahul.kandu at intel.com
Thu Jul 26 03:30:18 UTC 2018
Hi All,
Please find the vector math routine implementation for Linux in the following patch. Please review the following implementation.
http://cr.openjdk.java.net/~vdeshpande/SVML_Linux/webrev.01/
This includes 18 math routines implemented for both single-precision and double-precision floating points. Patch has support for SSE2, AVX1, AVX2 as well as AVX512, implementing from 64-bit up to 512-bit vector lengths.
Please note that, all CPU implementation files are merged in single file now e.g.
src/hotspot/os_cpu/linux_x86/svml_d_acos2_core_exha.s
src/hotspot/os_cpu/linux_x86/svml_d_acos2_core_l9ha.s
src/hotspot/os_cpu/linux_x86/svml_d_acos4_core_l9ha.s -> src/hotspot/os_cpu/linux_x86/svml_d_acos_linux_x86.s
src/hotspot/os_cpu/linux_x86/svml_d_acos8_core_z0ha.s
src/hotspot/os_cpu/linux_x86/svml_d_acos_cout_exha.s
src/hotspot/os_cpu/linux_x86/svml_d_acos_data_exha.s
There are total 36 files. filenames duplicate OS/CPU in the name and SVML (Short Vector Math Library) indicates that it is part of the Vector API.
This is based on razvan's original SVML patch.
regards,
Rahul
-----Original Message-----
From: panama-dev [mailto:panama-dev-bounces at openjdk.java.net] On Behalf Of Kandu, Rahul
Sent: Thursday, May 31, 2018 9:22 AM
To: Vladimir Ivanov <vladimir.x.ivanov at oracle.com>; panama-dev at openjdk.java.net
Subject: RE: math routine implementation with .s files
Hi Vladimir,
Re-naming files in more relevant way should be fine. It doesn't change underneath implementation. I'll look into merging the files.
Rahul
-----Original Message-----
From: Vladimir Ivanov [mailto:vladimir.x.ivanov at oracle.com]
Sent: Wednesday, May 30, 2018 11:27 PM
To: Kandu, Rahul <rahul.kandu at intel.com>; panama-dev at openjdk.java.net
Subject: Re: math routine implementation with .s files
Looks good!
As a side note, number of files added per operation looks like an overkill. What do you think about having a single .s file per operation?
src/hotspot/os_cpu/linux_x86/svml_d_acos2_core_exha.s
src/hotspot/os_cpu/linux_x86/svml_d_acos2_core_l9ha.s
src/hotspot/os_cpu/linux_x86/svml_d_acos4_core_l9ha.s
src/hotspot/os_cpu/linux_x86/svml_d_acos8_core_z0ha.s
src/hotspot/os_cpu/linux_x86/svml_d_acos_cout_exha.s
src/hotspot/os_cpu/linux_x86/svml_d_acos_data_exha.s
Also, some comments about naming. Current convention is to have os/cpu info duplicated in file name as well (e.g., src/hotspot/os_cpu/linux_x86/linux_x86_64.s or assembler_linux_x86.cpp).
And I'd prefer the names clearly state their relation to Vector API (either in the file name or placed in a subdir).
(But that's not something requiring immediate attention.)
Best regards,
Vladimir Ivanov
On 31/05/2018 04:51, Kandu, Rahul wrote:
> Hi All,
>
> Please find the patch which implements several transcendental and trigonometric vector math routines in from of assembly .s files.
> http://cr.openjdk.java.net/~rlupusoru/panama/webrev_linuxsvml_00/
>
> This is an extension of the patch submitted by Razvan earlier which implemented the Infrastructure for calling math routines in .s files.
>
> regards,
> Rahul
>
More information about the panama-dev
mailing list