Coder Social home page Coder Social logo

jfalcou / eve Goto Github PK

View Code? Open in Web Editor NEW
855.0 30.0 53.0 45.92 MB

Expressive Vector Engine - SIMD in C++ Goes Brrrr

Home Page: https://jfalcou.github.io/eve/

License: Boost Software License 1.0

CMake 1.67% C++ 98.31% Shell 0.03%
cpp simd simd-library simd-programming simd-parallelism hpc cpp-library sse2 ssse3 avx

eve's Introduction

⚡ Short Intro ⚡

I am Joel Falcou, Destroyer of World, Terror of the Compilers.

In my spare time, I am an associated professor at the University Paris-Saclay and researcher at the Laboratoire de Recherche d’Informatique in Orsay, France. My research focuses on studying generative programming idioms and techniques to design tools for parallel software development.

I also have a rather personal take on humor as you may have noticed already.

❓ Research Activities ❓

The main parts of my research topic are:

  • the exploration of Embedded Domain Specific Language design for parallel computing on various architectures;
  • the definition of a formal framework for reasoning about meta-programs.

As I need something to pad my academic paper up to at least eight pages, I usually play around with various application fields like real-time image processing on embedded architectures or HPC on multi-core clusters.

👯C++ Community 👯

I am the co-host of the C++FRUG Meetup, president of the C++FRUG Association and I co-organize the CPPP Conference.

You can find me on Mastodon or on the #include Discord

eve's People

Contributors

aguinet avatar chriselrod avatar denisyaroshevskiy avatar dpronin avatar hadrieng2 avatar jfalcou avatar jpenuchot avatar jtlap avatar justend29 avatar leha-bot avatar orao avatar panhaolin2001 avatar pauljurczak avatar simran-b avatar the-moisrex avatar toughengineer avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

eve's Issues

Issues when starting

Tried to do the setup:

Docs ==========================================
The big one at the moment is that docs are not readable as a generated web-page.
Read some top ones as markdown, looked through references

Potential typos

2 times scalar_value:

