Implementing Shadow Page Tables using TLB Maintenance Operations for Full Virtualization of ARM Architecture

ARM 구조의 전가상화를 위한 TLB 관리 명령어를 사용한 섀도 페이지 테이블 구현

  • 조지만 (상명대학교 일반대학원 컴퓨터과학과) ;
  • 오승재 (상명대학교 일반대학원 컴퓨터과학과) ;
  • 신동하 (상명대학교 소프트웨어대학 컴퓨터과학부)
  • Published : 2012.12.31

Abstract

Recently virtualization technology has been applied to ARM architecture based embedded systems. Typically, hardware resources such as processor, memory and device should be virtualized to implement system virtualization. To implement memory virtualization, shadow page table technique is typically used. A shadow page table is a page table which is maintained by a virtual machine monitor to manage the virtual address translation of guests running in a virtual machine. The implementation of shadow page tables is classified depending on the synchronization between guest page tables and shadow page tables. The first method uses traps to capture the page table writes. Since this method modifies guest page tables to be write-protected, the writing guest page tables generates a trap. Another method is using the TLB maintenance operations which guest executes. In this paper, we implement shadow page tables using the latter method and apply this shadow page table technique to the virtual machine monitor for ARM architecture that we are working on. Furthermore, we run Linux kernel on the virtual machine monitor and evaluate performance on a BeagleBoard-xM using QEMU emulator. The results of the evaluation show that the performance of our virtual machine monitor is slower than the virtual machine monitor using paravirtualization. However, this virtual machine monitor has good performance among the virtual machine monitors using full-virtualization.

최근 ARM 구조를 사용하는 임베디드 시스템에서 가상화 기술에 대한 관심이 높아지고 있다. 일반적으로 시스템 가상화 구현을 위해서는 프로세서, 메모리 및 디바이스 등의 하드웨어 자원을 가상화한다. 이 중 메모리 가상화를 구현하기 위한 방법으로 섀도 페이지 테이블 기술이 주로 사용되고 있다. 섀도 페이지 테이블은 가상 머신 상에서 동작하는 게스트의 가상 주소 변환을 관리하기 위하여 가상 머신 모니터가 유지하는 페이지 테이블이다. 섀도 페이지 테이블은 게스트 페이지 테이블과 섀도 페이지 테이블을 동기화하는 방법에 따라 게스트 페이지 테이블에 쓰기 보호를 설정하여 게스트가 페이지 테이블을 수정할 때 발생하는 예외를 이용하는 방법, 혹은 게스트가 수행하는 TLB 관리 명령어를 이용하는 방법으로 구현한다. 본 논문에서는 ARM 구조에서 TLB 관리 명령어를 이용한 섀도 페이지 테이블을 구현하여 본 연구에서 개발 중인 ARM 기반 가상 머신 모니터에 적용하였다. 또한 이 가상 머신 모니터를 이용하여 BeagleBoard-xM을 동작시키는 QEMU 에뮬레이터 상에서 Linux 커널을 수행시켜 성능을 시험하였다. 시험 결과는 기존의 ARM 기반 가상화 연구와 비교하여 반가상화 방식보다는 낮은 성능을 보였지만 전가상화 방식 중에서는 만족스러운 성능을 보였다.

Keywords

References

  1. Gernot Heiser, "The Role of Virtualization in Embedded Systems," Proceedings of the 1st Workshop on Isolation and Integration in Embedded Systems, Scotland, 2008.
  2. M. Tim Jones, "Virtualization for embedded systems," IBM developerWorks, 19 April 2011.
  3. Mendel Rosenblum and Tal Garfinkel, "Virtual Machine Monitors: Current Technology and Future Trends," Computer, IEEE, May 2005.
  4. Soo-Cheol Oh, KangHo Kim, KwangWon Koh, and Chang-Won Ahn, "ViMo: A Virtual Machine Monitor Supporting Full Virtualization For ARM Mobile Systems," Proceedings of Cloud Computing 2010, 2010.
  5. Seung Hyub Jeon, Chang-Won Ahn, and Chul Hun Lee, "Implementation of Supporting out of Synchronization of Shadow Page Table in ViMo Hypervisor based on ARM," Spring Conference of Korea Information Processing Society, Vol. 18, No. 1, 2011.
  6. Megumi Ito and Shuichi Oikawa, "Lightweight Shadow Paging for Efficient Memory Isolation in Gandalf VMM," 11th IEEE Symposium on Object Oriented Real-Time Distributed Computing, 2008.
  7. Christoffer Dall and Jason Nieh, "KVM for ARM," Proceedings of the 12th Linux Symposium, Ottawa, 2010.
  8. 조]지만 이 창훈 신 동하 "ARM 구조의 메모리 가상화를 위한 쉐도우 페이지 테이블 구현" 2011 대한임베디드공학회 추계학술대회 2011.
  9. Fabrice Bellard, "QEMU, a Fast and Portable Dynamic Translator," FREENIX Track: 2005 USENIX Annual Technical Conference, 2005.
  10. Larry McVoy and Carl Staelin, "lmbench: Portable tools for performance analysis," USENIX technical conference. San Diego, CA. January, pp.279-284, 1996.
  11. Prashanth Bungale, "ARM Virtualization: CPU & MMU Issues," VMware Labs Academic Course Materials, 2010.
  12. Joo-Young Hwang, Sang-Bum Suh, Sung-Kwan Heo, Chan-Ju Park, Jae-Min Ryu, Seong-Yeol Park and Chul-Ryun Kim Young, "Xen on arm: System virtualization using xen hypervisor for arm-based secure mobile phones," 5th IEEE Consumer Communications and Networking Conference, pp.257-261, 2008.
  13. Xvisor: eXtensible Versatile hypervISOR, http://xvisor.org.
  14. 이창훈, 신동하, "KVM/ARM의 가상화 민감 명령어에 대한 개선된 처리 기법" 한국차세대컴퓨팅학회 논문지 Vol.8 No.2, pp.6-14, 2012. 4.
  15. 이재호, 김도형, 박상현, 이영석, 이철훈, "가상화 기법을 이용한 리눅스 기반 모바일 단말기용 시뮬레이터 설계 및 구현" 한국차세대컴퓨팅학회 논문지 Vol.5 No.1, pp.41-52, 2009. 3.