public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Voluspa <lista1@comhem.se>
To: arjan@infradead.org
Cc: ak@suse.de, linux-kernel@vger.kernel.org
Subject: Re: [patch 1/2] sLeAZY FPU feature - x86_64 support
Date: Sun, 2 Jul 2006 03:39:11 +0200 (MEST)	[thread overview]
Message-ID: <19484194.1151804351308.JavaMail.tomcat@pne-ps3-sn2> (raw)

You have a very strange 2.6.17 kernel there. The include/linux/sched.h is so 
incompatible that the patching (with fuzz) places "unsigned char fpu_counter;" 
in a totally unrelated struct, and not in "struct task_struct  {".

Here's a working rebase of that part - sorry about mangling by this webmail 
client... Btw, the whole thing has no measurable effect on real world stuff 
like rendering through blender - on my machine, at least.

diff -Nur linux-2.6.17-git19-original/include/linux/sched.h linux-2.6.17-git19-
sleazyfpu/include/linux/sched.h
--- linux-2.6.17-git19-original/include/linux/sched.h   2006-07-02 01:17:
36.000000000 +0200
+++ linux-2.6.17-git19-sleazyfpu/include/linux/sched.h  2006-07-02 01:10:
42.000000000 +0200
@@ -926,6 +926,16 @@
         * cache last used pipe for splice
         */
        struct pipe_inode_info *splice_pipe;
+
+       /*
+       * fpu_counter contains the number of consecutive context switches
+       * that the FPU is used. If this is over a threshold, the lazy fpu
+       * saving becomes unlazy to save the trap. This is an unsigned char
+       * so that after 256 times the counter wraps and the behavior turns
+       * lazy again; this to deal with bursty apps that only use FPU for
+       * a short time
+       */
+       unsigned char fpu_counter;
 };
 
 static inline pid_t process_group(struct task_struct *tsk)

Mvh
Mats Johannesson


             reply	other threads:[~2006-07-02  1:39 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-02  1:39 Voluspa [this message]
2006-07-02  7:39 ` [patch 1/2] sLeAZY FPU feature - x86_64 support Arjan van de Ven
  -- strict thread matches above, loose matches on Subject: below --
2006-07-01 17:11 [patch 0/2] sLeAZY FPU feature Arjan van de Ven
2006-07-01 17:12 ` [patch 1/2] sLeAZY FPU feature - x86_64 support Arjan van de Ven
2006-07-01 21:49   ` Andi Kleen
2006-07-01 21:56     ` Arjan van de Ven

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=19484194.1151804351308.JavaMail.tomcat@pne-ps3-sn2 \
    --to=lista1@comhem.se \
    --cc=ak@suse.de \
    --cc=arjan@infradead.org \
    --cc=linux-kernel@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