[Mono-dev] [PATCH]: Use sparc 'sethi' in more cases.

David Miller davem at davemloft.net
Wed Nov 7 02:25:01 EST 2007

From: David Miller <davem at davemloft.net>
Date: Sat, 03 Nov 2007 16:15:20 -0700 (PDT)

> The Sparc code generator is too strict in it's tests
> for when just a 'sethi' can be used to load a constant.
> 'sethi' loads the top 22-bits of a 32-bit register with the given
> constant value.
> This patch corrects the test, so that we use 1 instruction
> instead of 2 more often.
> 2007-11-03  David S. Miller  <davem at davemloft.net>
> 	* sparc/sparc-codegen.h (sparc_set32, sparc_set): A plain sethi
> 	can be used if the constant value only has the top 22 bits set.


More information about the Mono-devel-list mailing list