From 1749c1dd425fdba82eb0f1a0761c4c3d71d55319 Mon Sep 17 00:00:00 2001 From: Marc Mutz Date: Sun, 25 Jan 2015 00:04:42 +0100 Subject: Centralize use of __attribute__((noinline)) There are currently only two users, but I have patches in the pipeline which mark some other function noinline, so proavtively centralize the ifdef'ery involved. Change-Id: I1f02351fdc903d4e026089e12b8a976ed6a8d603 Reviewed-by: Kai Koehne Reviewed-by: Thiago Macieira --- src/corelib/tools/qbytearray.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'src/corelib/tools/qbytearray.cpp') diff --git a/src/corelib/tools/qbytearray.cpp b/src/corelib/tools/qbytearray.cpp index f3844cf58d..7f6dab38c0 100644 --- a/src/corelib/tools/qbytearray.cpp +++ b/src/corelib/tools/qbytearray.cpp @@ -2761,15 +2761,11 @@ QByteArray QByteArray::mid(int pos, int len) const \sa toUpper(), {8-bit Character Comparisons} */ -// noinline so that the compiler won't inline the function in each of +// prevent the compiler from inlining the function in each of // toLower and toUpper when the only difference is the table being used // (even with constant propagation, there's no gain in performance). template -#ifdef Q_CC_MSVC -__declspec(noinline) -#elif defined(Q_CC_GNU) -__attribute__((noinline)) -#endif +Q_NEVER_INLINE static QByteArray toCase_template(T &input, const uchar * table) { // find the first bad character in input -- cgit v1.2.3