Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1374153

Re: [PATCH] sched/fair: Optimize sum computation with a lookup table

From Peter Zijlstra <peterz@infradead.org>
Newsgroups linux.kernel
Subject Re: [PATCH] sched/fair: Optimize sum computation with a lookup table
Date 2016-04-08 13:00 +0200
Message-ID <rlCiS-2wH-7@gated-at.bofh.it> (permalink)
References <rlBmP-1PG-41@gated-at.bofh.it> <rlBZw-2oe-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, Apr 08, 2016 at 03:31:41AM -0700, Joe Perches wrote:
> On Fri, 2016-04-08 at 10:07 +0800, Yuyang Du wrote:
> > __compute_runnable_contrib() uses a loop to compute sum, whereas a
> > table lookup can do it faster in a constant time.
> 
> Perhaps this becomes rather fragile code overly dependent on the
> current #define values of LOAD_AVG_MAX_N and LOAD_AVG_PERIOD.

Too late for that, these tables already heavily depend on these values.

Commit 5b51f2f80b3b ("sched: Make __update_entity_runnable_avg() fast"),
which introduced these tables, includes a program to re-compute the
values if we ever need to change them.

It might maybe make sense for Yuyang to update that program to also
compute this new table and include the whole new program in the
Changelog of this patch.

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] sched/fair: Optimize sum computation with a lookup table Yuyang Du <yuyang.du@intel.com> - 2016-04-08 12:00 +0200
  Re: [PATCH] sched/fair: Optimize sum computation with a lookup table Joe Perches <joe@perches.com> - 2016-04-08 12:40 +0200
    Re: [PATCH] sched/fair: Optimize sum computation with a lookup table Peter Zijlstra <peterz@infradead.org> - 2016-04-08 13:00 +0200
      Re: [PATCH] sched/fair: Optimize sum computation with a lookup table Juri Lelli <juri.lelli@arm.com> - 2016-04-08 18:30 +0200
  Re: [PATCH] sched/fair: Optimize sum computation with a lookup table Peter Zijlstra <peterz@infradead.org> - 2016-04-08 12:50 +0200
  Re: [PATCH] sched/fair: Optimize sum computation with a lookup table Peter Zijlstra <peterz@infradead.org> - 2016-04-08 12:50 +0200
  Re: [PATCH] sched/fair: Optimize sum computation with a lookup table Morten Rasmussen <morten.rasmussen@arm.com> - 2016-04-08 13:30 +0200

csiph-web