Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
book3s_paired_singles.c File Reference
#include <asm/kvm.h>
#include <asm/kvm_ppc.h>
#include <asm/disassemble.h>
#include <asm/kvm_book3s.h>
#include <asm/kvm_fpu.h>
#include <asm/reg.h>
#include <asm/cacheflush.h>
#include <asm/switch_to.h>
#include <linux/vmalloc.h>

Go to the source code of this file.

Macros

#define dprintk(...)   do { } while(0);
 
#define OP_LFS   48
 
#define OP_LFSU   49
 
#define OP_LFD   50
 
#define OP_LFDU   51
 
#define OP_STFS   52
 
#define OP_STFSU   53
 
#define OP_STFD   54
 
#define OP_STFDU   55
 
#define OP_PSQ_L   56
 
#define OP_PSQ_LU   57
 
#define OP_PSQ_ST   60
 
#define OP_PSQ_STU   61
 
#define OP_31_LFSX   535
 
#define OP_31_LFSUX   567
 
#define OP_31_LFDX   599
 
#define OP_31_LFDUX   631
 
#define OP_31_STFSX   663
 
#define OP_31_STFSUX   695
 
#define OP_31_STFX   727
 
#define OP_31_STFUX   759
 
#define OP_31_LWIZX   887
 
#define OP_31_STFIWX   983
 
#define OP_59_FADDS   21
 
#define OP_59_FSUBS   20
 
#define OP_59_FSQRTS   22
 
#define OP_59_FDIVS   18
 
#define OP_59_FRES   24
 
#define OP_59_FMULS   25
 
#define OP_59_FRSQRTES   26
 
#define OP_59_FMSUBS   28
 
#define OP_59_FMADDS   29
 
#define OP_59_FNMSUBS   30
 
#define OP_59_FNMADDS   31
 
#define OP_63_FCMPU   0
 
#define OP_63_FCPSGN   8
 
#define OP_63_FRSP   12
 
#define OP_63_FCTIW   14
 
#define OP_63_FCTIWZ   15
 
#define OP_63_FDIV   18
 
#define OP_63_FADD   21
 
#define OP_63_FSQRT   22
 
#define OP_63_FSEL   23
 
#define OP_63_FRE   24
 
#define OP_63_FMUL   25
 
#define OP_63_FRSQRTE   26
 
#define OP_63_FMSUB   28
 
#define OP_63_FMADD   29
 
#define OP_63_FNMSUB   30
 
#define OP_63_FNMADD   31
 
#define OP_63_FCMPO   32
 
#define OP_63_MTFSB1   38
 
#define OP_63_FSUB   20
 
#define OP_63_FNEG   40
 
#define OP_63_MCRFS   64
 
#define OP_63_MTFSB0   70
 
#define OP_63_FMR   72
 
#define OP_63_MTFSFI   134
 
#define OP_63_FABS   264
 
#define OP_63_MFFS   583
 
#define OP_63_MTFSF   711
 
#define OP_4X_PS_CMPU0   0
 
#define OP_4X_PSQ_LX   6
 
#define OP_4XW_PSQ_STX   7
 
#define OP_4A_PS_SUM0   10
 
#define OP_4A_PS_SUM1   11
 
#define OP_4A_PS_MULS0   12
 
#define OP_4A_PS_MULS1   13
 
#define OP_4A_PS_MADDS0   14
 
#define OP_4A_PS_MADDS1   15
 
#define OP_4A_PS_DIV   18
 
#define OP_4A_PS_SUB   20
 
#define OP_4A_PS_ADD   21
 
#define OP_4A_PS_SEL   23
 
#define OP_4A_PS_RES   24
 
#define OP_4A_PS_MUL   25
 
#define OP_4A_PS_RSQRTE   26
 
#define OP_4A_PS_MSUB   28
 
#define OP_4A_PS_MADD   29
 
#define OP_4A_PS_NMSUB   30
 
#define OP_4A_PS_NMADD   31
 
#define OP_4X_PS_CMPO0   32
 
#define OP_4X_PSQ_LUX   38
 
#define OP_4XW_PSQ_STUX   39
 
#define OP_4X_PS_NEG   40
 
#define OP_4X_PS_CMPU1   64
 
#define OP_4X_PS_MR   72
 
#define OP_4X_PS_CMPO1   96
 
#define OP_4X_PS_NABS   136
 
#define OP_4X_PS_ABS   264
 
#define OP_4X_PS_MERGE00   528
 
#define OP_4X_PS_MERGE01   560
 
