CPU maxed (purple bar full)

Discussion in 'Technical & Support' started by Cloudhopper, Jul 8, 2017.

  1. Cloudhopper

    Cloudhopper Registered

    Joined:
    Jun 25, 2017
    Messages:
    11
    Likes Received:
    3
    Hi,
    I'm trying to get rFactor2 to work smoothly, but I'm encountering severe stuttering when AI cars are around. GPU performance appears to be fine, but the CPU bar (purple bar) looks maxed out.
    [​IMG]

    My specs:
    i7 3770k @4.1GHz
    16GB Ram
    GTX 1070 8GB (FTW Edition)
    rFactor and OS run off SSDs.
    Running latest rFactor2 DX11 Beta build (issue was present in standard Steam release, changed to DX11 beta cause it was mentioned on the forums to help. No change though).

    I've googled a lot, found mentions of CPU thread threshold and affinity settings, but they all are a few years old and I cant seem to find them in the current set of JSONs or I'm looking in the wrong place.

    Any help is appreciated. Thanks so much for your time!
     
  2. ADSTA

    ADSTA Registered

    Joined:
    Nov 19, 2011
    Messages:
    2,013
    Likes Received:
    1,369
    I would have Task Manager running so you can see what is hogging your CPU.

    edit: What does the graph look like with no AI?
    Maybe you are just going overboard with the amount of AI cars.
     
    Cloudhopper likes this.
  3. rocketjockeyr6

    rocketjockeyr6 Registered

    Joined:
    Jul 11, 2016
    Messages:
    192
    Likes Received:
    116
    Also, which mod/track? Some have poorly optimized AI that eat up the CPU, more so at certain tracks. And yes, how many AI?
    Honestly though, as an FX8320e user, Im shocked to see an i7 struggling here, especially a k series. That Ivy Bridge is some tough stuff from what I understand.
     
    Cloudhopper likes this.
  4. Cloudhopper

    Cloudhopper Registered

    Joined:
    Jun 25, 2017
    Messages:
    11
    Likes Received:
    3
    Good starting points, lets get to it :)

    Track I've done the testing on is Spa Franchorchamps (ACSpa ver. 0.91) using a number of cars (primarily Enduracers GTE cars and the URD Corvette C7.R). I noticed the issue first when trying the Stockcar 2015 mod on what is totally-not Charlotte ;)

    The visible cars were set to 12 (I didn't change that, no idea if thats default.) When I reduce it to 6, which is the minimum it'll let me set, the performance smoothes out a lot. AI cars remain visible longer, (almost) no stutter while they're in my vicinity.

    I didn't notice this type of issue during my testing in the rfactor2 demo, where i believe a lot more cars were present at a single time.

    Again all your suggestions and help is appreciated. I agree that the CPU should perform better than it is, but I guess there is a lot of optimisation possible on my install. Thanks for all replies! :)
     
  5. stonec

    stonec Registered

    Joined:
    Jun 19, 2012
    Messages:
    3,399
    Likes Received:
    1,488
    AC Spa version has this issue on the downhill before Eau Rouge when you add many AI. It's probably related to road mesh that is wrongly built or not optimized for rF2. The 240 Hz tire model that rF2 uses is quite a bit more advanced than AC's, so it puts different requirements on tracks.
     
    Cloudhopper likes this.
  6. Cloudhopper

    Cloudhopper Registered

    Joined:
    Jun 25, 2017
    Messages:
    11
    Likes Received:
    3
    Interesting. Did some more testing on a track that I, according to the read me, should be performance heavy, the Nordschleife2 in Autumn. No issues with 10 AI on track, 6 cars visible.

    Have to go back later and do some oval testing again, but right now it's too muggy here. I'll park myself in front of a fan for a few hours.
     
  7. rocketjockeyr6

    rocketjockeyr6 Registered

    Joined:
    Jul 11, 2016
    Messages:
    192
    Likes Received:
    116
    The amount of visible AI should not affect the CPU, as it already has to calculate the AI whether it draws the model or not. But a 1070 should handle this game at max GFX...
    I have a GTX 960 4gb, and my max visible vehicles is 20, most settings are set to very high/max.
    Something very strange here...
    Are there any other CPU or GPU intensive games you run? How do those perform and on what settings?
     
    muz_j and Cloudhopper like this.
  8. Marcel Offermans

    Marcel Offermans Registered

    Joined:
    Oct 4, 2010
    Messages:
    646
    Likes Received:
    2,930
    What wheel and pedals are you using? One common cause for high CPU usage is a wheel driver that is relatively slow receiving FFB commands. A common solution for that is to search your controller.json file for an entry called "Use Thread" and set its value to "true".
     
  9. Cloudhopper

    Cloudhopper Registered

    Joined:
    Jun 25, 2017
    Messages:
    11
    Likes Received:
    3
    Thanks for the Reply Marcel.
    Pedals are Fanatec CSL Elite and the Wheel is the CSL Base with the BMW GT2 rim.
    Current setting in the JSON:
    "Use thread":true,​
    "Use thread#":"Use a separate thread to issue FFB commands which may block with some drivers"

    Think i changed that last weekend when i started to troubleshoot this problem.

    rocketjockey
    Well I'm not sure what qualifies as "intensive" these days. iRacing runs with realtively high settings at a steady 85fps up to 125fps. DCS World 2.0 runs at max settings at around 70 FPS... unless i fly a helicopter low over the sunset strip in Nevada. It collapses to 35ish then.
    Both running triple screens at 57xx*1920 as I do in rFactor2.
    Looking at the available information, my PC should be able to handle it, I didnt have any issues in the rFactor2 demo, the sim runs fine for a lot of other people. It has to be on my end. Hence why I'm here asking for the experience of the community ;)

    I just tested on totally-not Charlotte (Mountain Peak?) with the Stockcar 2015 mod and it doesn't make a difference now if I have 6 or 12 cars visible. CPU bar stays at 2/3ish for now. No stutter or anything.

    Is there a way I can change the amount of AI cars in the session? I'd like to exclude certain tracks and cars I was using as the cause.

    Thank you so much for your time and effort all. I appreciate it a lot that you help me getting started with rfactor2 :)
     
  10. rocketjockeyr6

    rocketjockeyr6 Registered

    Joined:
    Jul 11, 2016
    Messages:
    192
    Likes Received:
    116
    Not a problem. :)
    You can choose which and how many AI in the session setup screen, i.e. where you set weather, time of day, flag rules, etc.
    You can also choose to run a "Private Practice"(little box at the top of practice section of session setup page) which will keep the AI on the time table, and they will still rubber the track down. Also you can select their name in the time table/monitor and watch them.

    If this is the only program that performs poorly, maybe verify the game files in Steam. As a last resort, fully uninstall then re-install.
    Direct X, to the best of my knowledge, is really only GPU related, I dont think it would have an impact on the CPU which dx build you choose.

    Also, do you have any programs that monitor your CPU/GPU/System temperatures? If not, get one, and see what your temps are like.
    What kind of CPU cooling do you have? My Cooler Master Hyper N520 kicks serious heat exchanging booty. :D
     
  11. muz_j

    muz_j Registered

    Joined:
    Aug 20, 2014
    Messages:
    264
    Likes Received:
    188
    @rocketjockeyr6 - please clarify your PC's performance in general.
    Is the issue specific to RF2?

    Try to replicate the problem and then change to Windows Task manager as a quick check, then verify which process(es) are hogging CPU resource.

    There's something unusual going on as your PC should be able to run RF2 without much of a problem.

    If you're struggling to understand the root cause, then 3 Microsoft tools will help you nail it down.
    1) process monitor from the SysInternals Tool Suite - set it running in the back ground - replicate the problem, then change to Process Monitor and examine things - remember to stop it monitoring - which is on the File menu or CRTL-E.
    2) process explorer from the SysInternals Tool Suite - this can be very useful for drilling into child processes. Sort the display using the CPU column and focus on those.
    3) or lastly if you need it - Windows built-in performance monitor. If you go down this path and need a general guide, I'm happy to point you in the right direction. As a one sentence summary - create a user data collection set, choose to monitor performance counters, configure it to monitor the PROCESS object - not processor, but process and ensure all the child items are selected. Use something like a 10 second monitoring interval to begin with and log to CSV file. Replicate the problem, then quickly change to the performance monitor and stop its data collection - the goal being to try to minimize how much information you are collecting, as you'll have to analyse it afterwards.

    So option 3 is clearly more involved than options 1 or 2. Also the collection interval with performance monitor is critical to making the data useful (I've used it on large scale server farms, so have a lot experience with it). Too short an interval results in data overload. Too long and you can miss events, due to not having enough granularity with the data.

    The SysInternals Suite for the first two tools can be found here - it's 21 MB and it's free - and I high recommend it as a general troubleshooting toolset: https://technet.microsoft.com/en-us/sysinternals/bb842062.aspx

    Oh and lastly as a very basic system tune up - have a look at AutoRuns from the SysInternals Suite and examine everything configured to auto-start on your PC. You can disable items, by removing the tick box next to them, indicating they are enabled. That's a safer method than deleting items. Disable the ones you think are not required - like say a piece of software you forgot about that's running in the background, reboot the PC, test it for a while (a couple of days) and assuming you have no issues, then you can consider deleting the item properly. This tool will give you an overview of everything that's automatically running in the background and on startup - excluding items configured in task manager (off the top of my head).
     
    suryaprihadi likes this.
  12. Cloudhopper

    Cloudhopper Registered

    Joined:
    Jun 25, 2017
    Messages:
    11
    Likes Received:
    3
    After two busy evenings testing I have sort of a result.
    I dont wanna go into too much detail what exactly I did and what the individual results were (primarily cause I'm typing this from the tablet which is uncomfy). And a red herring I ended up chasing for two hours, which turned out to be correlation more than cause and it wasn't reproducible anyway.

    So here is what I ended up with for now:
    - start rf2
    - open task manager
    - change the affinity of the rfactor2.exe to any core apart from CPU 0 (i havent notice a difference between physical and logical cores, but I stick to physicals... because reasons)
    - drive

    After I had tests with a bare minimum-to-boot system, minimum graphics settings in private practice sessions that had abslutely abyssmal perormance, in contrast i can now, with the above run on max graphics settings, 24 ai cars and have half the CPU bar to spare.
    All tests done at Mountain Peak full oval with the StockCar 2015 car set.
    Tests confirmed on aforementioned Spa course with the URD Corvette C7.R, no issues whatsoever.

    I really have no clue as to why or how.
    If anyone wants to hazard a guess, be my guest. I appreciate al your help and patience on this journey to get it working.
     
    SPASKIS likes this.
  13. muz_j

    muz_j Registered

    Joined:
    Aug 20, 2014
    Messages:
    264
    Likes Received:
    188
    Your change suggests something was hogging CPU utilisation on your first core.
    You would probably need to do some monitoring to a log file and analysis to nail down the root cause, if you are interested - but your change is straight forward enough. Refer to my earlier comments on that. Windows Performance Monitor would be the best tool for that.

    You can use the "Start" command to launch something with a pre-defined affinity, if you want to do that - which would save you having to modify it each time after launch the game.
    https://www.eightforums.com/tutorials/40339-cpu-affinity-shortcut-program-create-windows.html

    ...at least you have made progress and can now run the game properly, but if it was me, I would want to know what's going on with your first CPU core.
     
    Cloudhopper likes this.
  14. Cloudhopper

    Cloudhopper Registered

    Joined:
    Jun 25, 2017
    Messages:
    11
    Likes Received:
    3
    Thanks @muz_j I do agree.
    I'm really divided on the issue. An educated guess would be my Antivirus. Another Malware. The first didn't find anything of the latter during a scan the night before, cause that suspicion crept up on me. So if I really want to get to the bottom of it... Maybe at the weekend.

    First I have to tackle the hopefully last issue I'm encountering which is more annoying.

    Thanks everyone for your help!
     
    muz_j likes this.
  15. Cloudhopper

    Cloudhopper Registered

    Joined:
    Jun 25, 2017
    Messages:
    11
    Likes Received:
    3
    So here is a little Update. After playing around with all sorts of stuff I settled on a weird trick (Have chrome open when I start rf2, go into the car, close Chrome. CPU drops to 50% all is well):
    After a while I noticed that the display and LEDs on my wheel weren't working in rf2.

    So i installed Fanaleds and disabled the LEDs and Display in the Controller.Json
    CPU seems to behave since then.
    Fanatec Driver Version: 289 BETA
    Firmware: 296

    I'll continue to test, but I'm getting fairly confident that this is related to the LEDs/Display of the CSL Elite Wheel Base.
    Prelimanry fix: Disable LED/Display in rf2 Controller.JSON and install Fanaleds.
     
    The Iron Wolf likes this.
  16. suryaprihadi

    suryaprihadi Registered

    Joined:
    Apr 16, 2017
    Messages:
    87
    Likes Received:
    32
    muz_j likes this.
  17. Filip

    Filip Registered

    Joined:
    Feb 9, 2017
    Messages:
    1,208
    Likes Received:
    937
    How can you close Chrome while in rF2?
    Because when in fullscreen mode alt+tab doesn't work for me. I need to exit rf2 completely (except for launcher) to access other processes
     
  18. Ho3n3r

    Ho3n3r Registered

    Joined:
    Feb 18, 2012
    Messages:
    552
    Likes Received:
    104
    Make sure Intel Speedstep is disabled in your BIOS. I had a similar issue a few years ago on an older CPU, and for some reason it always stuck on lower CPU speeds when playing rFactor 2. After disabling Speedstep and keeping the CPU at max, the problem went away.
     
  19. Yotan

    Yotan Registered

    Joined:
    Jan 17, 2012
    Messages:
    83
    Likes Received:
    6
    My CPU is i7-3770k too.
    I had same issue. It solved after read this thread and change "Use thread" to true and "Use Additional Hardware Features" to false in controller.json.
     
    Last edited: Nov 23, 2017
    The Iron Wolf likes this.
  20. Ari Antero

    Ari Antero Registered

    Joined:
    Jul 27, 2012
    Messages:
    1,882
    Likes Received:
    829
    Which motherboard do you have ?
     

Share This Page