[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] w64: Fix calls of TCG helper functions with 5 a
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] [PATCH] w64: Fix calls of TCG helper functions with 5 arguments |
Date: |
Wed, 12 Sep 2012 19:12:47 +0100 |
On 12 September 2012 19:03, Stefan Weil <address@hidden> wrote:
> diff --git a/tcg/i386/tcg-target.c b/tcg/i386/tcg-target.c
> index da17bba..43b5572 100644
> --- a/tcg/i386/tcg-target.c
> +++ b/tcg/i386/tcg-target.c
> @@ -118,7 +118,7 @@ static void patch_reloc(uint8_t *code_ptr, int type,
> static inline int tcg_target_get_call_iarg_regs_count(int flags)
> {
> if (TCG_TARGET_REG_BITS == 64) {
> - return 6;
> + return ARRAY_SIZE(tcg_target_call_iarg_regs);
> }
>
> return 0;
Hmm. Why can't we just return the array size in all cases?
Is there something special about 32 bit x86? I checked, and
all our other TCG targets return the same value as the size of
the iarg_regs array (either using ARRAY_SIZE or by just returning
the right number)...
-- PMM