If memrestrict doesn't help, try cleanmemWell
mkey82 has been busy again and has this handy tip for those having problems. Many thanks to
girishb who provided the Vista scheduler instructions.
It seems that some machines suffer from memory issues with GTAIV (especially those that have 2GB or less RAM) and memrestrict command line switch just doesn't cut it. Try cleanmem - it's free and it works in the background automatically, running only when it's needed.
Of course, this goes without saying, if you get the stalls after using command line switches as norestrictions, availablevidmem or nomemrestrict - STOP USING THOSE SWITCHES. K? 
1) Download the zip from
here (direct link
here, a 59k download)
2) Unpack the "cleanmem_v.1.4.2.zip" archive somewhere safe, like "C:\Program Files\Cleanmem" (you'll need to create the dir

3) Now browse to the directory and double click the "Install_32bit_OS.bat" if you have a 32 bit OS or "Install_64bit_OS.bat" for the 64 bit version. You will see a command prompt flash briefly and exit afterward.
4) If at any time you want to remove the app from your system, simply double click the "Uninstall.bat"
Now for the critical part - the app by default clears the RAM every half an hour. So maybe you'll want to decrease that interval if you get to the point when the game starts to stall in less then half an hour. So,
If You are using Windows XP then do the following :- 1) Go to Control Panel >> Scheduled Tasks and find "Clean System Memory" in the list.

2) Double click that entry or right click and choose properties in the menu. Now choose the "schedule" tab and click the "Advanced" button. In the "Repeat task" field choose how often should your RAM be cleared.

3) Confirm and exit, that's it!
If You are using Vista/Windows 7 then do the following :- 1. Navigate to Control Panel > Administrative Tools > Task Scheduler.
2. In the left pane, under Task Scheduler (Local), select Task Schedular Library.
3. In the middle pane, select 'Clean System Memory'. Right-click on it and select 'Properties'.
4. In Properties, select 'Triggers'. This is how the window will look like:

5. Highlight it by clicking on it and then click on 'Edit'. From here, you can edit the duration and such. The default settings should look like this:

Select the required repeat duration from the encircled drop down box. Do NOT change the other settings.
6. Once you're done, click OK to close all windows and you're set.
Hope this helps. Game safely