[Qemu-devel] [V4 PATCH 16/22] target-ppc: Add VSX ISA2.06 Multiply Add Instructions

2013-12-18 Thread Tom Musta
- xsnmaddmdp, xvnmaddmdp, xvnmaddmsp - xsnmsubadp, xvnmsubadp, xvnmsubasp - xsnmsubmdp, xvnmsubmdp, xvnmsubmsp V2: reworked implementation per comments from Richard Henderson and Peter Maydell. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target

[Qemu-devel] [V4 PATCH 19/22] target-ppc: Add VSX Vector Compare Instructions

2013-12-18 Thread Tom Musta
This patch adds the VSX floating point compare vector instructions: - xvcmpeqdp[.], xvcmpgedp[.], xvcmpgtdp[.] - xvcmpeqsp[.], xvcmpgesp[.], xvcmpgtsp[.] Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 57

[Qemu-devel] [V4 PATCH 09/22] target-ppc: Add VSX ISA2.06 xmul Instructions

2013-12-18 Thread Tom Musta
This patch adds the VSX floating point multiply instructions defined by V2.06 of the PowerPC ISA: xsmuldp, xvmuldp, xvmulsp. V2: re-implemented VSX_MUL macro. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 46

[Qemu-devel] [V4 PATCH 17/22] target-ppc: Add VSX xscmp*dp Instructions

2013-12-18 Thread Tom Musta
This patch adds the VSX scalar floating point compare ordered and unordered instructions. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 39 +++ target-ppc/helper.h |2

[Qemu-devel] [V4 PATCH 22/22] target-ppc: Add VSX Rounding Instructions

2013-12-18 Thread Tom Musta
This patch adds the VSX Round to Floating Point Integer instructions: - xsrdpi, xsrdpic, xsrdpim, xsrdpip, xsrdpiz - xvrdpi, xvrdpic, xvrdpim, xvrdpip, xvrdpiz - xvrspi, xvrspic, xvrspim, xvrspip, xvrspiz Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address

[Qemu-devel] [V4 PATCH 21/22] target-ppc: Add VSX ISA2.06 Integer Conversion Instructions

2013-12-18 Thread Tom Musta
, xvcvuxddp, xvcvuxwdp - xvcvsxdsp, xscvsxwsp, xvcvuxdsp, xvcvuxwsp Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 107 +++ target-ppc/helper.h | 22 ++ target-ppc

[Qemu-devel] [V4 PATCH 18/22] target-ppc: Add VSX xmax/xmin Instructions

2013-12-18 Thread Tom Musta
as well as one might think. Therefore specific routines for comparing 64 and 32 bit floating point numbers are implemented in the PowerPC helper code. V2: consolidated into a single macro, using the softfloat float*_max/float*_min routines. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed

Re: [Qemu-devel] [Qemu-ppc] [PATCH V3 01/19] Fix float64_to_uint64

2013-12-18 Thread Tom Musta
On 12/18/2013 9:52 AM, Peter Maydell wrote: On 18 December 2013 15:31, Tom Musta tommu...@gmail.com wrote: OK makes sense. I will fold the bug fix back into this series and re-publish. If you can keep all the softfloat patches in one PPC series and all at the beginning of the series

[Qemu-devel] [V4 PATCH 00/22] PowerPC VSX Stage 3

2013-12-18 Thread Tom Musta
functions. - assorted style fixes V3: re-submitting due to patch corruption. V4: Folded in softfloat bug fixes per Peter Maydell's request. Tom Musta (22): softfloat: Fix float64_to_uint64 softfloat: Add float32_to_uint64() softfloat: Fix float64_to_uint64_round_to_zero softfloat: Fix

Re: [Qemu-devel] [Qemu-ppc] [PATCH V3 01/19] Fix float64_to_uint64

2013-12-18 Thread Tom Musta
On 12/18/2013 9:52 AM, Peter Maydell wrote: On 18 December 2013 15:31, Tom Musta tommu...@gmail.com wrote: OK makes sense. I will fold the bug fix back into this series and re-publish. If you can keep all the softfloat patches in one PPC series and all at the beginning of the series

[Qemu-devel] [V3 PATCH 09/14] target-ppc: Add ISA 2.06 fcfid[u][s] Instructions

2013-12-18 Thread Tom Musta
This patch adds the fcfids, fcfidu and fcfidus instructions which were introduced in Power ISA 2.06. A common macro is provided to eliminated redudant code, and the existing fcfid instruction is re-implemented to use this macro. Signed-off-by: Tom Musta tommu...@gmail.com --- target-ppc

[Qemu-devel] [V3 PATCH 08/14] target-ppc: Add ISA2.06 Float to Integer Instructions

2013-12-18 Thread Tom Musta
-by: Tom Musta tommu...@gmail.com --- target-ppc/fpu_helper.c | 122 +-- target-ppc/helper.h |4 ++ target-ppc/translate.c | 12 + 3 files changed, 50 insertions(+), 88 deletions(-) diff --git a/target-ppc/fpu_helper.c b/target-ppc

[Qemu-devel] [V3 PATCH 10/14] target-ppc: Fix and enable fri[mnpz]

