On Tue, Jun 14, 2016 at 12:43 PM, Jim Wilson <jim.wil...@linaro.org> wrote:
> I can reproduce with an FSF binutils.  Not obvious why it is failing though.

A git bisect tracks the problem down to this commit.

palantir:2177$ git bisect bad
c1baaddf8861aea666b84baeb4746caff51a579d is the first bad commit
commit c1baaddf8861aea666b84baeb4746caff51a579d
Author: Renlin Li <renlin...@arm.com>
Date:   Thu Apr 2 14:59:45 2015 +0100

    [AArch64] Emit DATA_MAP in order within text section

    2015-03-27  Renlin Li  <renlin...@arm.com>

    gas/
      * config/tc-aarch64.c (mapping_state): Emit MAP_DATA within text
section in order.
      (mapping_state_2): Don't emit MAP_DATA here.
      (s_aarch64_inst): Align frag during state transition.
      (md_assemble): Likewise.

:040000 040000 513292511d3717bb5d8fa7f3227e5eb352025a02
06d2298d935ea4d0698c7dbf2b713e2dc290f498 M gas
palantir:2178$

The problem here is with the md_assemble change, which is calling
frag_align_code inside a loop, which means it can emit multiple
alignment frags with a single call.  We are not in the text section,
which means we always get this alignment frag.  These alignment frags
have variable size, and hence the .if test on dot no longer works.

This patch isn't present in the binutils-2.25 that tcwg is using.  The
patch is present in binutils-2.26.

I've never looked at this MAP_DATA support, so the solution is not
immediately obvious to me.

Testcase attached.

Jim

Attachment: tmp.s
Description: Binary data

_______________________________________________
linaro-toolchain mailing list
linaro-toolchain@lists.linaro.org
https://lists.linaro.org/mailman/listinfo/linaro-toolchain

Reply via email to