From: Sebastian Huber <sebastian.huber@embedded-brains.de>
To: binutils@sourceware.org
Subject: Re: 32-bit PowerPC sdata linker problem
Date: Tue, 10 Jun 2014 06:28:00 -0000 [thread overview]
Message-ID: <5396A55E.4040706@embedded-brains.de> (raw)
In-Reply-To: <20140607123407.GN5592@bubble.grove.modra.org>
On 2014-06-07 14:34, Alan Modra wrote:
> On Fri, Jun 06, 2014 at 04:15:23PM +0200, Sebastian Huber wrote:
>> >On 2014-06-06 15:49, Alan Modra wrote:
>>> > >On Fri, Jun 06, 2014 at 03:23:52PM +0200, Sebastian Huber wrote:
>>>>> > >>>On 2014-06-06 15:05, Alan Modra wrote:
>>>>>>> > >>>> >On Fri, Jun 06, 2014 at 02:48:55PM +0200, Sebastian Huber wrote:
>>>>>>>>> > >>>>> >> cmplwi cr0, \_REG, ppc_exc_lock_std@sdarel
>>>>>>>>> > >>>>> >>
>>>>>>>>> > >>>>> >> .endm
>>>>>>>>> > >>>>> >>
>>>>>>>>> > >>>>> >>I guess, I have to rewrite this a bit.
>>>>>>> > >>>> >
>>>>>>> > >>>> >Doesn't using a cmpwi rather than cmplwi work?
>>>>>>> > >>>> >
>>>>> > >>>
>>>>> > >>>No, the cmplwi uses 0x0000 || UIMM with the cmpwi we have
>>>>> > >>>EXTS(SIMM), but the upper 16-bit must be zero so that the comparison
>>>>> > >>>works in the macro.
>>> > >Oh, of course. Perhaps I should make cmpli accept both signed and
>>> > >unsigned 16-bit fields.
>> >
>> >I think our usage of this cmplwi with the implicit truncation from
>> >the linker is quite a hack. On the other hand it worked for several
>> >years.
> Applied.
>
> bfd/
> * elf32-ppc.c (ppc_elf_relocate_section): Treat field of cmpli
> insn as a bitfield; Use complain_overflow_bitfield.
> * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
> opcodes/
> * ppc-opc.c (UISIGNOPT): Define and use with cmpli.
> gas/
> * config/tc-ppc.c (ppc_insert_operand): Handle PPC_OPERAND_SIGNOPT
> on unsigned fields. Comment on PPC_OPERAND_SIGNOPT signed fields
> in 64-bit mode.
> gold/
> * powerpc.cc (relocate): Treat field of cmpli insn as a bitfield.
Thanks, now it works again.
--
Sebastian Huber, embedded brains GmbH
Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone : +49 89 189 47 41-16
Fax : +49 89 189 47 41-09
E-Mail : sebastian.huber@embedded-brains.de
PGP : Public key available on request.
Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
next prev parent reply other threads:[~2014-06-10 6:28 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <53918356.3040102@embedded-brains.de>
2014-06-06 10:54 ` Alan Modra
2014-06-06 11:23 ` Sebastian Huber
2014-06-06 11:31 ` Sebastian Huber
2014-06-06 12:15 ` Alan Modra
2014-06-06 12:49 ` Sebastian Huber
[not found] ` <20140606130559.GK5592@bubble.grove.modra.org>
[not found] ` <5391C0E8.7010409@embedded-brains.de>
[not found] ` <20140606134915.GL5592@bubble.grove.modra.org>
[not found] ` <5391CCFB.5060206@embedded-brains.de>
2014-06-07 12:34 ` Alan Modra
2014-06-10 6:28 ` Sebastian Huber [this message]
2014-06-06 12:17 ` Alan Modra
2014-06-07 12:47 ` Alan Modra
2014-06-16 11:21 ` Will Newton
2014-06-16 13:07 ` Alan Modra
2014-06-16 14:10 ` Will Newton
2014-06-16 14:11 ` Will Newton
2014-06-18 0:29 ` Alan Modra
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5396A55E.4040706@embedded-brains.de \
--to=sebastian.huber@embedded-brains.de \
--cc=binutils@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).