This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: label reference missed


On Thu, Aug 22, 2002 at 09:21:00PM -0700, Zack Weinberg wrote:
> On Thu, Aug 22, 2002 at 08:38:36PM -0700, Ulrich Drepper wrote:
> > 
> > I have this little piece of code:
> ...
> >   asm volatile ("jmp %0"::"m" (*&&fff));
> 
> This is just the classic "you can't jump out of an asm()" issue.
> 
> > I imagine that the change necessary to achieve this is minimal.  It 
> > would only require to recognize label references and mark the basic 
> > blocks they introduce as alive.
> 
> Not so simple; the optimizer would also have to be able to synthesize
> an edge from the asm to the label, and in general this could be quite
> difficult.

I like your counterprosal better anyway, but I've got a question on the
above - why is it difficult?  If the asm is somewhere that a jump to
the label would normally be allowed...


-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]