LinuxPPC-Dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Valentine <vbarshak@ru.mvista.com>
To: Wolfgang Denk <wd@denx.de>
Cc: HongWoo Lee <hongwoo7@gmail.com>, linuxppc-dev@lists.ozlabs.org
Subject: Re: Simple question about powerpc asm.
Date: Sat, 18 Jul 2009 17:55:35 +0400	[thread overview]
Message-ID: <4A61D457.2030105@ru.mvista.com> (raw)
In-Reply-To: <20090718125452.3760D832E416@gemini.denx.de>

Wolfgang Denk wrote:
> Dear Valentine,
> 
> In message <4A61A48D.8060601@ru.mvista.com> you wrote:
>> PowerPC instructions are 32-bit long. So, there are only 16 bits 
>> available within the instruction for constant values. Since address can 
>> be up to 64 bits, we have to load it a piece at a time. The "@" within 
>> the assembler instruct it to give a specially-processed form of a symbol 
>> value:
>>
>> @highest -- refers to bits 48-63 of a constant
>> @higher -- refers to bits 32-47 of a constant
>> @h -- refers to bits 16-31 of a constant
>> @l -- refers to bits 0-15 of a constant
> 
> Actually these bit numbers are wrong, as bit 0 is the MSB for PowerPC
> ;-)

All right, you got me ;)
Even copy-pasting from the IBM docs, one has to double-check :)

Regards,
Val.

> 
> Best regards,
> 
> Wolfgang Denk
> 

      reply	other threads:[~2009-07-18 13:54 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-18  9:24 Simple question about powerpc asm HongWoo Lee
2009-07-18 10:31 ` Valentine
2009-07-18 12:54   ` Wolfgang Denk
2009-07-18 13:55     ` Valentine [this message]

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=4A61D457.2030105@ru.mvista.com \
    --to=vbarshak@ru.mvista.com \
    --cc=hongwoo7@gmail.com \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=wd@denx.de \
    /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