All of lore.kernel.org
 help / color / mirror / Atom feed
From: Frank van Maarseveen <frankvm@frankvm.com>
To: linuxppc-dev@ozlabs.org
Subject: bug in arch/ppc/kernel/misc.S: __ashrdi3?
Date: Fri, 15 Jul 2005 18:01:15 +0200	[thread overview]
Message-ID: <20050715160115.GA22990@janus> (raw)

I don't really grok the code but an operand seems to be missing and the
assembler makes something out of it I don't trust:

_GLOBAL(__ashrdi3)
	...
	rlwinm  r8,r7,0,32      # t3 = (count < 32) ? 32 : 0

Trying it out:

$ cat a.c
void f(void)
{
        __asm("rlwinm  8,7,0,32");
}
$ ppc_4xx-gcc -O2 -c a.c
$ ppc-linux-objdump -S a.o

a.o:     file format elf32-powerpc

Disassembly of section .text:

00000000 <f>:
f():
   0:   54 e8 06 b4     rlwinm  r8,r7,0,26,26
   4:   4e 80 00 20     blr

-- 
Frank

             reply	other threads:[~2005-07-15 16:01 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-15 16:01 Frank van Maarseveen [this message]
2005-07-15 18:22 ` bug in arch/ppc/kernel/misc.S: __ashrdi3? Andreas Schwab
2005-07-16 17:39 ` Benjamin Herrenschmidt
2005-07-16 18:02   ` Andreas Schwab
2005-07-16 18:24     ` Benjamin Herrenschmidt
2005-07-18 12:14       ` Gabriel Paubert

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=20050715160115.GA22990@janus \
    --to=frankvm@frankvm.com \
    --cc=linuxppc-dev@ozlabs.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.