FACTOID # 22: South Dakota has the highest employment ratio in America, but the lowest median earnings of full-time male employees.

 Home Encyclopedia Statistics States A-Z Flags Maps FAQ About

 WHAT'S NEW

SEARCH ALL

FACTS & STATISTICS    Advanced view

Search encyclopedia, statistics and forums:

(* = Graphable)

Encyclopedia > Arithmetic logic unit
A typical schematic symbol for an ALU: A & B are operands; R is the output; F is the input from the Control Unit; D is an output status

In computing, an arithmetic logic unit (ALU) is a digital circuit that performs arithmetic and logical operations. The ALU is a fundamental building block of the central processing unit of a computer, and even the simplest microprocessors contain one for purposes such as maintaining timers. The processors found inside modern CPUs and GPUs have inside them very powerful and very complex ALUs; a single component may contain a number of ALUs. Image File history File links ALU_symbol. ... Image File history File links ALU_symbol. ... A control unit is the part of a CPU or other device that directs its operation. ... For the formal concept of computation, see computation. ... Digital circuits are electric circuits based on a number of discrete voltage levels. ... Arithmetic tables for children, Lausanne, 1835 Arithmetic or arithmetics (from the Greek word Î±ÏÎ¹Î¸Î¼ÏŒÏ‚ = number) is the oldest and most elementary branch of mathematics, used by almost everyone, for tasks ranging from simple day-to-day counting to advanced science and business calculations. ... Logic (from Classical Greek Î»ÏŒÎ³Î¿Ï‚ logos; meaning word, thought, idea, argument, account, reason, or principle) is the study of the principles and criteria of valid inference and demonstration. ... CPU redirects here. ... A microprocessor is a programmable digital electronic component that incorporates the functions of a central processing unit (CPU) on a single semiconducting integrated circuit (IC). ... The central processing unit (CPU) is the part of a computer that interprets and carries out the instructions contained in the software. ... â€œGPUâ€ redirects here. ...

Mathematician John von Neumann proposed the ALU concept in 1945, when he wrote a report on the foundations for a new computer called the EDVAC. For other persons named John Neumann, see John Neumann (disambiguation). ... The EDVAC as installed in Building 328 at the Ballistics Research Laboratory. ...

## Early development GA_googleFillSlot("encyclopedia_square");

In 1946, von Neumann worked with his colleagues in designing a computer for the Princeton Institute of Advanced Studies (IAS). The IAS computer became the prototype for many later computers. In the proposal, von Neumann outlined what he believed would be needed in his machine, including an ALU. The IAS machine was the first electronic digital computer built by the Institute for Advanced Study (IAS), Princeton, NJ, USA. The paper describing the design of the IAS machine was edited by John von Neumann, (see Von Neumann architecture). ...

Von Neumann stated that an ALU is a necessity for a computer because it is guaranteed that a computer will have to compute basic mathematical operations, including addition, subtraction, multiplication, and division.[1] He therefore believed it was "reasonable that [the computer] should contain specialized organs for these operations."[2]

## Numerical systems

An ALU must process numbers using the same format as the rest of the digital circuit. For modern processors, that almost always is the two's complement binary number representation. Early computers used a wide variety of number systems, including one's complement, sign-magnitude format, and even true decimal systems, with ten tubes per digit. The twos complement of a binary number is the value obtained by subtracting the number from a large power of two (specifically, from 2N for an N-bit twos complement). ... In mathematics, negative numbers in any base are represented in the usual way, by prefixing them with a âˆ’ sign. ... In mathematics, negative numbers in any base are represented in the usual way, by prefixing them with a âˆ’ sign. ...

ALUs for each one of these numeric systems had different designs, and that influenced the current preference for two's complement, as this is the representation that makes it easier for the ALUs to calculate additions and subtractions.[citation needed] The twos complement of a binary number is the value obtained by subtracting the number from a large power of two (specifically, from 2N for an N-bit twos complement). ...

## Practical overview

A simple 2-bit ALU that does XOR, AND, OR, and addition (click image for an explanation)

