From: "H. Peter Anvin" <hpa@zytor.com>
To: Jike Song <albcamus@gmail.com>
Cc: gcosta@redhat.com, linux-kernel@vger.kernel.org
Subject: Re: questions about rd{msr|tsc|pmc} instruction with x86-64
Date: Wed, 15 Oct 2008 23:39:35 -0700 [thread overview]
Message-ID: <48F6E1A7.2070602@zytor.com> (raw)
In-Reply-To: <df9815e70810152330h7886c77arb01e1fd308b4a7ae@mail.gmail.com>
Jike Song wrote:
>
> By my reading of Intel & AMD manuals, this comment is wrong. rdmsr of
> x86-64 has the same behavior as i386, namely the high 32bit returns in
> edx and the low 32bit in eax, not "returns at rax". And the gcc
> constraint "A" does mean edx:eax in x86-64 also, at least when testing
> on my AMD Turion 64 processor.
>
"A" means rdx:rax on x86-64, not edx:eax. For a 64-bit number, it
means, literally, "one of rdx or rax"! As you correctly point out, this
is not how rdmsr works.
-hpa
next prev parent reply other threads:[~2008-10-16 6:40 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-16 6:30 questions about rd{msr|tsc|pmc} instruction with x86-64 Jike Song
2008-10-16 6:39 ` H. Peter Anvin [this message]
2008-10-16 16:31 ` Jike Song
[not found] ` <48F76FA3.1000602@zytor.com>
2008-10-17 5:25 ` Jike Song
2008-10-20 13:47 ` Ingo Molnar
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=48F6E1A7.2070602@zytor.com \
--to=hpa@zytor.com \
--cc=albcamus@gmail.com \
--cc=gcosta@redhat.com \
--cc=linux-kernel@vger.kernel.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