From cf2a780ef4d47a2f91f5fc6ca0333c2b386e2235 Mon Sep 17 00:00:00 2001
From: Dominik Vogt <vogt@linux.vnet.ibm.com>
Date: Tue, 2 Jun 2015 08:12:44 +0100
Subject: [PATCH 3/3] Add "inline" to functions with the always_inline
attribute. III
---
gcc/testsuite/g++.dg/torture/pr51436.C | 3 ++-
gcc/testsuite/gcc.c-torture/execute/pr33992.c | 2 +-
gcc/testsuite/gcc.dg/debug/pr41264-1.c | 3 +--
gcc/testsuite/gcc.dg/tm/pr52141.c | 2 +-
gcc/testsuite/gcc.dg/torture/pr39204.c | 2 +-
gcc/testsuite/gcc.dg/tree-ssa/pr40087.c | 4 ++--
6 files changed, 8 insertions(+), 8 deletions(-)
@@ -3,7 +3,8 @@
typedef __SIZE_TYPE__ size_t;
extern "C" void *memcpy (void *, __const void *, size_t);
template < class Dest, class Source > struct BitCastHelper {
- static Dest cast (const Source & source) __attribute__ ((always_inline)) {
+ static Dest cast (const Source & source)
+ __attribute__ ((always_inline)) {
Dest dest;
memcpy (0, &source, sizeof dest);
}
@@ -7,7 +7,7 @@ bar (unsigned long long i)
abort ();
}
-static void __attribute__((always_inline))
+static inline void __attribute__((always_inline))
foo (unsigned long long *r)
{
int i;
@@ -1,12 +1,11 @@
/* { dg-do compile } */
-/* { dg-options "-Wno-attributes" } */
#if (__SIZEOF_INT__ <= 2)
typedef unsigned long hashval_t;
#else
typedef unsigned int hashval_t;
#endif
-static hashval_t __attribute__((always_inline))
+static inline hashval_t __attribute__((always_inline))
iterative_hash_host_wide_int (long val, hashval_t val2)
{
hashval_t a = (hashval_t) val;
@@ -2,7 +2,7 @@
/* { dg-options "-fgnu-tm -O0 -w" } */
__attribute__((always_inline))
-static void asmfunc(void)
+static inline void asmfunc(void)
{
__asm__ (""); /* { dg-error "asm not allowed in .transaction_safe" } */
}
@@ -112,7 +112,7 @@ static void _close_html_file (FILE * file)
for (f = 0; _word_substitution[f]; f++)
;
}
-static __attribute__((always_inline))
+static inline __attribute__((always_inline))
char * _do_text_substitution (char *input)
{
int start, end, middle, f;
@@ -1,9 +1,9 @@
/* { dg-do run } */
-/* { dg-options "-O1 -Wno-attributes" } */
+/* { dg-options "-O1" } */
extern void abort (void);
-static void __attribute__((always_inline))
+static inline void __attribute__((always_inline))
reverse(int *first, int *last)
{
if (first == last--)
--
2.3.0