This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: Why does gas put a stop bit in a bundle?
- From: "H. J. Lu" <hjl at lucon dot org>
- To: Jim Wilson <wilson at tuliptree dot org>
- Cc: binutils at sources dot redhat dot com
- Date: Thu, 1 May 2003 09:05:02 -0700
- Subject: Re: Why does gas put a stop bit in a bundle?
- References: <20030430093042.A5575@lucon.org> <3EAFED9F.7010803@tuliptree.org>
On Wed, Apr 30, 2003 at 11:37:03AM -0400, Jim Wilson wrote:
> H. J. Lu wrote:
> > GAS adds a stop bit at the last bundle in the current section
> > automatically.
> > Why does gas do that? I'd like to turn it off.
>
> Because we can't do dependency violation checking across section
> switches. Thus, in order to be safe, we must emit a stop bit when
> exiting the text section. Doing otherwise will result in code that
> silently fails at run time. Consider what happens if someone has C code
> with an extended asm that switches to an alternate code section and then
> back to text.
>
> Section switching also causes problems for generation of unwind info.
> It also used to cause trouble for dwarf2 compaction, but I think Richard
> Henderson fixed that problem.
Intel ia64 assembler doesn't add a stop bit. I consider it unfortunate
for gas. Can you create a testcase which shows dependency violation
doesn't with section switch? I'd like to add it to gas and I will take
a look at it when I find time.
Thanks.
H.J.