SPARC: unsigned vs. signed int loads
Paul Hohensee
Paul.Hohensee at Sun.COM
Wed Feb 11 08:41:44 PST 2009
Signed loads require a shifter or mux in the load path, so they can cost
an extra cycle.
I think we also use ldub for boolean loads.
paul
Christian Thalinger wrote:
> Hi all!
>
> Still working on 6797305, I recently was looking (again) closer at the
> load instructions in sparc.ad and I noticed that byte and short loads do
> a sign extend (ldsb and ldsh) while int loads do not (lduw).
>
> In CACAO we did fully 64-bit signed extended loads on Alpha and SPARC64
> so we could omit I2L conversions.
>
> Is there a reason why HotSpot does zero-extended int loads?
>
> -- Christian
>
>
More information about the hotspot-compiler-dev
mailing list