[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] QEMU TB Unlinking due to interrupt.

From: 陳韋任
Subject: Re: [Qemu-devel] QEMU TB Unlinking due to interrupt.
Date: Wed, 14 Dec 2011 22:29:31 +0800
User-agent: Mutt/1.5.21 (2010-09-15)

On Tue, Dec 13, 2011 at 08:29:50PM -0500, Xin Tong wrote:
> QEMU performs a recursive unchaining on the current executing tb when
> a timer fires.  This timer is set by setitimer in the qemu-timer.c.
  You mean dynticks_start_timer?

> This is what I mean by "interrupt pending". Of course, there are
> interrupts from emulated devices as well, but i do not know how that
> is set up, i.e. how tcg_handle_interrupt is called when the devices
> finishes some work. I hope you can enlighten me on that.

  I am not familiar with how QEMU deal with virtual devices. But AFAIK, virtual
devices will register IRQ to APIC (hw/apic.c), APIC will call cpu_interrupt
(cpu-all.h), which turns to call cpu_interrupt_handler. You can see 
is assigned as tcg_handle_interrupt in exec.c.  tcg_handle_interrupt raise env's
interrupt_request, and leave cpu_exec to check env's interrupt_request. 


Wei-Ren Chen (陳韋任)
Computer Systems Lab, Institute of Information Science,
Academia Sinica, Taiwan (R.O.C.)
Tel:886-2-2788-3799 #1667
Homepage: http://people.cs.nctu.edu.tw/~chenwj

reply via email to

[Prev in Thread] Current Thread [Next in Thread]