Re: [patch,avr] Fix PR 65657 - read from __memx address space tramples arguments to function call

2015-04-23 Thread Senthil Kumar Selvaraj
On Fri, Apr 17, 2015 at 01:16:58PM +0530, Senthil Kumar Selvaraj wrote: On Thu, Apr 16, 2015 at 06:47:26PM +0200, Georg-Johann Lay wrote: Am 04/16/2015 um 11:28 AM schrieb Senthil Kumar Selvaraj: On Thu, Apr 16, 2015 at 11:02:05AM +0200, Georg-Johann Lay wrote: Am 04/16/2015 um 08:43 AM

Re: [patch,avr] Fix PR 65657 - read from __memx address space tramples arguments to function call

2015-04-17 Thread Senthil Kumar Selvaraj
On Thu, Apr 16, 2015 at 06:47:26PM +0200, Georg-Johann Lay wrote: Am 04/16/2015 um 11:28 AM schrieb Senthil Kumar Selvaraj: On Thu, Apr 16, 2015 at 11:02:05AM +0200, Georg-Johann Lay wrote: Am 04/16/2015 um 08:43 AM schrieb Senthil Kumar Selvaraj: This patch fixes PR 65657. The following

Re: [patch,avr] Fix PR 65657 - read from __memx address space tramples arguments to function call

2015-04-17 Thread Denis Chertykov
2015-04-17 10:46 GMT+03:00 Senthil Kumar Selvaraj senthil_kumar.selva...@atmel.com: On Thu, Apr 16, 2015 at 06:47:26PM +0200, Georg-Johann Lay wrote: Am 04/16/2015 um 11:28 AM schrieb Senthil Kumar Selvaraj: On Thu, Apr 16, 2015 at 11:02:05AM +0200, Georg-Johann Lay wrote: Am 04/16/2015 um

[patch,avr] Fix PR 65657 - read from __memx address space tramples arguments to function call

2015-04-16 Thread Senthil Kumar Selvaraj
This patch fixes PR 65657. When cfgexpand.c expands a function call, it first figures out the registers in which the arguments will go, followed by expansion of the arguments themselves (right to left). It later emits mov insns to set the precomputed registers with the expanded RTXes. If one of

Re: [patch,avr] Fix PR 65657 - read from __memx address space tramples arguments to function call

2015-04-16 Thread Senthil Kumar Selvaraj
On Thu, Apr 16, 2015 at 11:02:05AM +0200, Georg-Johann Lay wrote: Am 04/16/2015 um 08:43 AM schrieb Senthil Kumar Selvaraj: This patch fixes PR 65657. The following artifact appears to be PR63633. I did see that one - unfortunately, that fix won't help here. IIUC, you check if input/output

Re: [patch,avr] Fix PR 65657 - read from __memx address space tramples arguments to function call

2015-04-16 Thread Georg-Johann Lay
Am 04/16/2015 um 08:43 AM schrieb Senthil Kumar Selvaraj: This patch fixes PR 65657. The following artifact appears to be PR63633. When cfgexpand.c expands a function call, it first figures out the registers in which the arguments will go, followed by expansion of the arguments themselves

Re: [patch,avr] Fix PR 65657 - read from __memx address space tramples arguments to function call

2015-04-16 Thread Georg-Johann Lay
Am 04/16/2015 um 11:28 AM schrieb Senthil Kumar Selvaraj: On Thu, Apr 16, 2015 at 11:02:05AM +0200, Georg-Johann Lay wrote: Am 04/16/2015 um 08:43 AM schrieb Senthil Kumar Selvaraj: This patch fixes PR 65657. The following artifact appears to be PR63633. I did see that one -

Re: [patch,avr] Fix PR 65657 - read from __memx address space tramples arguments to function call

2015-04-16 Thread Georg-Johann Lay
...and the sketch against 4.9 Index: config/avr/avr.c === --- config/avr/avr.c (revision 221321) +++ config/avr/avr.c (working copy) @@ -287,6 +287,94 @@ avr_to_int_mode (rtx x) } +static void +avr_rest_of_handle_expand_xload

Re: [patch,avr] Fix PR 65657 - read from __memx address space tramples arguments to function call

2015-04-16 Thread Denis Chertykov
2015-04-16 19:47 GMT+03:00 Georg-Johann Lay a...@gjlay.de: Am 04/16/2015 um 11:28 AM schrieb Senthil Kumar Selvaraj: On Thu, Apr 16, 2015 at 11:02:05AM +0200, Georg-Johann Lay wrote: Am 04/16/2015 um 08:43 AM schrieb Senthil Kumar Selvaraj: This patch fixes PR 65657. The following