2013-12-18 Thread Tom Musta
helper is modified to correctly handle some of the boundary cases (NaNs and the inexact flag). Signed-off-by: Tom Musta tommu...@gmail.com --- target-ppc/fpu_helper.c | 12 ++-- target-ppc/translate_init.c |2 ++ 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/target

[Qemu-devel] [V3 PATCH 13/14] target-ppc: Enable frsqrtes on Power7 and Power8

2013-12-18 Thread Tom Musta
-off-by: Tom Musta tommu...@gmail.com --- target-ppc/translate_init.c |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/target-ppc/translate_init.c b/target-ppc/translate_init.c index 7bb9bbc..ec65bf4 100644 --- a/target-ppc/translate_init.c +++ b/target-ppc/translate_init.c

[Qemu-devel] [V3 PATCH 06/14] target-ppc: Add ISA2.06 lbarx, lharx Instructions

2013-12-18 Thread Tom Musta
in aligment check for lharx (caught by Richard). Signed-off-by: Tom Musta tommu...@gmail.com --- target-ppc/translate.c | 50 +++ 1 files changed, 24 insertions(+), 26 deletions(-) diff --git a/target-ppc/translate.c b/target-ppc/translate.c index 3344fa9

[Qemu-devel] [V3 PATCH 14/14] target-ppc: Add ISA2.06 lfiwzx Instruction

2013-12-18 Thread Tom Musta
This patch adds the Load Floating Point as Integer Word and Zero Indexed (lfiwzx) instruction which was introduced in Power ISA 2.06. Signed-off-by: Tom Musta tommu...@gmail.com --- target-ppc/translate.c | 15 +++ 1 files changed, 15 insertions(+), 0 deletions(-) diff --git

[Qemu-devel] [V3 PATCH 11/14] target-ppc: Add ISA 2.06 ftdiv Instruction

2013-12-18 Thread Tom Musta
This patch adds the Floating Point Test for Divide instruction which was introduced in Power ISA 2.06. Signed-off-by: Tom Musta tommu...@gmail.com --- target-ppc/fpu_helper.c | 56 ++ target-ppc/helper.h |2 + target-ppc/translate.c | 17

[Qemu-devel] [V3 PATCH 12/14] target-ppc: Add ISA 2.06 ftsqrt

2013-12-18 Thread Tom Musta
This patch adds the Floating Point Test for Square Root instruction which was introduced in Power ISA 2.06. Signed-off-by: Tom Musta tommu...@gmail.com --- target-ppc/fpu_helper.c | 31 +++ target-ppc/helper.h |1 + target-ppc/translate.c | 14

[Qemu-devel] [V4 PATCH 20/22] target-ppc: Add VSX Floating Point to Floating Point Conversion Instructions

2013-12-18 Thread Tom Musta
This patch adds the VSX instructions that convert between floating point formats: xscvdpsp, xscvspdp, xvcvdpsp, xvcvspdp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 46

[Qemu-devel] [V3 PATCH 02/14] target-ppc: Add ISA2.06 bpermd Instruction

2013-12-18 Thread Tom Musta
This patch adds the Bit Permute Doubleword (bpermd) instruction, which was introduced in Power ISA 2.06 as part of the base 64-bit architecture. V2: Addressing stylistic comments from Richard Henderson. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden

[Qemu-devel] [V3 PATCH 01/14] target-ppc: Add Flag for Power ISA V2.06

2013-12-18 Thread Tom Musta
This patch adds a flag for base instruction additions to Power ISA 2.06B. The flag will be used to identify/select basic Book I and Book II instructions that were newly added in that revision of the architecture. The flag will not be used for VSX or Altivec. Signed-off-by: Tom Musta tommu

[Qemu-devel] [V3 PATCH 04/14] target-ppc: Add ISA2.06 divde[o] Instructions

2013-12-18 Thread Tom Musta
This patch adds the Divide Doubleword Extended instructions. The implementation builds on the unsigned helper provided in the previous patch. V2: Updated to use the host-utils 128 bit divide. Signed-off-by: Tom Musta tommu...@gmail.com --- include/qemu/host-utils.h | 14 ++ target

[Qemu-devel] [V4 PATCH 12/22] target-ppc: Add VSX ISA2.06 xsqrt Instructions

2013-12-18 Thread Tom Musta
This patch adds the VSX floating point square root instructions defined by V2.06 of the PowerPC ISA: xssqrtdp, xvsqrtdp, xvsqrtsp. V2: re-implemented the VSX_SQRT macro. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 44

[Qemu-devel] [V3 PATCH 00/14] target-ppc: Base ISA V2.06 for Power7/Power8

2013-12-18 Thread Tom Musta
Peter Maydell. softloat changes have been moved back to the VSX stage 3 patch series. Tom Musta (14): target-ppc: Add Flag for Power ISA V2.06 target-ppc: Add ISA2.06 bpermd Instruction target-ppc: Add ISA2.06 divdeu[o] Instructions target-ppc: Add ISA2.06 divde[o] Instructions target-ppc

