NVIDIA Sheds Light On Lack Of PhysX CPU Optimizations - HotHardware

NVIDIA Sheds Light On Lack Of PhysX CPU Optimizations

0 thumbs up
About four months ago, we covered the latest round of shin-kicking between ATI and NVIDIA, with ATI claiming that NVIDIA purposefully crippled CPU performance when running PhysX code and coerced developers to make use of it. NVIDIA denied all such claims, particularly those that implied it used its "The Way It's Meant To Be Played" program as a bludgeon to force hardware PhysX on developers or gamers.

A new report from David Kanter at Real World Technologies has dug into how PhysX is executed on a standard x86 CPU; his analysis confirms some of AMD's earlier statements. In many cases, the PhysX code that runs in a given title is both single-threaded and decidedly non-optimized. And instead of taking advantage of the SSE/SSE2 vectorization capabilities at the heart of every x86 processor sold since ~2005, PhysX calculations are done using ancient x87 instructions.

When in doubt, blame the PPU.

Before the introduction of SIMD sets like SSE and SSE2, if you wanted to do floating point calculations on an x86 processor, you used the x87 series of commands. In the past 11 years, however, Intel, AMD, and VIA have all three adopted SSE and SSE2. Both allow for much higher throughput than the classic x87 instruction set—given the ubiquity of support across the PC market, it's hard to tell why NVIDIA hasn't specifically mandated their use.

As RWT's analysis shows, however, virtually all of the applicable uops in both Cryostasis and Soft Body Physics use x87; SSE accounts for just a tiny percentage of the whole. Toss in the fact that CPU PhysX is typically single-threaded while GPU PhysX absolutely isn't, and Kanter's data suggests that NVIDIA has consciously chosen to avoid any CPU optimizations, and, in so doing, has artificially widened the gap between CPU and GPU performance. If that allegation sounds familiar, it's because we talked about it just a few weeks back, after Intel presented a whitepaper claiming that many of NVIDIA's test cases when claiming huge GPU performance advantages were unfairly optimized.
 

Article Index:

Prev 1 2 3 4 5 Next
0
+ -

Real,

What you've just said is actually a lot more helpful when it comes to possibly helping you solve that problem. :) You say you have a GTX 285 (2GB) and a 1GB Radeon HD 5850. Are you using both of them in the same system? I'm assuming not--I don't think the 5850 is powerful enough to trounce the GTX 285 (some people on Win 7 use a hacked drive to allow them to run a secondary GeForce for PhysX while simultaneously using a higher-end ATI card.


There's no reason PhysX shouldnt' be working on your GTX 285. There are several possibilities here:

1)  You've got a driver issue/bug that's keeping PhysX from executing properly.

2)  You're confused about the difference between software and hardware PhysX. The term "Software PhysX" refers to PhysX calculations performed by the CPU. There are something like 150 games that use software PhysX--NVIDIA has adapted it for the PS3, XBox, Wii, and iPod.

Hardware PhysX titles are much rarer. To date, Batman: Arkham Asylum, Mafia 2, Unreal Tournament 3, and Mirror's Edge have been the go-to titles for good game play and high-level PhysX support. Software PhysX titles do not take advantage of NVIDIA hardware.

This is a distinction that's not easy to clarify; I frankly wish NVIDIA had used two distinct terms for their software PhysX engine (which runs on many architectures) and the hardware PhysX execution that's particular to GeForce cards.

Here's the final caveat that makes the situation more nuanced than it looks at first glance. There are only a handful of hardware PhysX titles, there's an even smaller handful of those titles that are top-notch, and yes, NVIDIA is using a restricted, proprietary API. Look around the industry, however, and you'll see that NVIDIA is also the *only* company that's sunk real work into defining, developing, and using a hardware physics standard.

ATI periodically makes some noise in this general direction but has never released hardware physics support for any shipping title. Microsoft's DirectCompute and OpenCL are both available, but we haven't heard of any games adopting these options in hardware. That's why NV gets credit--however small their success, they remain the only company that's put a major, multi-year push behind hardware physics development.

Now, back to your situation. If you're having a problem that isn't covered by one of the two examples above, I'd be more than happy to work with you to get the GTX 285 running as it should. We can talk here, or you can drop me a PM/email.

 

0
+ -

Joel H:

ATI periodically makes some noise in this general direction but has never released hardware physics support for any shipping title. Microsoft's DirectCompute and OpenCL are both available, but we haven't heard of any games adopting these options in hardware.

