tests: cris: force inlining

The CRIS tests expect that functions marked inline are always inline.
With newer versions of GCC, building them results warnings like the
following and spurious failures when they are run.

In file included from tests/tcg/cris/check_moveq.c:5:0:
tests/tcg/cris/crisutils.h:66:20: warning: inlining failed in call to
'cris_tst_cc.constprop.0': call is unlikely and code size would grow [-Winline]
tests/tcg/cris/check_moveq.c:28:13: warning: called from here [-Winline]

Use the always_inline attribute when building them to fix this.

Reviewed-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
Signed-off-by: Rabin Vincent <rabinv@axis.com>
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
This commit is contained in:
Rabin Vincent 2016-08-23 16:34:59 +02:00 committed by Edgar E. Iglesias
parent 25930ed60a
commit 21ce148c7e
10 changed files with 28 additions and 26 deletions

View file

@ -5,12 +5,12 @@
#include "crisutils.h"
static inline int64_t add64(const int64_t a, const int64_t b)
static always_inline int64_t add64(const int64_t a, const int64_t b)
{
return a + b;
}
static inline int64_t sub64(const int64_t a, const int64_t b)
static always_inline int64_t sub64(const int64_t a, const int64_t b)
{
return a - b;
}