qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2] tcg-i386: Introduce limited deposit support


From: Richard Henderson
Subject: Re: [Qemu-devel] [PATCH v2] tcg-i386: Introduce limited deposit support
Date: Thu, 29 Sep 2011 07:58:13 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:6.0.2) Gecko/20110906 Thunderbird/6.0.2

On 09/29/2011 04:31 AM, Jan Kiszka wrote:
> 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
> x86, but also rarer cases where 32-bit or 64-bit code accesses bytes or
> words.
> 
> Signed-off-by: Jan Kiszka <address@hidden>
> ---
> 
> Changes in v2:
>  - introduce restricting predicates TCG_TARGET_deposit_i32/64_valid
>    to decide if deposit support can be used
>  - express register constraints via new 'Q' symbol

That's what I had in mind, yes.

The only thing that's missing now is a default version of 

> +#define TCG_TARGET_deposit_i32_valid(ofs, len) \
> +    (((ofs) == 0 && (len) == 8) || ((ofs) == 8 && (len) == 8) || \
> +     ((ofs) == 0 && (len) == 16))
> +#define TCG_TARGET_deposit_i64_valid    TCG_TARGET_deposit_i32_valid

These.


r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]