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


Groups > linux.kernel > #1374429

[PATCH] lockdep: Deinline register_lock_class, save 2328 bytes

From Denys Vlasenko <dvlasenk@redhat.com>
Newsgroups linux.kernel
Subject [PATCH] lockdep: Deinline register_lock_class, save 2328 bytes
Date 2016-04-08 21:10 +0200
Message-ID <rlJX3-7e-9@gated-at.bofh.it> (permalink)
References <rlJNn-8ev-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


This function compiles to 1328 bytes of machine code. Three callsites.

Registering a new lock class is definitely not *that* time-critical to inline it.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
CC: Peter Zijlstra <peterz@infradead.org>
CC: Ingo Molnar <mingo@redhat.com>
CC: linux-kernel@vger.kernel.org
---
 kernel/locking/lockdep.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/locking/lockdep.c b/kernel/locking/lockdep.c
index 53ab2f8..ffad373 100644
--- a/kernel/locking/lockdep.c
+++ b/kernel/locking/lockdep.c
@@ -708,7 +708,7 @@ look_up_lock_class(struct lockdep_map *lock, unsigned int subclass)
  * yet. Otherwise we look it up. We cache the result in the lock object
  * itself, so actual lookup of the hash should be once per lock object.
  */
-static inline struct lock_class *
+static struct lock_class *
 register_lock_class(struct lockdep_map *lock, unsigned int subclass, int force)
 {
 	struct lockdep_subclass_key *key;
-- 
2.1.0

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


Thread

[PATCH] drivers/infiniband/hw/nes/nes_verbs.c: Deinline nes_free_qp_mem, save 1072 bytes Denys Vlasenko <dvlasenk@redhat.com> - 2016-04-08 21:00 +0200
  [PATCH] fs/gfs2/glock.c: Deinline do_error, save 1856 bytes Denys Vlasenko <dvlasenk@redhat.com> - 2016-04-08 21:00 +0200
    Re: [PATCH] fs/gfs2/glock.c: Deinline do_error, save 1856 bytes Bob Peterson <rpeterso@redhat.com> - 2016-04-08 21:20 +0200
      Re: [PATCH] fs/gfs2/glock.c: Deinline do_error, save 1856 bytes Denys Vlasenko <dvlasenk@redhat.com> - 2016-04-08 21:50 +0200
    Re: [PATCH] fs/gfs2/glock.c: Deinline do_error, save 1856 bytes Bob Peterson <rpeterso@redhat.com> - 2016-04-12 18:50 +0200
  [PATCH] lockdep: Deinline register_lock_class, save 2328 bytes Denys Vlasenko <dvlasenk@redhat.com> - 2016-04-08 21:10 +0200
    [tip:locking/core] locking/lockdep: Deinline register_lock_class(),  save 2328 bytes tip-bot for Denys Vlasenko <tipbot@zytor.com> - 2016-04-13 13:40 +0200
  Re: [PATCH] drivers/infiniband/hw/nes/nes_verbs.c: Deinline  nes_free_qp_mem, save 1072 bytes Leon Romanovsky <leon@leon.nu> - 2016-04-11 07:00 +0200

csiph-web