Refs #727. Align stack buffer address on 32-bytes.
authorZhang Xianyi <traits.zhang@gmail.com>
Wed, 10 Feb 2016 19:51:26 +0000 (03:51 +0800)
committerZhang Xianyi <traits.zhang@gmail.com>
Wed, 10 Feb 2016 19:52:02 +0000 (03:52 +0800)
common_stackalloc.h

index 5bec0cf..71fb1a4 100644 (file)
@@ -54,7 +54,7 @@ USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
   if(stack_alloc_size > MAX_STACK_ALLOC / sizeof(TYPE))                    \
     stack_alloc_size = 0;                                                  \
   STACK_ALLOC_PROTECT_SET                                                  \
-  TYPE stack_buffer[stack_alloc_size];                                     \
+  TYPE stack_buffer[stack_alloc_size] __attribute__((aligned(0x20)));    \
   BUFFER = stack_alloc_size ? stack_buffer : (TYPE *)blas_memory_alloc(1);
 #else
   //Original OpenBLAS/GotoBLAS codes.