AltiVec

AltiVec is a floating point and integer SIMD instruction set designed and owned by Apple Computer, IBM and Motorola (the AIM alliance), and implemented on versions of the PowerPC including Motorola's G4 and IBM's G5 processors. AltiVec is a tradename owned solely by Motorola, so the system is also referred to as Velocity Engine by Apple and VMX by IBM.

AltiVec was the most powerful SIMD system in a desktop CPU when it was first introduced in the late-1990s. Compared to its contemporaries (Intel's integer-only MMX, floating point SSE, and various systems from other RISC vendors), AltiVec offered more registers that could be used in more ways and operated on by a much more flexible instruction set. However, Intel's fourth-generation SIMD system, SSE2 introduced with the Pentium 4, has many of the same functions as AltiVec.

Both AltiVec and SSE2 feature 128-bit vector registers that can represent sixteen 8-bit signed or unsigned chars, eight 16-bit signed or unsigned shorts, four 32-bit ints or four 32-bit floating point variables. Both provide cache-control instructions intended to minimize cache pollution when working on streams of data.

They also exhibit important differences. Unlike SSE2, AltiVec supports a special RGB "pixel" data type, but it does not operate on 64-bit double precision floats, and there is no way to move data directly between scalar and vector registers. In keeping with the "load/store" model of the PowerPC's RISC design, the vector registers, like the scalar registers, can only be loaded from and stored to memory. However, AltiVec provides a much more complete set of "horizontal" operations that work across all the elements of a vector; the allowable combinations of data type and operations are much more complete. 32 128-bit vector registers are provided, compared to 8 for SSE and SSE2, and most AltiVec instructions take three register operands compared to only two register/register or register/memory operands on IA-32.

Recent versions of the GNU Compiler Collection, IBM Visual Age Compiler and other compilers provide intrinsics to access AltiVec instructions directly from C and C++ programs. The "vector" storage class is introduced to permit the declaration of native vector types, e.g., "vector unsigned char foo;" declares a 128-bit vector variable named "foo" containing sixteen 8-bit unsigned chars. Overloaded intrinsic functions such as "vec_add" emit the appropriate op code based on the type of the elements within the vector, and very strong type checking is enforced. In contrast, the Intel-defined data types for IA-32 SIMD registers declare only the size of the vector register (128 or 64 bits) and in the case of a 128-bit register, whether it contains integers or floating point values. The programmer must select the appropriate intrinsic for the data types in use, e.g., _mm_add_epi16(x,y) for adding two vectors containing eight 16-bit integers.

Apple is the primary customer for AltiVec, and uses it to accelerate multimedia applications such as QuickTime and iTunes and image-processing programs such as Adobe Photoshop. AltiVec is also put to work in key parts of Apple's Mac OS X including in the Quartz graphics compositor. Motorola has supplied AltiVec units in all of their desktop CPU's since the G4. AltiVec is also used in some embedded systems to provide extremely high-performance digital signal processing.

IBM has consistently left VMX out of their proprietary POWER systems, which are intended for mainframe and server applications where it is not very useful. However, the most recent PowerPC 970 (dubbed the G5 by Apple) desktop CPU from IBM does include a high-performance AltiVec unit. The core includes a multiplier/adder unit and a full VMX unit.

According to the Apple document at http://developer.apple.com/hardware/ve/summary.html Altivec can perform 8 FLOPS per cycle and SSE can perform only 2 FLOPS per cycle. The obvious implication is that SSE would need a clock 4 times the frequency of Altivec to perform the same number of FLOPS per second. The clock speed of the Pentium chip is not 4 times the clock speed of the PowerPC chip so the Altivec is faster at the level of operations per second. Of course application speed depends on many other factors such as motherboard architecture, I/O architecture, compilers, operating system software and application software. The benchmarks at http://developer.apple.com/hardware/ve/summary.html demonstrate that the PowerPC is faster than the Pentium for those applications, with those hardware, compiler and applications configurations. Benchmarks are soon out of date. It will be interesting to see a new set of benchmarks for Apple applications on the recently (2005/06/06) announced Mac Intel Pentium systems.

External links

es:AltiVec fr:AltiVec it:AltiVec ja:AltiVec

Navigation

  • Art and Cultures
    • Art (https://academickids.com/encyclopedia/index.php/Art)
    • Architecture (https://academickids.com/encyclopedia/index.php/Architecture)
    • Cultures (https://www.academickids.com/encyclopedia/index.php/Cultures)
    • Music (https://www.academickids.com/encyclopedia/index.php/Music)
    • Musical Instruments (http://academickids.com/encyclopedia/index.php/List_of_musical_instruments)
  • Biographies (http://www.academickids.com/encyclopedia/index.php/Biographies)
  • Clipart (http://www.academickids.com/encyclopedia/index.php/Clipart)
  • Geography (http://www.academickids.com/encyclopedia/index.php/Geography)
    • Countries of the World (http://www.academickids.com/encyclopedia/index.php/Countries)
    • Maps (http://www.academickids.com/encyclopedia/index.php/Maps)
    • Flags (http://www.academickids.com/encyclopedia/index.php/Flags)
    • Continents (http://www.academickids.com/encyclopedia/index.php/Continents)
  • History (http://www.academickids.com/encyclopedia/index.php/History)
    • Ancient Civilizations (http://www.academickids.com/encyclopedia/index.php/Ancient_Civilizations)
    • Industrial Revolution (http://www.academickids.com/encyclopedia/index.php/Industrial_Revolution)
    • Middle Ages (http://www.academickids.com/encyclopedia/index.php/Middle_Ages)
    • Prehistory (http://www.academickids.com/encyclopedia/index.php/Prehistory)
    • Renaissance (http://www.academickids.com/encyclopedia/index.php/Renaissance)
    • Timelines (http://www.academickids.com/encyclopedia/index.php/Timelines)
    • United States (http://www.academickids.com/encyclopedia/index.php/United_States)
    • Wars (http://www.academickids.com/encyclopedia/index.php/Wars)
    • World History (http://www.academickids.com/encyclopedia/index.php/History_of_the_world)
  • Human Body (http://www.academickids.com/encyclopedia/index.php/Human_Body)
  • Mathematics (http://www.academickids.com/encyclopedia/index.php/Mathematics)
  • Reference (http://www.academickids.com/encyclopedia/index.php/Reference)
  • Science (http://www.academickids.com/encyclopedia/index.php/Science)
    • Animals (http://www.academickids.com/encyclopedia/index.php/Animals)
    • Aviation (http://www.academickids.com/encyclopedia/index.php/Aviation)
    • Dinosaurs (http://www.academickids.com/encyclopedia/index.php/Dinosaurs)
    • Earth (http://www.academickids.com/encyclopedia/index.php/Earth)
    • Inventions (http://www.academickids.com/encyclopedia/index.php/Inventions)
    • Physical Science (http://www.academickids.com/encyclopedia/index.php/Physical_Science)
    • Plants (http://www.academickids.com/encyclopedia/index.php/Plants)
    • Scientists (http://www.academickids.com/encyclopedia/index.php/Scientists)
  • Social Studies (http://www.academickids.com/encyclopedia/index.php/Social_Studies)
    • Anthropology (http://www.academickids.com/encyclopedia/index.php/Anthropology)
    • Economics (http://www.academickids.com/encyclopedia/index.php/Economics)
    • Government (http://www.academickids.com/encyclopedia/index.php/Government)
    • Religion (http://www.academickids.com/encyclopedia/index.php/Religion)
    • Holidays (http://www.academickids.com/encyclopedia/index.php/Holidays)
  • Space and Astronomy
    • Solar System (http://www.academickids.com/encyclopedia/index.php/Solar_System)
    • Planets (http://www.academickids.com/encyclopedia/index.php/Planets)
  • Sports (http://www.academickids.com/encyclopedia/index.php/Sports)
  • Timelines (http://www.academickids.com/encyclopedia/index.php/Timelines)
  • Weather (http://www.academickids.com/encyclopedia/index.php/Weather)
  • US States (http://www.academickids.com/encyclopedia/index.php/US_States)

Information

  • Home Page (http://academickids.com/encyclopedia/index.php)
  • Contact Us (http://www.academickids.com/encyclopedia/index.php/Contactus)

  • Clip Art (http://classroomclipart.com)
Toolbox
Personal tools