Statistics
| Branch: | Revision:

root / tcg @ 66a0a2cb

# Date Author Comment
9814dd27 12/02/2011 12:50 pm Dong Xu Wang

fix spelling in tcg sub directory

Signed-off-by: Dong Xu Wang <>
Signed-off-by: Stefan Hajnoczi <>

51711aee 11/28/2011 07:36 pm Stefan Weil

tci: Make flush_icache_range() inline

This is standard for other tcg targets and improves tci, too.

Signed-off-by: Stefan Weil <>
Signed-off-by: Anthony Liguori <>

b08d26b7 11/19/2011 01:20 pm Richard Henderson

tcg-sparc: Fix set-but-not used warnings.

In both cases, val is computed, but then not used in the
subsequent line, which then re-computes the quantity in
a different type (int32_t vs unsigned long).

Keep the computation type that's been working so far....

25cc4a76 11/19/2011 01:17 pm Blue Swirl

Merge branch 's390-1.0' of git://repo.or.cz/qemu/agraf

  • 's390-1.0' of git://repo.or.cz/qemu/agraf:
    s390x: initialize virtio dev region
    tcg: Use TCGReg for standard tcg-target entry points.
    tcg: Standardize on TCGReg as the enum for hard registers
    s390x: Add shutdown for TCG s390-virtio machine...
2a534aff 11/14/2011 06:47 pm Richard Henderson

tcg: Use TCGReg for standard tcg-target entry points.

Including tcg_out_ld, tcg_out_st, tcg_out_mov, tcg_out_movi.

Signed-off-by: Richard Henderson <>
Reviewed-by: Andreas Färber <>
Reviewed-by: Stefan Weil <>...

771142c2 11/14/2011 06:47 pm Richard Henderson

tcg: Standardize on TCGReg as the enum for hard registers

Most targets did not name the enum; tci used TCGRegister.

Signed-off-by: Richard Henderson <>
Reviewed-by: Andreas Färber <>
Reviewed-by: Stefan Weil <>...

9df3b45d 11/11/2011 06:33 pm David Gibson

tcg-ppc64: Fix compile errors for userspace only builds with gcc 4.6