[Qemu-devel] [V3 PATCH 05/14] target-ppc: Add ISA 2.06 divwe[u][o] Instructions

2013-12-18 Thread Tom Musta
This patch addes the Signed and Unsigned Divide Word Extended instructions which were introduced in Power ISA 2.06. V2: Eliminating extraneous code in the overflow case per comments from Richard Henderson. Fixed corner case bug in divweu (check for (RA) = (RB)). Signed-off-by: Tom Musta tommu

[Qemu-devel] [V3 PATCH 03/14] target-ppc: Add ISA2.06 divdeu[o] Instructions

2013-12-18 Thread Tom Musta
into host-utils per Richard Henderson's suggestion. Signed-off-by: Tom Musta tommu...@gmail.com --- include/qemu/host-utils.h | 14 ++ target-ppc/helper.h |1 + target-ppc/int_helper.c | 27 +++ target-ppc/translate.c| 20

[Qemu-devel] [V4 PATCH 11/22] target-ppc: Add VSX ISA2.06 xre Instructions

2013-12-18 Thread Tom Musta
This patch adds the VSX floating point reciprocal estimate instructions defined by V2.06 of the PowerPC ISA: xsredp, xvredp, xvresp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 35

[Qemu-devel] [V4 PATCH 15/22] target-ppc: Add VSX ISA2.06 xtsqrt Instructions

2013-12-18 Thread Tom Musta
This patch adds the VSX floating point test for software square root instructions defined by V2.06 of the PowerPC ISA: xstsqrtdp, xvtsqrtdp, xvtsqrtsp. V2: (a) using locally implemented ppc_float*_get_unbiased_exp routines (b) eliminated dependency on float*_is_denormal(). Signed-off-by: Tom

[Qemu-devel] [V3 PATCH 07/14] target-ppc: Add ISA 2.06 stbcx. and sthcx. Instructions

2013-12-18 Thread Tom Musta
. Signed-off-by: Tom Musta tommu...@gmail.com --- target-ppc/translate.c | 88 ++- 1 files changed, 41 insertions(+), 47 deletions(-) diff --git a/target-ppc/translate.c b/target-ppc/translate.c index c3d0ebe..27eef84 100644 --- a/target-ppc/translate.c

[Qemu-devel] [V4 PATCH 08/22] target-ppc: Add VSX ISA2.06 xadd/xsub Instructions

2013-12-18 Thread Tom Musta
This patch adds the floating point addition and subtraction instructions defined by V2.06 of the PowerPC ISA: xssubdp, xvsubdp and xvsubsp. V2: re-implemented helper macro and combined add and substract. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden

Re: [Qemu-devel] [Qemu-ppc] [PATCH 01/18] target-ppc: Add Flag for Power ISA V2.06

2013-12-19 Thread Tom Musta
On 12/18/2013 4:37 PM, Alexander Graf wrote: Am 18.12.2013 um 23:11 schrieb Scott Wood scottw...@freescale.com: On Wed, 2013-12-18 at 23:09 +0100, Alexander Graf wrote: On 18.12.2013, at 23:02, Scott Wood scottw...@freescale.com wrote: On Mon, 2013-12-09 at 09:46 -0600, Tom Musta wrote

Re: [Qemu-devel] [PATCH] PPC: Fix compilation with TCG debug

2013-12-20 Thread Tom Musta
On 12/20/2013 4:01 AM, Alexander Graf wrote: The recent VSX patches broken compilation of QEMU when configurated with --enable-debug, as it was treating target long TCG variables as i64 which is not true for 32bit targets. This patch fixes all the places that the compiler has found to use

Re: [Qemu-devel] [Qemu-ppc] [V4 PATCH 01/22] softfloat: Fix float64_to_uint64

2013-12-20 Thread Tom Musta
On 12/19/2013 4:11 PM, Peter Maydell wrote: On 18 December 2013 20:19, Tom Musta tommu...@gmail.com wrote: The comment preceding the float64_to_uint64 routine suggests that the implementation is broken. And this is, indeed, the case. This patch properly implements the conversion of a 64-bit

Re: [Qemu-devel] [V4 PATCH 02/22] softfloat: Add float32_to_uint64()

2013-12-20 Thread Tom Musta
On 12/19/2013 3:31 PM, Peter Maydell wrote: On 18 December 2013 20:19, Tom Musta tommu...@gmail.com wrote: This patch adds the float32_to_uint64() routine, which converts a 32-bit floating point number to an unsigned 64 bit number. This contribution can be licensed under either the softfloat

Re: [Qemu-devel] [PULL 00/32] ppc patch queue 2013-12-20

2013-12-24 Thread Tom Musta
On 12/23/2013 12:10 PM, Alexander Graf wrote: On 23.12.2013, at 19:08, Andreas Färber afaer...@suse.de wrote: Am 20.12.2013 02:00, schrieb Alexander Graf: Alex, we now have those meaningless-without-context commit messages in qemu.git history. I'm pretty sure I asked the contributor

Re: [Qemu-devel] [PATCH 00/22] A64 decoder patchset 6: rest of floating point