#define OP_4X_PS_MERGE10   592
 
#define OP_4X_PS_MERGE11   624
 
#define SCALAR_NONE   0
 
#define SCALAR_HIGH   (1 << 0)
 
#define SCALAR_LOW   (1 << 1)
 
#define SCALAR_NO_PS0   (1 << 2)
 
#define SCALAR_NO_PS1   (1 << 3)
 
#define GQR_ST_TYPE_MASK   0x00000007
 
#define GQR_ST_TYPE_SHIFT   0
 
#define GQR_ST_SCALE_MASK   0x00003f00
 
#define GQR_ST_SCALE_SHIFT   8
 
#define GQR_LD_TYPE_MASK   0x00070000
 
#define GQR_LD_TYPE_SHIFT   16
 
#define GQR_LD_SCALE_MASK   0x3f000000
 
#define GQR_LD_SCALE_SHIFT   24
 
#define GQR_QUANTIZE_FLOAT   0
 
#define GQR_QUANTIZE_U8   4
 
#define GQR_QUANTIZE_U16   5
 
#define GQR_QUANTIZE_S8   6
 
#define GQR_QUANTIZE_S16   7
 
#define FPU_LS_SINGLE   0
 
#define FPU_LS_DOUBLE   1
 
#define FPU_LS_SINGLE_LOW   2
 

Functions

bool kvmppc_inst_is_paired_single (struct kvm_vcpu *vcpu, u32 inst)
 
int kvmppc_emulate_paired_single (struct kvm_run *run, struct kvm_vcpu *vcpu)
 

Macro Definition Documentation

#define dprintk (   ...)    do { } while(0);

Definition at line 35 of file book3s_paired_singles.c.

#define FPU_LS_DOUBLE   1

Definition at line 158 of file book3s_paired_singles.c.

#define FPU_LS_SINGLE   0

Definition at line 157 of file book3s_paired_singles.c.

#define FPU_LS_SINGLE_LOW   2

Definition at line 159 of file book3s_paired_singles.c.

#define GQR_LD_SCALE_MASK   0x3f000000

Definition at line 148 of file book3s_paired_singles.c.

#define GQR_LD_SCALE_SHIFT   24

Definition at line 149 of file book3s_paired_singles.c.

#define GQR_LD_TYPE_MASK   0x00070000

Definition at line 146 of file book3s_paired_singles.c.

#define GQR_LD_TYPE_SHIFT   16

Definition at line 147 of file book3s_paired_singles.c.

#define GQR_QUANTIZE_FLOAT   0

Definition at line 151 of file book3s_paired_singles.c.

#define GQR_QUANTIZE_S16   7

Definition at line 155 of file book3s_paired_singles.c.

#define GQR_QUANTIZE_S8   6

Definition at line 154 of file book3s_paired_singles.c.

#define GQR_QUANTIZE_U16   5

Definition at line 153 of file book3s_paired_singles.c.

#define GQR_QUANTIZE_U8   4

Definition at line 152 of file book3s_paired_singles.c.

#define GQR_ST_SCALE_MASK   0x00003f00

Definition at line 144 of file book3s_paired_singles.c.

#define GQR_ST_SCALE_SHIFT   8

Definition at line 145 of file book3s_paired_singles.c.

#define GQR_ST_TYPE_MASK   0x00000007

Definition at line 142 of file book3s_paired_singles.c.

#define GQR_ST_TYPE_SHIFT   0

Definition at line 143 of file book3s_paired_singles.c.

#define OP_31_LFDUX   631

Definition at line 54 of file book3s_paired_singles.c.

#define OP_31_LFDX   599

Definition at line 53 of file book3s_paired_singles.c.

#define OP_31_LFSUX   567

Definition at line 52 of file book3s_paired_singles.c.

#define OP_31_LFSX   535

Definition at line 51 of file book3s_paired_singles.c.

#define OP_31_LWIZX   887

Definition at line 59 of file book3s_paired_singles.c.

#define OP_31_STFIWX   983

Definition at line 60 of file book3s_paired_singles.c.

#define OP_31_STFSUX   695

Definition at line 56 of file book3s_paired_singles.c.

#define OP_31_STFSX   663

Definition at line 55 of file book3s_paired_singles.c.

#define OP_31_STFUX   759

Definition at line 58 of file book3s_paired_singles.c.

#define OP_31_STFX   727

Definition at line 57 of file book3s_paired_singles.c.

#define OP_4A_PS_ADD   21

