ADD: added other eigen lib

This commit is contained in:
Henry Winkel
2022-12-21 16:19:04 +01:00
parent a570766dc6
commit 9e56c7f2c0
832 changed files with 36586 additions and 20006 deletions

View File

@@ -20,9 +20,12 @@ typedef Matrix<float,8,1> Vector8f;
void check_handmade_aligned_malloc()
{
// Hand-make alignment needs at least sizeof(void*) to store the offset.
constexpr int alignment = (std::max<int>)(EIGEN_DEFAULT_ALIGN_BYTES, sizeof(void*));
for(int i = 1; i < 1000; i++)
{
char *p = (char*)internal::handmade_aligned_malloc(i);
char *p = (char*)internal::handmade_aligned_malloc(i, alignment);
VERIFY(internal::UIntPtr(p)%ALIGNMENT==0);
// if the buffer is wrongly allocated this will give a bad write --> check with valgrind
for(int j = 0; j < i; j++) p[j]=0;