2014-01-02 Thread Tom Musta
On 12/31/2013 7:35 AM, Peter Maydell wrote: We need Tom Musta's softfloat patches too, so I have included them here. Note that two of these still have outstanding issues identified in code review : see the notes in their commit messages (and I haven't applied my signed-off-by line to them).

[Qemu-devel] [V5 PATCH 02/22] softfloat: Add float32_to_uint64()

2014-01-02 Thread Tom Musta
This patch adds the float32_to_uint64() routine, which converts a 32-bit floating point number to an unsigned 64 bit number. This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta tommu...@gmail.com --- V2: Reduced patch to just this single

[Qemu-devel] [V5 PATCH 00/22] target-ppc: PowerPC VSX Stage 3

2014-01-02 Thread Tom Musta
rounding of small negatives in float32_to_uint64 - simplification of max/min instructions using new softfloat routines. - assorted commentary changes. Tom Musta (22): softfloat: Fix float64_to_uint64 softfloat: Add float32_to_uint64() softfloat: Fix float64_to_uint64_round_to_zero

[Qemu-devel] [V5 PATCH 05/22] softfloat: Fix float64_to_uint32_round_to_zero

2014-01-02 Thread Tom Musta
the invalid exception flag is raised (but not the inexact flag). This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Peter Maydell address@hidden --- V4: Correct commit commentary. Corrected code to properly

[Qemu-devel] [V5 PATCH 01/22] softfloat: Fix float64_to_uint64

2014-01-02 Thread Tom Musta
the softfloat-2a or -2b license. Signed-off-by: Tom Musta tommu...@gmail.com --- V2: Added softfloat license statement. V3: Modified to meet QEMU coding conventions. V4: Fixed incorrect handling of small negatives, which, if rounded up to zero should not set the inexact flag. V5: Clarified handling

[Qemu-devel] [V5 PATCH 03/22] softfloat: Fix float64_to_uint64_round_to_zero

2014-01-02 Thread Tom Musta
the float64_to_uint64 routine. This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta tommu...@gmail.com --- fpu/softfloat.c | 12 +--- 1 files changed, 5 insertions(+), 7 deletions(-) diff --git a/fpu/softfloat.c b/fpu/softfloat.c

[Qemu-devel] [V5 PATCH 12/22] target-ppc: Add VSX ISA2.06 xsqrt Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX floating point square root instructions defined by V2.06 of the PowerPC ISA: xssqrtdp, xvsqrtdp, xvsqrtsp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: re-implemented the VSX_SQRT macro. target-ppc/fpu_helper.c | 44

[Qemu-devel] [V5 PATCH 04/22] softfloat: Fix float64_to_uint32

2014-01-02 Thread Tom Musta
. This contribution can be licensed under either the softfloat-2a or -2b license. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Peter Maydell addresshidden --- V4: Fixed handling of stickiness of the inexact bit per comments from Peter Maydell. fpu/softfloat.c | 15 +++ 1 files changed, 7

[Qemu-devel] [V5 PATCH 08/22] target-ppc: Add VSX ISA2.06 xadd/xsub Instructions

2014-01-02 Thread Tom Musta
This patch adds the floating point addition and subtraction instructions defined by V2.06 of the PowerPC ISA: xssubdp, xvsubdp and xvsubsp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: re-implemented helper macro and combined add and substract

[Qemu-devel] [V5 PATCH 11/22] target-ppc: Add VSX ISA2.06 xre Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX floating point reciprocal estimate instructions defined by V2.06 of the PowerPC ISA: xsredp, xvredp, xvresp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 35

[Qemu-devel] [V5 PATCH 06/22] target-ppc: Add set_fprf Argument to fload_invalid_op_excp()

2014-01-02 Thread Tom Musta
of the FPRF field is made conditional via a parameter. All invocations of this routine in existing instructions are modified to pass 1 and thus retain their current behavior. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 103

[Qemu-devel] [V5 PATCH 09/22] target-ppc: Add VSX ISA2.06 xmul Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX floating point multiply instructions defined by V2.06 of the PowerPC ISA: xsmuldp, xvmuldp, xvmulsp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: re-implemented VSX_MUL macro. target-ppc/fpu_helper.c | 46

[Qemu-devel] [V5 PATCH 10/22] target-ppc: Add VSX ISA2.06 xdiv Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX floating point divide instructions defined by V2.06 of the PowerPC ISA: xsdivdp, xvdivdp, xvdivsp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: re-implemented the VSX_DIV macro. target-ppc/fpu_helper.c | 49

[Qemu-devel] [V5 PATCH 13/22] target-ppc: Add VSX ISA2.06 xrsqrte Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX floating point reciprocal square root estimate instructions defined by V2.06 of the PowerPC ISA: xsrsqrtedp, xvrsqrtedp, xvrsqrtesp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: re-implemented VSX_RSQRTE macro. target

[Qemu-devel] [V5 PATCH 18/22] target-ppc: Add VSX xmax/xmin Instructions

2014-01-02 Thread Tom Musta
as well as one might think. Therefore specific routines for comparing 64 and 32 bit floating point numbers are implemented in the PowerPC helper code. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: consolidated into a single macro, using

