Hi Guys, I am checking in the patch below (to both the mainline and the 4.9 branch) in order to fix some unexpected failures in the gcc testsuite with the msp430-elf toolchain. With this patch in place the following tests now pass:
gcc.c-torture/execute/builtins/memcpy-chk.c gcc.c-torture/execute/builtins/memmove.c gcc.c-torture/execute/builtins/mempcpy-chk.c gcc.c-torture/execute/builtins/mempcpy.c gcc.c-torture/execute/builtins/strcpy-chk.c gcc.c-torture/execute/builtins/strcpy.c gcc.c-torture/execute/20020412-1.c gcc.c-torture/execute/20050826-2.c gcc.c-torture/execute/20050826-2.c gcc.c-torture/execute/920908-1.c gcc.c-torture/execute/pr56205.c gcc.c-torture/execute/strct-varg-1.c gcc.c-torture/execute/va-arg-22.c No regressions are introduced by the patch. The patch fixes two bugs - the first was that the zero_extendpsisi2 pattern was confusing gcc about the number of hard registers needed to hold an SImode value. The second fixes a problem with expanding va_arg when pointers are not a multiple of the word size. Cheers Nick gcc/ChangeLog 2014-05-20 Nick Clifton <ni...@redhat.com> * config/msp430/msp430.c (TARGET_GIMPLIFY_VA_ARG_EXPR): Define. (msp430_gimplify_va_arg_expr): New function. (msp430_print_operand): Handle (CONST (ZERO_EXTRACT)). * config/msp430/msp430.md (zero_extendpsisi2): Use + constraint on operand 0 in order to prevent confusion about the number of registers involved.
msp430.patch.xz
Description: application/xz