public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Rusty Russell <rusty@rustcorp.com.au>
To: "Jan Beulich" <JBeulich@novell.com>
Cc: "Michal Marek" <mmarek@suse.cz>,
	linux-kernel@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH] no need to align .modinfo strings
Date: Mon, 6 Sep 2010 17:49:55 +0930	[thread overview]
Message-ID: <201009061749.56921.rusty@rustcorp.com.au> (raw)
In-Reply-To: <4C7FB3A80200007800013F22@vpn.id2.novell.com>

On Thu, 2 Sep 2010 09:54:40 pm Jan Beulich wrote:
> Their use is not performance critical, and hence it seems better to
> save some space.
> 
> Signed-off-by: Jan Beulich <jbeulich@novell.com>

Acked-by: Rusty Russell <rusty@rustcorp.com.au>

The real question is: why is gcc aligning these?  Should it be aligning
any string literals at all?  If so, should we look for other such wastes
of space?

Thanks,
Rusty.

> --- linux-2.6.36-rc3/include/linux/moduleparam.h
> +++ 2.6.36-rc3-modinfo-align/include/linux/moduleparam.h
> @@ -21,8 +21,8 @@
>  #define __module_cat(a,b) ___module_cat(a,b)
>  #define __MODULE_INFO(tag, name, info)					  \
>  static const char __module_cat(name,__LINE__)[]				  \
> -  __used								  \
> -  __attribute__((section(".modinfo"),unused)) = __stringify(tag) "=" info
> +  __used __attribute__((section(".modinfo"), unused, aligned(1)))	  \
> +  = __stringify(tag) "=" info
>  #else  /* !MODULE */
>  #define __MODULE_INFO(tag, name, info)
>  #endif
> 
> 
> 

  reply	other threads:[~2010-09-06  8:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-02 12:24 [PATCH] no need to align .modinfo strings Jan Beulich
2010-09-06  8:19 ` Rusty Russell [this message]
2010-09-06  8:34   ` Jan Beulich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201009061749.56921.rusty@rustcorp.com.au \
    --to=rusty@rustcorp.com.au \
    --cc=JBeulich@novell.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mmarek@suse.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox