Difference between revisions of "Central processing unit"

From Conservapedia
Jump to navigation Jump to search
m (Slight correction)
 
(11 intermediate revisions by 4 users not shown)
Line 5: Line 5:
  
 
A microprocessor is '''any''' processor implemented on a single integrated circuit, however most microprocessors are CPUs. The largest producer of microprocessors used in general-purpose computers is [[Intel]].
 
A microprocessor is '''any''' processor implemented on a single integrated circuit, however most microprocessors are CPUs. The largest producer of microprocessors used in general-purpose computers is [[Intel]].
 +
 
== Operation ==
 
== Operation ==
−
The basic operation of a CPU is the "Fetch, Decode, Execute" cycle.<ref>[http://www.it.jcu.edu.au/Subjects/cp1300/resources/lectnotes/system/fde.html Fetch-Decode-Execute Cycle]</ref>  The ''instruction fetcher'' fetches instructions from memory.  The ''control logic'' decodes and executes the instruction.  The ALU is used to perform arithmetic and logical operations such as adding a value in memory to a value in a register and storing the result in another register.  On some CPUs, some instructions may require additional fetches from memory (e.g., to get or store operands).  A program in memory is executed sequentially, with each instruction stored in a different memory location.  The instruction pointer (IP) register keeps tracks of the current program position, and is updated (usually incremented) after each CPU cycle.
+
The basic operation of a CPU is the "Fetch, Decode, Execute" cycle.<ref>[http://www.it.jcu.edu.au/Subjects/cp1300/resources/lectnotes/system/fde.html Fetch-Decode-Execute Cycle]</ref>  The ''instruction fetcher'' fetches instructions from memory.  The ''control logic'' decodes and executes the instruction.  The [[ALU]] is used to perform arithmetic and logical operations such as adding a value in memory to a value in a register and storing the result in another register.  On some CPUs, some instructions may require additional fetches from memory (e.g., to get or store operands).  A program in memory is executed sequentially, with each instruction stored in a different memory location.  The instruction pointer (IP) register keeps tracks of the current program position, and is updated (usually incremented) after each instruction is executed.
 +
 
 +
== Architecture ==
 +
A CPU's architecture distinguishes it from other CPUs.  There are many aspects of CPU architecture.
 +
 
 +
===Data size===
 +
CPUs are defined by the number of bits that can be handled in a single operation.  For instance, a 16-bit CPU handles 2 bytes of data with most of its operations.  The amount of data that can be transferred to and from memory is this number of bits, which determines the width of memory required for a given CPU.  Most CPUs on the market today are 64-bit CPUs.  Operations can be performed on larger or smaller numbers of bits, but such operations tend to run more slowly because the CPU is optimized for it's native data size.
 +
 
 +
===Registers===
 +
Register sets are essentially a small amount of memory within the CPU, divided into a discrete number of registers.  There are general-purpose registers that can be used by programs and special-purpose registers that are restricted to certain functions.  General purpose registers are the native data size of the CPU.  Thus a 32-bit CPU will have 32-bit wide general-purpose registers.  Special-purpose registers are used to store flags indicating the result of arithmetic or logical operations, index into memory, and so forth.  Typical registers used for indexing into memory were the Instruction Pointer (IP) - sometimes called the Program Counter (PC) - and the Stack Pointer (SP).  Such registers which contain memory addresses tend to be twice the size of the CPU's data size.  Thus, the IP on an 8-bit CPU was 16-bits, and the IP on a 16-bit CPU was 32-bits.
  
−
==Prescient Quotes on Police State Hardware Surveillance==
+
===Instruction Set===
−
* "The progress of [[science]] in furnishing the [[big government|government]] with means of [[espionage]] is not likely to stop with [[wiretap]]ping. Ways may some day be developed by which the [[Police state|government]], without removing papers from [[hard disk|secret drawers]], can reproduce them in [[Foreign Intelligence Surveillance Court|court]], and by which it will be enabled to expose to a [[jury]] the most intimate occurrences of the home. Advances in the [[computer science|psychic and related sciences]] may bring means of exploring unexpressed beliefs, thoughts and emotions. 'That places the [[liberty]] of every [[citizen|man]] in the hands of every [[tyrant|petty officer]]' was said by James Otis of much lesser [[tyranny|intrusions]] than these. 1 To Lord Camden a far slighter intrusion seemed '[[subversive]] of all the comforts of society.' Can it be that the [[Constitution]] affords no [[Right to Privacy|protection]] against such invasions of [[Fourth Amendment|individual security]]?"
+
The instruction set of a given CPU model defines the basic operations that can be performed by the CPU.  These operations tend to be simple, such as adding two numbers, outputting a character, or moving data between registers.  In a given line of processors, the instruction sets are compatible, although as the newer models are released, they usually had additional instructions added.  Thus, newer processors were backwards compatible (meaning they could run the same programs as older processors), but older processors did not recognize the new instructions added to later models. Between processor lines, there is no compatibility. The instructions are stored in memory as "machine code" which are bit patterns that represent certain instructions. These bit patterns represent entirely different operations on different processor lines, which means that a program written for one CPU will not run on a different CPU line.
−
** [[Louis Brandeis]]''' (1856-1941), [[United States Supreme Court]] [[Associate Justice]] Dissenting, ''[[Olmstead v. United States]]'', 277 U.S. 438 (1928).
 
  
 +
There are two aspects to an instruction set.
 +
* Orthogonality: An instruction set is considered "orthogonal" if the instructions work with all general-purpose registers.  Instruction sets which limit certain instructions to certain registers are not considered orthogonal.  In reality, instruction sets fall somewhere along a spectrum between complete orthogonality and non-orthogonality.  The [[PDP-11]] has an example of an orthogonal instruction set.
 +
* RISC/CISC:  Reduced Instruction Set Computers (RISC) have fewer instructions than Complex Instruction Set Computers (CISC), which requires more instructions to complete the same task than on CISC processors.  The advantage to RISC instruction sets is that they can be implemented with fewer transistors, which allows faster instruction execution in theory.  In practice, the clock rate is the same on RISC and CISC CPUs.  However, more cores can be fit into a given semiconductor space with a RISC architecture. ARM processors are examples of RISC CPUs.  Intel iAPX processors are examples of CISC CPUs.
  
−
==See Also==
+
==See also==
 
* [[Moore's Law]]
 
* [[Moore's Law]]
−
* [[Tails (operating system)|Tails Anonymous Secure Operating System]]
 
−
* [[Linux]]
 
 
* [[IBM]], [[HP]], [[Dell]] and [[Microsoft]] [[Windows]]
 
* [[IBM]], [[HP]], [[Dell]] and [[Microsoft]] [[Windows]]
−
* [[Apple Computer]] [[Mac OS]] for [[Apple Macintosh]]
 
 
* [[Mobile device]]s: [[Smartphone]]s and [[tablet computer|tablets]]
 
* [[Mobile device]]s: [[Smartphone]]s and [[tablet computer|tablets]]
−
* [[Apple Computer|Apple]] [[iOS]] for [[iPhone]]-[[iPod]]-[[iPad]]
 
−
* [[Android (operating system)|Android]]
 
−
* [[BlackBerry OS|Blackberry]]
 
−
* [[Microsoft]] [[Windows Phone]] with [[Windows 8]]
 
−
----
 
−
* [[Duck Duck Go]] - [[Privacy]]-oriented [[Search engine]]
 
−
* [[Google]], [[Yahoo]] and [[Bing]]
 
−
----
 
−
* '''[[Censorship]]:'''  [[Tools of censorship]], [[Censorability]], [[Fairness Doctrine]], [[Liberal censorship]], [[Media censorship]]
 
−
----
 
−
* '''[[Perpetual war | The Perpetual War]]:''' [[War on Drugs]], [[War on Terror]] and the [[Police state]]
 
−
* '''Domestic [[Mass surveillance | Mass Surveillance]] of Law-Abiding [[Citizen]]s:'''  via [[Utah Data Center]], [[PRISM]], [[NSA]]-[[DHS]]-[[BATF]]-[[FBI]]-[[CIA]] and other [[Intelligence agency | Intelligence agencies]]' [[Computer surveillance]], [[Eavesdropping]], [[Data mining]], [[Spyware]], [[Wiretap]] - [[Roving wiretap]], [[Foreign Intelligence Surveillance Act]] of the [[Foreign Intelligence Surveillance Court]], [[NSA warrantless surveillance controversy]], [[National security letter]], [[Patriot Act]], [[NDAA]], [[Executive Order]]s, [[United States Census]], [[Common Core]], "[[Stasi]]"-like [[secret police]] "[[If You See Something, Say Something]]" [[informant]]s, and other exponential expansion of the [[Police State]]
 
−
* '''[[Asset forfeiture | Asset Forfeiture]]:''' [[Confiscation]] for [[Police]] [[budget deficit]] via [[RICO]]
 
−
* '''[[Militarization of police | Militarization of Police]]:''' [[SWAT]] and [[Pre-dawn raid | Pre-dawn]] [[No-knock raid]]s, [[Sneak and peek warrant]]
 
−
* '''[[War on Drugs]]:''' [[Addiction]] and [[Drug trafficking]] of the [[Drug cartel]]s, [[Mafia]], [[Gangs]], [[Drug dealer]]s, [[Hollywood values]] - [[Fashion industry values]] - [[Public school values]] - [[Professor values]]
 
−
* '''[[Computer crime | Computer Crime]] and [[Cyberwarfare]]:'''
 
−
** '''[[Hackers]]:''' [[China]], [[Russia]] and others
 
−
** [[Bradley Manning]] - [[Homosexual]] [[Hacker]] [[Traitor]] of [[State secret]]s
 
−
** [[Wikileaks]] and [[Julian Assange]] - [[Australia]]n [[leftist]] [[hacker]]
 
−
* '''Dangers of [[Social media | Social Media]]:''' Facebook, Twitter, [[Google | Google Plus]], [[YouTube]], [[Yahoo]]
 
−
* '''[[Big government | Big Government]]''': [[Liberal values|Liberal]] [[ObamaCare]]-[[Common Core]]-[[Social Security]] [[Welfare state]] leads to [[Nanny state]], leads to [[Gun control]], [[Militarization of police]], [[Asset forfeiture]] and Domestic [[mass surveillance]] of law-abiding [[citizen]]s via the '''[[Police state]]''': [[Globalist]]-[[United Nations]]-[[Statist]]-[[Socialist]]-[[National Socialist]]-[[Communist]]
 
−
* '''[[Liberal totalitarianism|Liberal Totalitarianism]]'''
 
  
 +
==References==
 +
{{reflist|2}}
  
−
'''Contrast with:'''
+
==External links==
−
 
+
*[http://computer.howstuffworks.com/microprocessor.htm How Microprocessors Work]
−
* '''[[Security]] [[Software]] and [[Security-focused operating systems | Security-Focused Operating Systems]]''' to protect [[unalienable rights | unalienable]] [[Fifth Amendment]] - [[Fourth Amendment]] [[Right to Privacy]] ([[Internet privacy]], [[Information privacy]], [[Expectation of privacy]]) and [[Second Amendment]] - [[First Amendment]] ([[Freedom of information]] and [[Political freedom]]) rights against [[unconstitutional]] [[Gun control]] - [[Internet censorship]] [[Big government]] [[Police state]], [[hackers]], and "[[5 U.S.C. § 3331|all enemies, foreign and domestic]]" of [[American values | American]] [[liberty]].
+
* https://prism-break.org/en
−
** '''[[Anonymity]] with [[Tails (operating system)|Tails Operating System]]''': [[Linux]]-based with [[Tor (anonymity network)]],  [[Firefox]] [[Iceweasel]] [[browser]], [[HTTPS Everywhere]] [[encryption]]
+
* https://www.eff.org - "Leading the fight against the [[NSA]]'s illegal [[mass surveillance]] program"
−
** '''[[Prism-break.org|Prism-Break.org]]''': Opt out of global data [[surveillance]] programs like [[PRISM]], [[ECHELON]], [[XKeyscore]] and [[Tempora]].<ref>"Help make [[mass surveillance]] of entire populations uneconomical! We all have an [[unalienable right]] to [[privacy]], which you can exercise today by [[encrypting]] your communications and ending your reliance on proprietary products and services."</ref>
+
* https://www.eff.org/secure-messaging-scorecard
−
** '''[[Open source | Open Source]] [[Free software]]''' not over-priced tracking by [[Microsoft]]-[[Apple]]-[[Google]]-[[Android]]
+
* http://justdelete.me
−
* '''[[Privacy search engines | Privacy Search Engines]]: [[Duck Duck Go]]''' and [[Ixquick]]: [[Privacy]]-oriented [[Search engine]]s instead of tracking by [[Google]], [[Yahoo]] and [[Bing]]
+
* http://lifehacker.com/just-delete-me-is-a-massive-list-of-links-to-close-all-1245040101
−
* '''[[Internet anonymity | Internet Anonymity]] - [[Right to be forgotten]] [[Pseudonymity]]''' ([[Pseudonym]]) using [[Anonymous web browsing]] with [[Tails]] and [[VPN]] ([[Virtual Private Network]]), [[HMA]], [[OpenVPN]] and [[IPsec]] , [[Proxy server]]s, [[Anonymizer]] ([[Anonymous proxies]])
+
* [http://epic.org/privacy/privacy_resources_faq.html Online Guide to Privacy Resources]
−
** '''[[Mozilla Firefox]]''' with [[Browser extension]]s instead of [[Microsoft]] [[Internet Explorer]], [[Google Chrome]], [[Safari (web browser)]] and [[Opera (web browser)]]
+
* http://www.nocards.org
−
** '''[[Browser security | Browser Security]]''' via [[HTTPS Everywhere]] ([[HTTPS]] ([[HTTP Secure]]) instead of [[Plaintext]] ([[Cleartext]]) [[HTTP]]; and [[NoScript]] to stop [[JavaScript]]
 
−
** '''[[Ad filtering | Ad Filtering]]''' ([[Privacy mode]] and [[Adblock Plus]] or [[Ghostery]]) to stop [[Ad tracking]] - [[Website visitor tracking]] via [[Geolocation]], [[Geotargeting]], [[Personally identifiable information]] and [[Device fingerprint]]s
 
−
* '''[[Internet safety | Internet Safety]], [[Computer security | Computer Security]] via [[Password strength]] and [[Password manager]]s''' via [[KeePass]] or [[LastPass]] and [[Antivirus]]-[[Firewall]]
 
−
* '''[[Secure communication | Secure Communication]]:'''
 
−
** '''[[E-mail privacy | E-mail Privacy]] and [[Email encryption | Email Encryption]]:''' [[Claws Mail]] or [[Enigmail]] or [[Kontact]] using [[Hushmail]] or [[MyKolab]], [[Anonymous remailer]], instead of tracking by [[Microsoft Outlook]], [[Mozilla Thunderbird]] using [[Yahoo! Mail]], [[Gmail]] [[iCloud]]
 
−
** '''[[Secure messaging | Secure Messaging]] and [[Off-the-Record Messaging]] via [[I2P]]''' [[Instant messaging]], [[Cryptocat]], [[Bitmessage]] instead of [[Skype]], [[Yahoo! Messenger]], [[Internet Relay Chat]], [[Google Plus]], Facebook
 
−
** '''[[Silent Phone]] with [[Silent Circle]]''' instead of [[Android]] or [[iPhone]] [[Smartphone]]
 
−
** '''[[OPSEC]]:''' "[[Loose lips sink ships]]"
 
−
* '''[[Encryption]]:''' [[Encryption software]], [[Disk encryption software]], [[LUKS]] or [[TrueCrypt]] instead of [[Microsoft]] [[BitLocker]],  [[PGP]] and [[GNU Privacy Guard]], [[Data encryption]], [[Public-key encryption]], [[Cryptography]]-[[Cryptanalysis]]-[[Cryptology]]-[[Steganography]]
 
−
* '''[[Peer-to-peer | Peer-to-Peer]]:''' [[Sneakernet]], [[Friend-to-friend]], [[Darknet (file sharing)]], [[Anonymous P2P]] instead of [[BitTorrent]]
 
−
* '''[[Deep Web]] - [[Dark Internet]]:''' [[Tor]], [[AmRD]], [[Tor2web]], [[The Hidden Wiki]], [[Anonymous blog]]
 
−
* '''[[Cryptocurrency]]-[[Digital currency | Digital Currency]]-[[Alternative currency | Alternative Currency]]-[[Virtual currency | Virtual Currency]]: [[Bitcoin]]''' and [[Hard money]]-[[Precious metals]]-[[Tangibles]] versus [[PayPal]], [[Credit cards]] and [[inflation]]-prone [[Dollar (U.S.)|U.S. Dollars]]: [[Federal Reserve System]]'s [[Keynesian economics]] [[Ponzi scheme]] of [[Quantitative easing]]-[[Debt monetization]] [[devaluation]] of [[Fiat currency]] through [[Money supply]]-[[Treasury bill]]s bought mostly by [[China]] and [[Japan]]
 
−
----
 
−
* '''[[Privacy resources | Privacy Resources]]:'''
 
−
** ''[[Hologram of Liberty]]'' - The Constitution's Shocking Alliance With Big Government by [[Boston T. Party]] - [[Kenneth W. Royce]]
 
−
** ''[[One Nation, Under Surveillance]] - Privacy From the Watchful Eye'' by [[Boston T. Party]]
 
−
** ''[[How to Be Invisible]] - Protect Your Home, Your Children, Your Assets, and Your Life'', by [[J. J. Luna]]
 
−
** '''[[Electronic Frontier Foundation]]''' and [[Electronic Privacy Information Center]], [[Oath Keepers]], [[Judicial Watch]]
 
−
** '''[[Freedom of Information Act]]''', [[Electronic Communications Privacy Act]] of 1986 and [[Privacy Act of 1974]]
 
−
** '''[[Edward J. Snowden]] Revelations''' of [[unconstitutional]] domestic spying on law-abiding [[American]] [[citizen]]s; [[GlobaLeaks]]
 
−
----
 
−
* '''[[Crypto-libertarianism]] [[Limited government]]''' implies: [[Conservative values]]/[[Traditional values]] - [[Modern conservatism]] - [[Preparedness | Modern preparedness]] are the original [[American]] [[Patriot]] [[Founding Fathers]]' values
 
−
** [[Capitalism]] and [[Free enterprise]]
 
−
** [[Family values]] and [[Parental rights]]: [[Sanctity of life]], [[Family]]-[[Marriage]], [[Homeschooling]] teaching [[Virtue]], [[Patriotism]], [[Duty]], and [[Self-reliance]]
 
−
 
 
−
 
 
−
==External Links==
 
 
* https://charlescarrollsociety.com/2013/06/10/prism-yes-they-can
 
* https://charlescarrollsociety.com/2013/06/10/prism-yes-they-can
 
* https://charlescarrollsociety.com/2013/05/06/memo-to-the-police-state-progressives-please-let-his-people-go
 
* https://charlescarrollsociety.com/2013/05/06/memo-to-the-police-state-progressives-please-let-his-people-go
Line 85: Line 47:
 
* https://charlescarrollsociety.com/2014/02/12/amrd-t-a-i-l-s-plastic-gloves-for-your-computer-american-redoubt - [[Tails operating system]]
 
* https://charlescarrollsociety.com/2014/02/12/amrd-t-a-i-l-s-plastic-gloves-for-your-computer-american-redoubt - [[Tails operating system]]
 
* https://charlescarrollsociety.com/2014/01/29/amrd-introducing-the-tor-browser-bundle/ - [[Tor browser]]
 
* https://charlescarrollsociety.com/2014/01/29/amrd-introducing-the-tor-browser-bundle/ - [[Tor browser]]
−
* https://prism-break.org/en - "Opt out of global data surveillance programs like [[PRISM]], [[XKeyscore]] and [[Tempora]]."<ref>"Help make [[mass surveillance]] of entire populations uneconomical. We all have a [[right to privacy]], which you can exercise today by [[encrypt]]ing your communications and ending your reliance on proprietary services."</ref>
 
−
* https://www.eff.org - "Leading the fight against the [[NSA]]'s illegal [[mass surveillance]] program"<ref>"Organization formed in 1990 to maintain and enhance intellectual freedom, privacy, and other values of civil liberties and democracy in networked communications. Publishes newsletters, Internet Guidebooks and other documents, provides mailing lists and other online forums, and hosts a large electronic document archive. Contact: info@eff.org. 454 Shotwell Street, San Francisco, CA 94110-1914. Tel: (415) 436-9333. Fax: (415) 436-9993. Executive Director: Sheryl Steele."</ref>
 
−
* https://www.eff.org/secure-messaging-scorecard
 
−
* http://justdelete.me
 
−
* http://lifehacker.com/just-delete-me-is-a-massive-list-of-links-to-close-all-1245040101
 
−
* [http://epic.org/privacy/privacy_resources_faq.html Online Guide to Privacy Resources]<ref>"EPIC was established in 1994 to focus public attention on emerging privacy issues relating to the National Information Infrastructure, such as the Clipper Chip, the Digital Telephony proposal, medical records privacy and the sale of consumer data. EPIC conducts litigation, sponsors conferences, produces reports, publishes the EPIC Alert and leads campaigns on privacy issues. For more information email: epic-info@epic.org, or contact EPIC, 1718 Connecticut Avenue, NW, Suite 200, Washington, DC 20009. Tel: (202) 483-1140. Executive Director: Marc Rotenberg."</ref>
 
−
* http://www.nocards.org - [[Coalition Against Unsolicited Commercial Email]]<ref>"CAUCE is an all volunteer, entirely web-based organization, created by Netizens to advocate for a legislative solution to the problem of UCE (spam). CAUCE began as a discussion group called SPAM-LAW, formed of members who felt that legislation was necessary to stop spam from choking the life out of the Internet. In 1997 CAUCE proposed an amendment to the Federal statute which outlaws junk "faxes" (47 USC 227) to also prohibit junk e-mail, and since then has remained a pre-eminent voice in the anti-spam community. Email: comments@cauce.org. President: Edward Cherlin."</ref>
 
−
 
−
 
−
==References==
 
−
{{reflist|2}}
 
  
 
[[Category:American Inventions]]
 
[[Category:American Inventions]]
−
[[Category:Cryptography]]
+
[[Category:Information Technology]]
−
[[Category:Technology]]
 
−
[[Category:Information technology]]
 
 
[[Category:Computer Science]]
 
[[Category:Computer Science]]
−
 
−
 
−
== External links ==
 
−
*[http://computer.howstuffworks.com/microprocessor.htm How Microprocessors Work]
 
−
 
−
[[Category:Computers]]
 
 
[[Category:Electrical Engineering]]
 
[[Category:Electrical Engineering]]

Latest revision as of 23:32, July 24, 2020

Block Diagram of a simple CPU

A Central Processing Unit (CPU) is the main control mechanism of a computer, containing control logic, registers, and arithmetic logic unit (ALU) as well as a memory interface. Some CPUs implement additional functionality, but often other capabilities are provided through peripheral processors that handle such things as input/output (I/O), floating-point arithmetic, and vector processing. All computers contain at least one CPU, but some contemporary computers contain over 1,000.

The purpose of a CPU is to execute programs. Programs are a series of numeric values, where each value indicates a specific operation. Each value is referred to as an instruction, and has a corresponding mnemonic for programming convenience. These values are known as machine code. All of the instructions that can be executed by a CPU are collectively known as the CPU's instruction set. Different CPU models usually implement completely different instruction sets, so that programs written for one CPU will not execute on a different one. Writing programs in machine code is difficult, so programs called assemblers were written to translate mnemonics into machine code, thus increasing the speed of writing, and the reliability of, programs. Since the 1960s, most programs have been written using a Programming Language, which are even easier to use than an assembler.

A microprocessor is any processor implemented on a single integrated circuit, however most microprocessors are CPUs. The largest producer of microprocessors used in general-purpose computers is Intel.

Operation

The basic operation of a CPU is the "Fetch, Decode, Execute" cycle.[1] The instruction fetcher fetches instructions from memory. The control logic decodes and executes the instruction. The ALU is used to perform arithmetic and logical operations such as adding a value in memory to a value in a register and storing the result in another register. On some CPUs, some instructions may require additional fetches from memory (e.g., to get or store operands). A program in memory is executed sequentially, with each instruction stored in a different memory location. The instruction pointer (IP) register keeps tracks of the current program position, and is updated (usually incremented) after each instruction is executed.

Architecture

A CPU's architecture distinguishes it from other CPUs. There are many aspects of CPU architecture.

Data size

CPUs are defined by the number of bits that can be handled in a single operation. For instance, a 16-bit CPU handles 2 bytes of data with most of its operations. The amount of data that can be transferred to and from memory is this number of bits, which determines the width of memory required for a given CPU. Most CPUs on the market today are 64-bit CPUs. Operations can be performed on larger or smaller numbers of bits, but such operations tend to run more slowly because the CPU is optimized for it's native data size.

Registers

Register sets are essentially a small amount of memory within the CPU, divided into a discrete number of registers. There are general-purpose registers that can be used by programs and special-purpose registers that are restricted to certain functions. General purpose registers are the native data size of the CPU. Thus a 32-bit CPU will have 32-bit wide general-purpose registers. Special-purpose registers are used to store flags indicating the result of arithmetic or logical operations, index into memory, and so forth. Typical registers used for indexing into memory were the Instruction Pointer (IP) - sometimes called the Program Counter (PC) - and the Stack Pointer (SP). Such registers which contain memory addresses tend to be twice the size of the CPU's data size. Thus, the IP on an 8-bit CPU was 16-bits, and the IP on a 16-bit CPU was 32-bits.

Instruction Set

The instruction set of a given CPU model defines the basic operations that can be performed by the CPU. These operations tend to be simple, such as adding two numbers, outputting a character, or moving data between registers. In a given line of processors, the instruction sets are compatible, although as the newer models are released, they usually had additional instructions added. Thus, newer processors were backwards compatible (meaning they could run the same programs as older processors), but older processors did not recognize the new instructions added to later models. Between processor lines, there is no compatibility. The instructions are stored in memory as "machine code" which are bit patterns that represent certain instructions. These bit patterns represent entirely different operations on different processor lines, which means that a program written for one CPU will not run on a different CPU line.

There are two aspects to an instruction set.

  • Orthogonality: An instruction set is considered "orthogonal" if the instructions work with all general-purpose registers. Instruction sets which limit certain instructions to certain registers are not considered orthogonal. In reality, instruction sets fall somewhere along a spectrum between complete orthogonality and non-orthogonality. The PDP-11 has an example of an orthogonal instruction set.
  • RISC/CISC: Reduced Instruction Set Computers (RISC) have fewer instructions than Complex Instruction Set Computers (CISC), which requires more instructions to complete the same task than on CISC processors. The advantage to RISC instruction sets is that they can be implemented with fewer transistors, which allows faster instruction execution in theory. In practice, the clock rate is the same on RISC and CISC CPUs. However, more cores can be fit into a given semiconductor space with a RISC architecture. ARM processors are examples of RISC CPUs. Intel iAPX processors are examples of CISC CPUs.

See also

References

External links