All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefan Weil <sw@weilnetz.de>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: Carsten Otte <cotte@de.ibm.com>, Alexander Graf <agraf@suse.de>,
	QEMU Developers <qemu-devel@nongnu.org>,
	Blue Swirl <blauwirbel@gmail.com>,
	Christian Borntraeger <borntraeger@de.ibm.com>,
	rth@twiddle.net
Subject: Re: [Qemu-devel] build errors on s390 tcg
Date: Tue, 04 Oct 2011 18:41:15 +0200	[thread overview]
Message-ID: <4E8B372B.3020603@weilnetz.de> (raw)
In-Reply-To: <CAFEAcA9CzWbZOLh1UacC=f3SsJUeqGH3cMxR194z6Rw2C+8sAw@mail.gmail.com>

Am 04.10.2011 14:44, schrieb Peter Maydell:
> On 4 October 2011 13:23, Alexander Graf <agraf@suse.de> wrote:
>> The problem is that tcg.c defines the functions with int arguments 
>> for TCG
>> register indexes, while s390/tcg-target.c takes TCGReg parameters. 
>> I'm not
>> sure which way is better, but using TCGReg feels more type safe to me.
>
> You're not consistent, though; for example the s390 
> tcg_target_reg_alloc_order
> array is declared as int[], not TCGReg[].
>
> -- PMM

I did not notice that s390 was different when I wrote my patch,
but I agree with Alex that TCGReg is more type safe. I also
think that using TCGReg documents the meaning of a parameter
better than using a simple int.

So there are two tasks to be done:

- Look for inconsistencies and fix them.

- Add and use TCGReg for all other targets, too.

Or are there any reasons why we should keep the int type parameters?

Regards,
Stefan Weil

      reply	other threads:[~2011-10-04 16:42 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-04 11:54 [Qemu-devel] build errors on s390 tcg Christian Borntraeger
2011-10-04 12:23 ` Alexander Graf
2011-10-04 12:44   ` Peter Maydell
2011-10-04 16:41     ` Stefan Weil [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E8B372B.3020603@weilnetz.de \
    --to=sw@weilnetz.de \
    --cc=agraf@suse.de \
    --cc=blauwirbel@gmail.com \
    --cc=borntraeger@de.ibm.com \
    --cc=cotte@de.ibm.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=rth@twiddle.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.