Statistics
| Branch: | Revision:

root / target-arm @ 771124e1

# Date Author Comment
0b03bdfc 01/25/2012 05:10 pm Peter Maydell

Add Cortex-A15 CPU definition

Add a definition of a Cortex-A15 CPU. Note that for the moment we do
not implement any of: * Large Physical Address Extensions (LPAE) * Virtualization Extensions * Generic Timer * TrustZone (this is also true of our existing Cortex-A9 model, etc)...

0383ac00 01/25/2012 02:42 pm Peter Maydell

Add dummy implementation of generic timer cp15 registers

Add a dummy implementation of the cp15 registers for the generic
timer (found in the Cortex-A15), just sufficient for Linux to
decide that it can't use it. This requires at least CNTP_CTL and
CNTFRQ to be implemented as RAZ/WI; we RAZ/WI all of c14....

dc8714ca 01/25/2012 01:49 pm Peter Maydell

target-arm: Fix implementation of TLB invalidate operations

Fix some bugs in the implementation of the TLB invalidate
operations on ARM: * the 'invalidate all' op was not passing flush_global=1
to tlb_flush(); this doesn't have a practical effect since...

85836979 01/25/2012 01:49 pm Peter Maydell

target-arm/helper.c: Don't assume softfloat int32 is 32 bits only

In the helper routines for VCVT float-to-int conversions, add
an explicit cast rather than relying on the softfloat int32
type being exactly 32 bits wide (which it is not guaranteed to be)....

5fe91019 01/25/2012 01:49 pm Mark Langsdorf

arm: store the config_base_register during cpu_reset

Long term, the config_base_register will be a QDM parameter. In the
meantime, models that use it need to be able to preserve it across
cpu_reset() calls.

Signed-off-by: Mark Langsdorf <>...

d3cb6e2b 01/13/2012 07:25 pm Peter Maydell

target-arm: Fix errors in decode of M profile CPS

Fix errors in the decode of M profile CPS: * the decode of the I (affects PRIMASK) and F (affects FAULTMASK)
bits was reversed * the FAULTMASK system register number is 19, not 17

This fixes an issue reported as LP:913925....

2be27624 01/13/2012 07:25 pm Rob Herring

arm: Add dummy support for co-processor 15's secure config register

Signed-off-by: Rob Herring <>
Signed-off-by: Mark Langsdorf <>
Signed-off-by: Peter Maydell <>

1b9e01c1 01/05/2012 05:49 pm Peter Maydell

target-arm: Don't use cpu_single_env in bank_number()

Avoid using cpu_single_env in bank_number() -- if we were
called via the gdb stub reading or writing the CPSR then
it is NULL and we will segfault if we take the cpu_abort().

Signed-off-by: Peter Maydell <>

37064a8b 01/05/2012 05:49 pm Peter Maydell

target-arm: Ignore attempts to set invalid modes in CPSR

Ignore attempts to set the CPSR mode field to an invalid value.
This is UNPREDICTABLE, but we should not cpu_abort() for things
a malicious guest (or a confused user on the gdbstub interface)
can provoke....

7da362d0 01/05/2012 05:49 pm Mark Langsdorf

arm: add dummy A9-specific cp15 registers

Add dummy register support for the cp15, CRn=c15 registers.

config_base_register and power_control_register currently
default to 0, but may have improved support after the QOM
CPU patches are finished.

Signed-off-by: Mark Langsdorf <>...

db8336cd 12/13/2011 08:19 pm Andreas Färber

target-arm: Infer VFPv3 feature from VFPv4

VFP4 => VFP3

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

08c40f3c 12/13/2011 08:19 pm Andreas Färber

target-arm: Infer ARMv5 feature from ARMv6

V6 => V5

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

6bf62124 12/13/2011 08:19 pm Andreas Färber

target-arm: Infer ARMv6 feature from v6K

V6K => V6

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

bbc5c5fa 12/13/2011 08:19 pm Andreas Färber

target-arm: Infer ARMv6(K) feature from ARMv7

V7 && M => V6
V7 && !M => V6K

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

10e87702 12/13/2011 08:19 pm Andreas Färber

target-arm: Infer AUXCR feature from ARMv6

V6 && !M => AUXCR

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