[Qemu-devel] [V5 PATCH 15/22] target-ppc: Add VSX ISA2.06 xtsqrt Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX floating point test for software square root instructions defined by V2.06 of the PowerPC ISA: xstsqrtdp, xvtsqrtdp, xvtsqrtsp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: (a) using locally implemented ppc_float

[Qemu-devel] [V5 PATCH 22/22] target-ppc: Add VSX Rounding Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX Round to Floating Point Integer instructions: - xsrdpi, xsrdpic, xsrdpim, xsrdpip, xsrdpiz - xvrdpi, xvrdpic, xvrdpim, xvrdpip, xvrdpiz - xvrspi, xvrspic, xvrspim, xvrspip, xvrspiz Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address

[Qemu-devel] [V5 PATCH 21/22] target-ppc: Add VSX ISA2.06 Integer Conversion Instructions

2014-01-02 Thread Tom Musta
, xvcvuxddp, xvcvuxwdp - xvcvsxdsp, xscvsxwsp, xvcvuxdsp, xvcvuxwsp Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 107 +++ target-ppc/helper.h | 22 ++ target-ppc

[Qemu-devel] [V5 PATCH 17/22] target-ppc: Add VSX xscmp*dp Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX scalar floating point compare ordered and unordered instructions. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 39 +++ target-ppc/helper.h |2

[Qemu-devel] [V5 PATCH 20/22] target-ppc: Add VSX Floating Point to Floating Point Conversion Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX instructions that convert between floating point formats: xscvdpsp, xscvspdp, xvcvdpsp, xvcvspdp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 45

[Qemu-devel] [V5 PATCH 19/22] target-ppc: Add VSX Vector Compare Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX floating point compare vector instructions: - xvcmpeqdp[.], xvcmpgedp[.], xvcmpgtdp[.] - xvcmpeqsp[.], xvcmpgesp[.], xvcmpgtsp[.] Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/fpu_helper.c | 58

[Qemu-devel] [V5 PATCH 14/22] target-ppc: Add VSX ISA2.06 xtdiv Instructions

2014-01-02 Thread Tom Musta
This patch adds the VSX floating point test for software divide instructions defined by V2.06 of the PowerPC ISA: xstdivdp, xvtdivdp, and xvtdivsp. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: added ppc_float*_get_unbiased_exp() routines

[Qemu-devel] [V5 PATCH 07/22] target-ppc: General Support for VSX Helpers

2014-01-02 Thread Tom Musta
This patch adds general support that will be used by the VSX helper routines: - a union describing the various VSR subfields. - access routines to get and set VSRs - VSX decoders - a general routine to generate a handler that invokes a VSX helper. Signed-off-by: Tom Musta tommu

[Qemu-devel] [V5 PATCH 16/22] target-ppc: Add VSX ISA2.06 Multiply Add Instructions

2014-01-02 Thread Tom Musta
- xsnmaddmdp, xvnmaddmdp, xvnmaddmsp - xsnmsubadp, xvnmsubadp, xvnmsubasp - xsnmsubmdp, xvnmsubmdp, xvnmsubmsp Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: reworked implementation per comments from Richard Henderson and Peter Maydell. target

[Qemu-devel] [V5 PATCH 04/14] target-ppc: VSX Stage 4: Refactor stxsdx

2014-01-03 Thread Tom Musta
This patch refactors the stxsdx instruction. Reusable code is extracted into a macro which will be used in subsequent patches in this series. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net --- target-ppc/translate.c | 27

[Qemu-devel] [V5 PATCH 03/14] target-ppc: VSX Stage 4: Add lxsiwax, lxsiwzx and lxsspx

2014-01-03 Thread Tom Musta
This patch adds the scalar load instructions introduced in ISA V2.07: - Load VSX Scalar as Integer Word Algebraic Indexd (lxsiwax) - Load VSX Scalar as Integer Word and Zero Indexed (lxsiwzx) - Load VSX Scalar Single-Precision Indexed (lxsspx) Signed-off-by: Tom Musta tommu...@gmail.com

[Qemu-devel] [V5 PATCH 05/14] target-ppc: VSX Stage 4: Add stxsiwx and stxsspx

2014-01-03 Thread Tom Musta
This patch adds two store scalar instructions: - Store VSX Scalar as Integer Word Indexed (stxsiwx) - Store VSX Scalar Single-Precision Indexed (stxsspx) Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net --- V5: Updated to address tcg-debug

[Qemu-devel] [V5 PATCH 00/14] [V5 PATCH 00/14] target-ppc: VSX Stage 4

2014-01-03 Thread Tom Musta
. V4: Changed fused multiply/add to use helper_frsp (inadvertently re-injected when I used an earlier patch). V5: Fixed tcg compilation problems. Tom Musta (14): target-ppc: VSX Stage 4: Add VSX 2.07 Flag target-ppc: VSX Stage 4: Refactor lxsdx target-ppc: VSX Stage 4: Add lxsiwax, lxsiwzx

[Qemu-devel] [V5 PATCH 01/14] target-ppc: VSX Stage 4: Add VSX 2.07 Flag

