Statistics
| Branch: | Revision:

root / target-s390x @ 26ca8c06

# Date Author Comment
c95ec459 01/05/2013 10:18 pm Richard Henderson

target-s390: Optimize ADDC/SUBB

Giving the proper mask to disas_jcc allows us to generate an inline
comparison generating the carry/borrow with setcond.

In the very worst case, when we must use the external helper to compute
a value for CC, we generate (cc > 1) instead of (cc >> 1), which is only...

bacf43c6 01/05/2013 10:18 pm Richard Henderson

target-s390: Optimize get_address

Don't load the displacement into a register first, add it second
so that tcg_gen_addi_i64 can eliminate zeros. Don't mask the
displacement first so that we don't turn small negative numbers
into large positive numbers.
...

b7886de3 01/05/2013 10:18 pm Richard Henderson

target-s390: Perform COMPARE AND SWAP inline

Still no proper solution for CONFIG_USER_ONLY, but the system
version is significantly better.

Signed-off-by: Richard Henderson <>

d918a65c 01/05/2013 10:18 pm Richard Henderson

target-s390: Use TCG_CALL_NO_WG for memory helpers

Those that do not read or write tcg registers, but can
raise exceptions via memory faults.

Signed-off-by: Richard Henderson <>

c482ea94 01/05/2013 10:18 pm Richard Henderson

target-s390: Use TCG_CALL_NO_WG for floating-point helpers

None of them read or write tcg registers, but most can
raise fp exceptions.

Signed-off-by: Richard Henderson <>

c20fec40 01/05/2013 10:18 pm Richard Henderson

target-s390: Use TCG_CALL_NO_WG for integer helpers

The division routines do not read or write tcg registers,
but can raise fixed-point divide exceptions.

Signed-off-by: Richard Henderson <>

893e1660 01/05/2013 10:18 pm Richard Henderson

target-s390: Use TCG_CALL_NO_WG for misc helpers

Signed-off-by: Richard Henderson <>

26cc0a3f 01/05/2013 10:18 pm Richard Henderson

target-s390: Use noreturn for exception and load_psw

Both always exit the cpu loop.

Signed-off-by: Richard Henderson <>

99b4f24b 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement POPCNT

Signed-off-by: Richard Henderson <>

2db014b5 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement CPSDR

Signed-off-by: Richard Henderson <>

49f7ee80 01/05/2013 10:18 pm Richard Henderson

target-s390: Check insn operand specifications

Removes all the fixmes for even register numbers, etc.

Signed-off-by: Richard Henderson <>

1d1f6301 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement LCDFR

Signed-off-by: Richard Henderson <>

d2d9feac 01/05/2013 10:18 pm Richard Henderson

target-s390: Use uint64_to_float128

Signed-off-by: Richard Henderson <>

a12000b9 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement SET ROUNDING MODE

Signed-off-by: Richard Henderson <>

411edc22 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement LOAD/SET FP AND SIGNAL

Signed-off-by: Richard Henderson <>

90b4f8ad 01/05/2013 10:18 pm Richard Henderson

target-s390: Fix cpu_clone_regs

R2 is the syscall return register, not R0.

Signed-off-by: Richard Henderson <>

d074ac6d 01/05/2013 10:18 pm Richard Henderson

target-s390: Optimize XC

Notice XC with same address and convert that to store of zero.

Signed-off-by: Richard Henderson <>

f24c49c2 01/05/2013 10:18 pm Richard Henderson

target-s390: Optmize emitting discards

While they aren't expensive, they aren't free to process. When we
know that the three cc helper variables are dead, don't kill them.

Signed-off-by: Richard Henderson <>

de379661 01/05/2013 10:18 pm Richard Henderson

target-s390: Tidy comparisons

After full conversion, we can audit the uses of LTGT cc ops
and see that none of the instructions can ever set CC=3.
Thus we can extend the table to treat that bit as ignored.

This fixes a regression wrt the pre-conversion translation...

a359b770 01/05/2013 10:18 pm Richard Henderson

target-s390: Optimize ADDU/SUBU CC testing

We can easily generate some masks for logical add/subtract inline.

Signed-off-by: Richard Henderson <>

