Re: [PATCH] target/i386: Clear OF, SF, and AF for fcomi/fucomi

Simon Scherer <[email protected]>
Newsgroups gmane.comp.emulators.qemu
Message-ID <CAEQwQtL3TZSHnYX6tnzYO9CRAOhAJC4xCL1kCR24ZLtbnBHxeQ@mail.gmail.com>
Good catch, sent as v2!

On Thu, Aug 6, 2026 at 6:28 PM Richard Henderson
<[email protected]> wrote:
>
> On 8/6/26 07:52, Simon Scherer wrote:
> > +    /* OF, SF, and AF are unconditionally cleared to 0 */
> > +    eflags = cpu_cc_compute_all(env) &
> > +                 ~(CC_O | CC_S | CC_Z | CC_A | CC_P | CC_C);
>
> There are only 6 flags, and you have cleared all of them.
> Which means you don't need to compute any of them, just
>
> -     CC_SRC = eflags | fcomi_ccval[ret + 1];
> +     CC_SRC = fcomi_ccval[ret + 1];
>
>
> r~
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.