How to: Reduce latencies on Samsung laptops

Discussion in 'Samsung' started by Dannemand, Sep 12, 2012.

Thread Status:
Not open for further replies.
  1. Dannemand

    Dannemand Decidedly Moderate Super Moderator

    Reputations:
    11,279
    Messages:
    4,384
    Likes Received:
    2,031
    Trophy Points:
    231
    Earlier this week, halcyon33 brought up the issue of kernel latency spikes on Samsung laptops, which can make them unsuitable for real-time audio and other CPU critical tasks.

    Basically these are cases where a piece of code "monopolizes" the CPU, either because it is poorly written (some Samsung utilities) or because it is critical code which must complete without interruption (some hardware drivers).

    After several days of tests and trials and tribulations between halcyon and myself, I think we have some conclusions on how to reduce or even eliminate these latencies. Even though we are both on Series 7 (halcyon on NP700Z5C and I on NP700Z3A) we expect our findings to apply to other Samsung models as well.

    PLease see the Samsung Series 7 Laptops - 15.0" and 15.6" Models (NP700Z4 & NP700Z5) thread for our discussion, starting at this post.

    I have relied entirely on LatencyMon from Resplendence Software to diagnose. halcyon33 also used DPC Latency.

    As far as I can tell, the following are the biggest contributors to high kernel latencies (not in order of severity):

    1) Easy Software Manager (ESWM). I believe what happens is, when ESWM checks for updates in the background, it causes Windows to rebuild its hardware device tree, which monopolizes the CPU for a few seconds. I recommend using ESWM after a clean Windows install to load drivers and necessary utilities (and load them in the correct order), then uninstall it afterwards. Use samsung.com to check for updates after that -- or simply install ESWM temporarily.

    2) Easy Settings. This package includes seven different modules that manipulate hardware and the low levels of the Windows operating system. It provides some significant features (including Fn-keys), but unfortunately it is not very well implemented, and many of these modules monopolize the CPU while running in the backgound.

    I recommend installing Easy Settings, copying its folder (C:\Program Files (x86)\Samsung\Easy Settings), then uninstalling the entire package. After this, the Fn-keys can be activated by loading the EasyDisplayMgr module (dmhkcore.exe) using either a shortcut in the Start Menu-Startup folder or one of the Run keys in the in the registry.

    3) Norton Internet Security. Never install Norton anything. ;) High kernel latencies is just one more reason. Seriously.

    4) Intel PROSet Wireless AND Bluetooth High-Speed drivers. Intel bundles a tremendous amount of bloatware with its WLAN and Bluetooth drivers, most of it running constantly in the background, causing kernel latencies to spike.

    Furthermore, there is an outright bug in most versions of the Intel 6230/6235 driver, causing it to drop WiFi a few mins after login: It will start happening if you ever disable/enable the Intel adapter in Device Manager. Then you'll have to disable/enable it on every reboot thereafter. Easy Settings' WLANStartup module exists to compensate for this bug, by performing disable/enable behind the scenes after user login. As long as you've never disabled the adapter in Device Manager (AND you don't have Easy Settings installed which disables/enables it behind your back), your network should be running promtply after login -- and stay connected.

    Of course we need WLAN and Bluetooth to work, so here is what I recommend: Do NOT install any of the full Intel PROSet Wireless/Blutooth packages, and do NOT install any of the following with Easy Software Manager:

    - Wiresless LAN driver
    - Bluetooth driver
    - Intel Wireless Display (maybe OK if installed later)

    Download and install Intel PROSet/Wireless driver version 15.2.0 from this Intel website. Make sure you download the DRIVER ONLY version, NOT the full software. The file is called Wireless_15.2.0_Ds64.exe (Google it if the link stops working). There are no options to choose, it just runs for a minute, displaying an animation. This should load drivers for your Intel 6230/6235 WiFi adapter which do NOT suffer from the problems described above.

    Windows 7 supports basic Bluetooth out of the box, including support for the Intel Bluetooth adapter. If you need Intel's newer and more elaborate Bluetooth features, just know that it comes at the price of somewhat higher kernel latencies.

    Note: I would love to hear from users of Broadcom WiFi how its drivers behave with regards to latencies.

    5) Windows System Restore. This is the Windows feature which allows you to save Restore Points and roll back to them in case your Windows installation gets messy. This is a great feature, but unfortunately it causes high kernel latencies and lots of page faults. It can be disabled under Control Panel-System-System Restore. If you do disable it, I recommend using an imaging tool (3rd party, Windows WIM or Samsung SRS5) to backup your Windows drive at regular intervals.

    6) Other Samsung latency suspects. In addition to the above, I would avoid installing the following utilities and bloatware, even though I have not seen hard evidence that they cause latency spikes.

    - CyberLink Youcam
    - CyberLink Media Suite
    - Samsung Recovery Solution 5
    - Intel Management Engine/HECI (use Windows update to install just the driver, saves a lot of uncessary overhead)

    7) Other Windows latency suspects. Even though I don't have hard evidence, I suspect some Windows 7 features could contribute to latency spikes. Particularly the media feaures, which trigger background tasks related to the MediaLibrary. For more suspects as well as a general list of bloatware that are candidates for removal, please see this recent post.

    Once these are removed, LatencyMon should be able to run for an extended time without excessive latency spikes. In my tests, I have run the Windows Performance Index Assesment and a network speedtest on speedtest.net. This lets LatencyMon run for a while and stresses some of the critical components that might trigger spikes. But even just sitting there doing nothing can suddenly show latency spikes, becuse it triggers some of those pesky background tasks that either run on regular intervals or when the PC is idle.

    In addition to making the system suitable for real-time tasks, reducing (or eliminating) latency spikes also makes it more responsive in general :)

    This is the first summarized write-up of our findings -- and we still have some tests to do before we can call this wrapped up. Until then, any comments or tests from others are highly welcome.

    It is important to point out that latencies are not a "black and white" issue: Less is better than more, but there will always be some; a single bad progam can completely jeopardize the system; but so can multiple programs or modules that are mere "demanding" which happen to trigger at the same time. That makes diagnosis rather difficult and time consuming.

    So please don't be too hard on us if your findings turn out differently. Just post it here so we can update the conclusions. :eek:

    Updates 2012-12-11:

    - As pointed out by Syl_M Intel has updated WiFi drivers out.

    - Prompted by a question from rhadoo, I finally got around to writing updates regarding alternative Easy Settings tweaks as well as info about Easy Settings 2.x. The post also contains a more comprehensive (and hopefully coherent :eek:) installation guide with various links. Posted here in the thread (that was a link).
     
    toughasnails and Ripcord999 like this.
  2. John Ratsey

    John Ratsey Moderately inquisitive Super Moderator

    Reputations:
    7,167
    Messages:
    28,880
    Likes Received:
    1,972
    Trophy Points:
    581
    Thank you for your research and this article.

    I've added this thread to the General section of the sticky index so it will be easy to find next time someone has latency problems (although Google has already got this thread near the top of the"Samsung latency" list).

    John
     
  3. bertsirkin

    bertsirkin Notebook Geek

    Reputations:
    11
    Messages:
    91
    Likes Received:
    3
    Trophy Points:
    16
    My NP900X3C-A04US is being delivered today - coming from a series of IBM/Lenovo laptops, Samsung-buyers-regret is starting to sink-in.

    Sorry if this post is lengthy, but, hopefully others will find the process useful.

    The first thing I’m planning on doing is installing a clean-install of Windows 7/64 professional. Based on the above software issues, The process I’m planning to use is as follows:

    1) Create a backup using Acronis 2013 True Image to my network
    2) Clean install Windows 7/64 Pro
    3) Install the following Samsung drivers:
    a) VGA(Graphics),INTEL (Driver) (ver.8.15.10.2618)
    b) Chipset (Driver) (ver.9.3.0.1019)
    c) HECI (Driver) (ver.8.0.0.1262)
    d) Intel Rapid Start Technology (Driver) (ver.1.0.0.1015)
    e) Intel Rapid Storage (Driver) (ver.11.0.0.1032)
    f) Lan (Driver) (ver.7.50.1123.2011)
    g) Sound(Audio) (Driver) (ver.6.0.1.6699)
    h) Touchpad (Driver) (ver.10.7.17.5)
    i) USB 3.0 (Driver) (ver.3.0.20.0)
    j) USB 3.0 Firmware (Driver) (ver.2.0.1.7)​

    4) DON’T install the following Samsung drivers:
    a) Wireless LAN,INTEL (Driver) (ver.15.0.0.75)
    b) Bluetooth (Driver) (ver.2.0.15.30131)​

    5) Install the following INTEL Wireless Driver:
    a) Intel® PROSet/Wireless Software and Drivers for Windows 7​

    6) Install the following Samsung Software
    a) Easy Support Center (Software) (ver.1.2.2.8)
    b) Install Guide (Software) (ver.1.9.0.0)
    c) MCE Update (Software) (ver.2.2.2.0)

    7) DON’T install the following Software:
    a) Easy Software manager (Software) (ver.1.2.22.16)
    b) Easy Settings (Software) (ver.1.1.1.4)
    c) Easy File Share (Software) (ver.1.2.4.8)
    d) Easy Migration (Software) (ver.1.0.0.19)
    e) Recovery Solution (Software) (ver.5.0.2.6)
    f) Software Launcher (Software) (ver.1.1.1.9)​

    The two items I'm not sure about are the HECI driver and the MCE Update Software - do I need either of these?

    Anything else I may be missing??

    thanks,
    bert
     
  4. Dannemand

    Dannemand Decidedly Moderate Super Moderator

    Reputations:
    11,279
    Messages:
    4,384
    Likes Received:
    2,031
    Trophy Points:
    231
    Thank you, John :)
     
    toughasnails likes this.
  5. Dannemand

    Dannemand Decidedly Moderate Super Moderator

    Reputations:
    11,279
    Messages:
    4,384
    Likes Received:
    2,031
    Trophy Points:
    231
    @bertsirkin: That was my next project: a recipe for a "lean" Windows install. You beat me to it :D

    I have some suggested changes for you, but it'll have to wait till tonight.

    As for buyers remorse, please remember that I am targeting an extreme setup, suitable for real-time applications, that can run for an extended period without any latency spikes.

    For most users, occasional spikes is not a problem.
     
    toughasnails likes this.
  6. bertsirkin

    bertsirkin Notebook Geek

    Reputations:
    11
    Messages:
    91
    Likes Received:
    3
    Trophy Points:
    16
    I suspect that the "lean" install will be a work-in-progress, with multiple options, depending on the users needs.

    Another option might be, although not as "clean" as a clean-install, would be a list of what to delete.

    Fedex just delivered the NP900X3C-A04US a little while ago, and I'm doing an Acronis image right now.

    I may also create the restore DVDs before I start doing anything stupid :)

    bert
     
  7. Dannemand

    Dannemand Decidedly Moderate Super Moderator

    Reputations:
    11,279
    Messages:
    4,384
    Likes Received:
    2,031
    Trophy Points:
    231
    Actually, I already posted my suggestion for a list of what to delete from a factory install (and conversely what to avoid installing during a clean install). I included a link in the opening post under (7). Here it is again.

    And congrats on your new your new laptop, that's a great machine. Since you're already doing imaging and backup, this post describes the steps I perform on a new laptop to make sure I can always recover, or get it back to factory state in case I want to sell it some day.

    Enjoy you new machine :)
     
    toughasnails likes this.
  8. bertsirkin

    bertsirkin Notebook Geek

    Reputations:
    11
    Messages:
    91
    Likes Received:
    3
    Trophy Points:
    16
    Great post - especially with the descriptions of everything.

    This may be the wrong thread for this, but I'll ask anyway:

    Using the Samsung F4" boot option, I created a "System Software" backup that appears to have an EXE and other files to re-install the drivers, but I'm not sure if I would have the ability to install just selected drivers.

    I also downloaded the drivers from the Samsung site.

    My inclination is to install the drivers from the Samsung site - any thoughts?

    Also, the SSD came with 4 partitions: C:, D: (BOOT, Sys Volume Info and bootmgr, (1-3) (strange name, with no assigned drive letter and nothing on it) and "SAMSUNG_REC" (appears to be the F4-backup/restore software).

    Can I assume that all of these partitions can be trashed on a clean-install (assuming I've backed everything up to DVD and will be imaging the drive for backup)?

    thanks,
    bert
     
  9. Dannemand

    Dannemand Decidedly Moderate Super Moderator

    Reputations:
    11,279
    Messages:
    4,384
    Likes Received:
    2,031
    Trophy Points:
    231
    @Bert, here are my comments on your suggested install. Hope it reaches you in time (seeing that you're already started ;) )

    1) You don't have to image the entire drive. As long as you have a backup of the Recovery partition AND the USB Admin Tool, you can always get back to factory. USB Admin Tool is created from Recovery Management Mode. See this post for details.

    3) I recommend you use Easy Software Manager to install the drivers, both because it is a lot faster and because it ensures the right order. You can either install it from a System Software backup OR just download it. If you leave your Recovery Partition intact, it will simply pull all the drivers from there, then update them once you have network access. You can uninstall it afterwards.

    If you prefer to download and install manually, here is the driver sequence I would use:

    - Chipset
    - Intel Rapid Storage (disable tray icon if you want)
    - USB3
    - Touchpad
    - Graphics
    - Sound (disable tray icon if you want)
    - LAN
    - Any firmware/BIOS udates

    I would NOT install the HECI package from Samsung. It comes with quite a bit of overhead which is unnecessary for 99% of users. Instead, just install the Intel ME driver that comes with Windows Update.

    As for Intel Rapid Start, I would wait until everything else is installed and running. I don't have it on my Series 7, but it was on a Series 5 I had previosuly.

    4-5) Correct, don't install ANY Intel PROSet or Bluetooth packages except the Wireless_15.2.0_Ds64.exe linked in the opening post.

    I would also install Ms_Hotfix_Critical and MS_Hotfix_common before connecting to the network for the first time.

    6) I personally don't have Easy Support Center or Samsung Install Guide. I doubt you will need them.

    As for MCE Update, I have MCE uninstalled on my PC and don't install the update either. If you have MCE, install the update.

    7) Samsung Recovery Solution can be useful, but since you have Acronis, you won't need it.

    Regarding Easy Settings, it is very central to the functionality of Samsung laptops, but unfortunately it has these issues with latency, delayed loading and more. If you can live with the issues, there are good reasons to install it. At the least would I do the hacked installation described in the opening post so that you have Fn keys.

    I think you're good to go!
     
    toughasnails likes this.
  10. bertsirkin

    bertsirkin Notebook Geek

    Reputations:
    11
    Messages:
    91
    Likes Received:
    3
    Trophy Points:
    16
    Thanks!

    I haven't started anything yet, am just downloading Windows 7 Pro from MSDN and have extracted the existing Windows 7 Pro product key from the laptop.

    I'll try installing the drivers one-by-one - I just feel more comfortable that way (I don't like anything that does stuff I don't know about -it's a "control" issue I have!). The worst that can happen is I have to re-install.

    I'll let you know how it goes.

    thanks,
    bert
     
Thread Status:
Not open for further replies.

Share This Page