Most of a processor's operations are performed by one or more ALU. An ALU loads data from input registers, executes, and stores the result into an output register. A Control Unit tells the ALU what operation to perform on the data. Other mechanisms move data between these registers and memory.[3] Image File history File links Size of this preview: 565 Ã— 599 pixelsFull resolution (2042 Ã— 2166 pixel, file size: 51 KB, MIME type: image/png) [[Category:]]== Summary == This ALU is a 2-bit ALU with two inputs (operands) named A and B: A[0] & B[0] is the least-significant bit... Image File history File links Size of this preview: 565 Ã— 599 pixelsFull resolution (2042 Ã— 2166 pixel, file size: 51 KB, MIME type: image/png) [[Category:]]== Summary == This ALU is a 2-bit ALU with two inputs (operands) named A and B: A[0] & B[0] is the least-significant bit... In computer architecture, a processor register is a small amount of very fast computer memory used to speed the execution of computer programs by providing quick access to frequently used valuesâ€”typically, these values are involved in multiple expression evaluations occurring within a small region on the program. ... A control unit is the part of a CPU or other device that directs its operation. ...

### Simple operations

Most ALUs can perform the following operations:

In computer science, the term integer is used to refer to any data type which can represent some subset of the mathematical integers. ... 3 + 2 = 5 with apples, a popular choice in textbooks[1] This article is about addition in mathematics. ... 5 - 2 = 3 (verbally, five minus two equals three) An example problem Subtraction is one of the four basic arithmetic operations; it is the inverse of addition. ... In mathematics, multiplication is an elementary arithmetic operation. ... In mathematics, especially in elementary arithmetic, division is an arithmetic operation which is the inverse of multiplication. ... In computer programming, a bitwise operation operates on one or two bit patterns or binary numerals at the level of their individual bits. ... Media:Example. ... The NOT gate is a digital logic gate that behaves according to the truth table to the right. ... // Function The OR gate is a digital logic gate that behaves according to the truth table to the right. ... This article is about XOR in the sense of an electronic logic gate (e. ... In computer programming, a bitwise operation operates on one or two bit patterns or binary numerals at the level of their individual bits. ... Sign extension is the operation, in computer arithmetic, of increasing the number of bits of a binary number while preserving the numbers sign (positive/negative). ...

### Complex operations

An engineer can design an ALU to calculate any operation, however complicated it is; the problem is that the more complex the operation, the more expensive the ALU is, the more space it uses in the processor, and the more power it dissipates, etc. Processor can mean: A central processing unit of a computer. ...

Therefore, engineers always calculate a compromise, to provide for the processor (or other circuits) an ALU powerful enough to make the processor fast, but yet not so complex as to become prohibitive. Imagine that you need to calculate the square root of a number; the digital engineer will examine the following options to implement this operation: Processor can mean: A central processing unit of a computer. ... Processor can mean: A central processing unit of a computer. ...

1. Design an extraordinarily complex ALU that calculates the square root of any number in a single step. This is called calculation in a single clock.
2. Design a very complex ALU that calculates the square root of any number in several steps. But--and here's the trick--the intermediate results go through a series of circuits that are arranged in a line, like a factory production line. That makes the ALU capable of accepting new numbers to calculate even before finished calculating the previous ones. That makes the ALU able to produce numbers as fast as a single-clock ALU, although the results start to flow out of the ALU only after an initial delay. This is called calculation pipeline.
3. Design a complex ALU that calculates the square root through several steps. This is called interactive calculation, and usually relies on control from a complex control unit with built-in microcode.
4. Design a simple ALU in the processor, and sell a separate specialized and costly processor that the customer can install just besides this one, and implements one of the options above. This is called the co-processor.
5. Tell the programmers that there is no co-processor and there is no emulation, so they will have to write their own algorithms to calculate square roots by software. This is performed by software libraries.
6. Emulate the existence of the co-processor, that is, whenever a program attempts to perform the square root calculation, make the processor check if there is a co-processor present and use it if there is one; if there isn't one, interrupt the processing of the program and invoke the operating system to perform the square root calculation through some software algorithm. This is called software emulation.

The options above go from the fastest and most expensive one to the slowest and least expensive one. Therefore, while even the simplest computer can calculate the most complicated formula, the simplest computers will usually take a long time doing that because several of the steps for calculating the formula. A control unit is the part of a CPU or other device that directs its operation. ... A microprogram is a program consisting of microcode that controls the different parts of a computers central processing unit (CPU). ... Processor can mean: A central processing unit of a computer. ... Processor can mean: A central processing unit of a computer. ... A co-processor is a secondary processor in a computer that handles tasks that the general-purpose CPU either cannot implement, or does not implement for efficiency reasons. ... This article is about emulation in computer science. ... This article is about emulation in computer science. ... A co-processor is a secondary processor in a computer that handles tasks that the general-purpose CPU either cannot implement, or does not implement for efficiency reasons. ... Processor can mean: A central processing unit of a computer. ... A co-processor is a secondary processor in a computer that handles tasks that the general-purpose CPU either cannot implement, or does not implement for efficiency reasons. ... In computing, an interrupt is an asynchronous signal from hardware or software indicating the need for attention. ... An operating system (OS) is the software that manages the sharing of the resources of a computer and provides programmers with an interface used to access those resources. ...

