diff mbox

[1/4] tcg-ppc64: Fix RLDCL opcode

Message ID 20130602222723.1e006760@kryten
State New
Headers show

Commit Message

Anton Blanchard June 2, 2013, 12:27 p.m. UTC
The rldcl instruction doesn't have an sh field, so the minor opcode
of 8 is actually 4 when using the XO30 macro.

Cc: qemu-stable@nongnu.org
Signed-off-by: Anton Blanchard <anton@samba.org>
---

Comments

Richard Henderson June 3, 2013, 2:28 p.m. UTC | #1
On 06/02/2013 05:27 AM, Anton Blanchard wrote:
> The rldcl instruction doesn't have an sh field, so the minor opcode
> of 8 is actually 4 when using the XO30 macro.
> 
> Cc: qemu-stable@nongnu.org
> Signed-off-by: Anton Blanchard <anton@samba.org>
> ---
> 
> Index: b/tcg/ppc64/tcg-target.c
> ===================================================================
> --- a/tcg/ppc64/tcg-target.c
> +++ b/tcg/ppc64/tcg-target.c
> @@ -357,7 +357,7 @@ static int tcg_target_const_match (tcg_t
>  #define RLDICL XO30(  0)
>  #define RLDICR XO30(  1)
>  #define RLDIMI XO30(  3)
> -#define RLDCL  XO30(  8)
> +#define RLDCL  XO30(  4)

Oops.

But that suggests then that we ought not be using XO30.
Or at least adding a comment.


r~
diff mbox

Patch

Index: b/tcg/ppc64/tcg-target.c
===================================================================
--- a/tcg/ppc64/tcg-target.c
+++ b/tcg/ppc64/tcg-target.c
@@ -357,7 +357,7 @@  static int tcg_target_const_match (tcg_t
 #define RLDICL XO30(  0)
 #define RLDICR XO30(  1)
 #define RLDIMI XO30(  3)
-#define RLDCL  XO30(  8)
+#define RLDCL  XO30(  4)
 
 #define BCLR   XO19( 16)
 #define BCCTR  XO19(528)