Actually, the reason I vote for ‘unsigned’ is to use a “base” machine type. I think for parameters and local variables (i.e. stuff that ideally lives in registers and not memory) it’s better.
Yes, but if you use int16 as an argument, you force the machine to compute on 16 bits. On x86, it’s relatively OK, there are 16-bit opcodes for everything since it started as a 16-bit ISA. But on ARM, PPC or other machines, the compiler may end up emitting additional code (things like “zero extend” or “sign extend” instructions) to make sure you only observe 16-bit values. So int16 makes sense for a struct field or a pointer type, rarely for parameters or locals. It does not hurt that much either, though. Christophe
|
_______________________________________________ Spice-devel mailing list Spice-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/spice-devel