Definition at line 113 of file book3s_paired_singles.c.

#define OP_4A_PS_DIV   18

Definition at line 111 of file book3s_paired_singles.c.

#define OP_4A_PS_MADD   29

Definition at line 119 of file book3s_paired_singles.c.

#define OP_4A_PS_MADDS0   14

Definition at line 109 of file book3s_paired_singles.c.

#define OP_4A_PS_MADDS1   15

Definition at line 110 of file book3s_paired_singles.c.

#define OP_4A_PS_MSUB   28

Definition at line 118 of file book3s_paired_singles.c.

#define OP_4A_PS_MUL   25

Definition at line 116 of file book3s_paired_singles.c.

#define OP_4A_PS_MULS0   12

Definition at line 107 of file book3s_paired_singles.c.

#define OP_4A_PS_MULS1   13

Definition at line 108 of file book3s_paired_singles.c.

#define OP_4A_PS_NMADD   31

Definition at line 121 of file book3s_paired_singles.c.

#define OP_4A_PS_NMSUB   30

Definition at line 120 of file book3s_paired_singles.c.

#define OP_4A_PS_RES   24

Definition at line 115 of file book3s_paired_singles.c.

#define OP_4A_PS_RSQRTE   26

Definition at line 117 of file book3s_paired_singles.c.

#define OP_4A_PS_SEL   23

Definition at line 114 of file book3s_paired_singles.c.

#define OP_4A_PS_SUB   20

Definition at line 112 of file book3s_paired_singles.c.

#define OP_4A_PS_SUM0   10

Definition at line 105 of file book3s_paired_singles.c.

#define OP_4A_PS_SUM1   11

Definition at line 106 of file book3s_paired_singles.c.

#define OP_4X_PS_ABS   264

Definition at line 130 of file book3s_paired_singles.c.

#define OP_4X_PS_CMPO0   32

Definition at line 122 of file book3s_paired_singles.c.

#define OP_4X_PS_CMPO1   96

Definition at line 128 of file book3s_paired_singles.c.

#define OP_4X_PS_CMPU0   0

Definition at line 102 of file book3s_paired_singles.c.

#define OP_4X_PS_CMPU1   64

Definition at line 126 of file book3s_paired_singles.c.

#define OP_4X_PS_MERGE00   528

Definition at line 131 of file book3s_paired_singles.c.

#define OP_4X_PS_MERGE01   560

Definition at line 132 of file book3s_paired_singles.c.

#define OP_4X_PS_MERGE10   592

Definition at line 133 of file book3s_paired_singles.c.

#define OP_4X_PS_MERGE11   624

Definition at line 134 of file book3s_paired_singles.c.

#define OP_4X_PS_MR   72

Definition at line 127 of file book3s_paired_singles.c.

#define OP_4X_PS_NABS   136

Definition at line 129 of file book3s_paired_singles.c.

#define OP_4X_PS_NEG   40

Definition at line 125 of file book3s_paired_singles.c.

#define OP_4X_PSQ_LUX   38

Definition at line 123 of file book3s_paired_singles.c.

#define OP_4X_PSQ_LX   6

Definition at line 103 of file book3s_paired_singles.c.

#define OP_4XW_PSQ_STUX   39

Definition at line 124 of file book3s_paired_singles.c.

#define OP_4XW_PSQ_STX   7

Definition at line 104 of file book3s_paired_singles.c.

#define OP_59_FADDS   21

Definition at line 62 of file book3s_paired_singles.c.

#define OP_59_FDIVS   18

Definition at line 65 of file book3s_paired_singles.c.

#define OP_59_FMADDS   29

Definition at line 70 of file book3s_paired_singles.c.

#define OP_59_FMSUBS   28

Definition at line 69 of file book3s_paired_singles.c.

#define OP_59_FMULS   25

Definition at line 67 of file book3s_paired_singles.c.

#define OP_59_FNMADDS   31

Definition at line 72 of file book3s_paired_singles.c.

#define OP_59_FNMSUBS   30

Definition at line 71 of file book3s_paired_singles.c.

#define OP_59_FRES   24

Definition at line 66 of file book3s_paired_singles.c.

#define OP_59_FRSQRTES   26

Definition at line 68 of file book3s_paired_singles.c.

#define OP_59_FSQRTS   22

Definition at line 64 of file book3s_paired_singles.c.

#define OP_59_FSUBS   20

Definition at line 63 of file book3s_paired_singles.c.

#define OP_63_FABS   264

