From: Richard Henderson <rth@twiddle.net>
To: gerg@snapgear.com
Cc: Greg Ungerer <gerg@uclinux.org>,
qemu-devel@nongnu.org, paul@codesourcery.com
Subject: Re: [Qemu-devel] [PATCH] m68k: implement move to/from usp register instruction
Date: Thu, 13 Sep 2012 10:34:15 -0700 [thread overview]
Message-ID: <50521917.6020208@twiddle.net> (raw)
In-Reply-To: <1347517980-16721-1-git-send-email-gerg@snapgear.com>
On 09/12/2012 11:33 PM, gerg@snapgear.com wrote:
> +uint32_t HELPER(move_from_usp)(CPUM68KState * env)
> +{
> + return env->sp[M68K_USP];
> +}
You don't need helpers for these.
> DISAS_INSN(move_from_usp)
> {
> + TCGv reg;
> if (IS_USER(s)) {
> gen_exception(s, s->pc - 2, EXCP_PRIVILEGE);
> return;
> }
> - /* TODO: Implement USP. */
> - gen_exception(s, s->pc - 2, EXCP_ILLEGAL);
> + reg = AREG(insn, 0);
> + gen_helper_move_from_usp(reg, cpu_env);
tcg_gen_ld_i32(AREG(insn, 0), offsetof(CPUM68KState, sp[M68K_USP]));
> DISAS_INSN(move_to_usp)
> {
> + TCGv reg;
> if (IS_USER(s)) {
> gen_exception(s, s->pc - 2, EXCP_PRIVILEGE);
> return;
> }
> - /* TODO: Implement USP. */
> - gen_exception(s, s->pc - 2, EXCP_ILLEGAL);
> + reg = AREG(insn, 0);
> + gen_helper_move_to_usp(cpu_env, reg);
tcg_gen_st_i32(AREG(insn, 0), offsetof(CPUM68KState, sp[M68K_USP]));
r~
next prev parent reply other threads:[~2012-09-13 17:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-13 6:33 [Qemu-devel] [PATCH] m68k: implement move to/from usp register instruction gerg
2012-09-13 17:34 ` Richard Henderson [this message]
2012-09-13 23:36 ` Greg Ungerer
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=50521917.6020208@twiddle.net \
--to=rth@twiddle.net \
--cc=gerg@snapgear.com \
--cc=gerg@uclinux.org \
--cc=paul@codesourcery.com \
--cc=qemu-devel@nongnu.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.