VIS2 pattern review

David Miller davem@davemloft.net
Thu Oct 13 20:06:00 GMT 2011


From: David Miller <davem@davemloft.net>
Date: Thu, 13 Oct 2011 14:26:36 -0400 (EDT)

> 	product = src1 * src2;
> 
> 	scaled = (product & 0x00ffff00) >> 8;
> 	if (product & 0x80)
> 		scaled++;

In fact, all of the partitioned multiply instructions scale the result
by 8 bits with rounding towards positive infinity.

Therefore, we have to use an unspec for all of them.



More information about the Gcc mailing list