NASA Built-in Hardware
The dedicated mission computers are tested extensively for vibration resistance, resistance to cosmic and solar radiation (both particulate and EM), magnetic fields, and are also prioritized for low energy consumption and high reliability. Generally, this results in processors a generation or three older than current desktops, and often in larger architecture versions and slower speeds.
Further, the motherboards and enclosures are often custom made designs, like the Shuttle's upgraded AP-101B, using a 400 kHz single core main processor, and 24 dedicated IO processors, in a radiation resistant case with a vibration resistant motherboard, and a very small amount of memory - a few hundred kilobytes.
Many satellites use off-the shelf processors; for years, the Zilog Z-80, Intel 8080, and Motorolla 68000 were staple processors, because they were both inexpensive (having outlived the patents), and had already passed the NASA testing requirements. Newer processors have since replaced them in common use, but missions into the late 1990's made use of NASA-specific production 8080 chips. (A top-end Z80 is 20 MHz, 8-bit clean, single core, and $12. This has resulted in a couple of students looking to use it on microsat projects - it's cheap and space rated.)
Off the Shelf Hardware
NASA has, since about 1992, allowed the use of off the shelf IBM laptops for some mission critical applications. They've found that the devices are unreliable in orbit, due to magnetic field fluctuations. Still, they are reliable enough to be used in general purpose non-flight-essential uses.
Hand calculators, including HP-41's, have been used by several astronauts over the years; these devices have larger circuits, slower processors, less memory, and have always been used only for non-mission-critical applications. (The HP-41 also was used to simulate the AP-101. It was also the backup plan in case of failure of the AP-101 cluster.)
References
http://www.nasa.gov/mission_pages/shuttle/flyout/flyfeature_shuttlecomputers.html
http://spaceflight.nasa.gov/shuttle/reference/shutref/orbiter/avionics/dps/gpc.html
http://hpinspace.wordpress.com/category/hp-41/
http://www.hq.nasa.gov/pao/History/computers/Ch4-6.html