13 May, 2010

1 commit

  • If there are no active threasd using a semaphore, it is always correct
    to unqueue blocked threads. This seems to be what was intended in the
    undo code.

    What was done instead, was to look for a sem count of zero - this is an
    impossible situation, given that at least one thread is known to be
    queued on the semaphore. The code might be correct as written, but it's
    hard to reason about and it's not what was intended (otherwise the goto
    out would have been unconditional).

    Go for checking the active count - the alternative is not worth the
    headache.

    Signed-off-by: Michel Lespinasse
    Signed-off-by: David Howells
    Signed-off-by: Linus Torvalds

    Michel Lespinasse
     

30 Jan, 2008

1 commit

  • introduce the "asmregparm" calling convention: for functions
    implemented in assembly with a fixed regparm input parameters
    calling convention.

    mark the semaphore and rwsem slowpath functions with that.

    Signed-off-by: Ingo Molnar
    Signed-off-by: Miklos Szeredi
    Signed-off-by: Thomas Gleixner

    Ingo Molnar
     

18 Dec, 2007

1 commit

  • This following commit

    http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=fdf8cb0909b531f9ae8f9b9d7e4eb35ba3505f07

    un-inlined a low-level rwsem function, but did not mark it as __sched.
    The result is that it now shows up as thread wchan (which also affects
    /proc/profile stats). The following simple patch fixes this by properly
    marking rwsem_down_failed_common() as a __sched function.

    Also in this patch, which is up for discussion, marks down_read() and
    down_write() proper as __sched. For profiling, it is pretty much
    useless to know that a semaphore is beig help - it is necessary to know
    _which_ one. By going up another frame on the stack, the information
    becomes much more useful.

    In summary, the below change to lib/rwsem.c should be applied; the
    changes to kernel/rwsem.c could be applied if other kernel hackers agree
    with my proposal that down_read()/down_write() in the profile is not
    enough.

    [ akpm@linux-foundation.org: build fix ]

    Signed-off-by: Livio Soares
    Signed-off-by: Andrew Morton
    Signed-off-by: Ingo Molnar

    Livio Soares
     

11 Oct, 2006

1 commit


30 Sep, 2006

1 commit

  • Un-inlining rwsem_down_failed_common() (two callsites) reduced lib/rwsem.o
    on my Athlon, gcc 4.1.2 from 5935 to 5480 Bytes (455 Bytes saved).

    I thus guess that reduced icache footprint (and better function caching) is
    worth more than any function call overhead.

    Signed-off-by: Andreas Mohr
    Cc: David Howells
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andreas Mohr
     

04 Jul, 2006

2 commits


01 May, 2005

1 commit


17 Apr, 2005

1 commit

  • Initial git repository build. I'm not bothering with the full history,
    even though we have it. We can create a separate "historical" git
    archive of that later if we want to, and in the meantime it's about
    3.2GB when imported into git - space that would just make the early
    git days unnecessarily complicated, when we don't have a lot of good
    infrastructure for it.

    Let it rip!

    Linus Torvalds