Outreachy 2016 DecemberMarch: Difference between revisions

From QEMU
No edit summary
No edit summary
Line 1: Line 1:
= Introduction =
= Introduction =


QEMU is considering participating in [https://www.gnome.org/outreachy/ Outreachy 2016 December-March]. This page contains our ideas list and information for mentors.
QEMU is participating in [https://www.gnome.org/outreachy/ Outreachy 2016 December-March]. This page contains our ideas list and information for applicants and mentors.


= Find Us =
= Find Us =
Line 16: Line 16:


== QEMU projects ==
== QEMU projects ==
=== Event loop profiling tool ===
'''Summary:''' Develop a top(1)-like tool to monitor event loop dispatching
A running QEMU process can have a number of different types of threads.  An I/O thread (either the main thread, or a custom iothread for dataplane devices) is a thread that runs an poll based event loop.
The event loop dispatches I/O events that come from user interface (e.g.  monitor fd), guest OS (e.g. ioeventfd), or program's internal sources (e.g.  bottom halves or timers).  Their occupation of host CPU time is often very useful debug/diagnostic information. Ideally the profiling code in QEMU would be in a dedicated thread so it is still usable even when the event loops are stuck.
In this project you will develop a tool for QEMU that is like the top(1) utility for Linux, to monitor QEMU's event loops. As a prerequisite, you need to modify QEMU to expose necessary data that will be collected by the new tool to generate the profiling output.
You must be familiar with (n)curses library and multi-threaded programming. You can write the tool in either C or Python.
'''Links:'''
* https://en.wikipedia.org/wiki/Event_loop
* [https://docs.python.org/2/library/curses.html Python curses module]
'''Details:'''
* Skill level: advanced
* Language: C, (optional) Python
* Mentor: Fam Zheng <famz@redhat.com> (fam on IRC), Stefan Hajnoczi <stefanha@redhat.com> (stefanha on IRC)


=== qtest-os: a mini operating system written in Python ===
=== qtest-os: a mini operating system written in Python ===

Revision as of 15:51, 27 September 2016

Introduction

QEMU is participating in Outreachy 2016 December-March. This page contains our ideas list and information for applicants and mentors.

Find Us

  • IRC: #qemu-outreachy on irc.oftc.net

For general questions about QEMU in Outreachy, please contact the following people:

Project Ideas

This is the listing of suggested project ideas.

QEMU projects

qtest-os: a mini operating system written in Python

Summary: Write a Python library to interact with QEMU's qtest, and then as much as possible of a "mini-OS" written in Python

QEMU uses "qtest" as a mechanism for tests to interact with devices. qtest unit tests are currently written in C, using the GTest framework from glib and glue libraries called "libqtest" and "libqos". libqtest implements the qtest socket protocol, while libqos provides utility functions to deal with e.g. guest memory allocation and PCI devices. However, the functionality of libqos is limited, and using a high-level language like Python will make it easier to prototype and build more complex functionality in libqos.

This project will investigate using qtest from Python, including:

  • writing a Python library with the same functionality as libqtest
  • converting some of the existing tests from C to Python
  • extending qtest with a driver model ("qtest-os").

The last bullet splits a unit test in three parts: a description of QEMU's supported machine types, a set of drivers, and the unit test code proper. For example, given:

  • a SCSI unit test
  • a description of the machine type X saying that X a PCI bus
  • a driver for X's PCI host bridge
  • a driver for virtio-scsi

qtest would infer that the unit test can run by starting X with a virtio-scsi device.

Links:

Details:

  • Skill level: medium
  • Language: Python
  • Mentor: Paolo Bonzini <pbonzini@redhat.com> (bonzini on IRC)

Project idea template

=== TITLE ===
 
 '''Summary:''' Short description of the project
 
 Detailed description of the project.
 
 '''Links:'''
 * Wiki links to relevant material
 * External links to mailing lists or web sites
 
 '''Details:'''
 * Skill level: beginner or intermediate or advanced
 * Language: C
 * Mentor: Email address and IRC nick
 * Suggested by: Person who suggested the idea

Information for mentors

Mentors are responsible for keeping in touch with their candidate and assessing the candidate's progress.

The mentor typically gives advice, reviews the candidate's code, and has regular communication with the candidate to ensure progress is being made.

Being a mentor is a significant time commitment, plan for 5 hours per week. Make sure you can make this commitment because backing out during the summer will affect the candidate's experience.

The mentor chooses their candidate by reviewing candidate application forms, giving out bite-sized tasks so applicants can submit a patch upstream, and conducting IRC interviews with candidates. Depending on the number of candidates, this can be time-consuming in itself. Choosing the right candidate is critical so that both the mentor and the candidate can have a successful experience.