projects
/
sdk
/
emulator
/
qemu.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a5e1cbc
)
microblaze-user: Deliver SIGFPE on div by zero
author
Edgar E. Iglesias
<edgar.iglesias@gmail.com>
Mon, 22 Aug 2011 16:42:54 +0000
(18:42 +0200)
committer
Edgar E. Iglesias
<edgar.iglesias@gmail.com>
Mon, 22 Aug 2011 16:47:38 +0000
(18:47 +0200)
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
linux-user/main.c
patch
|
blob
|
history
diff --git
a/linux-user/main.c
b/linux-user/main.c
index
95e3fe6
..
89a51d7
100644
(file)
--- a/
linux-user/main.c
+++ b/
linux-user/main.c
@@
-2339,6
+2339,13
@@
void cpu_loop (CPUState *env)
env->iflags &= ~(IMM_FLAG | D_FLAG);
switch (env->sregs[SR_ESR] & 31) {
+ case ESR_EC_DIVZERO:
+ info.si_signo = SIGFPE;
+ info.si_errno = 0;
+ info.si_code = TARGET_FPE_FLTDIV;
+ info._sifields._sigfault._addr = 0;
+ queue_signal(env, info.si_signo, &info);
+ break;
case ESR_EC_FPU:
info.si_signo = SIGFPE;
info.si_errno = 0;