2014-01-03 Thread Tom Musta
This patch adds a flag to identify those VSX instructions that are new to Power ISA V2.07. The flag is added to the Power 8 processor initialization so that the P8 models understand how to decode and emulate instructions in this category. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed

[Qemu-devel] [V5 PATCH 02/14] target-ppc: VSX Stage 4: Refactor lxsdx

2014-01-03 Thread Tom Musta
This patch refactors the lxsdx generator. Resuable code is isolated into a macro. The macro will be used in subsequent patches in this series to implement other scalar load instructions. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net --- target-ppc

[Qemu-devel] [V5 PATCH 10/14] target-ppc: VSX Stage 4: Add xssqrtsp

2014-01-03 Thread Tom Musta
This patch adds the VSX Scalar Square Root Single Precision (xssqrtsp) instruction. The existing VSX_SQRT() macro is modified to support rounding of the intermediate double-precision result to single-precision. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r

[Qemu-devel] [V5 PATCH 06/14] target-ppc: VSX Stage 4: Add xsaddsp and xssubsp

2014-01-03 Thread Tom Musta
This patch adds the VSX Scalar Add Single-Precision (xsaddsp) and VSX Scalar Subtract Single-Precision (xssubsp) instructions. The existing VSX_ADD_SUB macro is modified to support the rounding of the (intermediate) result to single-precision. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed

[Qemu-devel] [V5 PATCH 11/14] target-ppc: VSX Stage 4: add xsrsqrtesp

2014-01-03 Thread Tom Musta
This patch adds the VSX Scalar Reciprocal Square Root Estimate Single Precision (xsrsqrtesp) instruction. The existing VSX_RSQRTE() macro is modified to support rounding of the intermediate double-precision result to single precision. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed

[Qemu-devel] [V5 PATCH 09/14] target-ppc: VSX Stage 4: Add xsresp

2014-01-03 Thread Tom Musta
This patch adds the VSX Scalar Reciprocal Estimate Single Precision (xsresp) instruction. The existing VSX_RE macro is modified to support rounding of the intermediate double precision result to single precision. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r

[Qemu-devel] [V5 PATCH 07/14] target-ppc: VSX Stage 4: Add xsmulsp

2014-01-03 Thread Tom Musta
This patch adds the VSX Scalar Multiply Single-Precision (xsmulsp) instruction. The existing VSX_MUL macro is modified to support rounding of the intermediate result to single precision. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net --- V2: Updated

[Qemu-devel] [V5 PATCH 08/14] target-ppc: VSX Stage 4: Add xsdivsp

2014-01-03 Thread Tom Musta
This patch adds the VSX Scalar Divide Single Precision (xsdivsp) instruction. The existing VSX_DIV macro is modified to support rounding of the intermediate double precision result to single precision. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net

[Qemu-devel] [V5 PATCH 13/14] target-ppc: VSX Stage 4: Add xscvsxdsp and xscvuxdsp

2014-01-03 Thread Tom Musta
point conversion macro (VSX_CVT_INT_TO_FP) is modified to support the rounding of the intermediate floating point result to single precision. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net --- V2: updated conversion to single precision range. target

[Qemu-devel] [V5 PATCH 14/14] target-ppc: VSX Stage 4: Add xxleqv, xxlnand and xxlorc

2014-01-03 Thread Tom Musta
This patchs adds the VSX Logical instructions that are new with ISA V2.07: - VSX Logical Equivalence (xxleqv) - VSX Logical NAND (xxlnand) - VSX Logical ORC (xxlorc) Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net --- V5: Changes to address tcg

Re: [Qemu-devel] [Qemu-ppc] [V3 PATCH 03/14] target-ppc: Add ISA2.06 divdeu[o] Instructions

2014-01-03 Thread Tom Musta
On 12/27/2013 6:30 PM, Scott Wood wrote: These instructions are phased-in on embedded, and unlike bpermd are not present on e5500/e6500 which are 64-bit ISA 2.06 implementations. Wasn't the conclusion in a previous thread to use separate flags for these instruction groups? -Scott Scott:

Re: [Qemu-devel] [V3 PATCH 10/14] target-ppc: Fix and enable fri[mnpz]

2014-01-06 Thread Tom Musta
On 12/24/2013 10:02 AM, Richard Henderson wrote: I'll also note that frin can't properly be implemented with float_round_nearest_even because it doesn't round to even. Good catch. I should be able to use Peter's ties away rounding mode patches.

[Qemu-devel] [V4 PATCH 00/22] target-ppc: Base ISA V2.06 for Power7/Power8

