<div dir="ltr"><div><div><div>Hi,<br><br></div>I am working on Kernel Binary Translator which pushes the translated PC instead of the original PC on the stack when an interrupt or exception occurs while executing in kernel mode. There could be some problem if the interrupt or exception handler uses the PC value pushed on the stack. Since interrupts are disabled in kernel mode this problem won&#39;t exist. But still some exceptions like page fault can occur in kernel mode. I just want to make sure that these handlers don&#39;t use the PC value from the stack or don&#39;t overwrite the return address on the stack.<br>
<br></div>Thanks,<br></div>Piyus  </div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Aug 2, 2013 at 4:20 AM, Timothy Roscoe <span dir="ltr">&lt;<a href="mailto:troscoe@inf.ethz.ch" target="_blank">troscoe@inf.ethz.ch</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
As Andrew says, the Barrelfish CPU driver processes all exceptions (whether hardware interrupts or traps) serially with interrupts disabled, unless it&#39;s idling.<br>
<br>
Note that (like K42 and Psyche) Barrelfish uses upcall dispatch most of the time (think Scheduler Activations), so exit from an exception handler is typically a jump to a completely different IP/PC value from when that (or any other) exception occurred.<br>

<br>
Note also that Barrelfish doesn&#39;t have any kernel threads - each CPU driver has a single, static, dedicated kernel stack.<br>
<br>
Could you say a little more about what you mean?<br>
<br>
 -- Mothy<div><div class="h5"><br>
<br>
On 13-08-01 05:32 AM, Piyus Kedia wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5">
Hi All,<br>
<br>
I am working on dynamic binary translator. Please tell me if anybody<br>
know if in Barrelfish interrupted kernel PC is ever used in interrupt<br>
handlers?<br>
<br>
Thanks and regards,<br>
Piyus<br>
<br>
<br>
<br>
<br></div></div>
______________________________<u></u>_________________<br>
Barrelfish-users mailing list<br>
<a href="mailto:Barrelfish-users@lists.inf.ethz.ch" target="_blank">Barrelfish-users@lists.inf.<u></u>ethz.ch</a><br>
<a href="https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users" target="_blank">https://lists.inf.ethz.ch/<u></u>mailman/listinfo/barrelfish-<u></u>users</a><br>
<br>
</blockquote>
<br>
</blockquote></div><br></div>