Lost Planet 2 uses DirectCompute for enhanced water physics and softbody compute although the framerate hit is much more massive than physx (because there is only option to turn on/off DX11 options and it includes tessellation), also the water physics implementation in that game looks horrible since its only shallow water effect and not particle.

0
+ -

Technically I stand corrected. From your description, however, it sounds pretty awful.

0
+ -

Joel,

The GTX285 is in the PC I'm using today. It has a i5-750, 8GB of DDR3-1600 RAM, a OZC Agility 60GB SSD, and a pair of Seagate 750TB 7200RPM Drives. This is the "Little" box so to speak.

I have UT3 and have added the PhysX mod to the game. I've updated the game completely as far as I know. When I try to run the PhysX maps, it slows to a crawl right away. (totally unplayable and not fun)

At the moment, I'm running the latest driver from NVIDIA. (I do a weekly search for all of the computers for drivers just to stay busy) I have tried several.

After a couple of months of screwing around with this situation, swapping the cards around between this, the i7-870, and the AMD X3-720 system, trading the two types of DDR3-1600 RAM that I own, Formatting the drive and installing the game only on the systems, I just gave up in frustration.

I even bought a new Gigabyte GT240 1GB-GDDR5 OC edition PCI-E card to add to the system to act as the PhysX processor,.....to no avail. (it's now sitting on the shelf collecting dust) Adding another card to the PCI-e bus chops my video bandwidth from one @ X16 speeds to dual X8 speeds on these two LGA-1156 socket systems, but according to some sites out there, it should still work. It did not.

EDIT: I just tried it out again after posting this, and it played fine for about 30 seconds and then slowed down to a choppy crawl.

0
+ -

realneil:

EDIT: I just tried it out again after posting this, and it played fine for about 30 seconds and then slowed down to a choppy crawl.

 Properly implemented Physx can be very efficient while still offering some very nice effects.

Metro 2033 is a perfect example. Enabling Physx offers little to no performance hit, yet provides a noticable difference in visuals.

0
+ -

acarzt:
Properly implemented Physx can be very efficient while still offering some very nice effects.

So it's the UT3 game that's stuffed?

0
+ -

RealNeil,

No. I've personally played UT3's PhysX maps with a GTX 260. Based on what you've described, it's not that PhysX doesn't work--the code is being run on your CPU rather than your GPU.

The simplest thing to do would be to try a different program. The Mafia 2 demo supports PhysX, Batman: AA has a good implementation and can be downloaded here:  http://www.nzone.com/object/nzone_batmanaa_downloads.html


The reason I'm suggesting we check a different title is because it'll help nail down whether or not the problem is in-driver (I suspect it is).

Two simple questions for you--I'm assuming you've done both of these, but it's always best to cover the bases when troubleshooting.

1)  The new NVIDIA drivers allow you to explicitly choose how PhysX is executed. Have you selected to run PhysX on the GPU? (If it says Auto, try changing it to the GPU explicitly).

2)  In Unreal Tournament 2003,  have you've enabled hardware PhysX using the toggle inside the game menus? 

3) You say you've tried multiple driver revisions. How do you install and uninstall drivers? Describe the steps you take, please.

We'll sort this out.

Joel

0
+ -

Point #1) was set to auto so I changed it to use just the GTX285. Game worked smoothly for a longer time, (one minute) but still reverted to jerkiness (crappy frame rate) When I had the two NVIDIA cards in the system, I had it set to use the GT240 1GB card with no decent result. It was even worse.

Point #2) I have the hardware PhysX turned on in the game and have had it on all along.

Point #3) I usually just install the latest released driver onto the computer when I download it. I do not do an uninstall first.

 

Thanks for the help

0
+ -

I usually just install the latest released driver onto the computer when I download it. I do not do an uninstall first..

Yeah..that's almost certainly the problem, and just running NVIDIA's removal tool isn't good enough. What OS are you running? I can't guarantee that this is your issue...but I'd lay good odds--75%--that not uninstalling drivers first is the problem. Don't just go run NVIDIA's own uninstallation software--you've got to do this the right way or else you'll be screwing with it for hours.

0
+ -

I have Enterprise Win-7 64Bit on all of them.

I have Revo Uninstaller on the systems too. Should I use that?

Prev 1 2 3 4 5 Next
Login or Register to Comment
Post a Comment
Username:   Password: