target-ppc: Define Endian-Correct Accessors for VSR Field Access
authorTom Musta <tommusta@gmail.com>
Mon, 31 Mar 2014 21:03:57 +0000 (16:03 -0500)
committerAlexander Graf <agraf@suse.de>
Tue, 8 Apr 2014 09:20:01 +0000 (11:20 +0200)
commit80189035de73f30e42a7f933c45cccfc4b0c56e9
treef6aa76e916362c32fe0c60c3aad24041995f4f17
parent0453099b7d20c9fc2946ed74f1d965ae4d173d19
target-ppc: Define Endian-Correct Accessors for VSR Field Access

This change defines accessors for VSR doubleword and word fields that
are correct from a host Endian perspective.  This allows code to
use the Power ISA indexing numbers in code.

For example, the xscvdpsxws instruction has a target VSR that looks
like this:

  0           32       64                    127
  +-----------+--------+-----------+-----------+
  | undefined | SW     | undefined | undefined |
  +-----------+--------+-----------+-----------+

VSX helper code will use VsrW(1) to access this field.

Signed-off-by: Tom Musta <tommusta@gmail.com>
Tested-by: Tom Musta <tommusta@gmail.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
target-ppc/fpu_helper.c