This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils 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: Patch: Add a stop bit in alignment for alloc.


"H. J. Lu" <hjl@lucon.org> writes:

> @@ -9990,7 +9993,24 @@ md_assemble (str)
>    flags = idesc->flags;
>  
>    if ((flags & IA64_OPCODE_FIRST) != 0)
> -    insn_group_break (1, 0, 0);
> +    {
> +      /* The alignment frag has to end with a stop bit only if the
> +	 next instruction after the alignment directive has to be
> +	 the first instruction in an instruction group.  */
> +      if (align_frag)
> +	{
> +	  while (align_frag->fr_type != rs_align_code)
> +	    {
> +	      align_frag = align_frag->fr_next;
> +	      assert (align_frag);
> +	    }
> +	  if (align_frag->fr_next == frag_now)
> +	    align_frag->tc_frag_data = 1;
> +	}
> +
> +      insn_group_break (1, 0, 0);
> +    }
> +  align_frag = NULL;
>  
>    if ((flags & IA64_OPCODE_NO_PRED) != 0 && qp_regno != 0)
>      {

This breaks the attached test case (from glibc):

$ ./as-new init-first.s 
init-first.s: Assembler messages:
init-first.s:31: Internal error!
Assertion failure in md_assemble at /cvs/binutils/gas/config/tc-ia64.c
line 10013.
Please report this bug.

Andreas.

-- 
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux AG, Maxfeldstraße 5, 90409 Nürnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."

Attachment: init-first.s
Description: Text document


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