Fair Scheduling for AVX2 and AVX-512 Workloads

  • Author:

    Mathias Gottschlag, Philipp Machauer, Yussuf Khalil, Frank Bellosa

  • Source:

    2021 USENIX Annual Technical Conference. July 14–16, 2021

  • Abstract:

    CPU schedulers such as the Linux Completely Fair Scheduler try to allocate equal shares of the CPU  performance to tasks of equal priority by allocating equal CPU time as a technique to improve quality of service for individual tasks. Recently, CPUs have, however, become power-limited to the point where different subsets of the instruction set allow for different operating frequencies depending on the complexity of the instructions. In particular, Intel CPUs with support for AVX2 and AVX-512 instructions often reduce their frequency when these 256-bit and 512-bit SIMD instructions are used in order to prevent excessive power consumption. This frequency reduction often impacts other less power-intensive processes, in which case equal allocation of CPU time results in unequal performance and a substantial lack of performance isolation.

    We describe a modification to existing schedulers to restore fairness for workloads involving tasks which execute complex power-intensive instructions. In particular, we present a technique to identify AVX2/AVX-512 tasks responsible for frequency reduction, and we modify CPU time accounting to increase the priority of other tasks slowed down by these AVX2/AVX-512 tasks. Whereas previously non-AVX applications running in parallel to AVX-512 applications were slowed down by 24.9% on average, our prototype reduces the performance difference between non-AVX tasks and AVX-512 tasks in such scenarios to 5.4% on average, with a similar improvement for workloads involving AVX2 applications.

     

    @inproceedings {273812,
        author = {Mathias Gottschlag and Philipp Machauer and Yussuf Khalil and Frank Bellosa},
        title = {Fair Scheduling for AVX2 and AVX-512 Workloads},
        booktitle = {2021 {USENIX} Annual Technical Conference ({USENIX} {ATC} 21)},
        year = {2021},
        isbn = {978-1-939133-23-6},
        pages = {745--758},
        url = {https://www.usenix.org/conference/atc21/presentation/gottschlag},
        publisher = {{USENIX} Association},
        month = jul,
    }