This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [tree-ssa] Fix gimplification of volatile asms [patch]
On 10 Jun 2003 18:14:47 -0400, Diego Novillo <dnovillo@redhat.com> wrote:
> On Tue, 2003-06-10 at 17:57, Jason Merrill wrote:
>> Er, why didn't the old code have the desired effect?
> Because *stmt_p and stmt are the same thing and the call to build()
> clobbers the previous contents of *stmt_p.
No, it doesn't. Actually, looking at the code again, the problem is that
*stmt_p and stmt aren't the same thing; *stmt_p is the first statement in a
series, which is unlikely to be the ASM_STMT we're interested in. Having
checking in the ASM_VOLATILE_P macro would have caught this. Oops.
The patch is good.
Jason