[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1376089460-5459-6-git-send-email-andi@firstfloor.org>
Date: Fri, 9 Aug 2013 16:04:12 -0700
From: Andi Kleen <andi@...stfloor.org>
To: linux-kernel@...r.kernel.org
Cc: x86@...nel.org, mingo@...nel.org, torvalds@...ux-foundation.org,
Andi Kleen <ak@...ux.intel.com>
Subject: [PATCH 05/13] sched: mark should_resched() __always_inline
From: Andi Kleen <ak@...ux.intel.com>
At least gcc 4.6 and some earlier ones does not inline this function.
Since it's small and on relatively hot paths force inline it.
Signed-off-by: Andi Kleen <ak@...ux.intel.com>
---
kernel/sched/core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 74d7c04..23df96a 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -3767,7 +3767,7 @@ SYSCALL_DEFINE0(sched_yield)
return 0;
}
-static inline int should_resched(void)
+static __always_inline int should_resched(void)
{
return need_resched() && !(preempt_count() & PREEMPT_ACTIVE);
}
--
1.8.3.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists