Is there any existing CPU implementation which uses one's complement?

4

1

Programming languages like Ada or VHDL define an integer datatype as -2^31+1 to 2^31-1. This rule goes back to CPUs with an one's complement ALU. It allows the program to run on one's and two's complement machines with the same behavior.

So is there any existing CPU implementation which uses one's complement?

Paebbels

Posted 2016-10-20T19:33:28.863

Reputation: 170

Answer: Not likely to be any. Please see https://en.wikipedia.org/wiki/Two%27s_complement for more detail.

– Hannu – 2016-10-20T19:58:09.903

You can create a datatype for 1's complement easily enough in most programming languages. It would basically be 2's complement but the value would be converted to 1's complement. – Ramhound – 2016-10-20T20:43:28.210

But for Ada and VHDL, you can't use -2^31 as a number in some language implementations, even if the underlying system supports it. The idea is to drop the restriction from the VHDL standard. – Paebbels – 2016-10-20T20:47:35.063

1

There is probably some ClearPath Dorado hardware still running and certainly systems are still on the market using emulation on top of Intel x86 processors (PDF: "The Dorado 8300 Series is one more example of Unisys commitment ... A key element of this initiative is the integration of market-leading technology, such as the latest Intel processor platforms").

– Paul A. Clayton – 2016-10-21T02:36:26.707

@Hannu network protocols use one's complement so it's possible that CPUs used in routers are one's complement – phuclv – 2017-06-08T09:46:52.350

Plenty of Dorado systems out there. And still being made and sold. – Marc Wilson – 2017-07-21T18:39:37.573

Answers

5

Unisys 1100/2200 legacy systems use 1's complement arithmetic, and this continues in the newer Dorado series.

Rather than there "perhaps" being some still in use, they are being actively developed and have scored some 7-figure sales in recent years.

Increasingly, the microcode is now emulated using commodity hardware rather than the expensive ECL (Emitter-Coupled Logic) that older processors used, but the bangs-per-buck hasn't made it to the top of the range yet, and big banks etc are still using the big iron.

E.g. Lloyds Banking Group's core banking system runs on a 32-processor cluster of Dorado processors, and Nationwide Building Society also did a tech refresh in recent years.

The Met police use this tech for their CAD (Computer Aided Despatch) system too.

Other big users include the New York state welfare system, Nike, Subaru, NATO....

Marc Wilson

Posted 2016-10-20T19:33:28.863

Reputation: 146

1Oh, and the -0 value has an important use on Unisys systems; it's a value that can never result from an arithmetic operation in the CPU, so it's often used as a flag value. – Marc Wilson – 2017-07-21T18:41:17.340