2cf5e350 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement BRANCH ON INDEX

Signed-off-by: Richard Henderson <>

7a6c7067 01/05/2013 10:18 pm Richard Henderson

target-s390: Tidy s->op_cc handling

There's no need to force computation of the true cc_op when taking an
exception or single stepping. In either case we'll enter the next TB
with s->cc_op = DYNAMIC and recompute anyway. Just make sure that
s->cc_op is stored back to env->cc_op as needed....

5550359f 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement COMPARE AND BRANCH

Signed-off-by: Richard Henderson <>

2d6a8698 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement RISBG

Signed-off-by: Richard Henderson <>

143cbbc5 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement LDGR, LGDR

Signed-off-by: Richard Henderson <>

d6c6372e 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement R[NOX]SBG

Signed-off-by: Richard Henderson <>

e0def909 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement PREFETCH

Signed-off-by: Richard Henderson <>

403e217f 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement COMPARE RELATIVE LONG

Signed-off-by: Richard Henderson <>

1c268751 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement COMPARE AND TRAP

Signed-off-by: Richard Henderson <>

632086da 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement LOAD ON CONDITION

Signed-off-by: Richard Henderson <>

b92fa334 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement STORE ON CONDITION

Signed-off-by: Richard Henderson <>

6ac1b45f 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement CONVERT TO LOGICAL

Signed-off-by: Richard Henderson <>

2112bf1b 01/05/2013 10:18 pm Richard Henderson

target-s390: Implement CONVERT FROM LOGICAL

Signed-off-by: Richard Henderson <>

e805a0d3 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SPX, STPX

Signed-off-by: Richard Henderson <>

411fea3d 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STAP

Signed-off-by: Richard Henderson <>

cfef53e3 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert IPTE

Signed-off-by: Richard Henderson <>

8026417c 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert ISKE

Signed-off-by: Richard Henderson <>

2bbde27f 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SSKE

Signed-off-by: Richard Henderson <>

5cc69c54 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert RRBE

Signed-off-by: Richard Henderson <>

2c423fc0 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert subchannel instructions

While we're at it, list all of the chapter 14 subchannel insns.
Which is easy since all merely need indicate non-operation.

Signed-off-by: Richard Henderson <>

204504e2 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STURA

Signed-off-by: Richard Henderson <>

3d596f49 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert CSP

Signed-off-by: Richard Henderson <>

39a5003c 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STCKE

Signed-off-by: Richard Henderson <>

14244b21 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SACF

Signed-off-by: Richard Henderson <>

d14b3e09 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STSI

Signed-off-by: Richard Henderson <>

fc778b55 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STFL

Signed-off-by: Richard Henderson <>

7ab938d7 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LPSWE

Signed-off-by: Richard Henderson <>

dc458df9 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SERVC

Signed-off-by: Richard Henderson <>

4f3adfb2 01/05/2013 10:18 pm Richard Henderson

target-s390: Delete dead code from old translator

The use of inline restricts detection of static functions that are
no longer used. Limit the use of inline to those functions that
are conditionally used based on CONFIG_USER_ONLY.

Signed-off-by: Richard Henderson <>

6e2704e7 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert IPM

Note that the previous placement of the PM field was incorrect.

Signed-off-by: Richard Henderson <>

374724f9 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert CKSM

Signed-off-by: Richard Henderson <>

d62a4c97 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert EAR, SAR

Signed-off-by: Richard Henderson <>

ee6c38d5 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert MVPG

Signed-off-by: Richard Henderson <>

aa31bf60 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert CLST, MVST

Signed-off-by: Richard Henderson <>

4600c994 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SRST

Signed-off-by: Richard Henderson <>

71bd6669 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STIDP

Signed-off-by: Richard Henderson <>

35289799 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SCK

Signed-off-by: Richard Henderson <>

434c91a5 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STCK

Signed-off-by: Richard Henderson <>

dd3eb7b5 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SCKC, STCKC

Signed-off-by: Richard Henderson <>

c4f0a863 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SPT, STPT

Signed-off-by: Richard Henderson <>

28d55556 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SPKA

Signed-off-by: Richard Henderson <>

