Tell the compiler that v4f is aligned
It's guaranteed that this is now aligned on a 16-byte boundary.
This commit is contained in:
parent
5ef9c84f97
commit
e7faebf6af
10
configure.ac
10
configure.ac
@ -272,7 +272,7 @@ AM_GLIB_GNU_GETTEXT
|
||||
# [ax_gcc_version_option=yes],
|
||||
# [ax_gcc_version_option=no]
|
||||
# )
|
||||
AC_MSG_CHECKING([for gcc version])
|
||||
AC_MSG_CHECKING([for $CC version])
|
||||
GCC_VERSION=""
|
||||
version=$($CC -dumpversion)
|
||||
if test $? = 0; then
|
||||
@ -326,7 +326,7 @@ AC_TYPE_SIZE_T
|
||||
|
||||
# g++/gcc 4.x and 5.x have rather broken vector support ... 5.4.1 seems to
|
||||
# work, but 5.4.0 fails to even compile
|
||||
AC_MSG_CHECKING([for gcc with working vector support])
|
||||
AC_MSG_CHECKING([for $CC with working vector support])
|
||||
if test x"$GCC_VERSION_MAJOR" != x"4" -a x"$GCC_VERSION_MAJOR" != x"5"; then
|
||||
AC_MSG_RESULT([yes])
|
||||
else
|
||||
@ -339,7 +339,7 @@ if test x"$ax_cv_have_var_attribute_vector_size" = x"yes"; then
|
||||
AC_MSG_CHECKING([for C++ vector shuffle])
|
||||
AC_LANG_PUSH([C++])
|
||||
AC_TRY_COMPILE([
|
||||
typedef float v4f __attribute__((vector_size(4 * sizeof(float))));
|
||||
typedef float v4f __attribute__((vector_size(4 * sizeof(float)),aligned(16)));
|
||||
],[
|
||||
v4f f; f[3] = 99;
|
||||
],[
|
||||
@ -362,7 +362,7 @@ if test x"$have_vector_shuffle" = x"yes"; then
|
||||
AC_MSG_CHECKING([for C++ vector arithmetic])
|
||||
AC_LANG_PUSH([C++])
|
||||
AC_TRY_COMPILE([
|
||||
typedef float v4f __attribute__((vector_size(4 * sizeof(float))));
|
||||
typedef float v4f __attribute__((vector_size(4 * sizeof(float)),aligned(16)));
|
||||
],[
|
||||
v4f f = {1, 2, 3, 4}; f *= 12.0;
|
||||
v4f g = {5, 6, 7, 8}; f = g > 0 ? g : -1 * g;
|
||||
@ -382,7 +382,7 @@ if test x"$have_vector_arith" = x"yes"; then
|
||||
AC_MSG_CHECKING([for C++ signed constants in vector templates])
|
||||
AC_LANG_PUSH([C++])
|
||||
AC_TRY_COMPILE([
|
||||
typedef float v4f __attribute__((vector_size(4 * sizeof(float))));
|
||||
typedef float v4f __attribute__((vector_size(4 * sizeof(float)),aligned(16)));
|
||||
template <typename T>
|
||||
static void
|
||||
h( v4f B )
|
||||
|
@ -85,7 +85,7 @@
|
||||
#ifdef HAVE_VECTOR_ARITH
|
||||
/* A vector of four floats.
|
||||
*/
|
||||
typedef float v4f __attribute__((vector_size(4 * sizeof(float))));
|
||||
typedef float v4f __attribute__((vector_size(4 * sizeof(float)),aligned(16)));
|
||||
#endif /*HAVE_VECTOR_ARITH*/
|
||||
|
||||
typedef struct _VipsCompositeBase {
|
||||
|
Loading…
Reference in New Issue
Block a user