SPARC: unsigned vs. signed int loads

John Rose John.Rose at Sun.COM
Wed Feb 11 11:56:36 PST 2009


On Feb 11, 2009, at 8:35 AM, Christian Thalinger wrote:

> Is there a reason why HotSpot does zero-extended int loads?

As Paul said there's a cycle savings on some systems--on  SPARC.

The register allocator is able to express "useful payload in low 32  
bits, garbage in upper 32 bits", as a consequence of its using a 32- 
bit unit of storage uniformly.  (The 64-bit registers are pairs of  
allocator units, on all CPUs.)  This is the normal state for a C2  
register on a mixed 32/64 system (i.e., SPARC V8plus).  Intel systems  
are either all-32-bit or all-64-bit, so the distinction is less  
interesting here, I guess.

-- John

P.S. This touches on why 128-bit vectors are a tricky addition, as I  
pointed out earlier.



More information about the hotspot-compiler-dev mailing list