From patchwork Fri Jun 13 22:59:20 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andi Kleen X-Patchwork-Id: 1499 Received: (qmail 409 invoked by alias); 13 Jun 2014 22:59:26 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 391 invoked by uid 89); 13 Jun 2014 22:59:25 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL, BAYES_00, RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: one.firstfloor.org Date: Sat, 14 Jun 2014 00:59:20 +0200 From: Andi Kleen To: Andi Kleen Cc: Andreas Schwab , libc-alpha@sourceware.org, carlos@redhat.com, Andi Kleen Subject: Re: [PATCH 2/3] Add adaptive elision to rwlocks v2 Message-ID: <20140613225920.GD5714@two.firstfloor.org> References: <1402532621-26622-1-git-send-email-andi@firstfloor.org> <1402532621-26622-3-git-send-email-andi@firstfloor.org> <87y4x0y0er.fsf@igel.home> <20140613224633.GC5714@two.firstfloor.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20140613224633.GC5714@two.firstfloor.org> User-Agent: Mutt/1.5.20 (2009-06-14) On Sat, Jun 14, 2014 at 12:46:33AM +0200, Andi Kleen wrote: > On Fri, Jun 13, 2014 at 11:17:32PM +0200, Andreas Schwab wrote: > > Andi Kleen writes: > > > > > @@ -22,6 +22,7 @@ > > > #include > > > #include > > > #include > > > +#include > > > > pthread_rwlock_rdlock.c:25:19: fatal error: elide.h: No such file or directory > > #include > > On what platform is that? Perhaps the fallback file got lost. This patch should fix it. Ok to commit? Author: Andi Kleen Date: Fri Jun 13 15:50:45 2014 -0700 Add fallback file for elide.h Add the missing fallback file for elide.h to fix non x86 builds. Sorry about that. This is just a noop macro file that makes all elision code to be optimized out. 2014-06-13 Andi Kleen * sysdeps/generic/elide.h (ELIDE_LOCK, ELIDE_TRYLOCK, ELIDE_UNLOCK): Add fallback macros. diff --git a/sysdeps/generic/elide.h b/sysdeps/generic/elide.h new file mode 100644 index 0000000..180e632 --- /dev/null +++ b/sysdeps/generic/elide.h @@ -0,0 +1,25 @@ +/* elide.h: Fallback noop lock elision support. + Copyright (C) 2014 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, see + . */ +#ifndef ELIDE_H +#define ELIDE_H 1 + +#define ELIDE_LOCK(adapt_count, is_lock_free) 0 +#define ELIDE_TRYLOCK(adapt_count, is_lock_free, write) 0 +#define ELIDE_UNLOCK(is_lock_free) 0 + +#endif