b3faf5f0 12/13/2011 08:19 pm Andreas Färber

target-arm: Infer Thumb2 feature from ARMv7

V7 => THUMB2

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

908ce980 12/13/2011 08:19 pm Andreas Färber

target-arm: Infer Thumb division feature from M profile

M => THUMB_DIV

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

86e72db6 12/13/2011 08:19 pm Andreas Färber

target-arm: Infer VFP feature from VFPv3

VFP3 => VFP

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

dd4ebc2e 12/13/2011 08:19 pm Jean-Christophe DUBOIS

arm: Fix CP15 FSR (C5) domain setting

Return the correct value in the domain field in the cp15 DFSR
(C5) -- bug noticed during Xvisor development.

Signed-off-by: Jean-Christophe DUBOIS <>
[Peter Maydell: reworded commit message]
Signed-off-by: Peter Maydell <>

ddb572ec 12/13/2011 08:19 pm Andreas Färber

target-arm: Infer ARMv4T feature from ARMv5

V5 => V4T

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

f4fc247b 12/05/2011 10:38 pm Peter Maydell

target-arm/helper.c: Don't allocate TCG resources unless TCG enabled

Don't call arm_translate_init() (which allocates TCG resources)
unless TCG is enabled.

Signed-off-by: Peter Maydell <>
Signed-off-by: Andrzej Zaborowski <>

02afbf64 12/05/2011 10:38 pm Peter Maydell

target-arm/translate.c: Fix slightly misleading comment in Thumb decoder

Clarify some slightly misleading comments in the Thumb decoder's
handling of the memory hint space -- in particular one code path
marked as 'UNPREDICTABLE or unallocated hint' also includes some...

12b1de3a 10/20/2011 05:25 pm Andreas Färber

target-arm: Fix use of free() in cpu_arm_close()

env is allocated in cpu_arm_init() with g_malloc0(), so free with g_free().

Signed-off-by: Andreas Färber <>
Signed-off-by: Peter Maydell <>

da97f52c 10/19/2011 07:14 pm Peter Maydell

target-arm: Implement VFPv4 fused multiply-accumulate insns

Implement the fused multiply-accumulate instructions (VFMA, VFMS,
VFNMA, VFNMS) which are new in VFPv4.

Signed-off-by: Peter Maydell <>

15180256 10/19/2011 07:14 pm Dmitry Koshelev

target-arm/machine.c: Restore VFP registers correctly

Fix the restoring of VFP registers on vmload.

Signed-off-by: Dmitry Koshelev <>
Reviewed-by: Juan Quintela <>
[peter.maydell: improved commit message a little]...

47789990 10/19/2011 07:14 pm Peter Maydell

target-arm: Rename ARM_FEATURE_DIV to _THUMB_DIV

