)]}'
{
  "commit": "73fe6aae84400e2b475e2a1dc4e8592cd3ed6e69",
  "tree": "97c7d6a866d75563082c422491fc423b47aca9d7",
  "parents": [
    "c7a1e46aa9782a947cf2ed506245d43396dbf991"
  ],
  "author": {
    "name": "Gregory Haskins",
    "email": "ghaskins@novell.com",
    "time": "Fri Jan 25 21:08:07 2008 +0100"
  },
  "committer": {
    "name": "Ingo Molnar",
    "email": "mingo@elte.hu",
    "time": "Fri Jan 25 21:08:07 2008 +0100"
  },
  "message": "sched: add RT-balance cpu-weight\n\nSome RT tasks (particularly kthreads) are bound to one specific CPU.\nIt is fairly common for two or more bound tasks to get queued up at the\nsame time.  Consider, for instance, softirq_timer and softirq_sched.  A\ntimer goes off in an ISR which schedules softirq_thread to run at RT50.\nThen the timer handler determines that it\u0027s time to smp-rebalance the\nsystem so it schedules softirq_sched to run.  So we are in a situation\nwhere we have two RT50 tasks queued, and the system will go into\nrt-overload condition to request other CPUs for help.\n\nThis causes two problems in the current code:\n\n1) If a high-priority bound task and a low-priority unbounded task queue\n   up behind the running task, we will fail to ever relocate the unbounded\n   task because we terminate the search on the first unmovable task.\n\n2) We spend precious futile cycles in the fast-path trying to pull\n   overloaded tasks over.  It is therefore optimial to strive to avoid the\n   overhead all together if we can cheaply detect the condition before\n   overload even occurs.\n\nThis patch tries to achieve this optimization by utilizing the hamming\nweight of the task-\u003ecpus_allowed mask.  A weight of 1 indicates that\nthe task cannot be migrated.  We will then utilize this information to\nskip non-migratable tasks and to eliminate uncessary rebalance attempts.\n\nWe introduce a per-rq variable to count the number of migratable tasks\nthat are currently running.  We only go into overload if we have more\nthan one rt task, AND at least one of them is migratable.\n\nIn addition, we introduce a per-task variable to cache the cpus_allowed\nweight, since the hamming calculation is probably relatively expensive.\nWe only update the cached value when the mask is updated which should be\nrelatively infrequent, especially compared to scheduling frequency\nin the fast path.\n\nSigned-off-by: Gregory Haskins \u003cghaskins@novell.com\u003e\nSigned-off-by: Steven Rostedt \u003csrostedt@redhat.com\u003e\nSigned-off-by: Ingo Molnar \u003cmingo@elte.hu\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "cae35b6b9aecf9a849085a3c67a56da6c57d69cb",
      "old_mode": 33188,
      "old_path": "include/linux/init_task.h",
      "new_id": "572c65bcc80f42e43ff6bc2f88c2bb02ab08dbfe",
      "new_mode": 33188,
      "new_path": "include/linux/init_task.h"
    },
    {
      "type": "modify",
      "old_id": "0846f1f9e196d35c1e9af6f841d77f6f5e13aa03",
      "old_mode": 33188,
      "old_path": "include/linux/sched.h",
      "new_id": "b07a2cf76401b2b3dc91364d08813e2a7ad1ad26",
      "new_mode": 33188,
      "new_path": "include/linux/sched.h"
    },
    {
      "type": "modify",
      "old_id": "09c0b90a69ccd5a265958e01968f0bbf68af37b7",
      "old_mode": 33188,
      "old_path": "kernel/fork.c",
      "new_id": "930c51865ab44a4b75e219acf13a8354ff1410a6",
      "new_mode": 33188,
      "new_path": "kernel/fork.c"
    },
    {
      "type": "modify",
      "old_id": "357d3a084de84695e187391689d3625798deeaa1",
      "old_mode": 33188,
      "old_path": "kernel/sched.c",
      "new_id": "66e99b419b31e7bf3fcd1ce5fc4b759b060ff709",
      "new_mode": 33188,
      "new_path": "kernel/sched.c"
    },
    {
      "type": "modify",
      "old_id": "c492fd2b2eece53eaad1965bb726aa7ad37dbf0f",
      "old_mode": 33188,
      "old_path": "kernel/sched_rt.c",
      "new_id": "ae4995c09aacd7645c464e705e0fa10ce2e62b66",
      "new_mode": 33188,
      "new_path": "kernel/sched_rt.c"
    }
  ]
}
