diff mbox

[6/6] tcg-arm: Make tcg_out_addi inline

Message ID 1313615510-10615-7-git-send-email-rth@twiddle.net
State New
Headers show

Commit Message

Richard Henderson Aug. 17, 2011, 9:11 p.m. UTC
As it's not used, fixes a compilation error.

Signed-off-by: Richard Henderson <rth@twiddle.net>
---
 tcg/arm/tcg-target.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Comments

Peter Maydell Aug. 19, 2011, 11:51 p.m. UTC | #1
On 17 August 2011 22:11, Richard Henderson <rth@twiddle.net> wrote:
> As it's not used, fixes a compilation error.
>
> Signed-off-by: Richard Henderson <rth@twiddle.net>

Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

(We just hit this with the Ubuntu package builds of qemu-linaro
for ARM host...)

-- PMM
andrzej zaborowski Aug. 20, 2011, 12:10 a.m. UTC | #2
On 20 August 2011 01:51, Peter Maydell <peter.maydell@linaro.org> wrote:
> On 17 August 2011 22:11, Richard Henderson <rth@twiddle.net> wrote:
>> As it's not used, fixes a compilation error.

Stefan Weil submitted an identical patch a couple of weeks ago, but I
can't see the rationale for inlining.  It seems like working around
the warning is the only reason for this patch (?), so let's either
remove/#if0 out the function or fix the compilation options to not
error out on something that's not an error. (I'd prefer the latter but
others may object)

Cheers
Peter Maydell Aug. 20, 2011, 4:19 a.m. UTC | #3
On 20 August 2011 01:10, andrzej zaborowski <balrogg@gmail.com> wrote:
> On 20 August 2011 01:51, Peter Maydell <peter.maydell@linaro.org> wrote:
>> On 17 August 2011 22:11, Richard Henderson <rth@twiddle.net> wrote:
>>> As it's not used, fixes a compilation error.
>
> Stefan Weil submitted an identical patch a couple of weeks ago, but I
> can't see the rationale for inlining.  It seems like working around
> the warning is the only reason for this patch (?), so let's either
> remove/#if0 out the function or fix the compilation options to not
> error out on something that's not an error. (I'd prefer the latter but
> others may object)

Yeah, we could remove the function (I'd prefer that to ifdeffery).
I see malc did this for ppc/ppc64 in commits 1a2eb162414 and
c24a9c6ef94.

If we do this, for consistency we should also remove the unused
implementations in tcg/ia64 and tcg/s390.

-- PMM
diff mbox

Patch

diff --git a/tcg/arm/tcg-target.c b/tcg/arm/tcg-target.c
index 93eb0f1..c94a354 100644
--- a/tcg/arm/tcg-target.c
+++ b/tcg/arm/tcg-target.c
@@ -1820,7 +1820,7 @@  static inline void tcg_out_st(TCGContext *s, TCGType type, int arg,
     tcg_out_st32(s, COND_AL, arg, arg1, arg2);
 }
 
-static void tcg_out_addi(TCGContext *s, int reg, tcg_target_long val)
+static inline void tcg_out_addi(TCGContext *s, int reg, tcg_target_long val)
 {
     if (val > 0)
         if (val < 0x100)