Rename the ARM_FEATURE_DIV feature bit to _THUMB_DIV, to
make room for a new feature switch enabling DIV in the ARM
encoding. (Cores may implement either (a) no divide insns
(b) divide insns in Thumb encodings only (c) divide insns...

b8b8ea05 10/19/2011 07:14 pm Peter Maydell

target-arm: Add ARM UDIV/SDIV support

Add support for UDIV and SDIV in ARM mode. This is a new optional
feature for A profile cores (Thumb mode has had UDIV and SDIV for
M profile cores for some time).

Signed-off-by: Peter Maydell <>

26cc6abf 10/19/2011 07:14 pm Christophe LYON

rsqrte_f32: No need to copy sign bit.

Indeed, the result is known to be always positive.

Signed-off-by: Christophe Lyon <>
Signed-off-by: Peter Maydell <>

41e9564d 10/19/2011 07:14 pm Peter Maydell

target-arm: v6 media multiply space: UNDEF on unassigned encodings

Clean up the decoding of the v6 media multiply space so that we UNDEF
on unassigned encodings rather than randomly interpreting them as
some instruction in this space.

Signed-off-by: Peter Maydell <>

057643f6 10/10/2011 04:09 pm Anthony Liguori

Merge remote-tracking branch 'stefanha/trivial-patches' into staging

6e19a137 10/08/2011 01:00 pm Blue Swirl

ARM: fix segfault

Fix a bug in bccd9ec5f098668576342c83d90d6d6833d61d33,
target-arm/op_helper.c missed a change unlike all other targets.
This lead to a NULL pointer dereferences.

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

297d1b4e 10/05/2011 11:22 am Andreas Färber

target-arm: Fix typo

The command line option is called -kernel, not -kenrel.

Cc: Paul Brook <>
Reviewed-by: Peter Maydell <>
Signed-off-by: Andreas Färber <>
Signed-off-by: Stefan Hajnoczi <>

bccd9ec5 10/01/2011 12:31 pm Blue Swirl

softmmu_header: pass CPUState to tlb_fill

Pass CPUState pointer to tlb_fill() instead of architecture local
cpu_single_env hacks.

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 <>

b9c6cbff 08/09/2011 08:16 pm Edgar E. Iglesias

Merge remote-tracking branch 'pm-arm/for-upstream' into pm

97b348e7 08/07/2011 12:32 pm Blue Swirl

Remove unused is_softmmu parameter from cpu_handle_mmu_fault

Parameter is_softmmu (and its evil mutant twin brother is_softmuu)
is not used in cpu_*_handle_mmu_fault() functions, remove them
and adjust callers.

Acked-by: Richard Henderson <>...

3e457172 07/30/2011 12:41 pm Blue Swirl

exec.h cleanup

Move softmmu_exec.h include directives from target-*/exec.h to
target-*/op_helper.c. Move also various other stuff only used in
op_helper.c there.

Define global env in dyngen-exec.h.

For i386, move wrappers for segment and FPU helpers from user-exec.c...

7807eed9 07/26/2011 05:30 pm Jamie Iles

target-arm: support for ARM1176JZF-s cores

Add support for v6K ARM1176JZF-S. This core includes the VA<->PA
translation capability and security extensions.

Signed-off-by: Jamie Iles <>
Signed-off-by: Peter Maydell <>

906879a9 07/26/2011 05:30 pm Peter Maydell

target-arm: Mark 1136r1 as a v6K core

The 1136r1 is actually a v6K core (unlike the 1136r0); mark it as such,
thus enabling the TLS registers, NOP hints, CLREX, half and byte wide
exclusive load/stores, etc.

The VA-to-PA translation registers are not present on 1136r1, so...

87f19eb2 07/26/2011 05:30 pm Peter Maydell

target-arm: Support v6 barriers in linux-user mode

ARMv6 implemented various operations as special cases of cp15 accesses
which are true instructions in v7; this includes barriers (DMB, DSB, ISB).
Catch this special case at translate time, so that it works in linux-user...

934814f1 07/26/2011 05:30 pm Peter Maydell

target-arm: Handle UNDEF and UNPREDICTABLE cases for VLDM, VSTM

Handle the UNDEF and UNPREDICTABLE cases for VLDM and VSTM. In
particular, we now generate an undef exception for overlarge imm8
values rather than generating 1000+ TCG ops and hitting an assertion....

6e0c0ed1 07/26/2011 05:30 pm Peter Maydell

target-arm: UNDEF on a VCVTT/VCVTB UNPREDICTABLE to avoid TCG assert

VCVTT/VCVTB with bit 8 set is UNPREDICTABLE; we choose to UNDEF.
This avoids a TCG assert later when the VCVTT/VCVTB code tries to
use a source register that wasn't ever set up.

We pull the check for the presence of the half-precision extension...

a492892c 07/26/2011 05:30 pm Peter Maydell

target-arm: Don't print debug messages for various UNDEF cases

Remove some stray printfs for cases which don't generally happen
(some VFP UNDEF cases, reads and writes to unknown cp14 registers);
we should simply generate an UNDEF when the instruction is executed....

0ab06d83 07/26/2011 05:22 pm Jamie Iles

target-arm: make VMSAv7 remapping and AP dependent on V6K

The VMSAv7 remapping and access permissions were introduced in ARMv6K
and not ARMv7.

Signed-off-by: Jamie Iles <>
Signed-off-by: Peter Maydell <>

8e31bf38 07/23/2011 07:26 pm Matthew Fernandez

Correct spelling of licensed

Correct typos of "licenced" to "licensed".

Reviewed-by: Stefan Weil <>
Reviewed-by: Andreas F=E4rber <>
Signed-off-by: Matthew Fernandez <>
Signed-off-by: Anthony Liguori <>

a3ce3668 07/20/2011 11:23 pm Blue Swirl

Merge branch 'for-upstream' of git://git.linaro.org/people/pmaydell/qemu-arm

  • 'for-upstream' of git://git.linaro.org/people/pmaydell/qemu-arm:
    target-arm: Fix BASEPRI, BASEPRI_MAX, and FAULTMASK access
    target-arm: Minimal implementation of performance counters...
462a8bc6 07/04/2011 10:58 pm Stefan Weil

arm: Add const attribute to some arm_boot_info pointers

Parameter 'info' is const, so add the missing attribute.

v2:
Add 'const' to the local variable info in do_cpu_reset() and to
the boot_info field in CPUARMState (suggested by Peter Maydell).

Cc: Andrzej Zaborowski <>...

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 <>

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

Move cpu_has_work and cpu_pc_from_tb to cpu.h

Move functions cpu_has_work() and cpu_pc_from_tb() from exec.h to cpu.h. This is
needed by later patches.

Signed-off-by: Blue Swirl <>

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

exec.h: fix coding style and change cpu_has_work to return bool

Before the next patch, fix coding style of the areas affected.

Change the type of the return value from cpu_has_work() and
qemu_cpu_has_work() to bool.

Signed-off-by: Blue Swirl <>

1162c041 06/26/2011 09:25 pm Blue Swirl

cpu_loop_exit: avoid using AREG0

Make cpu_loop_exit() take a parameter for CPUState instead of relying
on global env.

Signed-off-by: Blue Swirl <>

82845826 06/22/2011 06:02 pm Sebastian Huber

target-arm: Fix BASEPRI, BASEPRI_MAX, and FAULTMASK access

Correct the decode of the register numbers for BASEPRI, BASEPRI_MAX
and FAULTMASK, according to "ARMv7-M Architecture Reference Manual"
issue D section "B5.2.3 MRS" and "B5.2.3 MSR".

Signed-off-by: Sebastian Huber <>...

74594c9d 06/22/2011 06:02 pm Peter Maydell

target-arm: Minimal implementation of performance counters

Newer Linux kernels assume the existence of the performance counter
cp15 registers. Provide a minimal implementation of these registers.
We support no events. This should be compliant with the ARM ARM,...

02da0b2d 06/22/2011 06:01 pm Peter Maydell

Revert "target-arm: Use global env in neon_helper.c helpers"

This effectively reverts commit 2a3f75b42ac255be09ec2939b96c549ec830efd3
so that we return to passing CPUState to helpers as an explicit parameter.
(There were a number of conflicts in target-arm/translate.c which had...

aa47cfdd 06/22/2011 06:01 pm Peter Maydell

target-arm: Pass fp status pointer explicitly to neon fp helpers

Make the Neon helpers for various floating point operations take an
explicit pointer to the float_status they use, so they don't rely on
the global environment pointer any more. This also allows us to drop...

ae1857ec 06/22/2011 06:01 pm Peter Maydell

target-arm: Make VFP binop helpers take pointer to fpstatus, not CPUState

Make the VFP binop helper functions take a pointer to the fp status, not
the entire CPUState. This will allow us to use them for Neon operations too.

Signed-off-by: Peter Maydell <>

5aaebd13 06/22/2011 06:01 pm Peter Maydell

target-arm: Add helper function to generate code to get fpstatus pointer

Add and use a helper function which returns a TCGv which is a pointer
to the fp_status for either Neon or VFP operations.

Signed-off-by: Peter Maydell <>

477955bd 06/22/2011 06:01 pm Peter Maydell

Revert "target-arm: Use global env in iwmmxt_helper.c helpers"

This reverts commit 947a2fa21b61703802a660a938cabd7b3600ee79,
returning the iwmmxt helpers to passing env in as a parameter.

Signed-off-by: Peter Maydell <>

81c05daf 06/03/2011 07:42 pm Alex Zuepke

target-arm: BKPT instructions should raise prefetch aborts with IFSR type 00010

Signed-off-by: Alex Zuepke <>
Reviewed-by: Peter Maydell <>
Signed-off-by: Aurelien Jarno <>

b7fa9214 06/03/2011 07:13 pm Peter Maydell

target-arm: Fix compilation failure for 64 bit hosts

Use the correct _ptr aliases for manipulating the pointer to
the fp_status; this fixes a compilation failure on 64 bit hosts.

Signed-off-by: Peter Maydell <>
Acked-by: Stefan Weil <>...

89e40268 05/23/2011 11:53 pm Peter Maydell

target-arm/exec.h: Remove unused #define of M0

Remove a preprocessor #define which is never used.

Signed-off-by: Peter Maydell <>
Signed-off-by: Aurelien Jarno <>

36802b6b 05/23/2011 11:39 pm Peter Maydell

target-arm: Signal Underflow when denormal flushed to zero on output

On ARM the architecture mandates that when an output denormal is flushed to
zero we must set the FPSCR UFC (underflow) bit, so map softfloat's
float_flag_output_denormal accordingly.

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

5500b06c 05/23/2011 11:39 pm Peter Maydell

target-arm: Use correct float status for Neon int-float conversions

The Neon versions of int-float conversions must use the "standard FPSCR"
rather than the default FPSCR. Implement this by having the helper
functions take a pointer to the appropriate float_status value rather...

cab565c4 05/23/2011 11:39 pm Peter Maydell

target-arm: Signal InvalidOp for Neon GE and GT compares of QNaN

If the input to a Neon float comparison is a quiet NaN, the ARM ARM
specifies that we should raise InvalidOp if the comparison is GE or GT
but not for EQ. (Signaling NaNs raise InvalidOp regardless). This means...

43fe9bdb 05/23/2011 11:39 pm Peter Maydell

target-arm: Signal InputDenormal for VRECPE, VRSQRTE, VRECPS, VRSQRTS

The helpers for VRECPE.F32, VSQRTE.F32, VRECPS and VRSQRTS handle denormals
as special cases, so we must set the InputDenormal exception flag ourselves.

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

1146a817 05/23/2011 11:39 pm Peter Maydell

target-arm: Don't set FP exceptions in recip, recip_sqrt estimate fns

The functions which do the core estimation algorithms for the VRSQRTE
and VRECPE instructions should not set floating point exception flags,
so use a local fp status for doing these calculations....

605a6aed 05/15/2011 01:22 am Peter Maydell

target-arm: Fix VMLA, VMLS, VNMLS, VNMLA handling of NaNs

Correct handling of NaNs for VFP VMLA, VMLS, VNMLS and VNMLA requires that
we implement the set of negations and additions specified by the ARM ARM;
plausible looking simplifications like turning (-A + B) into (B - A) or...

711c2128 05/12/2011 04:08 pm Anthony Liguori

Merge remote-tracking branch 'stefanha/trivial-patches' into staging

Conflicts:
cpu-all.h

403946c0 05/08/2011 07:55 pm Richard Henderson

target-arm: Privatize CPU_INTERRUPT_FIQ.

This interrupt name was only used by the ARM port.

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

1301f322 05/08/2011 12:02 pm Stefan Weil

Fix typos in comments (neccessary -> necessary)

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

a1c7273b 05/08/2011 12:02 pm Stefan Weil

Fix typos in comments and code (occured -> occurred and related)

The code changed here is an unused data type name (evt_flush_occurred).

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

a7d3970d 04/27/2011 09:14 pm Peter Maydell

target-arm: Don't update base register on abort in Thumb T1 LDM

Make sure the base register isn't updated if it is in the load list
for a Thumb LDM (T1 encoding) which aborts partway through the load.

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

5856d44e 04/27/2011 09:13 pm YuYeon Oh

target-arm: fix LDMIA bug on page boundary
target-arm: fix LDMIA bug on page boundary

When consecutive memory locations are on page boundary, a base register may be
loaded before page fault occurs. After page fault handling, it losts the memory
location information. To solve this problem, loading a base register has to put back....

f2dd89d0 04/25/2011 11:10 pm Peter Maydell

target-arm: Handle UNDEF cases for Neon VLD/VST multiple-structures

Correctly UNDEF for Neon VLD/VST "multiple structures" forms where the
align field is not valid.

Signed-off-by: Peter Maydell <>
Signed-off-by: Aurelien Jarno <>

93262b16 04/25/2011 11:10 pm Peter Maydell

target-arm: Handle UNDEFs for Neon single element load/stores

Handle the UNDEF and UNPREDICTABLE cases for Neon "single element to
one lane" VLD and "single element from one lane" VST.

Signed-off-by: Peter Maydell <>
Signed-off-by: Aurelien Jarno <>

ec444452 04/20/2011 02:01 pm Peter Maydell

target-arm: Set Invalid flag for NaN in float-to-int conversions

When we catch the special case of an input NaN in ARM float to int
helper functions, set the Invalid flag as well as returning the
correct result.

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

5bc95aa2 04/20/2011 01:59 pm Dmitry Eremin-Solenikov

Implement basic part of SA-1110/SA-1100

Basic implementation of DEC/Intel SA-1100/SA-1110 chips emulation.
Implemented:
- IRQs
- GPIO
- PPC
- RTC
- UARTs (no IrDA/etc.)
- OST reused from pxa25x

Everything else is TODO (esp. PM/idle/sleep!) - see the todo in the...

618ba8e6 04/20/2011 11:37 am Stefan Weil

Remove unused function parameter from cpu_restore_state

The previous patch removed the need for parameter puc.
Is is now unused, so remove it.

Cc: Aurelien Jarno <>
Reviewed-by: Peter Maydell <>
Signed-off-by: Stefan Weil <>

e87b7cb0 04/20/2011 11:33 am Stefan Weil

Remove unused function parameters from gen_pc_load and rename the function

Function gen_pc_load was introduced in commit
d2856f1ad4c259e5766847c49acbb4e390731bd4.
The only reason for parameter searched_pc was
a debug statement in target-i386/translate.c....

7b59220e 04/17/2011 09:41 pm Lluís

move helpers.h to helper.h

This provides a consistent naming scheme across all targets.

Signed-off-by: Lluís Vilanova <>
Signed-off-by: Aurelien Jarno <>

61cc8701 04/16/2011 02:24 pm Stefan Weil

Fix some typos in comments and documentation

helpfull -> helpful
usefull -> useful
cotrol -> control

and a grammar fix.

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

4d9ad7f7 04/13/2011 09:47 pm Peter Maydell

target-arm: Don't overflow when calculating value for signed VABAL

In the VABAL instruction we take the absolute difference of two
values of size x and store it in a result of size 2x. This means
we have to be careful to calculate the absolute difference using...

7d80fee5 04/13/2011 12:33 am Peter Maydell

target-arm: Handle UNDEF cases for Neon invalid modified-immediates

For Neon "one register and a modified immediate value" forms, the
combination op=1 cmode=1111 is unallocated and should UNDEF.
All instructions of this form also UNDEF if Q 1 and Vd&lt;0&gt; 1....

695272dc 04/13/2011 12:33 am Peter Maydell

target-arm: Handle UNDEF cases for Neon 3-regs-different-widths

Add missing UNDEF checks for instructions in the Neon "3 registers of
different widths" data processing space.

Signed-off-by: Peter Maydell <>
Signed-off-by: Aurelien Jarno <>

3e3326df 04/13/2011 12:33 am Peter Maydell

target-arm: Handle UNDEF cases for Neon 2 regs + scalar forms

Add missing checks for cases which must UNDEF in the Neon "2 registers and
a scalar" data processing instruction space.

Signed-off-by: Peter Maydell <>
Signed-off-by: Aurelien Jarno <>

52579ea1 04/13/2011 12:33 am Peter Maydell

target-arm: Handle UNDEF cases for VEXT

VEXT must UNDEF if Q 1 && (Vd&lt;0&gt; 1 || Vr<0> 1 || Vm&lt;0&gt; 1)

Signed-off-by: Peter Maydell <>
Signed-off-by: Aurelien Jarno <>

600b828c 04/13/2011 12:33 am Peter Maydell

target-arm: Simplify checking of size field in Neon 2reg-misc forms

Many of the Neon "2 register misc" instruction forms require invalid
size fields to cause the instruction to UNDEF. Pull this information
out into an array; this simplifies the code and also means we can do...

fc2a9b37 04/13/2011 12:33 am Peter Maydell

target-arm: Handle UNDEF cases for Neon 2 register misc forms

Add missing UNDEF checks for Neon "two register miscellaneous" forms: * all instructions except VMOVN,VQMOVN must UNDEF
if Q==1 && (Vd<0> 1 || Vm&lt;0&gt; 1) * VMOVN,VQMOVN,VCVT.F16.F32 UNDEF if Q 1 || Vm&lt;0&gt; 1...

56907d77 04/13/2011 12:33 am Peter Maydell

target-arm: Treat UNPREDICTABLE VTBL, VTBX case as UNDEF

Catch the UNPREDICTABLE case for Neon VTBL,VTBX, and UNDEF it
rather than allowing the helper function to index off the end
of the register file.

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

133da6aa 04/13/2011 12:33 am Juha Riihimäki

target-arm: Handle UNDEF cases for VDUP (scalar)

Handle the UNDEF cases for VDUP:
imm4 x000
Q 1 && Vd<0> == 1

Signed-off-by: Juha Riihimäki <>
Reviewed-by: Peter Maydell <>
Signed-off-by: Aurelien Jarno <>

9df38c47 04/13/2011 12:33 am Peter Maydell

target-arm: Detect tininess before rounding for FP operations

The ARM architecture mandates that we detect tininess before rounding,
so set the softfloat fp_status up appropriately.

Signed-off-by: Peter Maydell <>
Signed-off-by: Aurelien Jarno <>

2bc70834 04/13/2011 12:33 am Peter Maydell

target-arm: Collapse VSRI case into VSHL, VSLI

Collapse some switch cases for VSRI into those for VSHL, VSLI,
since the bodies are the same. (This is not completely obvious
for the size < 3 case, but since for VSRI we know U=1 the
GEN_NEON_INTEGER_OP() expansion is equivalent to the open-coded...

62698be3 04/12/2011 10:51 pm Peter Maydell

target-arm: Use lookup table for size check on Neon 3-reg-same insns

Simplify the checks for invalid size values for the Neon "three registers
of the same size" instruction forms (and add them where they were missing)
by using a lookup table.

This includes adding symbolic constants for the op values in this space,...

25f84f79 04/12/2011 10:51 pm Peter Maydell

target-arm: Handle UNDEF cases for Neon 3-regs-same insns

Correct the handling of UNDEF cases for the NEON "3 registers same
size" forms, by adding missing checks and rationalising some others
so they are done early enough to avoid leaking TCG temporaries....

a5a14945 04/12/2011 10:51 pm Juha Riihimäki

target-arm: Simplify three-register pairwise code

Since we know that the case of (pairwise && q) has been caught
earlier, we can simplify the register setup code for each pass
in the three-register-same-size Neon loop.

Signed-off-by: Juha Riihimäki <>...

cc13115b 04/12/2011 10:51 pm Peter Maydell

target-arm: Handle UNDEF cases for Neon "2 regs and shift" insns

Correctly handle all the UNDEF cases for Neon instructions of the
"2 registers and shift" form, and make sure that we check for these
cases early enough not to leak TCG temporaries.

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

be5e7a76 04/10/2011 01:53 am Dmitry Eremin-Solenikov

arm: basic support for ARMv4/ARMv4T emulation

Currently target-arm/ assumes at least ARMv5 core. Add support for
handling also ARMv4/ARMv4T. This changes the following instructions:

BX

BKPT, BLX, CDP2, CLZ, LDC2, LDRD, MCRR, MCRR2, MRRC, MCRR, MRC2, MRRC,...

4b4a72e5 04/10/2011 01:45 am Stefan Weil

Fix conversions from pointer to tcg_target_long

tcg_gen_exit_tb takes a parameter of type tcg_target_long,
so the type casts of pointer to long should be replaced by
type casts of pointer to tcg_target_long (suggested by Blue Swirl).

These changes are needed for build environments where...

947a2fa2 04/04/2011 09:18 pm Peter Maydell

target-arm: Use global env in iwmmxt_helper.c helpers

Use the global 'env' variable in the helper functions in iwmmxt_helper.c.
This means we don't need to pass env as an argument to them any more.

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

cc49f217 04/04/2011 09:18 pm Peter Maydell

target-arm: Make Neon helper routines use correct FP status

Make the Neon helper routines use the correct FP status from
the CPUEnv rather than using a dummy static one. This means
they will correctly handle denormals and NaNs and will set
FPSCR exception bits properly....