tcg/ppc64/tcg-target.c has a couple of places where variables are set
unconditionally, but otherwise used only for softmmu builds, not
userspace only builds. This causes compiler warnings (which are fatal...

c51d9cb5 11/02/2011 10:52 pm Blue Swirl

Merge branch 'tci' of git://qemu.weilnetz.de/qemu

  • 'tci' of git://qemu.weilnetz.de/qemu:
    tcg: Add tcg interpreter to configure / make
    tcg: Add tci disassembler
    tcg: Add interpreter for bytecode
    tcg: Add bytecode generator for tcg interpreter
    tcg: Make ARRAY_SIZE(tcg_op_defs) globally available...
0756e71c 11/02/2011 12:12 am Richard Henderson

tcg: Fix whitespace in tcg-op.h.

Removing the only tabs in the file.

Signed-off-by: Richard Henderson <>
Signed-off-by: malc <>

2f98c9db 11/02/2011 12:12 am Richard Henderson

tcg: Fix regression in tcg_gen_deposit_i64.

The error being caused by the failure to copy the other half of
the input to the output after having narrowed the deposit operation.

Signed-off-by: Richard Henderson <>
Signed-off-by: malc <>

ce285b17 10/31/2011 10:52 pm Stefan Weil

tcg: TCG targets may define tcg_qemu_tb_exec

Targets may use a non standard definition of tcg_tb_exec
by defining this macro in their tcg_target.h.

This is used here by ppc. It will be used by the TCG interpreter, too.

Cc: malc <>
Signed-off-by: Stefan Weil <>

2a24374a 10/31/2011 10:52 pm Stefan Weil

tcg: Make ARRAY_SIZE(tcg_op_defs) globally available

tcg_op_defs was already a global array.

The tci disassembler also needs ARRAY_SIZE(tcg_op_defs),
so add a new global constant with this value.

Signed-off-by: Stefan Weil <>

7316329a 10/31/2011 10:52 pm Stefan Weil

tcg: Add bytecode generator for tcg interpreter

Unlike other tcg target code generators, this one does not generate
machine code for some cpu. It generates machine independent bytecode
which is interpreted later.

This allows running QEMU on any host.

Interpreted bytecode is slower than direct execution of generated...

df072774 10/30/2011 11:06 am Richard Henderson

tcg: Optimize some forms of deposit.

If the deposit replaces the entire word, optimize to a move.

If we're inserting to the top of the word, avoid the mask of arg2
as we'll be shifting out all of the garbage and shifting in zeros.

If the host is 32-bit, reduce a 64-bit deposit to a 32-bit deposit...

8ef935b2 10/14/2011 04:39 pm Stefan Weil

tcg: Fix spelling in comment (varables -> variables)

Signed-off-by: Stefan Weil <>
Signed-off-by: Stefan Hajnoczi <>

dc439de7 10/08/2011 06:21 pm Peter Maydell

tcg/s390: Remove unused tcg_out_addi()

Remove the unused function tcg_out_addi() from the s390 TCG backend;
this brings it into line with other backends.

Signed-off-by: Peter Maydell <>
Acked-by: Richard Henderson <>...

49856292 10/08/2011 06:20 pm Peter Maydell

tcg/ia64: Remove unused tcg_out_addi()

Remove the unused function tcg_out_addi() from the ia64 TCG backend;
this brings it into line with other backends.

Signed-off-by: Peter Maydell <>
Signed-off-by: Blue Swirl <>

a4773324 10/01/2011 09:42 am Jan Kiszka

tcg-i386: Introduce limited deposit support

x86 cannot provide an optimized generic deposit implementation. But at
least for a few special cases, namely for writing bits 0..7, 8..15, and
0..15, versions using only a single instruction are feasible.
Introducing such limited support improves emulating 16-bit x86 code on...

df0eda9b 10/01/2011 09:15 am Peter Maydell

tcg/arm: Remove unused tcg_out_addi()

Remove the unused function tcg_out_addi() from the ARM TCG backend;
this fixes a compilation failure on ARM hosts with newer gcc.

Signed-off-by: Peter Maydell <>
Reviewed-by: Richard Henderson <>...

7f6f0ae5 10/01/2011 09:11 am Stefan Weil

tcg: Add some assertions

Signed-off-by: Stefan Weil <>
Signed-off-by: Blue Swirl <>

c0ad3001 10/01/2011 09:11 am Stefan Weil

tcg: Add forward declarations for local functions

These functions are defined in the tcg target specific file
tcg-target.c.

The forward declarations assert that every tcg target uses
the same function prototype.

Signed-off-by: Stefan Weil <>...

840f5861 10/01/2011 09:11 am Stefan Weil

tcg: Don't declare TCG_TARGET_REG_BITS in tcg-target.h

It is now declared for all tcg targets in tcg.h,
so the tcg target specific declarations are redundant.

Signed-off-by: Stefan Weil <>
Signed-off-by: Blue Swirl <>

817b838e 10/01/2011 09:09 am Stefan Weil

tcg: Declare TCG_TARGET_REG_BITS in tcg.h

TCG_TARGET_REG_BITS can be determined by the compiler,
so there is no need to declare it for each individual tcg target.

This is especially important for new tcg targets
which will be supported by the tcg interpreter....

be9c4183 09/17/2011 08:56 pm Stefan Weil

tcg/ppc64: Only one call output register needed for 64 bit hosts

The second register is only needed for 32 bit hosts.

Cc: Vassili Karpov <>
Fine-with-me'd-by: Vassili Karpov <>
Signed-off-by: Stefan Weil <>...

26a74ae3 09/17/2011 08:55 pm Stefan Weil

tcg/sparc: Only one call output register needed for 64 bit hosts

The second register is only needed for 32 bit hosts.

Cc: Blue Swirl <>
Signed-off-by: Stefan Weil <>
Signed-off-by: Blue Swirl <>

5ddd17b4 09/17/2011 08:55 pm Stefan Weil

tcg/s390: Only one call output register needed for 64 bit hosts

The second register is only needed for 32 bit hosts.

Cc: Alexander Graf <>
Acked-by: Richard Henderson <>
Signed-off-by: Stefan Weil <>
Signed-off-by: Blue Swirl <>

af15a623 09/17/2011 08:54 pm Stefan Weil

tcg/ia64: Only one call output register needed for 64 bit hosts

The second register is never used for ia64 hosts.

Cc: Aurelien Jarno <>
Signed-off-by: Stefan Weil <>
Signed-off-by: Blue Swirl <>

68af23af 09/17/2011 08:54 pm Stefan Weil

tcg/i386: Only one call output register needed for 64 bit hosts

The second register is only needed for 32 bit hosts.

Signed-off-by: Stefan Weil <>
Signed-off-by: Blue Swirl <>

e89720b1 09/09/2011 06:07 pm Thomas Huth

tcg/ppc64: Fix zero extension code generation bug for ppc64 host

The ppc64 code generation backend uses an rldicr (Rotate Left Double
Immediate and Clear Right) instruction to implement zero extension of
a 32 bit quantity to a 64 bit quantity (INDEX_op_ext32u_i64). However...

70d705fd 09/01/2011 08:20 pm Peter Maydell

tcg/ppc/tcg-target.c: Avoid 'set but not used' gcc warnings

Move the declaration and initialisation of some variables in
tcg_out_qemu_ld and tcg_out_qemu_st inside CONFIG_SOFTMMU, to
avoid the "variable set but not used" warning of gcc 4.6.

Signed-off-by: Peter Maydell <>...

fe0de7aa 08/28/2011 10:17 am Blue Swirl

TCG: improve optimizer debugging

Use enum TCGOpcode instead of plain old int so that the name of
current op can be seen in GDB. Add a default case to switch
so that GCC does not complain about unhandled enum cases.

Signed-off-by: Blue Swirl <>

f412c762 08/23/2011 10:24 pm Richard Henderson

tcg: Update --enable-debug for TCG_OPF_NOT_PRESENT.

Signed-off-by: Richard Henderson <>
Reviewed-by: Peter Maydell <>
Signed-off-by: Edgar E. Iglesias <>

0bf1dbdc 08/22/2011 05:26 pm malc

tcg/ppc64: fix 16/32 mixup

Signed-off-by: malc <>

157f2662 08/22/2011 01:40 pm malc

tcg/ppc64: implement not_i32/64 and ext32u_i64

Signed-off-by: malc <>

350dba6c 08/22/2011 01:39 pm malc

tcg/ppc32: implement deposit_i32

Signed-off-by: malc <>

64ba39af 08/21/2011 09:52 pm Richard Henderson

tcg-ia64: Fix typos in AREG0 setup in prologue.

Signed-off-by: Richard Henderson <>
Signed-off-by: Blue Swirl <>

cb25c80a 08/21/2011 09:52 pm Richard Henderson

tcg: Constant fold neg, andc, orc, eqv, nand, nor.

Signed-off-by: Richard Henderson <>
Signed-off-by: Blue Swirl <>

6e6a9924 08/21/2011 09:52 pm Richard Henderson

tcg-hppa: Fix CPU_TEMP_BUF_NLONGS oversight.

Signed-off-by: Richard Henderson <>
Signed-off-by: Blue Swirl <>

25c4d9cc 08/21/2011 09:52 pm Richard Henderson

tcg: Always define all of the TCGOpcode enum members.

By always defining these symbols, we can eliminate a lot of ifdefs.

To allow this to be checked reliably, the semantics of the
TCG_TARGET_HAS_* macros must be changed from def/undef to true/false.
This allows even more ifdefs to be removed, converting them into...

8399ad59 08/21/2011 09:52 pm Richard Henderson

tcg: Add and use TCG_OPF_64BIT.

This allows the simplification of the op_bits function from
tcg/optimize.c.

Signed-off-by: Richard Henderson <>
Signed-off-by: Blue Swirl <>

7267c094 08/21/2011 07:01 am Anthony Liguori

Use glib memory allocation and free functions

qemu_malloc/qemu_free no longer exist after this commit.

Signed-off-by: Anthony Liguori <>

e31b0a7c 08/07/2011 12:33 pm Blue Swirl

TCG: fix copy propagation

Copy propagation introduced in 22613af4a6d9602001e6d0e7b6d98aa40aa018dc
considered only global registers. However, register temps and stack
allocated locals must be handled differently because register temps
don't survive across brcond....

2ec00650 07/30/2011 09:54 pm Blue Swirl

TCG: fix breakage by previous patch

Fix incorrect logic and typos in previous commit
1bfd07bdfe56cea43dbe258dcb161e46b0ee29b7.

Signed-off-by: Blue Swirl <>

1bfd07bd 07/30/2011 03:21 pm Blue Swirl

TCG: fix breakage on some RISC hosts

Fix breakage by a640f03178c22355a158fa9378e4f8bfa4f517a6
and 55c0975c5b358e948b9ae7bd7b07eff92508e756.

Some TCG targets don't implement all TCG ops, so make
optimizing those conditional.

Signed-off-by: Blue Swirl <>

a640f031 07/30/2011 01:51 pm Kirill Batuzov

Do constant folding for unary operations.

Perform constant folding for NOT and EXT{8,16,32}{S,U} operations.

Signed-off-by: Kirill Batuzov <>
Signed-off-by: Blue Swirl <>

9a81090b 07/30/2011 01:51 pm Kirill Batuzov

Do constant folding for boolean operations.

Perform constant folding for AND, OR, XOR operations.

Signed-off-by: Kirill Batuzov <>
Signed-off-by: Blue Swirl <>

55c0975c 07/30/2011 01:51 pm Kirill Batuzov

Do constant folding for shift operations.

Perform constant forlding for SHR, SHL, SAR, ROTR, ROTL operations.

Signed-off-by: Kirill Batuzov <>
Signed-off-by: Blue Swirl <>

53108fb5 07/30/2011 01:51 pm Kirill Batuzov

Do constant folding for basic arithmetic operations.

Perform actual constant folding for ADD, SUB and MUL operations.

Signed-off-by: Kirill Batuzov <>
Signed-off-by: Blue Swirl <>

22613af4 07/30/2011 01:51 pm Kirill Batuzov

Add copy and constant propagation.

Make tcg_constant_folding do copy and constant propagation. It is a
preparational work before actual constant folding.

Signed-off-by: Kirill Batuzov <>
Signed-off-by: Blue Swirl <>

8f2e8c07 07/30/2011 01:51 pm Kirill Batuzov

Add TCG optimizations stub

Added file tcg/optimize.c to hold TCG optimizations. Function tcg_optimize
is called from tcg_gen_code_common. It calls other functions performing
specific optimizations. Stub for constant folding was added.

Signed-off-by: Kirill Batuzov <>...

ea15fb06 07/21/2011 12:03 am Stefan Weil

tcg/mips: Fix regression caused by typo (copy + paste bug)

cppcheck reports an error:
qemu/tcg/mips/tcg-target.c:1487: error: Invalid number of character (()

The unpatched code won't compile on mips hosts starting with commit
cea5f9a28faa528b6b1b117c9ab2d8828f473fef....

107a47cc 07/16/2011 04:17 pm Peter Maydell

tcg/README: Expand advice on number of TCG ops per target insn

Expand the note on the number of TCG ops generated per target insn,
to be clearer about the range of applicability of the 20 op rule
of thumb. Also add a note about the hard MAX_OP_PER_INSTR limit....

f74b32de 07/02/2011 09:48 pm Blue Swirl

TCG/PPC: use stack for TCG temps

Use stack instead of temp_buf array in CPUState for TCG temps.

Signed-off-by: Blue Swirl <>

ec188429 07/02/2011 12:07 am Richard Henderson

tcg-hppa: Support deposit opcode.

Signed-off-by: Richard Henderson <>
Signed-off-by: Blue Swirl <>

2a6a665f 07/01/2011 11:52 pm Blue Swirl

TCG/HPPA: use stack for TCG temps

Use stack instead of temp_buf array in CPUState for TCG temps.

Signed-off-by: Richard Henderson <>
Signed-off-by: Blue Swirl <>

a42bceec 07/01/2011 11:49 pm Blue Swirl

TCG/HPPA: use TCG_REG_CALL_STACK instead of TCG_REG_SP

Use TCG_REG_CALL_STACK instead of TCG_REG_SP for consistency.

Acked-by: Richard Henderson <>
Signed-off-by: Blue Swirl <>

c24a9c6e 06/28/2011 01:27 am malc

tcg/ppc64: Remove tcg_out_addi

The only user (within tcg.c) was removed

Signed-off-by: malc <>

1a2eb162 06/28/2011 01:26 am malc

tcg/ppc: Remove tcg_out_addi

The only user (within tcg.c) was removed

Signed-off-by: malc <>

f44c9960 06/26/2011 09:25 pm Blue Swirl

TCG/Sparc64: use stack for TCG temps

Use stack instead of temp_buf array in CPUState for TCG temps.

On Sparc64, stack pointer is not aligned but there is a fixed bias of 2047,
so don't try to enforce alignment.

Signed-off-by: Blue Swirl <>

ac0275dc 06/26/2011 09:25 pm Blue Swirl

TCG/x86: use stack for TCG temps

Use stack instead of temp_buf array in CPUState for TCG
temps.

Signed-off-by: Blue Swirl <>

e83c80f7 06/26/2011 09:25 pm Blue Swirl

TCG/x86: use TCG_REG_CALL_STACK instead of TCG_REG_ESP

Except for specific cases where the use of %esp changes the encoding of
the instruction, it's cleaner to use TCG_REG_CALL_STACK instead of
TCG_REG_ESP.

Signed-off-by: Blue Swirl <>

345649c0 06/26/2011 09:25 pm Blue Swirl

TCG: remove broken stack allocation for call arguments

The code for stack allocation for call arguments is way too simplistic
to actually work on targets with non-trivial stack allocation policies,
e.g. ppc64. We've also already allocated TCG_STATIC_CALL_ARGS_SIZE worth...

b591dc59 06/26/2011 09:25 pm Blue Swirl

TCG: fix negative frame offset calculations

size_t is unsigned, so the frame offset calculations can be incorrect for
negative offsets.

Signed-off-by: Blue Swirl <>

614f104d 06/26/2011 09:25 pm Blue Swirl

Delegate setup of TCG temporaries to targets

Delegate TCG temp_buf setup to targets, so that they can use a stack
frame later instead.

Signed-off-by: Blue Swirl <>

cea5f9a2 06/26/2011 09:25 pm Blue Swirl

cpu-exec.c: avoid AREG0 use

Make functions take a parameter for CPUState instead of relying
on global env. Pass CPUState pointer to TCG prologue, which moves
it to AREG0.

Thanks to Peter Maydell and Laurent Desnogues for the ARM prologue
change.

Revert the hacks to avoid AREG0 use on Sparc hosts....

2b41f10e 06/26/2011 09:25 pm Blue Swirl

Remove exec-all.h include directives

Most exec-all.h include directives are now useless, remove them.

Signed-off-by: Blue Swirl <>

568fffe3 06/03/2011 07:32 pm Christophe Fergeau

tcg: Fix unused-but-set-variable warning

Based on a patch from Hans de Goede <>

This warning is new in gcc 4.6.

Acked-by: Amit Shah <>
Signed-off-by: Christophe Fergeau <>
Signed-off-by: Aurelien Jarno <>

ebecf363 06/03/2011 07:26 pm Peter Maydell

tcg: If DEBUG_TCGV, distinguish TCGv_ptr from TCGv_i32/TCGv_i64

When compiling with DEBUG_TCGV enabled, make the TCGv_ptr type distinct
from TCGv_i32/TCGv_i64. This means that using an i32 or i64 TCG op to
manipulate a TCGv_ptr will always be detected at compile time, rather...

6bd4b08a 06/03/2011 07:26 pm Peter Maydell

tcg/tcg-op.h: Fix prototypes for ld/st functions on 64 bit hosts

The prototypes for the ld/st functions on a 64 bit host declared
the address parameter as a TCGv_i64 rather than a TCGv_ptr. This
worked OK (since the two are aliases), but needs to be fixed to...

03938c13 06/03/2011 07:23 pm Brad

Use the correct header in the TCG MIPS code to find cacheflush() on OpenBSD.

Use the correct header in the TCG MIPS code to find cacheflush() on OpenBSD
to fix compilation of the MIPS host support for OpenBSD/mips64 based architecures.

Signed-off-by: Brad Smith <>...

06ea77bc 05/29/2011 01:58 pm Stefan Weil

Fix spelling in comment (additon -> addition)

Signed-off-by: Stefan Weil <>
Signed-off-by: Stefan Hajnoczi <>

8c11ad25 05/23/2011 11:38 pm Aurelien Jarno

tcg: don't keep dead outputs in registers

If an op with dead outputs is not removed, because it has side effects
or has multiple output and only one dead, mark the registers as dead
instead of saving them. This avoid a few register spills on TCG targets
with low register count, especially with div2 and mul2 ops, or when a...

6b64b624 05/23/2011 11:38 pm Aurelien Jarno

tcg: mark dead output argument in op_dead_args

If an op is not removed and has dead output arguments, mark it
in op_dead_args similarly to what is done for input arguments.

Signed-off-by: Aurelien Jarno <>

866cb6cb 05/23/2011 11:38 pm Aurelien Jarno

tcg: replace op_dead_iargs by op_dead_args

Allow all args to be dead by replacing the input specific op_dead_iargs
variable by op_dead_args. Note this is a purely mechanical change.

Signed-off-by: Aurelien Jarno <>

5225d669 05/08/2011 12:02 pm Stefan Weil

Fix typos in comments (accross -> across)

Signed-off-by: Stefan Weil <>
Signed-off-by: Stefan Hajnoczi <>

24e838b7 03/24/2011 04:27 am Peter Maydell

tcg/arm: Support host code being compiled for Thumb

Although the TCG generated code is always in ARM mode, it is possible
that the host code was compiled by gcc in Thumb mode (this is often the
default for Linux distributions targeting ARM v7 only). Handle this...

27bfd83c 03/07/2011 10:26 am Peter Maydell

tcg: Add support for debugging leakage of temporaries

Add support (if CONFIG_DEBUG_TCG is defined) for debugging leakage
of temporary variables. Generally any temporaries created by
a target while it is translating an instruction should be freed
by the end of that instruction; otherwise carefully crafted...

3a34dfd7 01/20/2011 01:16 pm Edgar E. Iglesias

tcg: README, name deposit second argument len/LEN

Signed-off-by: Edgar E. Iglesias <>

b7767f0f 01/20/2011 01:16 pm Richard Henderson

tcg: Define "deposit" as an optional operation.

Signed-off-by: Richard Henderson <>
Signed-off-by: Edgar E. Iglesias <>

56779034 01/12/2011 01:06 am Aurelien Jarno

tcg arm/mips/ia64: add a comment about retranslation and caches

Add a comment about cache coherency and retranslation, so that people
developping new targets based on existing ones are warned of the issue.

Acked-by: Edgar E. Iglesias <>...

0f11f25a 01/10/2011 08:30 am Aurelien Jarno

tcg/arm: improve constant loading

Improve constant loading in two ways:
- On all ARM versions, it's possible to load 0xffffff00 = 0x100 using
the mvn rd, #0. Fix the conditions.
On <= ARMv6 versions, where movw and movt are not available, load the
constants using mov and orr with rotations depending on the constant...

a3e28aa5 01/10/2011 02:39 am Aurelien Jarno

tcg/ia64: remove an unnecessary stop bit

Spotted by Richard Henderson.

Signed-off-by: Aurelien Jarno <>

759c90ba 01/09/2011 11:01 pm Mike Frysinger

tcg: fix typo in readme

Signed-off-by: Mike Frysinger <>
Signed-off-by: Blue Swirl <>

aa95e3a5 01/09/2011 11:00 pm Stefan Weil

tcg/README: Spelling fixes

Signed-off-by: Stefan Weil <>
Signed-off-by: Blue Swirl <>

d43ffce1 01/08/2011 05:41 pm Aurelien Jarno

tcg/mips: fix branch target change during code retranslation

TCG on MIPS was trying to avoid changing the branch offset, but didn't
due to a stupid typo. Fix it.

Signed-off-by: Aurelien Jarno <>

9a3abc21 01/08/2011 05:41 pm Aurelien Jarno

tcg/arm: fix qemu_st64 for big endian targets

Due to a typo, qemu_st64 doesn't properly byteswap the 32-bit low word of
a 64 bit word before saving it. This patch fixes that.

Acked-by: Andrzej Zaborowski <>
Signed-off-by: Aurelien Jarno <>

c69806ab 01/08/2011 05:39 pm Aurelien Jarno

tcg/arm: fix branch target change during code retranslation

QEMU uses code retranslation to restore the CPU state when an exception
happens. For it to work the retranslation must not modify the generated
code. This is what is currently implemented in ARM TCG....

255108c0 12/01/2010 08:48 pm Richard Henderson

tcg-ia64: Provide default GUEST_BASE.

Fix compilation error when GUEST_BASE is not defined.

Signed-off-by: Richard Henderson <>
Signed-off-by: Edgar E. Iglesias <>

b3b0091f 12/01/2010 08:48 pm Richard Henderson

tcg-ia64: Implement qemu_ld32.

The port was not properly merged following
86feb1c860dc38e9c89e787c5210e8191800385e

Signed-off-by: Richard Henderson <>
Signed-off-by: Edgar E. Iglesias <>

650a217a 12/01/2010 08:48 pm Richard Henderson

tcg-ia64: Fix tlb read error for 32-bit targets.

Use ld4 not ld8 for reading the tlb of 32-bit targets.

Signed-off-by: Richard Henderson <>
Signed-off-by: Edgar E. Iglesias <>

07f59737 12/01/2010 08:48 pm Richard Henderson

tcg-ia64: Fix address compilation in qemu_st.

A typo in the usermode address calculation path; R3 used where R2 needed.

Signed-off-by: Richard Henderson <>
Signed-off-by: Edgar E. Iglesias <>

393f398b 12/01/2010 08:48 pm Richard Henderson

tcg-ia64: Fix warning in qemu_ld.

The usermode version of qemu_ld doesn't used mem_index,
leading to set-but-not-used warnings.

Signed-off-by: Richard Henderson <>
Signed-off-by: Edgar E. Iglesias <>

0909cbde 12/01/2010 08:48 pm Richard Henderson

tcg: Fix default definition of divu_i32 and remu_i32.

The arguments to tcg_gen_helper32 for these functions were not
updated correctly in rev 2bece2c88331f024a46527634e3dd91c71d22141.

Signed-off-by: Richard Henderson <>
Signed-off-by: Edgar E. Iglesias <>

405cf9ff 10/30/2010 11:01 am Stefan Weil

tcg: Use fprintf_function (format checking)

fprintf_function uses format checking with GCC_FMT_ATTR.

Cc: Blue Swirl <>
Signed-off-by: Stefan Weil <>
Signed-off-by: Blue Swirl <>

c3b08d0e 10/20/2010 11:52 pm Stefan Weil

tcg: Fix compiler error (comparison of unsigned expression)

When qemu is configured with --enable-debug-tcg,
gcc throws this warning (or error with -Werror):

tcg/tcg.c:1030: error: comparison of unsigned expression >= 0 is always true

Fix it by removing the >= 0 part....

b1d6d51d 08/14/2010 11:57 pm Andreas Färber

TCG: Revert ppc64 tcg_out_movi32 change

3b6dac34161bc0a342336072643c2f6d17e0ec45 apparently broke the ppc64 TCG target
compilation in the code path without guest base.

Reverting this line fixes the build.

Signed-off-by: Andreas F?rber <>...

e9119cd8 08/14/2010 11:40 pm Andreas Färber

TCG: Fix Darwin/ppc calling convention recognition

5da79c86a3744e3a901c7986c109dd06951befd2 broke compilation on Mac OS X v10.5 ppc.
Apple's GCC 4.0.1 does not define _CALL_DARWIN. Recognize APPLE again as well.

Signed-off-by: Andreas F?rber <>...

48bb3750 06/30/2010 12:07 am Richard Henderson

tcg-s390: new TCG Target

Original patch from Ulrich Hecht, further work from Alexander Graf
and Richard Henderson.

Cc: Ulrich Hecht <>
Cc: Alexander Graf <>
Signed-off-by: Richard Henderson <>
Signed-off-by: Aurelien Jarno <>

b9e946c7 06/29/2010 10:30 pm Richard Henderson

tcg-ppc: Conditionally reserve TCG_GUEST_BASE_REG.

We need not reserve the register unless we're going to use it.

Signed-off-by: Richard Henderson <>
Signed-off-by: malc <>

2bece2c8 06/16/2010 12:29 pm Richard Henderson

tcg: Optionally sign-extend 32-bit arguments for 64-bit hosts.

Some hosts (amd64, ia64) have an ABI that ignores the high bits
of the 64-bit register when passing 32-bit arguments. Others
require the value to be properly sign-extended for the type.
I.e. "int32_t" must be sign-extended and "uint32_t" must be...