features.h 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. /*
  3. * Only give sleepers 50% of their service deficit. This allows
  4. * them to run sooner, but does not allow tons of sleepers to
  5. * rip the spread apart.
  6. */
  7. SCHED_FEAT(GENTLE_FAIR_SLEEPERS, true)
  8. /*
  9. * Place new tasks ahead so that they do not starve already running
  10. * tasks
  11. */
  12. SCHED_FEAT(START_DEBIT, true)
  13. /*
  14. * Prefer to schedule the task we woke last (assuming it failed
  15. * wakeup-preemption), since its likely going to consume data we
  16. * touched, increases cache locality.
  17. */
  18. SCHED_FEAT(NEXT_BUDDY, false)
  19. /*
  20. * Prefer to schedule the task that ran last (when we did
  21. * wake-preempt) as that likely will touch the same data, increases
  22. * cache locality.
  23. */
  24. SCHED_FEAT(LAST_BUDDY, true)
  25. /*
  26. * Consider buddies to be cache hot, decreases the likelyness of a
  27. * cache buddy being migrated away, increases cache locality.
  28. */
  29. SCHED_FEAT(CACHE_HOT_BUDDY, true)
  30. /*
  31. * Allow wakeup-time preemption of the current task:
  32. */
  33. SCHED_FEAT(WAKEUP_PREEMPTION, true)
  34. SCHED_FEAT(HRTICK, false)
  35. SCHED_FEAT(DOUBLE_TICK, false)
  36. /*
  37. * Decrement CPU capacity based on time not spent running tasks
  38. */
  39. SCHED_FEAT(NONTASK_CAPACITY, true)
  40. /*
  41. * Queue remote wakeups on the target CPU and process them
  42. * using the scheduler IPI. Reduces rq->lock contention/bounces.
  43. */
  44. SCHED_FEAT(TTWU_QUEUE, true)
  45. /*
  46. * When doing wakeups, attempt to limit superfluous scans of the LLC domain.
  47. */
  48. SCHED_FEAT(SIS_AVG_CPU, false)
  49. SCHED_FEAT(SIS_PROP, true)
  50. /*
  51. * Issue a WARN when we do multiple update_rq_clock() calls
  52. * in a single rq->lock section. Default disabled because the
  53. * annotations are not complete.
  54. */
  55. SCHED_FEAT(WARN_DOUBLE_CLOCK, false)
  56. #ifdef HAVE_RT_PUSH_IPI
  57. /*
  58. * In order to avoid a thundering herd attack of CPUs that are
  59. * lowering their priorities at the same time, and there being
  60. * a single CPU that has an RT task that can migrate and is waiting
  61. * to run, where the other CPUs will try to take that CPUs
  62. * rq lock and possibly create a large contention, sending an
  63. * IPI to that CPU and let that CPU push the RT task to where
  64. * it should go may be a better scenario.
  65. */
  66. SCHED_FEAT(RT_PUSH_IPI, true)
  67. #endif
  68. SCHED_FEAT(RT_RUNTIME_SHARE, false)
  69. SCHED_FEAT(LB_MIN, false)
  70. SCHED_FEAT(ATTACH_AGE_LOAD, true)
  71. SCHED_FEAT(WA_IDLE, true)
  72. SCHED_FEAT(WA_WEIGHT, true)
  73. SCHED_FEAT(WA_BIAS, true)
  74. /*
  75. * UtilEstimation. Use estimated CPU utilization.
  76. */
  77. SCHED_FEAT(UTIL_EST, true)
  78. SCHED_FEAT(UTIL_EST_FASTUP, true)
  79. SCHED_FEAT(ALT_PERIOD, true)
  80. SCHED_FEAT(BASE_SLICE, true)