PR target/71103
* config/avr/avr.md (define_expand "mov<mode>"): If the source
operand is subreg (symbol_ref) then move the symbol ref to register.
PR target/71103
* gcc.target/avr/pr71103.c: New test.
From-SVN: r236558
+2016-05-21 Pitchumani Sivanupandi <pitchumani.s@atmel.com>
+
+ PR target/71103
+ * config/avr/avr.md (define_expand "mov<mode>"): If the source
+ operand is subreg (symbol_ref) then move the symbol ref to register.
+
2016-05-21 Jan Hubicka <hubicka@ucw.cz>
* tree.c (array_at_struct_end_p): Look through MEM_REF.
rtx dest = operands[0];
rtx src = avr_eval_addr_attrib (operands[1]);
+ if (SUBREG_P(src) && (GET_CODE(XEXP(src,0)) == SYMBOL_REF) &&
+ can_create_pseudo_p())
+ {
+ rtx symbol_ref = XEXP(src, 0);
+ XEXP (src, 0) = copy_to_mode_reg (GET_MODE(symbol_ref), symbol_ref);
+ }
+
if (avr_mem_flash_p (dest))
DONE;
+2016-05-20 Pitchumani Sivanupandi <pitchumani.s@atmel.com>
+
+ PR target/71103
+ * gcc.target/avr/pr71103.c: New test.
+
2016-05-21 Kugan Vivekanandarajah <kuganv@linaro.org>
PR middle-end/71179
--- /dev/null
+/* { dg-do compile } */
+/* { dg-options "-O1" } */
+
+struct ResponseStruct{
+ unsigned char responseLength;
+ char *response;
+};
+
+static char response[5];
+struct ResponseStruct something(){
+ struct ResponseStruct returnValue;
+ returnValue.responseLength = 5;
+ returnValue.response = response;
+ return returnValue;
+}
+