United Business Media EE Times


Search

HOMELATEST NEWSSEMICONDUCTORSMOST POPULARMARKET INTELLIGENCE UNITFORUMSDESIGNNEW PRODUCTSCAREERSBLOGSCONTACTEVENTSSIGN UP!RSS

 


MMX -- No pain, no gain


T his week, we'll tackle the big question that's been avoided amid all the hype about Intel's new MMX microprocessors--namely, how to actually squeeze the promised multimedia performance advantages out of the just-released P55C Pentium-class. (Intel is also preparing a family of Pentium-Pro-class MMX processors code-named "Klamath," which are expected to be available later this year.)

MMX is shorthand for "multimedia extensions"--57 new instructions that have been added to the x86 instruction set. The extensions apply a single-instruction/multiple-data technique to process many chunks of data in parallel. For example, four 16-bit data elements (or eight 8-bit data elements) can be packed into a single 64-bit word and operated on with just one instruction.

That sounds impressive. However, the watchwords in using MMX should be "no pain, no gain." Despite what your cousin repeated at the family Christmas gathering ("Did you hear about those new chips from Intel that'll make your media multiply?"), an MMX processor wouldn't provide any boost unless software has been written to specifically take advantage of the new instructions.

Here's another rub: writing code using MMX instructions is no trivial task. Indeed, it may be beyond the reach of the average C-language programmer.

I took some heat from the folks at Intel when I pointed this out in a recent column in EE Times . Look, MMX is great. But don't kid yourself that it's a free ride. Today's compilers aren't up to the task of taking high-level C code and converting it into optimized MMX instructions. So, using the multimedia extensions means that you have to write the MMX portion of your application using in-line assembly language.

Moreover, it'll probably be at least two years before MMX-optimizing compilers are available. Until then, you can use current-generation products like Microsoft's Visual C++ version 4.2, which supports in-line MMX instructions--a feature that was no doubt trivial to incorporate. On a more useful note, Visual C++ has a debug mode that lets you look at and step through your MMX code.

If you do know assembly-language programming (this means you're either a game developer or over 35!), be advised that you can't just bang out a quick MMX subroutine. You have to apply nume rous hints and kinks to ensure that your software is properly optimized. There are 12 firm rules and an additional 13 "suggestions" that must be applied -- things like avoiding small loads after large stores to the same area of memory and inserting "no-ops to maximize instruction pairing. If you don't pay attention, you may be in worse shape than if you eschewed MMX entirely.

Systems-software vendors like Microsoft are beginning to roll MMX into products like the DirectX API. But it's important that the word get out to apps developers and others that they're going to have to put their PCs to the grindstone and start coding.

As for end-users, when a vendor touts its software as being "MMX-enabled," I strongly suggest asking them exactly where and how they're using the multimedia extensions. There are already cases where companies are trumpeting MMX support in programs that contains little more than a snippet in an isolated module.

For writing your code snippets, Intel offers some additi onal help in the form of an "MMX Developer's Guide" and an "MMX Programmer's Reference Manual." Intel has also posted application notes that provide useful examples, such as "Using MMX Instructions for 3D Bilinear Texture Mapping."

Beyond Intel, there are two other microprocessor manufacturers -- AMD and Cyrix -- that plan to support clones of the MMX instruction set. Cyrix Corp. is building a Pentium-Pro-class CPU, called M2, which it says will be fully MMX-compatible.

For its part, AMD will support MMX in its upcoming K6, which is also a Pentium Pro-class chip. AMD is providing a wealth of details on its plans in a technical document called "K6 P rocessor Multimedia Extensions."

That's all for this installment of Wintel Watch. What's your take on this new column? What topics would you like to see in coming weeks? E-mail me

Alexander Wolfe is EE Times' Managing Editor for computers and communications


Have an opinion, comment or question about the Wintel platform? Explore next-generation design challenges -- things like MMX, DirectX and Univeral Serial Bus -- with other EE Times readers on our new Wintel Watch forum.

To view past 'Wintel Watch' columns

To view other columns

  Free Subscription to EE Times
First Name Last Name
Company Name Title
Email address
  Click here for your Free Subscription to EETimes Europe

 
CAREER CENTER
Ready to take that job and shove it?
SEARCH JOBS
SPONSOR

RECENT JOB POSTINGS
CAREER NEWS
10 Search Engines You Don't Know About
Go beyond Google and get vertical. These specialized search sites will help you find the business information you need -- fast.

For more great jobs, career related news, features and services, please visit EETimes' Career Center.


All White Papers »   

 

FEATURED TOPIC



ADDITIONAL TOPICS












Home | About | Editorial Calendar | Feedback | Subscriptions | Newsletter | Media Kit | Contact | Reprints|  RSS|   Digital|  Mobile
Network Websites
International
Network Features



All materials on this site Copyright © 2008 TechInsights, a Division of United Business Media LLC All rights reserved.
Privacy Statement | Your California Privacy Rights | Terms of Service | About