cpufreq.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: bugzilla-daemon@bugzilla.kernel.org
To: cpufreq@vger.kernel.org
Subject: [Bug 75121] Intel Pstate driver - powersave mode - CPU frequency too low
Date: Sat, 03 May 2014 03:49:52 +0000	[thread overview]
Message-ID: <bug-75121-12968-qyfeCeUi6W@https.bugzilla.kernel.org/> (raw)
In-Reply-To: <bug-75121-12968@https.bugzilla.kernel.org/>

https://bugzilla.kernel.org/show_bug.cgi?id=75121

--- Comment #12 from Doug Smythies <dsmythies@telus.net> ---
Created attachment 134831
  --> https://bugzilla.kernel.org/attachment.cgi?id=134831&action=edit
CPU 7 frequency vs load. Turbo on. Modified C0 inclusion

There was a stupid mistake in the code change I made in the previous post. Here
it is again, fixed.

static inline void intel_pstate_calc_busy(struct cpudata *cpu,
                                        struct sample *sample)
{
        int32_t core_pct;
        int32_t c0_pct;
        int32_t temp;

// As a float with 6 FRAC_BITS ( 1 << FRAC_BITS / 4 )
#define C0_WEIGHT 16

        core_pct = div_fp(int_tofp((sample->aperf)),
                        int_tofp((sample->mperf)));
        core_pct = mul_fp(core_pct, int_tofp(100));
        FP_ROUNDUP(core_pct);

        c0_pct = div_fp(int_tofp(sample->mperf), int_tofp(sample->tsc));

        sample->freq = fp_toint(
                mul_fp(int_tofp(cpu->pstate.max_pstate * 1000), core_pct));

//      sample->core_pct_busy = core_pct;
//      sample->core_pct_busy = mul_fp(core_pct, c0_pct);
        temp = core_pct - int_tofp(limits.min_perf_pct);
        c0_pct = int_tofp(1) - mul_fp((int_tofp(1) - c0_pct), C0_WEIGHT);
        temp = mul_fp(temp, c0_pct);
        sample->core_pct_busy = temp + int_tofp(limits.min_perf_pct);
}

And the graph shows the effect, for C0_WEIGHT of 1 (Doug3) and 0.25 (Doug 4)

-- 
You are receiving this mail because:
You are the assignee for the bug.

  parent reply	other threads:[~2014-05-03  3:49 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-29 23:47 [Bug 75121] New: Intel Pstate driver - powersave mode - CPU frequency too low bugzilla-daemon
2014-04-29 23:54 ` [Bug 75121] " bugzilla-daemon
2014-04-29 23:56 ` bugzilla-daemon
2014-04-29 23:59 ` bugzilla-daemon
2014-04-30  0:08 ` bugzilla-daemon
2014-05-02 14:25 ` bugzilla-daemon
2014-05-02 23:42 ` bugzilla-daemon
2014-05-02 23:58 ` bugzilla-daemon
2014-05-03  0:03 ` bugzilla-daemon
2014-05-03  0:05 ` bugzilla-daemon
2014-05-03  0:11 ` bugzilla-daemon
2014-05-03  0:19 ` bugzilla-daemon
2014-05-03  0:47 ` bugzilla-daemon
2014-05-03  0:47 ` bugzilla-daemon
2014-05-03  3:49 ` bugzilla-daemon [this message]
2014-05-03  3:58 ` bugzilla-daemon
2014-05-03  4:59 ` bugzilla-daemon
2014-05-03  5:00 ` bugzilla-daemon
2014-05-04 19:18 ` bugzilla-daemon
2014-05-05 18:05 ` bugzilla-daemon
2014-05-05 18:52 ` bugzilla-daemon
2014-05-08 22:19 ` bugzilla-daemon
2014-05-08 22:21 ` bugzilla-daemon
2014-05-08 22:26 ` bugzilla-daemon
2014-05-28 21:22 ` bugzilla-daemon
2014-06-03 20:45 ` bugzilla-daemon
2015-07-21 19:28 ` bugzilla-daemon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-75121-12968-qyfeCeUi6W@https.bugzilla.kernel.org/ \
    --to=bugzilla-daemon@bugzilla.kernel.org \
    --cc=cpufreq@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).