The lock holder and the lock waiter pre-emption problems: nip them in the bud using informed spinlocks (I-Spinlocks) - Archive ouverte HAL Accéder directement au contenu
Communication Dans Un Congrès Année : 2017

The lock holder and the lock waiter pre-emption problems: nip them in the bud using informed spinlocks (I-Spinlocks)

Résumé

In native Linux systems, spinlock's implementation relies on the assumption that both the lock holder thread and lock waiter threads cannot be preempted. However, in a virtualized environment, these threads are scheduled on top of virtual CPUs (vCPU) that can be preempted by the hypervisor at any time, thus forcing lock waiter threads on other vCPUs to busy wait and to waste CPU cycles. This leads to the well-known Lock Holder Preemption (LHP) and Lock Waiter Preemption (LWP) issues. In this paper, we propose I-Spinlock (for Informed Spinlock), a new spinlock implementation for virtualized environments. Its main principle is to only allow a thread to acquire a lock if and only if the remaining time-slice of its vCPU is sufficient to enter and leave the critical section. This is possible if the spinlock primitive is aware (informed) of its time-to-preemption (by the hypervisor). We implemented I-Spinlock in the Xen virtualization system. We show that our solution is compliant with both para-virtual and hardware virtualization modes. We performed extensive performance evaluations with various reference benchmarks and compared our solution to previous solutions. The evaluations demonstrate that I-Spinlock outperforms other solutions, and more significantly when the number of core increases.
Fichier principal
Vignette du fichier
Djomgwe-Teabe_22297.pdf (494.83 Ko) Télécharger le fichier
Origine : Fichiers produits par l'(les) auteur(s)
Loading...

Dates et versions

hal-02604135 , version 1 (16-05-2020)

Identifiants

  • HAL Id : hal-02604135 , version 1
  • OATAO : 22297

Citer

Boris Teabe, Vlad-Tiberiu Nitu, Alain Tchana, Daniel Hagimont. The lock holder and the lock waiter pre-emption problems: nip them in the bud using informed spinlocks (I-Spinlocks). European Conference on Computer Systems (EuroSys 2017), Apr 2017, Belgrade, Serbia. pp.286-297. ⟨hal-02604135⟩
72 Consultations
441 Téléchargements

Partager

Gmail Facebook X LinkedIn More