This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: MS/CW-style inline assembly for GCC
- From: Diego Novillo <dnovillo at redhat dot com>
- To: Stan Shebs <shebs at apple dot com>
- Cc: Richard Henderson <rth at redhat dot com>, "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Mon, 03 May 2004 22:04:40 -0400
- Subject: Re: MS/CW-style inline assembly for GCC
- Organization: Red Hat Canada
- References: <4096C4A0.8030000@apple.com> <20040504000056.GA3693@redhat.com> <4096E55C.80000@apple.com>
On Mon, 2004-05-03 at 20:35, Stan Shebs wrote:
> Can you be more specific about the difficulties?
>
What are the semantics wrt data flow across asm chunks?
foo()
{
int x;
x = 10;
__asm__ {
....
}
return x + 1;
}
How does the asm block inform the IL of modifications and/or uses of
local/global variables? How do the optimizers know whether 'return 11'
is valid? You either tell them no transformations are valid, any
transformation is valid or provide a structured way of accessing data
flow information.
By the same token, how do you provide control flow information to the
optimizers? GCC will want to build an SSA form on the tree level
representation very soon. You have to provide very precise and detailed
data and control flow information for __asm__ blocks.
Diego.