family if it satisfies the [scalar_value](reference/concepts.html#simd_value).

17 and forward?

**EVE** is a C++20 and forward implementation of a type based wrapper around for SIMD computations. It wraps SIMD instruction sets for most current architectures. It aims at showing how C++20 can be used to design and implement efficient, low level, high abstraction library suited for high performances.

Do you want to maybe add how to run tests?

Building library/verifying tests

cmake -G Ninja -DEVE_BUILD_TEST ..
Parse error in command line argument: -DEVE_BUILD_TEST
Should be: VAR:type=value
CMake Error: No cmake script provided.
CMake Error: Problem processing arguments. Aborting.

dyarosh@dyarosh-u:~/space/eve/build$ cmake -G Ninja  ..
-- The CXX compiler identification is Clang 11.0.0
-- Check for working CXX compiler: /usr/local/bin/clang++
-- Check for working CXX compiler: /usr/local/bin/clang++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- [eve] Building  mode with: 
-- Found OpenMP_CXX: -fopenmp=libomp (found version "4.5") 
-- Found OpenMP: TRUE (found version "4.5")  
-- Configuring done
-- Generating done
-- Build files have been written to: /home/dyarosh/space/eve/build/tts-download
-- Found OpenMP_CXX: -fopenmp=libomp (found version "4.5") 
-- [tts] TTS is used as a in-project dependency - No install targets available
-- [eve] Boost found in /usr/include - Boost dependent tests activated
-- Configuring done
-- Generating done
-- Build files have been written to: /home/dyarosh/space/eve/build
dyarosh@dyarosh-u:~/space/eve/build$ ninja -j 8 tests
[12/16123] Building CXX object tts-build/src/CMakeFiles/tts.dir/info.cpp.o
FAILED: tts-build/src/CMakeFiles/tts.dir/info.cpp.o 
/usr/local/bin/clang++  -DTTS_API_EXPORTS=1 -Dtts_EXPORTS -Itts-src/include -Itts-src/src -fPIC   -Wall -fvisibility=hidden -std=gnu++17 -MD -MT tts-build/src/CMakeFiles/tts.dir/info.cpp.o -MF tts-build/src/CMakeFiles/tts.dir/info.cpp.o.d -o tts-build/src/CMakeFiles/tts.dir/info.cpp.o -c tts-src/src/info.cpp
tts-src/src/info.cpp:16:10: fatal error: 'filesystem' file not found
#include <filesystem>
         ^~~~~~~~~~~~
1 error generated.
[19/16123] Building CXX object tts-build/src/CMakeFiles/tts.dir/args.cpp.o
ninja: build stopped: subcommand failed.

filesystem was not found. I have file system in libc++ .

Unfortunately, the best I could find in terms of building with libc++ was:
cmake -G Ninja -DCMAKE_CXX_FLAGS=-stdlib=libc++ ..
Which breaks spy

dyarosh@dyarosh-u:~/space/eve/build$ cmake -G Ninja -DCMAKE_CXX_FLAGS=-stdlib=libc++ ..
-- [eve] Building  mode with: -stdlib=libc++
-- Found OpenMP_CXX: -fopenmp=libomp  
-- Configuring done
-- Generating done
-- Build files have been written to: /home/dyarosh/space/eve/build/tts-download
-- Found OpenMP_CXX: -fopenmp=libomp  
-- [tts] TTS is used as a in-project dependency - No install targets available
-- [eve] Boost found in /usr/include - Boost dependent tests activated
-- Configuring done
-- Generating done
-- Build files have been written to: /home/dyarosh/space/eve/build
dyarosh@dyarosh-u:~/space/eve/build$ ninja -j 8 tests
[1/16123] Building CXX object test/doc/constant/CMakeFiles/doc.constant.valmin.unit.dir/valmin.cpp.o
FAILED: test/doc/constant/CMakeFiles/doc.constant.valmin.unit.dir/valmin.cpp.o 
/usr/local/bin/clang++   -Itts-src/include -I../test -I../include -stdlib=libc++   -std=c++17 -Wall -Wno-missing-braces -MD -MT test/doc/constant/CMakeFiles/doc.constant.valmin.unit.dir/valmin.cpp.o -MF test/doc/constant/CMakeFiles/doc.constant.valmin.unit.dir/valmin.cpp.o.d -o test/doc/constant/CMakeFiles/doc.constant.valmin.unit.dir/valmin.cpp.o -c ../test/doc/constant/valmin.cpp
In file included from ../test/doc/constant/valmin.cpp:1:
In file included from ../include/eve/constant/valmin.hpp:13:
In file included from ../include/eve/detail/overload.hpp:14:
In file included from ../include/eve/arch/spec.hpp:15:
In file included from ../include/eve/arch/x86/spec.hpp:14:
In file included from ../include/eve/arch/x86/predef.hpp:45:
../include/eve/detail/spy.hpp:465:31: error: no template named 'stdcpp_t' in namespace 'spy::detail'
  using stdlib_type = detail::stdcpp_t<(_LIBCPP_VERSION/1000)%10,0,_LIBCPP_VERSION%1000,0>;
                      ~~~~~~~~^
../include/eve/detail/spy.hpp:475:20: error: unknown type name 'stdlib_type'
  constexpr inline stdlib_type stdlib;
                   ^
../include/eve/detail/spy.hpp:480:45: error: no return statement in constexpr function
  inline constexpr stdlib_info<SLIB,M,N,P>::operator bool() const noexcept
                                            ^
3 errors generated.
[2/16123] Building CXX object test/doc/core/CMakeFiles/doc.core.sqrt.unit.dir/sqrt.cpp.o
FAILED: test/doc/core/CMakeFiles/doc.core.sqrt.unit.dir/sqrt.cpp.o 
/usr/local/bin/clang++   -Itts-src/include -I../test -I../include -stdlib=libc++   -std=c++17 -Wall -Wno-missing-braces -MD -MT test/doc/core/CMakeFiles/doc.core.sqrt.unit.dir/sqrt.cpp.o -MF test/doc/core/CMakeFiles/doc.core.sqrt.unit.dir/sqrt.cpp.o.d -o test/doc/core/CMakeFiles/doc.core.sqrt.unit.dir/sqrt.cpp.o -c ../test/doc/core/sqrt.cpp
In file included from ../test/doc/core/sqrt.cpp:1:
In file included from ../include/eve/function/sqrt.hpp:14:
In file included from ../include/eve/function/definition/sqrt.hpp:14:
In file included from ../include/eve/detail/overload.hpp:14:
In file included from ../include/eve/arch/spec.hpp:15:
In file included from ../include/eve/arch/x86/spec.hpp:14:
In file included from ../include/eve/arch/x86/predef.hpp:45:
../include/eve/detail/spy.hpp:465:31: error: no template named 'stdcpp_t' in namespace 'spy::detail'
  using stdlib_type = detail::stdcpp_t<(_LIBCPP_VERSION/1000)%10,0,_LIBCPP_VERSION%1000,0>;
                      ~~~~~~~~^
../include/eve/detail/spy.hpp:475:20: error: unknown type name 'stdlib_type'
  constexpr inline stdlib_type stdlib;
                   ^
../include/eve/detail/spy.hpp:480:45: error: no return statement in constexpr function
  inline constexpr stdlib_info<SLIB,M,N,P>::operator bool() const noexcept
                                            ^
3 errors generated.
[3/16123] Building CXX object test/doc/core/CMakeFiles/doc.core.tofloat.unit.dir/tofloat.cpp.o
FAILED: test/doc/core/CMakeFiles/doc.core.tofloat.unit.dir/tofloat.cpp.o 
/usr/local/bin/clang++   -Itts-src/include -I../test -I../include -stdlib=libc++   -std=c++17 -Wall -Wno-missing-braces -MD -MT test/doc/core/CMakeFiles/doc.core.tofloat.unit.dir/tofloat.cpp.o -MF test/doc/core/CMakeFiles/doc.core.tofloat.unit.dir/tofloat.cpp.o.d -o test/doc/core/CMakeFiles/doc.core.tofloat.unit.dir/tofloat.cpp.o -c ../test/doc/core/tofloat.cpp
In file included from ../test/doc/core/tofloat.cpp:1:
In file included from ../include/eve/function/tofloat.hpp:14:
In file included from ../include/eve/function/definition/tofloat.hpp:14:
In file included from ../include/eve/detail/overload.hpp:14:
In file included from ../include/eve/arch/spec.hpp:15:
In file included from ../include/eve/arch/x86/spec.hpp:14:
In file included from ../include/eve/arch/x86/predef.hpp:45:
../include/eve/detail/spy.hpp:465:31: error: no template named 'stdcpp_t' in namespace 'spy::detail'
  using stdlib_type = detail::stdcpp_t<(_LIBCPP_VERSION/1000)%10,0,_LIBCPP_VERSION%1000,0>;
                      ~~~~~~~~^
../include/eve/detail/spy.hpp:475:20: error: unknown type name 'stdlib_type'
  constexpr inline stdlib_type stdlib;
                   ^
../include/eve/detail/spy.hpp:480:45: error: no return statement in constexpr function
  inline constexpr stdlib_info<SLIB,M,N,P>::operator bool() const noexcept
                                            ^
3 errors generated.
[4/16123] Building CXX object test/doc/core/CMakeFiles/doc.core.sub.unit.dir/sub.cpp.o
FAILED: test/doc/core/CMakeFiles/doc.core.sub.unit.dir/sub.cpp.o 
/usr/local/bin/clang++   -Itts-src/include -I../test -I../include -stdlib=libc++   -std=c++17 -Wall -Wno-missing-braces -MD -MT test/doc/core/CMakeFiles/doc.core.sub.unit.dir/sub.cpp.o -MF test/doc/core/CMakeFiles/doc.core.sub.unit.dir/sub.cpp.o.d -o test/doc/core/CMakeFiles/doc.core.sub.unit.dir/sub.cpp.o -c ../test/doc/core/sub.cpp
In file included from ../test/doc/core/sub.cpp:1:
In file included from ../include/eve/function/sub.hpp:14:
In file included from ../include/eve/function/definition/sub.hpp:13:
In file included from ../include/eve/detail/overload.hpp:14:
In file included from ../include/eve/arch/spec.hpp:15:
In file included from ../include/eve/arch/x86/spec.hpp:14:
In file included from ../include/eve/arch/x86/predef.hpp:45:
../include/eve/detail/spy.hpp:465:31: error: no template named 'stdcpp_t' in namespace 'spy::detail'
  using stdlib_type = detail::stdcpp_t<(_LIBCPP_VERSION/1000)%10,0,_LIBCPP_VERSION%1000,0>;
                      ~~~~~~~~^
../include/eve/detail/spy.hpp:475:20: error: unknown type name 'stdlib_type'
  constexpr inline stdlib_type stdlib;
                   ^
../include/eve/detail/spy.hpp:480:45: error: no return statement in constexpr function
  inline constexpr stdlib_info<SLIB,M,N,P>::operator bool() const noexcept
                                            ^
3 errors generated.
[5/16123] Building CXX object test/doc/core/CMakeFiles/doc.core.toint.unit.dir/toint.cpp.o
FAILED: test/doc/core/CMakeFiles/doc.core.toint.unit.dir/toint.cpp.o 
/usr/local/bin/clang++   -Itts-src/include -I../test -I../include -stdlib=libc++   -std=c++17 -Wall -Wno-missing-braces -MD -MT test/doc/core/CMakeFiles/doc.core.toint.unit.dir/toint.cpp.o -MF test/doc/core/CMakeFiles/doc.core.toint.unit.dir/toint.cpp.o.d -o test/doc/core/CMakeFiles/doc.core.toint.unit.dir/toint.cpp.o -c ../test/doc/core/toint.cpp
In file included from ../test/doc/core/toint.cpp:1:
In file included from ../include/eve/function/toint.hpp:14:
In file included from ../include/eve/function/definition/toint.hpp:14:
In file included from ../include/eve/detail/overload.hpp:14:
In file included from ../include/eve/arch/spec.hpp:15:
In file included from ../include/eve/arch/x86/spec.hpp:14:
In file included from ../include/eve/arch/x86/predef.hpp:45:
../include/eve/detail/spy.hpp:465:31: error: no template named 'stdcpp_t' in namespace 'spy::detail'
  using stdlib_type = detail::stdcpp_t<(_LIBCPP_VERSION/1000)%10,0,_LIBCPP_VERSION%1000,0>;
                      ~~~~~~~~^
../include/eve/detail/spy.hpp:475:20: error: unknown type name 'stdlib_type'
  constexpr inline stdlib_type stdlib;
                   ^
../include/eve/detail/spy.hpp:480:45: error: no return statement in constexpr function
  inline constexpr stdlib_info<SLIB,M,N,P>::operator bool() const noexcept
                                            ^
3 errors generated.
[6/16123] Building CXX object test/doc/core/CMakeFiles/doc.core.ulpdist.unit.dir/ulpdist.cpp.o
FAILED: test/doc/core/CMakeFiles/doc.core.ulpdist.unit.dir/ulpdist.cpp.o 
/usr/local/bin/clang++   -Itts-src/include -I../test -I../include -stdlib=libc++   -std=c++17 -Wall -Wno-missing-braces -MD -MT test/doc/core/CMakeFiles/doc.core.ulpdist.unit.dir/ulpdist.cpp.o -MF test/doc/core/CMakeFiles/doc.core.ulpdist.unit.dir/ulpdist.cpp.o.d -o test/doc/core/CMakeFiles/doc.core.ulpdist.unit.dir/ulpdist.cpp.o -c ../test/doc/core/ulpdist.cpp
In file included from ../test/doc/core/ulpdist.cpp:1:
In file included from ../include/eve/function/ulpdist.hpp:14:
In file included from ../include/eve/function/definition/ulpdist.hpp:14:
In file included from ../include/eve/detail/overload.hpp:14:
In file included from ../include/eve/arch/spec.hpp:15:
In file included from ../include/eve/arch/x86/spec.hpp:14:
In file included from ../include/eve/arch/x86/predef.hpp:45:
../include/eve/detail/spy.hpp:465:31: error: no template named 'stdcpp_t' in namespace 'spy::detail'
  using stdlib_type = detail::stdcpp_t<(_LIBCPP_VERSION/1000)%10,0,_LIBCPP_VERSION%1000,0>;
                      ~~~~~~~~^
../include/eve/detail/spy.hpp:475:20: error: unknown type name 'stdlib_type'
  constexpr inline stdlib_type stdlib;
                   ^
../include/eve/detail/spy.hpp:480:45: error: no return statement in constexpr function
  inline constexpr stdlib_info<SLIB,M,N,P>::operator bool() const noexcept
                                            ^
3 errors generated.
[7/16123] Building CXX object test/doc/core/CMakeFiles/doc.core.trunc.unit.dir/trunc.cpp.o
FAILED: test/doc/core/CMakeFiles/doc.core.trunc.unit.dir/trunc.cpp.o 
/usr/local/bin/clang++   -Itts-src/include -I../test -I../include -stdlib=libc++   -std=c++17 -Wall -Wno-missing-braces -MD -MT test/doc/core/CMakeFiles/doc.core.trunc.unit.dir/trunc.cpp.o -MF test/doc/core/CMakeFiles/doc.core.trunc.unit.dir/trunc.cpp.o.d -o test/doc/core/CMakeFiles/doc.core.trunc.unit.dir/trunc.cpp.o -c ../test/doc/core/trunc.cpp
In file included from ../test/doc/core/trunc.cpp:1:
In file included from ../include/eve/function/trunc.hpp:14:
In file included from ../include/eve/function/definition/trunc.hpp:14:
In file included from ../include/eve/detail/overload.hpp:14:
In file included from ../include/eve/arch/spec.hpp:15:
In file included from ../include/eve/arch/x86/spec.hpp:14:
In file included from ../include/eve/arch/x86/predef.hpp:45:
../include/eve/detail/spy.hpp:465:31: error: no template named 'stdcpp_t' in namespace 'spy::detail'
  using stdlib_type = detail::stdcpp_t<(_LIBCPP_VERSION/1000)%10,0,_LIBCPP_VERSION%1000,0>;
                      ~~~~~~~~^
../include/eve/detail/spy.hpp:475:20: error: unknown type name 'stdlib_type'
  constexpr inline stdlib_type stdlib;
                   ^
../include/eve/detail/spy.hpp:480:45: error: no return statement in constexpr function
  inline constexpr stdlib_info<SLIB,M,N,P>::operator bool() const noexcept
                                            ^
3 errors generated.
[8/16123] Building CXX object test/doc/core/CMakeFiles/doc.core.tanh.unit.dir/tanh.cpp.o
FAILED: test/doc/core/CMakeFiles/doc.core.tanh.unit.dir/tanh.cpp.o 
/usr/local/bin/clang++   -Itts-src/include -I../test -I../include -stdlib=libc++   -std=c++17 -Wall -Wno-missing-braces -MD -MT test/doc/core/CMakeFiles/doc.core.tanh.unit.dir/tanh.cpp.o -MF test/doc/core/CMakeFiles/doc.core.tanh.unit.dir/tanh.cpp.o.d -o test/doc/core/CMakeFiles/doc.core.tanh.unit.dir/tanh.cpp.o -c ../test/doc/core/tanh.cpp
In file included from ../test/doc/core/tanh.cpp:1:
In file included from ../include/eve/function/tanh.hpp:14:
In file included from ../include/eve/function/definition/tanh.hpp:14:
In file included from ../include/eve/detail/overload.hpp:14:
In file included from ../include/eve/arch/spec.hpp:15:
In file included from ../include/eve/arch/x86/spec.hpp:14:
In file included from ../include/eve/arch/x86/predef.hpp:45:
../include/eve/detail/spy.hpp:465:31: error: no template named 'stdcpp_t' in namespace 'spy::detail'
  using stdlib_type = detail::stdcpp_t<(_LIBCPP_VERSION/1000)%10,0,_LIBCPP_VERSION%1000,0>;
                      ~~~~~~~~^
../include/eve/detail/spy.hpp:475:20: error: unknown type name 'stdlib_type'
  constexpr inline stdlib_type stdlib;
                   ^
../include/eve/detail/spy.hpp:480:45: error: no return statement in constexpr function
  inline constexpr stdlib_info<SLIB,M,N,P>::operator bool() const noexcept
                                            ^
3 errors generated.
ninja: build stopped: subcommand failed.

Support AVX512

New plan of actions:

  • Add support for detecting AVX512* ABI and related register type
  • Adapt logical to AVX512 types
  • Adapt internal operators
  • Optimize other functions

saturate

bitwise_cast and wide_cast have the syntax xxx_cast(x,as())
saturate has saturate(as(),x)
perhaps we must change saturate parameter order to be consistent

Implement element_type

element_type<T> is value_type_t<T> except for types like logical and complex where it's identity

rewrite bitwise_select and if_else

the scalar version of bitwise_select is in fact generic and could be displaced.
Once done, if_else common version could be written in terms of bitwise_select

what remains to do to achieve a first step ?

TO REMOVE DEFINITIVELY:
bitfloating.hpp
compare_equal.hpp
compare_greater_equal.hpp
compare_greater.hpp
compare_less_equal.hpp
compare_less.hpp
compare_not_equal.hpp
divides.hpp
enumerate.hpp
dot.hpp
fix.hpp
genmaskc.hpp
genmask.hpp
group.hpp
hmsb.hpp
ifix.hpp
if_allbits_else_zero.hpp
if_dec.hpp
if_inc.hpp
if_minus.hpp
if_neg.hpp
ifnot_dec.hpp
ifnot_inc.hpp
ifnot_minus.hpp
ifnot_neg.hpp
ifnot_plus.hpp
if_plus.hpp
if_zero_else_allbits.hpp
ilogb.hpp
insert.hpp
majority.hpp
mask2logical.hpp
minmod.hpp
nearbyint.hpp
neg.hpp
nextpow2.hpp
predecessor.hpp
rem_2pi.hpp
rem_pio2_straight.hpp
remquo.hpp
repeat_lower_half.hpp
repeat_upper_half.hpp
reverse.hpp
sbits.hpp
shift_left.hpp
shift_right.hpp
sincospi.hpp
slide.hpp
split_high.hpp
split.hpp
split_low.hpp
split_multiplies.hpp
successor.hpp
tenpower.hpp <- a fusionner dans exp10
deinterleave_first.hpp
deinterleave_second.hpp
interleave_even.hpp
interleave_first.hpp
interleave_odd.hpp
interleave_second.hpp

REMOVE NOW BUT TO PUT BACK LATER:
bits.hpp
bit_maskc <- a faire plus tard
clz.hpp <- a renommer
ctz.hpp <- a renommer
lexicographical_compare
cotd.hpp
cscd.hpp
cummax.hpp
cummin.hpp
cumprod.hpp
cumsum.hpp
deinterleave.hpp
erfc.hpp
erfcx.hpp
erf.hpp
exprecnegc.hpp
exprecneg.hpp
expx2.hpp
ffs.hpp <- a renommer
fpclassify.hpp
gamma.hpp
gammaln.hpp
hi.hpp
indeg.hpp -> radindeg.hpp
interleave.hpp
lo.hpp
ilog2.hpp <- a renommer
inrad.hpp -> deginrad.hpp
isincluded_c.hpp <- a renommer
isincluded.hpp <- a renommer
safe_max.hpp <- a mettre dans detail
safe_min.hpp <- a mettre dans detail
reversebits.hpp
rol.hpp
ror.hpp
rrol.hpp
rror.hpp
nthroot.hpp
secd.hpp
signbit.hpp
signgam.hpp
sindcosd.hpp <- a renommer
sind.hpp
tand.hpp
significants.hpp <- a renommer
sqrt1pm1.hpp
stirling.hpp
subadd.hpp

KEEP FOR RELEASE:
maximum.hpp
minimum.hpp
prod.hpp
shuffle.hpp
sinc.hpp
sincpi.hpp
sinhc.hpp
sum.hpp

TO INVESTIGATE:
reldist.hpp
swapbytes.hpp

conditional swap

a swap[cond](a,b) would be great.
It seems that could be a shuffle

power

power works fine in avx2 and works all the way. But it has to be benched more thoroghly (in ssse4 for instance) to see if a convert from wide raw method to wide result + limits handling will not be faster than the direct implementation.

negate negatenz

these functions had been forgotten and but be implemented

enforce_precision

g++-9 seems to have a flaw with combined -mavx2 and -mfma options that produce fast-math like
over-optimization as (x-c)+c evaluation to x in floating point computation.

this behaviour is like ub sensitive to code displacement or insered write orders and disappear with debug option

we need indexed load and multi extraction syntax w=v[i] for wide v and wide i

indexed load will be useful in the new reduction scheme for trigo

the multi extraction must work this way
if v is of type wide<T,N> and ind of type wide<I,M> containing integers in the range 0..N-1
w=v[i] will return a wide<T,M> vector such that w[j] =v[i[j]] for each j in [0, N-1]

We need :

  • a gather-like load
  • a dynamic shuffle, maybe called lookup?

Consolidate aggregator files

Files like arithmetic.hpp need to be cleared up and split if needed in accordance to the documentation.

Orphans files need to be cleaned up too.

XOP

si XOP est défini il faut donner une valeur à EVE_HW_X86

Loading `aligned_ptr<const T>`

Test case:

TEST_CASE("eve_extra.load_const_aligned_ptr", "[eve_extra]") {
  using wide = eve::wide<char, eve::fixed<16>>;
  alignas(wide) std::array<char, 16> data;
  data.fill(1);

  eve::aligned_ptr<const char, 16> ptr{data.cbegin()};

  auto loaded = eve::load(ptr, eve::as_<wide>{});
  REQUIRE(loaded == wide{1});
}

Error message:

[1/2] Building CXX object src/test/CMakeFiles/tests.dir/eve_extra.t.cc.o
FAILED: src/test/CMakeFiles/tests.dir/eve_extra.t.cc.o 
/usr/local/bin/clang++   -I../src/../../eve/include -I../src/. -O3 -DNDEBUG   -Werror -Wall -Wextra -Wpedantic -Og -g -Wno-unused-parameter -DEVE_DISABLE_ASSERTS -fno-omit-frame-pointer --std=c++17 -stdlib=libc++ -fsanitize=address -march=native -std=gnu++17 -MD -MT src/test/CMakeFiles/tests.dir/eve_extra.t.cc.o -MF src/test/CMakeFiles/tests.dir/eve_extra.t.cc.o.d -o src/test/CMakeFiles/tests.dir/eve_extra.t.cc.o -c ../src/test/eve_extra.t.cc
../src/test/eve_extra.t.cc:115:17: error: no matching function for call to 'load'
  auto loaded = eve::load(ptr, eve::as_<wide>{});
                ^~~~~~~~~
../src/../../eve/include/eve/function/load.hpp:44:24: note: candidate template ignored: deduced conflicting types for parameter 'T' ('const char' vs. 'eve::wide<char, eve::fixed<16>, eve::sse_>')
  EVE_FORCEINLINE auto load(aligned_ptr<T, Align> ptr, as_<T> const &) noexcept
                       ^
../src/../../eve/include/eve/function/load.hpp:76:24: note: candidate template ignored: deduced conflicting types for parameter 'T' ('const char' vs. 'char')
  EVE_FORCEINLINE auto load(aligned_ptr<T, Align> ptr, as_<wide<T, Size, ABI>> const &) noexcept
                       ^
../src/../../eve/include/eve/function/load.hpp:38:24: note: candidate template ignored: could not match 'T *' against 'eve::aligned_ptr<const char, 16>'
  EVE_FORCEINLINE auto load(T *ptr, as_<T> const &) noexcept
                       ^
../src/../../eve/include/eve/function/load.hpp:66:24: note: candidate template ignored: could not match 'T *' against 'eve::aligned_ptr<const char, 16>'
  EVE_FORCEINLINE auto load(T *ptr, as_<wide<T, Size, ABI>> const &) noexcept
                       ^
../src/../../eve/include/eve/function/load.hpp:84:24: note: candidate template ignored: could not match 'logical<T> *' against 'eve::aligned_ptr<const char, 16>'
  EVE_FORCEINLINE auto load(logical<T> *ptr, as_<logical<wide<T, Size, ABI>>> const &) noexcept
                       ^
../src/../../eve/include/eve/function/load.hpp:94:24: note: candidate template ignored: could not match 'logical<type-parameter-0-2>' against 'const char'
  EVE_FORCEINLINE auto load(aligned_ptr<logical<T>, Align> ptr,
                       ^
../src/../../eve/include/eve/function/load.hpp:26:24: note: candidate function template not viable: requires single argument 'ptr', but 2 arguments were provided
  EVE_FORCEINLINE auto load(T *ptr) noexcept
                       ^
../src/../../eve/include/eve/function/load.hpp:32:24: note: candidate function template not viable: requires single argument 'ptr', but 2 arguments were provided
  EVE_FORCEINLINE auto load(aligned_ptr<T, Align> ptr) noexcept
                       ^
../src/../../eve/include/eve/function/load.hpp:54:24: note: candidate function template not viable: requires single argument 'ptr', but 2 arguments were provided
  EVE_FORCEINLINE auto load(wide<T, Size, ABI> *ptr) noexcept
                       ^
../src/../../eve/include/eve/function/load.hpp:60:24: note: candidate function template not viable: requires single argument 'ptr', but 2 arguments were provided
  EVE_FORCEINLINE auto load(aligned_ptr<wide<T, Size, ABI>> ptr) noexcept
                       ^

check() doesn't play nice with decorated functions

Apparently, the decoration mechanism has been implemented in a certain way while it was thought to be done otherwise. This leads to check() not interacting properly with decorated functions.

This needs to be solved without changing the semantic of decoration w/r to conditional functions

g++10 pb with avx2 fma

big_(sincos) simd have failures that only appear and not on all systems with -mfma -mavx2 for double.
Is it a compiler pb ? The failure seems difficult to isolate and write orders in the code often makes
it disappear.

Implement `is_nez`

is_nez is is_not_equal(x,0) for arithmetic types and identity for logical

as_ status is unclear

multiple points:

  • [x ] Use as<T>()in place of as_<T>{} calls
  • we must provide shortcuts for specific type markup like single_, uchar_ etc...

Eve doesn't disable asserts on clang -O3

I don't exaclty know how, but:

Given code:

using wide = eve::wide<char, eve::fixed<32>>;
eve::aligned_ptr<char, alignof(wide)> test(char* s) {
  return {s};
}

When I compile with:

clang++ -std=c++17 -O3  -march=native

I get

.L_Z4testPc$local:
	.cfi_startproc
# %bb.0:
	push	rax
	.cfi_def_cfa_offset 16
	mov	rsi, rdi
	mov	rdi, rsp
	call	_ZN3eve11aligned_ptrIcLm32EEC2EPc
	mov	rax, qword ptr [rsp]
	pop	rcx
	.cfi_def_cfa_offset 8
	ret
.Lfunc_end0:
... # lots of code with iostream

When I pass

clang++ -std=c++17 -DNDEBUG -O3  -march=native 

I get

.L_Z4testPc$local:
	.cfi_startproc
# %bb.0:
	mov	rax, rdi
	ret

which is what I'd expect.

Same for

clang++ -std=c++17 -DEVE_DISABLE_ASSERTS -O3  -march=native 

Could be a clang bug I don't know but still.

scalaire pur

faut-il pouvoir tester eve sans aucun simd et si oui comment ?

logical and bool

It will be good to add two overload to each of the binary logical operators logical_xxx, between a logical/bool and bool/logical

why do we stil separate scalar and common ?

Is there still a reason to maintain separate files for scalar and common implementation of most functions ?
More if constexpr could perhaps do the job allowing the suppression of a bunch of include files ?

AVX2 equality comparison splits register in 2

After dissambing, found an issue:

Funciton:

auto test(eve::wide<char, eve::fixed<32>> x,
          eve::wide<char, eve::fixed<32>> y) {
  return x == y;
}

Assembly:

	vpcmpeqb	xmm2, xmm0, xmm1
	vextracti128	xmm0, ymm0, 1
	vextracti128	xmm1, ymm1, 1
	vpcmpeqb	xmm0, xmm0, xmm1
	vinserti128	ymm0, ymm2, xmm0, 1
	ret

Expected:

vpcmpeqb        ymm0, ymm0, ymm1

Compiler options:

clang++ -std=c++17 -O3 -DEVE_DISABLE_ASSERTS  -march=native

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.