lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

On Fri, Aug 21, 2015 at 05:03:53PM -0300, Roberto Ierusalimschy wrote:
> > In other words, just because the machine uses ones' complement doesn't mean
> > there's a negative 0. [...]
> Is there any machine nowadays that use ones' complement?

Not that I'm aware of, other than the Unisys mentioned by Jay Carlson. But I
think sometime in the past few years Unisys replaced the ASICs with software
emulation on Intel Xeons, although I can't remember where I read that.

Here's a manual to the C compiler for ClearPath OS 2200.

	"UCS C represents an integer in 36-bit ones complement form (or
	72-bit ones complement form, if the long long type attribute is
	specified)." Volume 1 Section 6.1.1.

The MCP mainframe line (previously Burroughs) uses signed-magnitude.

	"Integer type representation differs between A Series C and C
	language on most other machines. A Series C uses a signed-magnitude
	representation for integers instead of two's-complement
	representation." Volume 1 p C-8.

Intel's new MPX extension uses ones' complement for storing address bounds,
but that's not as relevant.