Raphaël Rigo wrote:
Dirk Behme wrote:

Hi Raphaël,

maybe you find some time and like to answer to Fabrice's remark regarding patch 8
below?

http://lists.gnu.org/archive/html/qemu-devel/2006-06/msg00419.html

Would be nice to get as many of the pending MIPS patches applied as possible.

Many thanks

Dirk

Fabrice Bellard wrote:

Pending MIPS patches (bugs & improvements):
===========================================


8. [PATCH] Add mips-user signal handling
http://lists.gnu.org/archive/html/qemu-devel/2006-06/msg00319.html



OK. Need to check the handling of "env->PC += 4" in linux-user/main.c. I want to be sure there is not a better solution. Adding setup_rt_frame would be good too.

Hello,
there are 2 possibilities to handle this env->PC += 4:
- do a special case wrapper here to avoid increasing PC when it's a sigreturn.
   -    in do_sigreturn set PC with a -4 offset.
I chose the first way because I thought it would be cleaner, if anyone was to change this part of the code, then it would be clear that sigreturn directly sets PC. Using the 2nd possibility, one could change this += 4 without knowing do_sigreturn would be affected.

I also checked if we could get rid of this weird piece of code, but could not find a clear way to do so.

So i preferred maintainability over efficiency, but if you think
setting PC with an offset of -4 in signal.c is better, tell me and i will update the patch.

There is another simpler solution and I applied it. BTW, the Linux kernel uses the same solution :-)

Fabrice.



_______________________________________________
Qemu-devel mailing list
Qemu-devel@nongnu.org
http://lists.nongnu.org/mailman/listinfo/qemu-devel

Reply via email to