skip to main content
research-article

Efficient memory virtualization for Cross-ISA system mode emulation

Published:01 March 2014Publication History
Skip Abstract Section

Abstract

Cross-ISA system-mode emulation has many important applications. For example, Cross-ISA system-mode emulation helps computer architects and OS developers trace and debug kernel execution-flow efficiently by emulating a slower platform (such as ARM) on a more powerful plat-form (such as an x86 machine). Cross-ISA system-mode emulation also enables workload consolidation in data centers with platforms of different instruction-set architectures (ISAs). However, system-mode emulation is much slower. One major overhead in system-mode emulation is the multi-level memory address translation that maps guest virtual address to host physical address. Shadow page tables (SPT) have been used to reduce such overheads, but primarily for same-ISA virtualization. In this paper we propose a novel approach called embedded shadow page tables (ESPT). EPST embeds a shadow page table into the address space of a cross-ISA dynamic binary translation (DBT) and uses hardware memory management unit in the CPU to translate memory addresses, instead of software translation in a current DBT emulator like QEMU. We also use the larger address space on modern 64-bit CPUs to accommodate our DBT emulator so that it will not interfere with the guest operating system. We incorporate our new scheme into QEMU, a popular, retargetable cross-ISA system emulator. SPEC CINT2006 benchmark results indicate that our technique achieves an average speedup of 1.51 times in system mode when emulating ARM on x86, and a 1.59 times speedup for emulating IA32 on x86_64.

References

  1. James Smith and Ravi Nair, "Virtual Machines: Versatile Platforms for Systems and Processes", Elsevier, 2005, ISBN: 1-55860-910-5 Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. E. Witchel and M. Rosenblum, "Embra: Fast and Flexible Machine Simulation", Proceedings of the ACM SIGMETRICS international conference on Measurement and modeling of computer systems, 1996 Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Luk, C.-K., Cohn, R., Muth, R., Patil, H., Klauser, A., Lowney, G., and Wallace, S., Reddi, V. J., Hazelwood, K., "Pin: Building Customized Program Analysis Tools with Dynamic Instrumentation", Programming languages design and implementation, June 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. N. Nethercote. Dynamic Binary Analysis and Instrumentation. A dissertation submitted for the degree of doctor of philosophy, University of Cambridge, November 2004.Google ScholarGoogle Scholar
  5. K. Scott and J. Davidson. Strata: A Software Dynamic Trans-lation Infrastructure. In IEEE Workshop on Binary Translation (2001).Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. A. Chernoff and Ray Hookway, "DIGITAL FX!32: Running 32-Bit x86 Applications on Alpha NT", the Proc. of the USENIX Windows NT Workshop, August 1997 Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Vmware. http://www.vmware.com.Google ScholarGoogle Scholar
  8. Xen. http://www.xen.org.Google ScholarGoogle Scholar
  9. Sheng Yang, "Extending KVM with new Intel® Virtualization technology", Intel Open Source Technology Center, KVM Forum 2008.Google ScholarGoogle Scholar
  10. WANG, C., HU, S., KIM, H.-S., NAIR, S., BRETERNITZ, M., YING, Z., and WU, Y. "Stardbt: An efficient multi-platform dynamic binary translation system", In Advances in Computer Systems Architecture, vol. 4697. 2007 Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Virtualbox. http://www.virtualbox.org/.Google ScholarGoogle Scholar
  12. Payer, M., Kravina, E., and Gross T. R., "Lightweight Memory Tracing". In USENIX ATC, 2013 Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Bellard, F.; "QEMU, a Fast and Portable Dynamic Translator," in USENIX ATC 2005 Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. K. Scott, N. Kumar, B. R. Childers, J.W. Davidson, and M. L. Soffa, "Overhead reduction techniques for software dynamic translation," in Proc. IPDPS, 2004, pp. 200--207.Google ScholarGoogle Scholar
  15. D. Bruening, T. Garnett, S. Amarasinghe, "DynamoRIO: An Infrastructure for Adaptive Dynamic Optimization", Proceedings of the international symposium on code generation and optimization, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. Transitive corporation. quicktransit software. http://www.transitive.com/.Google ScholarGoogle Scholar
  17. Xiao Guangrong, "KVM MMU Virtualization", Linux Foundation Events, 2011.Google ScholarGoogle Scholar
  18. N. Nethercote and J. Seward, "Valgrind: A Framework for Heavyweight dynamic Binary Instrumentation", ACM SIG-PLAN Conference on Programming Language Design and Implementation (PLDI 2007), June 2007 Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. E. Bugnion, S. Devine, M. Rosenblum, J. Sugerman and E. Y. Wang, "Bringing Virtualization to the x86 Architecture with the Original VMware Workstation", TOCS , volume 30 issue 4, Nov 2012 Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. K. Adams and O. Agesen, "A Comparison of Software and Hardware Techniques for x86 Virtualization", ASPLOS'06, San Jose, California, USA, October 21--25, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Efficient memory virtualization for Cross-ISA system mode emulation

    Recommendations

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in

    Full Access

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader
    About Cookies On This Site

    We use cookies to ensure that we give you the best experience on our website.

    Learn more

    Got it!