2014-01-07 Thread Tom Musta
helpers to avoid double rounding. - Corrected frin to use nearest ties away rounding mode instead of nearest ties to even. - Updated (new) Power7+ model to include all newly added instruction flags. - Assorted comments from Richard Henderson, Peter Maydell and Scott Wood. Tom Musta (22

[Qemu-devel] [V4 PATCH 05/22] target-ppc: Add ISA 2.06 divweu[o] Instructions

2014-01-07 Thread Tom Musta
This patch addes the Unsigned Divide Word Extended instructions which were introduced in Power ISA 2.06B. Signed-off-by: Tom Musta tommu...@gmail.com --- V2: Eliminating extraneous code in the overflow case per comments from Richard Henderson. Fixed corner case bug in divweu (check for (RA

[Qemu-devel] [V4 PATCH 03/22] target-ppc: Add ISA2.06 divdeu[o] Instructions

2014-01-07 Thread Tom Musta
. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: Moved the 128-bit divide routine into host-utils per Richard Henderson's suggestion. V4: Use the newly added PPC2_DIVE_ISA206 flag. Modified helper macro which will be common for divde[u] and divwe[u

[Qemu-devel] [V4 PATCH 02/22] target-ppc: Add Flag for ISA2.06 Divide Extended Instructions

2014-01-07 Thread Tom Musta
This patch adds a flag for the Divide Extended instructions that were introduced in Power ISA V2.06B. The flag is added to the Power7 and Power8 models. Signed-off-by: Tom Musta tommu...@gmail.com --- V4: Split into new and separate patch. Added flag to Power7+ model. target-ppc/cpu.h

[Qemu-devel] [V4 PATCH 04/22] target-ppc: Add ISA2.06 divde[o] Instructions

2014-01-07 Thread Tom Musta
This patch adds the Divide Doubleword Extended instructions. The implementation builds on the unsigned helper provided in the previous patch. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: Updated to use the host-utils 128 bit divide. V4: Using

[Qemu-devel] [V4 PATCH 10/22] target-ppc: Add Flag for ISA V2.06 Floating Point Conversion

2014-01-07 Thread Tom Musta
This patch adds a flag for the floating point conversion instructions introduced in Power ISA 2.06B. Signed-off-by: Tom Musta tommu...@gmail.com --- V4: Split single flag into multiple flags per discussion with Alex Graf and Scott Wood. Added to Power7+ config. target-ppc/cpu.h

[Qemu-devel] [V4 PATCH 12/22] target-ppc: Add ISA 2.06 fcfid[u][s] Instructions

2014-01-07 Thread Tom Musta
This patch adds the fcfids, fcfidu and fcfidus instructions which were introduced in Power ISA 2.06B. A common macro is provided to eliminate repetitious code, and the existing fcfid instruction is refactored to use this macro. Signed-off-by: Tom Musta tommu...@gmail.com --- V4: Using the newly

[Qemu-devel] [V4 PATCH 15/22] softfloat: Refactor code handling various rounding modes

2014-01-07 Thread Tom Musta
tiesAway rounding mode. Signed-off-by: Peter Maydell peter.mayd...@linaro.org Message-Id: 1389013881-15726-16-git-send-email-peter.mayd...@linaro.org Reviewed-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net --- fpu/softfloat.c | 405

[Qemu-devel] [V4 PATCH 09/22] target-ppc: Add ISA 2.06 stbcx. and sthcx. Instructions

2014-01-07 Thread Tom Musta
This patch adds the byte and halfword variants of the Store Conditional instructions. A common macro is introduced and the existing implementations of stwcx. and stdcx. are refactored to use this macro. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden

[Qemu-devel] [V4 PATCH 19/22] target-ppc: Add ISA 2.06 ftdiv Instruction

2014-01-07 Thread Tom Musta
This patch adds the Floating Point Test for Divide instruction which was introduced in Power ISA 2.06B. Signed-off-by: Tom Musta tommu...@gmail.com --- V4: Using the newly added PPC2_FP_TST_ISA206 flag. Modified helper signature per Richard Henderson's review. target-ppc/fpu_helper.c | 56

[Qemu-devel] [V4 PATCH 18/22] target-ppc: Add Flag for Power ISA V2.06 Floating Point Test Instructions

2014-01-07 Thread Tom Musta
This patch adds a flag for Floating Point Test instructions that were introduced in Power ISA V2.06B. Signed-off-by: Tom Musta tommu...@gmail.com --- V4: Split single flag into multiple flags per discussion with Alex Graf and Scott Wood. Added flag to Power7+ model. target-ppc/cpu.h

[Qemu-devel] [V4 PATCH 20/22] target-ppc: Add ISA 2.06 ftsqrt

2014-01-07 Thread Tom Musta
This patch adds the Floating Point Test for Square Root instruction which was introduced in Power ISA 2.06. Signed-off-by: Tom Musta tommu...@gmail.com --- V4: Using the newly added PPC2_FP_TST_ISA206 flag. Modified helper signature per Richard Henderson's review. target-ppc/fpu_helper.c

[Qemu-devel] [V4 PATCH 22/22] target-ppc: Add ISA2.06 lfiwzx Instruction

2014-01-07 Thread Tom Musta
This patch adds the Load Floating Point as Integer Word and Zero Indexed (lfiwzx) instruction which was introduced in Power ISA 2.06. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V4: Using the PPC2_FP_CVT_ISA206 flag. target-ppc/translate.c

[Qemu-devel] [V4 PATCH 21/22] target-ppc: Enable frsqrtes on Power7 and Power8

2014-01-07 Thread Tom Musta
-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- target-ppc/translate_init.c |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/target-ppc/translate_init.c b/target-ppc/translate_init.c index bcaee6c..a83c964 100644 --- a/target-ppc

[Qemu-devel] [V4 PATCH 11/22] target-ppc: Add ISA2.06 Float to Integer Instructions

2014-01-07 Thread Tom Musta
(fctidu) - Floating Convert to Integer Doubleword Unsigned with Round Toward Zero (fctiduz) A common macro is developed to eliminate repetitious code. Existing instructions are also refactoried to use this macro (fctiw, fctiwz, fctid, fctidz). Signed-off-by: Tom Musta tommu...@gmail.com

[Qemu-devel] [V4 PATCH 17/22] target-ppc: Fix and enable fri[mnpz]

2014-01-07 Thread Tom Musta
helper is modified to correctly handle some of the boundary cases (NaNs and the inexact flag). Signed-off-by: Tom Musta tommu...@gmail.com --- V4: frin changed to use ties away rounding mode per Richard Henderson's review. Modified NaN handling. Proper handling of stickiness of the inexact flag

[Qemu-devel] [V4 PATCH 01/22] target-ppc: Add ISA2.06 bpermd Instruction

2014-01-07 Thread Tom Musta
This patch adds the Bit Permute Doubleword (bpermd) instruction, which was introduced in Power ISA 2.06 as part of the base 64-bit architecture. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson address@hidden --- V2: Addressing stylistic comments from Richard Henderson

[Qemu-devel] [V4 PATCH 06/22] target-ppc: Add ISA 2.06 divwe[o] Instructions

2014-01-07 Thread Tom Musta
This patch addes the signed Divide Word Extended instructions which were introduced in Power ISA 2.06B. Signed-off-by: Tom Musta tommu...@gmail.com --- V2: Eliminating extraneous code in the overflow case per comments from Richard Henderson. Fixed corner case bug in divweu (check for (RA) = (RB

[Qemu-devel] [V4 PATCH 16/22] softfloat: Add support for ties-away rounding

2014-01-07 Thread Tom Musta
the rounding operation naturally causes the exact tie to round up in magnitude. Signed-off-by: Peter Maydell peter.mayd...@linaro.org Message-Id: 1389013881-15726-17-git-send-email-peter.mayd...@linaro.org Reviewed-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net --- fpu

[Qemu-devel] [V4 PATCH 08/22] target-ppc: Add ISA2.06 lbarx, lharx Instructions

2014-01-07 Thread Tom Musta
This patch adds the byte and halfword variants of the Load and Reserve instructions. Since there is much commonality among all forms of Load and Reserve, a macro is provided and the existing implementations of lwarx and ldarx are refactoried to use this macro. Signed-off-by: Tom Musta tommu

[Qemu-devel] [V4 PATCH 07/22] target-ppc: Add Flag for ISA2.06 Atomic Instructions

2014-01-07 Thread Tom Musta
This patch adds a flag for the atomic instructions introduced in Power ISA V2.06B. Signed-off-by: Tom Musta tommu...@gmail.com --- V4: Split into new and separate patch. Added to Power7+ model. target-ppc/cpu.h|5 - target-ppc/translate_init.c |9 ++--- 2 files

[Qemu-devel] [V4 PATCH 14/22] softfloat: Factor out RoundAndPackFloat16 and NormalizeFloat16Subnormal

2014-01-07 Thread Tom Musta
-by: Peter Maydell peter.mayd...@linaro.org Message-Id: 1389013881-15726-14-git-send-email-peter.mayd...@linaro.org Reviewed-by: Tom Musta tommu...@gmail.com Reviewed-by: Richard Henderson r...@twiddle.net --- fpu/softfloat.c | 209 +-- 1 files

[Qemu-devel] [V4 PATCH 13/22] softfloat: Fix exception flag handling for float32_to_float16()

2014-01-07 Thread Tom Musta
...@linaro.org Reviewed-by: Richard Henderson r...@twiddle.net Reviewed-by: Tom Musta tommu...@gmail.com --- fpu/softfloat.c | 105 ++ 1 files changed, 66 insertions(+), 39 deletions(-) diff --git a/fpu/softfloat.c b/fpu/softfloat.c index 2c598ca..f95c964

Re: [Qemu-devel] [V5 PATCH 00/14] [V5 PATCH 00/14] target-ppc: VSX Stage 4

2014-01-09 Thread Tom Musta
Arggh. I relied on Power ISA Book I Section 7.6.1 as a definitive list of VSX instructions. Unfortunately it is not complete. I will publish soon V6 of this series to add in some ISA 2.07 VSX instructions that I missed: - mfvsr*, mtvsr* - fmrg[eo]w - xsrsp - xscvdpspn, xscvspdpn

[Qemu-devel] [V6 PATCH 01/18] target-ppc: VSX Stage 4: Add VSX 2.07 Flag

2014-01-10 Thread Tom Musta
This patch adds a flag to identify those VSX instructions that are new to Power ISA V2.07. The flag is added to the Power 8 processor initialization so that the P8 models understand how to decode and emulate instructions in this category. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed

<    1   2   3   4   5   6   7   8   9   >