Powerful processors like the Intel Core and AMD64 implement option #1 for several simple operations, #2 for the most common complex operations and #3 for the extremely complex operations. That is possible by the ability of building very complex ALUs in these processors. This article is about the Intel mobile processor family. ... AMD64 Logo AMD64 (also x86-64 or x64) is a 64-bit microprocessor architecture and corresponding instruction set designed by Advanced Micro Devices. ... A CPU The processor sub-system of a data processing system processes received information after it has been encoded into data by the input sub-system. ...

### Inputs and outputs

The inputs to the ALU are the data to be operated on (called operands) and a code from the control unit indicating which operation to perform. Its output is the result of the computation. In mathematics, an operand is one of the inputs (arguments) of an operator. ... A control unit is the part of a CPU or other device that directs its operation. ...

In many designs the ALU also takes or generates as inputs or outputs a set of condition codes from or to a status register. These codes are used to indicate cases such as carry-in or carry-out, overflow, divide-by-zero, etc.[4] A status register (also: flag register or condition code register (CCR)) is a collection of flag bits for a processor that indicates own unique FLAGS register. ... The term carry may refer to: A violation whilst dribbling in the game of basketball. ... Look up Overflow in Wiktionary, the free dictionary. ... For the album by Hux Flux, see Division by Zero (album). ...

### ALUs vs. FPUs

A Floating Point Unit also performs arithmetic operations between two values, but they do so for numbers in floating point representation, which is much more complicated than the two's complement representation used in a typical ALU. In order to do these calculations, a FPU has several complex circuits built-in, including some internal ALUs. A floating point unit (FPU) is a part of a computer system specially designed to carry out operations on floating point numbers. ... A floating-point number is a digital representation for a number in a certain subset of the rational numbers, and is often used to approximate an arbitrary real number on a computer. ... The twos complement of a binary number is the value obtained by subtracting the number from a large power of two (specifically, from 2N for an N-bit twos complement). ... A floating point unit (FPU) is a part of a computer system specially designed to carry out operations on floating point numbers. ...

Usually engineers call an ALU the circuit that performs arithmetic operations in integer formats (like two's complement and BCD), while the circuits that calculate on more complex formats like floating point, complex numbers, etc. usually receive a more illustrious name. The integers are commonly denoted by the above symbol. ... The twos complement of a binary number is the value obtained by subtracting the number from a large power of two (specifically, from 2N for an N-bit twos complement). ... In computing and electronic systems, binary-coded decimal (BCD) is an encoding for decimal numbers in which each digit is represented by its own binary sequence. ... A floating-point number is a digital representation for a number in a certain subset of the rational numbers, and is often used to approximate an arbitrary real number on a computer. ... The complex numbers are an extension of the real numbers, in which all non-constant polynomials have roots. ...

## See also

The 7400 chip, containing four NANDs. ... The 74S181 4 bit ALU bitslice resting on a page from the datasheet. ... In electronics, an adder is a device which will perform the addition, S, of two numbers. ... In digital design, a multiplier or multiplication ALU is a hardware circuit dedicated to multiplying two binary values. ... Digital circuits are electric circuits based on a number of discrete voltage levels. ... Several algorithms exist to perform division in digital designs. ...

## Notes

1. ^ Stallings page 19
2. ^ Stallings page 19
3. ^ Stallings page 290-291
4. ^ Stallings page 290-291

## References

William Stallings is an American computer scientist, best known for his textbooks on computer science topics such as operating systems, computer networks, computer organization, and cryptography. ...

Results from FactBites:

 Arithmetic and Logical Unit: Definition and Links by Encyclopedian.com (222 words) An Arithmetic and Logical Unit (ALU) is one of the core components of all Central Processing Units. For these calculations a separate component, such as a divider or Floating Point Unit (FPU), is often used, although it is also possible that a microcode program may use the ALU to emulate these operations. The ALU takes as inputs the data to be operated on and a code from the control unit indicating which operation to perform, and for output provides the result of the computation.
More results at FactBites »

 COMMENTARY Post Reply

Share your thoughts, questions and commentary here
 Your name Your comments

Want to know more?
Search encyclopedia, statistics and forums:

Press Releases |  Feeds | Contact
The Wikipedia article included on this page is licensed under the GFDL.
Images may be subject to relevant owners' copyright.
All other elements are (c) copyright NationMaster.com 2003-5. All Rights Reserved.
Usage implies agreement with terms, 1022, m