Definition at line 98 of file book3s_paired_singles.c.

#define OP_63_FADD   21

Definition at line 80 of file book3s_paired_singles.c.

#define OP_63_FCMPO   32

Definition at line 90 of file book3s_paired_singles.c.

#define OP_63_FCMPU   0

Definition at line 74 of file book3s_paired_singles.c.

#define OP_63_FCPSGN   8

Definition at line 75 of file book3s_paired_singles.c.

#define OP_63_FCTIW   14

Definition at line 77 of file book3s_paired_singles.c.

#define OP_63_FCTIWZ   15

Definition at line 78 of file book3s_paired_singles.c.

#define OP_63_FDIV   18

Definition at line 79 of file book3s_paired_singles.c.

#define OP_63_FMADD   29

Definition at line 87 of file book3s_paired_singles.c.

#define OP_63_FMR   72

Definition at line 96 of file book3s_paired_singles.c.

#define OP_63_FMSUB   28

Definition at line 86 of file book3s_paired_singles.c.

#define OP_63_FMUL   25

Definition at line 84 of file book3s_paired_singles.c.

#define OP_63_FNEG   40

Definition at line 93 of file book3s_paired_singles.c.

#define OP_63_FNMADD   31

Definition at line 89 of file book3s_paired_singles.c.

#define OP_63_FNMSUB   30

Definition at line 88 of file book3s_paired_singles.c.

#define OP_63_FRE   24

Definition at line 83 of file book3s_paired_singles.c.

#define OP_63_FRSP   12

Definition at line 76 of file book3s_paired_singles.c.

#define OP_63_FRSQRTE   26

Definition at line 85 of file book3s_paired_singles.c.

#define OP_63_FSEL   23

Definition at line 82 of file book3s_paired_singles.c.

#define OP_63_FSQRT   22

Definition at line 81 of file book3s_paired_singles.c.

#define OP_63_FSUB   20

Definition at line 92 of file book3s_paired_singles.c.

#define OP_63_MCRFS   64

Definition at line 94 of file book3s_paired_singles.c.

#define OP_63_MFFS   583

Definition at line 99 of file book3s_paired_singles.c.

#define OP_63_MTFSB0   70

Definition at line 95 of file book3s_paired_singles.c.

#define OP_63_MTFSB1   38

Definition at line 91 of file book3s_paired_singles.c.

#define OP_63_MTFSF   711

Definition at line 100 of file book3s_paired_singles.c.

#define OP_63_MTFSFI   134

Definition at line 97 of file book3s_paired_singles.c.

#define OP_LFD   50

Definition at line 40 of file book3s_paired_singles.c.

#define OP_LFDU   51

Definition at line 41 of file book3s_paired_singles.c.

#define OP_LFS   48

Definition at line 38 of file book3s_paired_singles.c.

#define OP_LFSU   49

Definition at line 39 of file book3s_paired_singles.c.

#define OP_PSQ_L   56

Definition at line 46 of file book3s_paired_singles.c.

#define OP_PSQ_LU   57

Definition at line 47 of file book3s_paired_singles.c.

#define OP_PSQ_ST   60

Definition at line 48 of file book3s_paired_singles.c.

#define OP_PSQ_STU   61

Definition at line 49 of file book3s_paired_singles.c.

#define OP_STFD   54

Definition at line 44 of file book3s_paired_singles.c.

#define OP_STFDU   55

Definition at line 45 of file book3s_paired_singles.c.

#define OP_STFS   52

Definition at line 42 of file book3s_paired_singles.c.

#define OP_STFSU   53

Definition at line 43 of file book3s_paired_singles.c.

#define SCALAR_HIGH   (1 << 0)

Definition at line 137 of file book3s_paired_singles.c.

#define SCALAR_LOW   (1 << 1)

Definition at line 138 of file book3s_paired_singles.c.

#define SCALAR_NO_PS0   (1 << 2)

Definition at line 139 of file book3s_paired_singles.c.

#define SCALAR_NO_PS1   (1 << 3)

Definition at line 140 of file book3s_paired_singles.c.

#define SCALAR_NONE   0

Definition at line 136 of file book3s_paired_singles.c.

Function Documentation

int kvmppc_emulate_paired_single ( struct kvm_run run,
struct kvm_vcpu vcpu 
)

Definition at line 641 of file book3s_paired_singles.c.

bool kvmppc_inst_is_paired_single ( struct kvm_vcpu vcpu,
u32  inst 
)

Definition at line 361 of file book3s_paired_singles.c.