Displaying 9 results from an estimated 9 matches for "myaddvec".
2019 Jun 10
2
[RFC] Expose user provided vector function for auto-vectorization.
...should care about?
For the case mentioned earlier:
float MyAdd(float* a, int b) { return *a + b; }
__declspec(vector_variant(implements(MyAdd(float *a, int b)),
linear(a), vectorlength(8),
nomask, processor(core_2nd_gen_avx)))
__m256 __regcall MyAddVec(float* v_a, __m128i v_b1, __m128i v_b2)
If FE emitted
;; Alwaysinline
define <8 x float> @MyAddVec.abi_wrapper(float* %v_a, <8 x i32> %v_b) {
;; Not sure about the exact values in the mask parameter.
%v_b1 = shufflevector <8 x i32> %v_b, <8 x i32> undef, <4 x i32>...
2019 Jun 10
2
[RFC] Expose user provided vector function for auto-vectorization.
...reference-vector-variant:
>
> float MyAdd(float* a, int b) { return *a + b; }
> __declspec(vector_variant(implements(MyAdd(float *a, int b)),
> linear(a), vectorlength(8),
> nomask, processor(core_2nd_gen_avx)))
> __m256 __regcall MyAddVec(float* v_a, __m128i v_b1, __m128i v_b2)
>
> We need somehow communicate which lanes of widened "b" would map for the b1 parameter and which would go to the b2. If we only care about single ABI (like the one mandated by the OMP) than such things could be put to TTI, but what about ot...
2019 Jun 11
2
RFC: Interface user provided vector functions with the vectorizer.
...t;}
```
## Example 06
This is an x86 example, equivalent to the one provided by Andrei
Elovikow in
http://lists.llvm.org/pipermail/llvm-dev/2019-June/132885.html. Godbolt
rendering with ICC at https://godbolt.org/z/Of1NxZ
```
float MyAdd(float* a, int b) __attribute__(clang_declare_simd_variant(“MyAddVec", simdlen(8), notinbranch, arch("core_2nd_gen_avx"))
{
return *a + b;
}
__m256 MyAddVec(float* v_a, __m128i v_b1, __m128i v_b2);
```
The resulting IR attribute is:
```
attribute #0 = {vector-abi-variant="_ZGVbN8l4v_MyAdd(MyAddVec)"}
```
## Example showing interactio...
2019 Jun 07
2
[RFC] Expose user provided vector function for auto-vectorization.
...r-developer-guide-and-reference-vector-variant:
float MyAdd(float* a, int b) { return *a + b; }
__declspec(vector_variant(implements(MyAdd(float *a, int b)),
linear(a), vectorlength(8),
nomask, processor(core_2nd_gen_avx)))
__m256 __regcall MyAddVec(float* v_a, __m128i v_b1, __m128i v_b2)
We need somehow communicate which lanes of widened "b" would map for the b1 parameter and which would go to the b2. If we only care about single ABI (like the one mandated by the OMP) than such things could be put to TTI, but what about other ABIs?...
2019 Jun 17
3
RFC: Interface user provided vector functions with the vectorizer.
...is an x86 example, equivalent to the one provided by Andrei
> Elovikow in
> http://lists.llvm.org/pipermail/llvm-dev/2019-June/132885.html. Godbolt
> rendering with ICC at https://godbolt.org/z/Of1NxZ
>
> ```
> float MyAdd(float* a, int b) __attribute__(clang_declare_simd_variant(“MyAddVec", simdlen(8), notinbranch, arch("core_2nd_gen_avx"))
> {
> return *a + b;
> }
>
>
> __m256 MyAddVec(float* v_a, __m128i v_b1, __m128i v_b2);
> ```
>
> The resulting IR attribute is:
>
> ```
> attribute #0 = {vector-abi-variant="_ZGVbN8l4v_M...
2019 Jun 24
2
RFC: Interface user provided vector functions with the vectorizer.
...ndrei
>> > Elovikow in
>> > http://lists.llvm.org/pipermail/llvm-dev/2019-June/132885.html. Godbolt
>> > rendering with ICC at https://godbolt.org/z/Of1NxZ> >
>> > ```
>> > float MyAdd(float* a, int b)
> __attribute__(clang_declare_simd_variant(“MyAddVec", simdlen(8),
> notinbranch, arch("core_2nd_gen_avx"))
>> > {
>> > return *a + b;
>> > }
>> >
>> >
>> > __m256 MyAddVec(float* v_a, __m128i v_b1, __m128i v_b2);
>> > ```
>> >
>> > The resulting IR...
2019 Jun 21
2
RFC: Interface user provided vector functions with the vectorizer.
...vided by Andrei
> > Elovikow in
> > http://lists.llvm.org/pipermail/llvm-dev/2019-June/132885.html.
> > Godbolt rendering with ICC at https://godbolt.org/z/Of1NxZ
> >
> > ```
> > float MyAdd(float* a, int b)
> > __attribute__(clang_declare_simd_variant(“MyAddVec", simdlen(8), notinbranch, arch("core_2nd_gen_avx")) {
> > return *a + b;
> > }
> >
> >
> > __m256 MyAddVec(float* v_a, __m128i v_b1, __m128i v_b2); ```
> >
> > The resulting IR attribute is:
> >
> > ```
> > attribute #0...
2019 Jun 24
2
RFC: Interface user provided vector functions with the vectorizer.
>Thank you everybody for their input, and for your patience. This is proving harder than expected! :)
Thank you for doing the hard part of the work.
Hideki
-----Original Message-----
From: Francesco Petrogalli [mailto:Francesco.Petrogalli at arm.com]
Sent: Monday, June 24, 2019 11:26 AM
To: Saito, Hideki <hideki.saito at intel.com>
Cc: Doerfert, Johannes <jdoerfert at anl.gov>;
2019 Jun 24
4
RFC: Interface user provided vector functions with the vectorizer.
...provided by Andrei
> > Elovikow in
> > http://lists.llvm.org/pipermail/llvm-dev/2019-June/132885.html.
> > Godbolt rendering with ICC at https://godbolt.org/z/Of1NxZ
> >
> > ```
> > float MyAdd(float* a, int b)
> > __attribute__(clang_declare_simd_variant(“MyAddVec", simdlen(8), notinbranch, arch("core_2nd_gen_avx")) {
> > return *a + b;
> > }
> >
> >
> > __m256 MyAddVec(float* v_a, __m128i v_b1, __m128i v_b2); ```
> >
> > The resulting IR attribute is:
> >
> > ```
> > attribute #0...