0568d8aa 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert PTLB

Signed-off-by: Richard Henderson <>

1a800a2d 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert FP SUBTRACT

Signed-off-by: Richard Henderson <>

f08a5c31 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert FP DIVIDE

Signed-off-by: Richard Henderson <>

83b00736 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert FP MULTIPLY

Signed-off-by: Richard Henderson <>

722bfec3 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert MULTIPLY AND ADD, SUBTRACT

Use the new float*_muladd interface to softfloat.

Signed-off-by: Richard Henderson <>

31aa97d1 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert TEST DATA CLASS

Signed-off-by: Richard Henderson <>

5d7fd045 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert FP LOAD COMPLIMENT, NEGATIVE, POSITIVE

Signed-off-by: Richard Henderson <>

16d7b2a4 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert FP SQUARE ROOT

Signed-off-by: Richard Henderson <>

24db8412 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LOAD ZERO

Signed-off-by: Richard Henderson <>

68c8bd93 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert CONVERT TO FIXED

Signed-off-by: Richard Henderson <>

683bb9a8 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert CONVERT FROM FIXED

Signed-off-by: Richard Henderson <>

102bf2c6 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert FLOGR

Signed-off-by: Richard Henderson <>

8379bfdb 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LFPC, SFPC

Note that we were failing to set the rounding mode in fpu_status.

Signed-off-by: Richard Henderson <>

ea20490f 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert EFPC, STFPC

Signed-off-by: Richard Henderson <>

504488b8 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LCTL, STCTL

Signed-off-by: Richard Henderson <>

f3de39c4 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert COMPARE AND SWAP

Signed-off-by: Richard Henderson <>

32a44d58 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert CLM

Signed-off-by: Richard Henderson <>

2ae68059 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STCM

Signed-off-by: Richard Henderson <>

112bf079 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert TPROT

Signed-off-by: Richard Henderson <>

3e398cf9 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LOAD CONTROL, part 2

Signed-off-by: Richard Henderson <>

d54f5865 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LOAD REVERSED

Signed-off-by: Richard Henderson <>

e025e52a 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STORE REVERSED

Signed-off-by: Richard Henderson <>

7691c23b 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LLGT

Signed-off-by: Richard Henderson <>

587626f8 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert FP ADD, COMPARE, LOAD TEST/ROUND/LENGTHENED

Signed-off-by: Richard Henderson <>

77f8d6c3 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LOAD, STORE MULTIPLE

Signed-off-by: Richard Henderson <>

6a04d76a 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert MOVE

Signed-off-by: Richard Henderson <>

a05d2b6b 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert NI, XI, OI

Signed-off-by: Richard Henderson <>

145cdb40 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert STNSM, STOSM

Signed-off-by: Richard Henderson <>

7df3e93a 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LAM, STAM

Signed-off-by: Richard Henderson <>

eb66e6a9 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert CLCLE, MVCLE

Signed-off-by: Richard Henderson <>

af9e5a04 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert MVC

The code that was in gen_op_mvc was a bit confused wrt what lengths
it wanted to handle. I also disbelieve that the inline memset is
worthwhile.

Signed-off-by: Richard Henderson <>

0a949039 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert NC, XC, OC, TR, UNPK

Signed-off-by: Richard Henderson <>

4f7403d5 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert CLC

Signed-off-by: Richard Henderson <>

97c3ab61 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert MVCP, MVCS

Signed-off-by: Richard Henderson <>

d8fe4a9c 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert LRA

Note that truncating the store to r1 based on PSW_MASK_64
is incorrect. We always modify the entire register.

Signed-off-by: Richard Henderson <>

0c240015 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SIGP

Signed-off-by: Richard Henderson <>

972e35b9 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert DIAGNOSE

Signed-off-by: Richard Henderson <>

cbe24bfa 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SHIFT, ROTATE SINGLE

Note that we were missing the 32-bit SLA.

Signed-off-by: Richard Henderson <>

a79ba339 01/05/2013 10:18 pm Richard Henderson

target-s390: Convert SHIFT DOUBLE

Signed-off-by: Richard Henderson <>