Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751652Ab0DJOBt (ORCPT ); Sat, 10 Apr 2010 10:01:49 -0400 Received: from bombadil.infradead.org ([18.85.46.34]:47687 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751317Ab0DJOBr convert rfc822-to-8bit (ORCPT ); Sat, 10 Apr 2010 10:01:47 -0400 Subject: Re: Question about lock sequence From: Peter Zijlstra To: Hitoshi Mitake Cc: LKML , Ingo Molnar , Frederic Weisbecker , Paul Mackerras , Arnaldo Carvalho de Melo In-Reply-To: <4BC05677.7070406@dcl.info.waseda.ac.jp> References: <4BC05677.7070406@dcl.info.waseda.ac.jp> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT Date: Sat, 10 Apr 2010 16:01:51 +0200 Message-ID: <1270908111.4222.4.camel@twins> Mime-Version: 1.0 X-Mailer: Evolution 2.28.1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2364 Lines: 53 On Sat, 2010-04-10 at 19:44 +0900, Hitoshi Mitake wrote: > Hi, > > I found that my understand about lockdep is completely wrong :( , > so state machine of perf lock should be fixed before optimization. > > And I found that behaviour related to some of spin locks are strange. > The concrete example is lock sequences targeting dcache_lock (defined in > head of fs/dcache.c). > > I made a little (and not essential) change to perf lock, and observe > lock sequence targeting it. > Changed perf lock shows sequence of locks in time order, > and I grepped the output of it with dcache, like this: > > % sudo ./perf lock report | grep dcache > > The head part of result is this: > # -