qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 06/11] TCG/x86: use stack for TCG temps


From: Richard Henderson
Subject: Re: [Qemu-devel] [PATCH 06/11] TCG/x86: use stack for TCG temps
Date: Tue, 17 May 2011 07:57:53 -0700
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.17) Gecko/20110428 Fedora/3.1.10-1.fc14 Thunderbird/3.1.10

On 05/14/2011 12:38 PM, Blue Swirl wrote:
> -    frame_size = push_size + TCG_STATIC_CALL_ARGS_SIZE;
> +    frame_size = push_size + TCG_STATIC_CALL_ARGS_SIZE +
> +        CPU_TEMP_BUF_NLONGS * sizeof(long);
>      frame_size = (frame_size + TCG_TARGET_STACK_ALIGN - 1) &
>          ~(TCG_TARGET_STACK_ALIGN - 1);
>      stack_addend = frame_size - push_size;
> +    tcg_set_frame(s, TCG_REG_ESP, 0, CPU_TEMP_BUF_NLONGS * sizeof(long));
> +
> +    /* Save all callee saved registers.  */
> +    for (i = 0; i < ARRAY_SIZE(tcg_target_callee_save_regs); i++) {
> +        tcg_out_push(s, tcg_target_callee_save_regs[i]);
> +    }
> +
>      tcg_out_addi(s, TCG_REG_ESP, -stack_addend);

Wrong argument to tcg_set_frame.  The temps need to be above the
outgoing call arguments, i.e. offset TCG_STATIC_CALL_ARGS_SIZE.


r~



reply via email to

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