[PATCH, AArch64] Fix PR 65624 (ICE in aarch64-linux-gnueabi crosscompiler on i686 host).

Alan Lawrence alan.lawrence@arm.com
Wed Apr 1 11:02:00 GMT 2015


Looks good to me. Indeed, I'd support this being an "obvious" fix....

--Alan

Maxim Ostapenko wrote:
> Hi,
> 
> expanding  AArch64 AdvSIMD builtins, aarch64_simd_expand_builtin puts 
> return type and arguments types in args[SIMD_MAX_BUILTIN_ARGS] array and 
> indicates the last argument with SIMD_ARG_STOP. When expanding 
> 4-argument builtin with return value, aarch64_simd_expand_builtin stores 
> SIMD_ARG_STOP to args[5], that overflows args since 
> SIMD_MAX_BUILTIN_ARGS == 5. This causes ICE for aarch64 cross-compiler 
> on i686 host:
> 
> $ 
> /home/m.ostapenko/jazz64/vd49_a5x/toolchain/aarch64-tizen/libexec/gcc/aarch64-tizen-linux-gnueabi/5.0.0/cc1 
> -quiet ref_vqdmlsl_lane.c -quiet -dumpbase ref_vqdmlsl_lane.c 
> -march=armv8-a+simd -mlittle-endian -mabi=lp64 -auxbase-strip 
> ref_vqdmlsl_lane.gccarm.o -g -Wall -Wno-unused-variable 
> -Wno-unused-function -Wno-error=unused-local-typedefs -fshort-wchar 
> -freport-bug
> 
> // In file included from ref_vqdmlal_lane.c:27:0,
> //                  from ref_vqdmlsl_lane.c:29:
> // 
> /home/m.ostapenko/jazz64/vd49_a5x/toolchain/aarch64-tizen/lib/gcc/aarch64-tizen-linux-gnueabi/5.0.0/include/arm_neon.h: 
> In function 'exec_vqdmlsl_lane':
> // 
> /home/m.ostapenko/jazz64/vd49_a5x/toolchain/aarch64-tizen/lib/gcc/aarch64-tizen-linux-gnueabi/5.0.0/include/arm_neon.h:19165:10: 
> internal compiler error: tree check: accessed operand 8 of call_expr 
> with 7 operands in aarch64_simd_expand_args, at 
> config/aarch64/aarch64-builtins.c:915
> //    return __builtin_aarch64_sqdmlsl_lanev4hi (__a, __b, __c, __d);
> //           ^
> // 0x89b4948 tree_operand_check_failed(int, tree_node const*, char 
> const*, int, char const*)
> // 
>  >----/home/m.ostapenko/jazz64/vd49_a5x/toolchain/build/sources/gcc_1/gcc/tree.c:9507
> // 0x8a3c9f9 tree_operand_check
> // 
>  >----/home/m.ostapenko/jazz64/vd49_a5x/toolchain/build/sources/gcc_1/gcc/tree.h:3346
> // 0x8a3c9f9 aarch64_simd_expand_args
> // 
>  >----/home/m.ostapenko/jazz64/vd49_a5x/toolchain/build/sources/gcc_1/gcc/config/aarch64/aarch64-builtins.c:915
> // 0x8a3c9f9 aarch64_simd_expand_builtin(int, tree_node*, rtx_def*)
> 
> This trivial patch fixes the issue.
> 
> No regressions found for aarch64-linux-gnueabi (on x86_64 and i686 
> hosts), ok to commit?
> 
> -Maxim
> 
> 



More information about the Gcc-patches mailing list