ppc: fix result of DLMZB when no zero bytes are found It must return 8 and place 8 in XER, but the current code uses i directly which is 9 at this point of the code. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Tom Musta <tommusta@gmail.com> Signed-off-by: Alexander Graf <agraf@suse.de>
diff --git a/target-ppc/int_helper.c b/target-ppc/int_helper.c index 29ff4f6..83c1ad0 100644 --- a/target-ppc/int_helper.c +++ b/target-ppc/int_helper.c
@@ -2556,6 +2556,7 @@ } i++; } + i = 8; if (update_Rc) { env->crf[0] = 0x2; }