projects
/
GitHub
/
LineageOS
/
G12
/
android_kernel_amlogic_linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9c4801c
)
sched: micro-optimize mmdrop()
author
Ingo Molnar
<mingo@elte.hu>
Mon, 9 Jul 2007 16:52:01 +0000
(18:52 +0200)
committer
Ingo Molnar
<mingo@elte.hu>
Mon, 9 Jul 2007 16:52:01 +0000
(18:52 +0200)
micro-optimize mmdrop(). Improves schedule()'s assembly a bit.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
include/linux/sched.h
patch
|
blob
|
blame
|
history
diff --git
a/include/linux/sched.h
b/include/linux/sched.h
index 785ec8465bd39a8e12fef5c72f756afae27a33b5..cfb680585ab8bd87762fe3e9b2bedfb404882760 100644
(file)
--- a/
include/linux/sched.h
+++ b/
include/linux/sched.h
@@
-1514,7
+1514,7
@@
extern struct mm_struct * mm_alloc(void);
extern void FASTCALL(__mmdrop(struct mm_struct *));
static inline void mmdrop(struct mm_struct * mm)
{
- if (
atomic_dec_and_test(&mm->mm_count
))
+ if (
unlikely(atomic_dec_and_test(&mm->mm_count)
))
__mmdrop(mm);
}