Storing 64-bit result on ARM using inline assembly

Ian Lance Taylor iant@google.com
Thu Jul 2 02:29:00 GMT 2009


Leonitis <rubixqb@gmail.com> writes:

> I am trying to write an inline function that does a 32-bit by 32-bit
> multiply (32x32->64).

I think you're making it a bit hard on yourself.  How about this:

long long
foo(int i, int j)
{
  return (long long) i * (long long) j;
}

Seems to work for me, when optimizing.

Ian



More information about the Gcc-help mailing list