Re: [RFC PATCH 1/2] arch/m68k/lib/mulsi3.S: Optimize]

George Spelvin
2016-05-12T20:52:19Z

Thank you very much!

Greg Ungerer wrote:
> This syntax fails for me (using a binutils-2.25.1 based toolchain).
> Registers must be prefixed with a "%", so here %sp and %a0.
>
> arch/m68k/lib/mulsi3.S: Assembler messages:
> arch/m68k/lib/mulsi3.S:12: Error: syntax error -- statement `lea 4(sp),a0' ignored
>
> That was compiling with just this one patch for a ColdFire target.

Well, *that* is an embarrassing oversight. If you fix that obvious typo
(I used ":%s/[ad][01]/%&/g"), do you have a way of testing it?

Setting up a suitable Qemu environment is many times the effort needed
to write the code, so I was hoping someone with the facilities already
in place would be willing to test.

I've stared at the code and am convinced it's right, but I remember
Knuth's words: "Beware of bugs in the above code; I have only proved it
correct, not tried it."