aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorNick Piggin <nickpiggin@yahoo.com.au>2005-06-25 17:57:21 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-06-25 19:24:42 -0400
commit687f1661d302bc70ce906594a6d3f615ef075a50 (patch)
tree2895a027851322c2badcd40acf6b871698f2962b /include
parent68767a0ae428801649d510d9a65bb71feed44dd1 (diff)
[PATCH] sched: sched tuning
Do some basic initial tuning. Signed-off-by: Nick Piggin <nickpiggin@yahoo.com.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include')
-rw-r--r--include/asm-i386/topology.h2
-rw-r--r--include/asm-ia64/topology.h61
-rw-r--r--include/asm-x86_64/topology.h3
-rw-r--r--include/linux/topology.h11
4 files changed, 54 insertions, 23 deletions
diff --git a/include/asm-i386/topology.h b/include/asm-i386/topology.h
index 5eb6f61dcefc..2461b731781e 100644
--- a/include/asm-i386/topology.h
+++ b/include/asm-i386/topology.h
@@ -81,7 +81,7 @@ static inline int node_to_first_cpu(int node)
81 .per_cpu_gain = 100, \ 81 .per_cpu_gain = 100, \
82 .flags = SD_LOAD_BALANCE \ 82 .flags = SD_LOAD_BALANCE \
83 | SD_BALANCE_EXEC \ 83 | SD_BALANCE_EXEC \
84 | SD_BALANCE_NEWIDLE \ 84 | SD_BALANCE_FORK \
85 | SD_WAKE_BALANCE, \ 85 | SD_WAKE_BALANCE, \
86 .last_balance = jiffies, \ 86 .last_balance = jiffies, \
87 .balance_interval = 1, \ 87 .balance_interval = 1, \
diff --git a/include/asm-ia64/topology.h b/include/asm-ia64/topology.h
index 21cf351fd05c..4e64c2a6b369 100644
--- a/include/asm-ia64/topology.h
+++ b/include/asm-ia64/topology.h
@@ -42,25 +42,54 @@
42 42
43void build_cpu_to_node_map(void); 43void build_cpu_to_node_map(void);
44 44
45#define SD_CPU_INIT (struct sched_domain) { \
46 .span = CPU_MASK_NONE, \
47 .parent = NULL, \
48 .groups = NULL, \
49 .min_interval = 1, \
50 .max_interval = 4, \
51 .busy_factor = 64, \
52 .imbalance_pct = 125, \
53 .cache_hot_time = (10*1000000), \
54 .per_cpu_gain = 100, \
55 .cache_nice_tries = 2, \
56 .busy_idx = 2, \
57 .idle_idx = 1, \
58 .newidle_idx = 2, \
59 .wake_idx = 1, \
60 .forkexec_idx = 1, \
61 .flags = SD_LOAD_BALANCE \
62 | SD_BALANCE_NEWIDLE \
63 | SD_BALANCE_EXEC \
64 | SD_WAKE_AFFINE, \
65 .last_balance = jiffies, \
66 .balance_interval = 1, \
67 .nr_balance_failed = 0, \
68}
69
45/* sched_domains SD_NODE_INIT for IA64 NUMA machines */ 70/* sched_domains SD_NODE_INIT for IA64 NUMA machines */
46#define SD_NODE_INIT (struct sched_domain) { \ 71#define SD_NODE_INIT (struct sched_domain) { \
47 .span = CPU_MASK_NONE, \ 72 .span = CPU_MASK_NONE, \
48 .parent = NULL, \ 73 .parent = NULL, \
49 .groups = NULL, \ 74 .groups = NULL, \
50 .min_interval = 80, \ 75 .min_interval = 8, \
51 .max_interval = 320, \ 76 .max_interval = 8*(min(num_online_cpus(), 32)), \
52 .busy_factor = 320, \ 77 .busy_factor = 64, \
53 .imbalance_pct = 125, \ 78 .imbalance_pct = 125, \
54 .cache_hot_time = (10*1000000), \ 79 .cache_hot_time = (10*1000000), \
55 .cache_nice_tries = 1, \ 80 .cache_nice_tries = 2, \
81 .busy_idx = 3, \
82 .idle_idx = 2, \
83 .newidle_idx = 0, /* unused */ \
84 .wake_idx = 1, \
85 .forkexec_idx = 1, \
56 .per_cpu_gain = 100, \ 86 .per_cpu_gain = 100, \
57 .flags = SD_LOAD_BALANCE \ 87 .flags = SD_LOAD_BALANCE \
58 | SD_BALANCE_EXEC \ 88 | SD_BALANCE_EXEC \
59 | SD_BALANCE_NEWIDLE \ 89 | SD_BALANCE_FORK \
60 | SD_WAKE_IDLE \
61 | SD_WAKE_BALANCE, \ 90 | SD_WAKE_BALANCE, \
62 .last_balance = jiffies, \ 91 .last_balance = jiffies, \
63 .balance_interval = 1, \ 92 .balance_interval = 64, \
64 .nr_balance_failed = 0, \ 93 .nr_balance_failed = 0, \
65} 94}
66 95
@@ -69,17 +98,21 @@ void build_cpu_to_node_map(void);
69 .span = CPU_MASK_NONE, \ 98 .span = CPU_MASK_NONE, \
70 .parent = NULL, \ 99 .parent = NULL, \
71 .groups = NULL, \ 100 .groups = NULL, \
72 .min_interval = 80, \ 101 .min_interval = 64, \
73 .max_interval = 320, \ 102 .max_interval = 64*num_online_cpus(), \
74 .busy_factor = 320, \ 103 .busy_factor = 128, \
75 .imbalance_pct = 125, \ 104 .imbalance_pct = 133, \
76 .cache_hot_time = (10*1000000), \ 105 .cache_hot_time = (10*1000000), \
77 .cache_nice_tries = 1, \ 106 .cache_nice_tries = 1, \
107 .busy_idx = 3, \
108 .idle_idx = 3, \
109 .newidle_idx = 0, /* unused */ \
110 .wake_idx = 0, /* unused */ \
111 .forkexec_idx = 0, /* unused */ \
78 .per_cpu_gain = 100, \ 112 .per_cpu_gain = 100, \
79 .flags = SD_LOAD_BALANCE \ 113 .flags = SD_LOAD_BALANCE, \
80 | SD_BALANCE_EXEC, \
81 .last_balance = jiffies, \ 114 .last_balance = jiffies, \
82 .balance_interval = 100*(63+num_online_cpus())/64, \ 115 .balance_interval = 64, \
83 .nr_balance_failed = 0, \ 116 .nr_balance_failed = 0, \
84} 117}
85 118
diff --git a/include/asm-x86_64/topology.h b/include/asm-x86_64/topology.h
index 802d09b9c99f..c1bc3fad482e 100644
--- a/include/asm-x86_64/topology.h
+++ b/include/asm-x86_64/topology.h
@@ -42,12 +42,11 @@ extern int __node_distance(int, int);
42 .cache_nice_tries = 2, \ 42 .cache_nice_tries = 2, \
43 .busy_idx = 3, \ 43 .busy_idx = 3, \
44 .idle_idx = 2, \ 44 .idle_idx = 2, \
45 .newidle_idx = 1, \ 45 .newidle_idx = 0, \
46 .wake_idx = 1, \ 46 .wake_idx = 1, \
47 .forkexec_idx = 1, \ 47 .forkexec_idx = 1, \
48 .per_cpu_gain = 100, \ 48 .per_cpu_gain = 100, \
49 .flags = SD_LOAD_BALANCE \ 49 .flags = SD_LOAD_BALANCE \
50 | SD_BALANCE_NEWIDLE \
51 | SD_BALANCE_FORK \ 50 | SD_BALANCE_FORK \
52 | SD_BALANCE_EXEC \ 51 | SD_BALANCE_EXEC \
53 | SD_WAKE_BALANCE, \ 52 | SD_WAKE_BALANCE, \
diff --git a/include/linux/topology.h b/include/linux/topology.h
index 665597207def..0320225e96da 100644
--- a/include/linux/topology.h
+++ b/include/linux/topology.h
@@ -91,7 +91,7 @@
91 .per_cpu_gain = 25, \ 91 .per_cpu_gain = 25, \
92 .busy_idx = 0, \ 92 .busy_idx = 0, \
93 .idle_idx = 0, \ 93 .idle_idx = 0, \
94 .newidle_idx = 0, \ 94 .newidle_idx = 1, \
95 .wake_idx = 0, \ 95 .wake_idx = 0, \
96 .forkexec_idx = 0, \ 96 .forkexec_idx = 0, \
97 .flags = SD_LOAD_BALANCE \ 97 .flags = SD_LOAD_BALANCE \
@@ -121,15 +121,14 @@
121 .cache_nice_tries = 1, \ 121 .cache_nice_tries = 1, \
122 .per_cpu_gain = 100, \ 122 .per_cpu_gain = 100, \
123 .busy_idx = 2, \ 123 .busy_idx = 2, \
124 .idle_idx = 0, \ 124 .idle_idx = 1, \
125 .newidle_idx = 1, \ 125 .newidle_idx = 2, \
126 .wake_idx = 1, \ 126 .wake_idx = 1, \
127 .forkexec_idx = 0, \ 127 .forkexec_idx = 1, \
128 .flags = SD_LOAD_BALANCE \ 128 .flags = SD_LOAD_BALANCE \
129 | SD_BALANCE_NEWIDLE \ 129 | SD_BALANCE_NEWIDLE \
130 | SD_BALANCE_EXEC \ 130 | SD_BALANCE_EXEC \
131 | SD_WAKE_AFFINE \ 131 | SD_WAKE_AFFINE, \
132 | SD_WAKE_BALANCE, \
133 .last_balance = jiffies, \ 132 .last_balance = jiffies, \
134 .balance_interval = 1, \ 133 .balance_interval = 1, \
135 .nr_balance_failed = 0, \ 134 .nr_balance_failed = 0, \