On Wed, Oct 24, 2018 at 10:19 AM Max Filippov <jcmvb...@gmail.com> wrote:
>
> On Wed, Oct 24, 2018 at 4:35 AM Laurent Vivier <laur...@vivier.eu> wrote:
> > > diff --git a/linux-user/flatload.c b/linux-user/flatload.c
> > > index 2eefe55e5000..1893966b5b30 100644
> > > --- a/linux-user/flatload.c
> > > +++ b/linux-user/flatload.c
>
> > > -        sp -= 16 - ((sp + stack_len) & 15);
> > > +    if ((sp - stack_len) & 15) {
> > > +        sp -= ((sp - stack_len) & 15);
> > > +    }
> >
> > If I understand correctly the purpose, I think it could be clearer like:
> >
> >     sp = (sp - stack_len) & ~15;
>
> Yes, you're right. I'll send v2.

Well, not exactly. The sp is not moved down stack_len + alignment bytes,
only the alignment bytes. I'll send v2 anyway.

-- 
Thanks.
-- Max

Reply via email to