GTA IV is dependent upon multiple cores, usually more than 2 makes a difference.
I had an Athlon X64 4200+ X2 (which is similiar in construct to your Pentium D) and it couldn't play it above 15 fps period, even on low settings.
When I upgraded to an Phenom II X3 720 BE, things improved. But even then, I still had to upgrade my GPU as well. I had an HD 3870 and with the Phenom II, I was getting on average around 35 fps with the demo. I'm now getting around 40-45 and that's on high, but not full high.
It also depends on how much memory your GPU has because the more details you turn up, the more memory it takes. One thing to cut down is the view distance. I have it set around 30 I believe which still gives you a pretty good view.
Also, how much memory do you have and what is it's type and speed?