Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-13 Thread Ezequiel Garcia
On Thu, Sep 13, 2012 at 4:17 AM, Michal Marek  wrote:
> Dne 13.9.2012 02:30, Ezequiel Garcia napsal(a):
>> Hi,
>>
>> On Sun, Sep 9, 2012 at 6:25 PM, David Rientjes  wrote:
>>> On Sat, 8 Sep 2012, Ezequiel Garcia wrote:
>>>
 diff --git a/Makefile b/Makefile
 index ddf5be9..df6045a 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -561,6 +561,10 @@ else
  KBUILD_CFLAGS+= -O2
  endif

 +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
 +KBUILD_CFLAGS+= -fno-inline-small-functions
>>>
>>> This isn't the only option that controls automatic inlining of functions,
>>> see indirect-inlining, inline-functions, and inline-functions-called-once.
>>>
>>
>> I'll check about this gcc options and re-send, renamed as:
>> CONFIG_DISABLE_CC_AUTOMATIC_INLINING
>
> Please name it CONFIG_CC_
>

Yeah, that's what I meant, sorry.

Ezequiel.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-13 Thread Michal Marek
Dne 13.9.2012 02:30, Ezequiel Garcia napsal(a):
> Hi,
> 
> On Sun, Sep 9, 2012 at 6:25 PM, David Rientjes  wrote:
>> On Sat, 8 Sep 2012, Ezequiel Garcia wrote:
>>
>>> diff --git a/Makefile b/Makefile
>>> index ddf5be9..df6045a 100644
>>> --- a/Makefile
>>> +++ b/Makefile
>>> @@ -561,6 +561,10 @@ else
>>>  KBUILD_CFLAGS+= -O2
>>>  endif
>>>
>>> +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
>>> +KBUILD_CFLAGS+= -fno-inline-small-functions
>>
>> This isn't the only option that controls automatic inlining of functions,
>> see indirect-inlining, inline-functions, and inline-functions-called-once.
>>
> 
> I'll check about this gcc options and re-send, renamed as:
> CONFIG_DISABLE_CC_AUTOMATIC_INLINING

Please name it CONFIG_CC_

Michal

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-13 Thread Michal Marek
Dne 13.9.2012 02:30, Ezequiel Garcia napsal(a):
 Hi,
 
 On Sun, Sep 9, 2012 at 6:25 PM, David Rientjes rient...@google.com wrote:
 On Sat, 8 Sep 2012, Ezequiel Garcia wrote:

 diff --git a/Makefile b/Makefile
 index ddf5be9..df6045a 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -561,6 +561,10 @@ else
  KBUILD_CFLAGS+= -O2
  endif

 +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
 +KBUILD_CFLAGS+= -fno-inline-small-functions

 This isn't the only option that controls automatic inlining of functions,
 see indirect-inlining, inline-functions, and inline-functions-called-once.

 
 I'll check about this gcc options and re-send, renamed as:
 CONFIG_DISABLE_CC_AUTOMATIC_INLINING

Please name it CONFIG_CC_something

Michal

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-13 Thread Ezequiel Garcia
On Thu, Sep 13, 2012 at 4:17 AM, Michal Marek mma...@suse.cz wrote:
 Dne 13.9.2012 02:30, Ezequiel Garcia napsal(a):
 Hi,

 On Sun, Sep 9, 2012 at 6:25 PM, David Rientjes rient...@google.com wrote:
 On Sat, 8 Sep 2012, Ezequiel Garcia wrote:

 diff --git a/Makefile b/Makefile
 index ddf5be9..df6045a 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -561,6 +561,10 @@ else
  KBUILD_CFLAGS+= -O2
  endif

 +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
 +KBUILD_CFLAGS+= -fno-inline-small-functions

 This isn't the only option that controls automatic inlining of functions,
 see indirect-inlining, inline-functions, and inline-functions-called-once.


 I'll check about this gcc options and re-send, renamed as:
 CONFIG_DISABLE_CC_AUTOMATIC_INLINING

 Please name it CONFIG_CC_something


Yeah, that's what I meant, sorry.

Ezequiel.
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-12 Thread Ezequiel Garcia
Hi,

On Sun, Sep 9, 2012 at 6:25 PM, David Rientjes  wrote:
> On Sat, 8 Sep 2012, Ezequiel Garcia wrote:
>
>> diff --git a/Makefile b/Makefile
>> index ddf5be9..df6045a 100644
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -561,6 +561,10 @@ else
>>  KBUILD_CFLAGS+= -O2
>>  endif
>>
>> +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
>> +KBUILD_CFLAGS+= -fno-inline-small-functions
>
> This isn't the only option that controls automatic inlining of functions,
> see indirect-inlining, inline-functions, and inline-functions-called-once.
>

I'll check about this gcc options and re-send, renamed as:
CONFIG_DISABLE_CC_AUTOMATIC_INLINING

Thanks for both your feedback,
Ezequiel.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-12 Thread Ezequiel Garcia
Hi,

On Sun, Sep 9, 2012 at 6:25 PM, David Rientjes rient...@google.com wrote:
 On Sat, 8 Sep 2012, Ezequiel Garcia wrote:

 diff --git a/Makefile b/Makefile
 index ddf5be9..df6045a 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -561,6 +561,10 @@ else
  KBUILD_CFLAGS+= -O2
  endif

 +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
 +KBUILD_CFLAGS+= -fno-inline-small-functions

 This isn't the only option that controls automatic inlining of functions,
 see indirect-inlining, inline-functions, and inline-functions-called-once.


I'll check about this gcc options and re-send, renamed as:
CONFIG_DISABLE_CC_AUTOMATIC_INLINING

Thanks for both your feedback,
Ezequiel.
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-09 Thread David Rientjes
On Sat, 8 Sep 2012, Ezequiel Garcia wrote:

> diff --git a/Makefile b/Makefile
> index ddf5be9..df6045a 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -561,6 +561,10 @@ else
>  KBUILD_CFLAGS+= -O2
>  endif
>  
> +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
> +KBUILD_CFLAGS+= -fno-inline-small-functions

This isn't the only option that controls automatic inlining of functions, 
see indirect-inlining, inline-functions, and inline-functions-called-once.

> +endif
> +
>  include $(srctree)/arch/$(SRCARCH)/Makefile
>  
>  ifdef CONFIG_READABLE_ASM
> diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
> index 2403a63..c8fd50f 100644
> --- a/lib/Kconfig.debug
> +++ b/lib/Kconfig.debug
> @@ -1265,6 +1265,17 @@ config LATENCYTOP
>  source mm/Kconfig.debug
>  source kernel/trace/Kconfig
>  
> +config DISABLE_GCC_AUTOMATIC_INLINING
> + bool "Disable gcc automatic inlining"
> + depends on TRACING
> + help
> +   This option tells gcc he's not allowed to inline functions 
> automatically,
> +   when they are not marked as 'inline'.
> +   In turn, this enables to trace an event with an accurate call site.
> +   Of course, the resultant kernel is slower and slightly smaller.
> +
> +   Select this option only if you want to trace call sites accurately.
> +
>  config PROVIDE_OHCI1394_DMA_INIT
>   bool "Remote debugging over FireWire early on boot"
>   depends on PCI && X86
> -- 
> 1.7.8.6
> 
> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to majord...@kvack.org.  For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: mailto:"d...@kvack.org;> em...@kvack.org 
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-09 Thread David Rientjes
On Sat, 8 Sep 2012, Ezequiel Garcia wrote:

 diff --git a/Makefile b/Makefile
 index ddf5be9..df6045a 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -561,6 +561,10 @@ else
  KBUILD_CFLAGS+= -O2
  endif
  
 +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
 +KBUILD_CFLAGS+= -fno-inline-small-functions

This isn't the only option that controls automatic inlining of functions, 
see indirect-inlining, inline-functions, and inline-functions-called-once.

 +endif
 +
  include $(srctree)/arch/$(SRCARCH)/Makefile
  
  ifdef CONFIG_READABLE_ASM
 diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
 index 2403a63..c8fd50f 100644
 --- a/lib/Kconfig.debug
 +++ b/lib/Kconfig.debug
 @@ -1265,6 +1265,17 @@ config LATENCYTOP
  source mm/Kconfig.debug
  source kernel/trace/Kconfig
  
 +config DISABLE_GCC_AUTOMATIC_INLINING
 + bool Disable gcc automatic inlining
 + depends on TRACING
 + help
 +   This option tells gcc he's not allowed to inline functions 
 automatically,
 +   when they are not marked as 'inline'.
 +   In turn, this enables to trace an event with an accurate call site.
 +   Of course, the resultant kernel is slower and slightly smaller.
 +
 +   Select this option only if you want to trace call sites accurately.
 +
  config PROVIDE_OHCI1394_DMA_INIT
   bool Remote debugging over FireWire early on boot
   depends on PCI  X86
 -- 
 1.7.8.6
 
 --
 To unsubscribe, send a message with 'unsubscribe linux-mm' in
 the body to majord...@kvack.org.  For more info on Linux MM,
 see: http://www.linux-mm.org/ .
 Don't email: a href=mailto:d...@kvack.org; em...@kvack.org /a
 
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-08 Thread Sam Ravnborg
On Sat, Sep 08, 2012 at 05:47:50PM -0300, Ezequiel Garcia wrote:
> As its name suggest this option prevents gcc from auto inlining
> small functions. This is very important if one wants to obtain
> traces with accurate call sites.
> 
> Without this option, gcc will collapse some small functions,
> even when not marked as 'inline' thus making impossible to
> correlate the trace caller address to the real function it belongs.
> 
> Of course, the resultant kernel is slower and slightly smaller,
> but that's not an issue if the focus is on tracing accuracy.
> 
> Cc: Michal Marek 
> Signed-off-by: Ezequiel Garcia 
> ---
>  Makefile  |4 
>  lib/Kconfig.debug |   11 +++
>  2 files changed, 15 insertions(+), 0 deletions(-)
> 
> diff --git a/Makefile b/Makefile
> index ddf5be9..df6045a 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -561,6 +561,10 @@ else
>  KBUILD_CFLAGS+= -O2
>  endif
>  
> +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
> +KBUILD_CFLAGS+= -fno-inline-small-functions
> +endif
> +
>  include $(srctree)/arch/$(SRCARCH)/Makefile
>  
>  ifdef CONFIG_READABLE_ASM
> diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
> index 2403a63..c8fd50f 100644
> --- a/lib/Kconfig.debug
> +++ b/lib/Kconfig.debug
> @@ -1265,6 +1265,17 @@ config LATENCYTOP
>  source mm/Kconfig.debug
>  source kernel/trace/Kconfig
>  
> +config DISABLE_GCC_AUTOMATIC_INLINING
> + bool "Disable gcc automatic inlining"

Could we please call this option for:
config CC_DISABLE_AUTOMATIC_INLINING

We have at least a few other options following that naming scheme.
And today we have no options named *GCC_*

Sam
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-08 Thread Ezequiel Garcia
As its name suggest this option prevents gcc from auto inlining
small functions. This is very important if one wants to obtain
traces with accurate call sites.

Without this option, gcc will collapse some small functions,
even when not marked as 'inline' thus making impossible to
correlate the trace caller address to the real function it belongs.

Of course, the resultant kernel is slower and slightly smaller,
but that's not an issue if the focus is on tracing accuracy.

Cc: Michal Marek 
Signed-off-by: Ezequiel Garcia 
---
 Makefile  |4 
 lib/Kconfig.debug |   11 +++
 2 files changed, 15 insertions(+), 0 deletions(-)

diff --git a/Makefile b/Makefile
index ddf5be9..df6045a 100644
--- a/Makefile
+++ b/Makefile
@@ -561,6 +561,10 @@ else
 KBUILD_CFLAGS  += -O2
 endif
 
+ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
+KBUILD_CFLAGS  += -fno-inline-small-functions
+endif
+
 include $(srctree)/arch/$(SRCARCH)/Makefile
 
 ifdef CONFIG_READABLE_ASM
diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
index 2403a63..c8fd50f 100644
--- a/lib/Kconfig.debug
+++ b/lib/Kconfig.debug
@@ -1265,6 +1265,17 @@ config LATENCYTOP
 source mm/Kconfig.debug
 source kernel/trace/Kconfig
 
+config DISABLE_GCC_AUTOMATIC_INLINING
+   bool "Disable gcc automatic inlining"
+   depends on TRACING
+   help
+ This option tells gcc he's not allowed to inline functions 
automatically,
+ when they are not marked as 'inline'.
+ In turn, this enables to trace an event with an accurate call site.
+ Of course, the resultant kernel is slower and slightly smaller.
+
+ Select this option only if you want to trace call sites accurately.
+
 config PROVIDE_OHCI1394_DMA_INIT
bool "Remote debugging over FireWire early on boot"
depends on PCI && X86
-- 
1.7.8.6

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-08 Thread Ezequiel Garcia
As its name suggest this option prevents gcc from auto inlining
small functions. This is very important if one wants to obtain
traces with accurate call sites.

Without this option, gcc will collapse some small functions,
even when not marked as 'inline' thus making impossible to
correlate the trace caller address to the real function it belongs.

Of course, the resultant kernel is slower and slightly smaller,
but that's not an issue if the focus is on tracing accuracy.

Cc: Michal Marek mma...@suse.cz
Signed-off-by: Ezequiel Garcia elezegar...@gmail.com
---
 Makefile  |4 
 lib/Kconfig.debug |   11 +++
 2 files changed, 15 insertions(+), 0 deletions(-)

diff --git a/Makefile b/Makefile
index ddf5be9..df6045a 100644
--- a/Makefile
+++ b/Makefile
@@ -561,6 +561,10 @@ else
 KBUILD_CFLAGS  += -O2
 endif
 
+ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
+KBUILD_CFLAGS  += -fno-inline-small-functions
+endif
+
 include $(srctree)/arch/$(SRCARCH)/Makefile
 
 ifdef CONFIG_READABLE_ASM
diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
index 2403a63..c8fd50f 100644
--- a/lib/Kconfig.debug
+++ b/lib/Kconfig.debug
@@ -1265,6 +1265,17 @@ config LATENCYTOP
 source mm/Kconfig.debug
 source kernel/trace/Kconfig
 
+config DISABLE_GCC_AUTOMATIC_INLINING
+   bool Disable gcc automatic inlining
+   depends on TRACING
+   help
+ This option tells gcc he's not allowed to inline functions 
automatically,
+ when they are not marked as 'inline'.
+ In turn, this enables to trace an event with an accurate call site.
+ Of course, the resultant kernel is slower and slightly smaller.
+
+ Select this option only if you want to trace call sites accurately.
+
 config PROVIDE_OHCI1394_DMA_INIT
bool Remote debugging over FireWire early on boot
depends on PCI  X86
-- 
1.7.8.6

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 01/10] Makefile: Add option CONFIG_DISABLE_GCC_AUTOMATIC_INLINING

2012-09-08 Thread Sam Ravnborg
On Sat, Sep 08, 2012 at 05:47:50PM -0300, Ezequiel Garcia wrote:
 As its name suggest this option prevents gcc from auto inlining
 small functions. This is very important if one wants to obtain
 traces with accurate call sites.
 
 Without this option, gcc will collapse some small functions,
 even when not marked as 'inline' thus making impossible to
 correlate the trace caller address to the real function it belongs.
 
 Of course, the resultant kernel is slower and slightly smaller,
 but that's not an issue if the focus is on tracing accuracy.
 
 Cc: Michal Marek mma...@suse.cz
 Signed-off-by: Ezequiel Garcia elezegar...@gmail.com
 ---
  Makefile  |4 
  lib/Kconfig.debug |   11 +++
  2 files changed, 15 insertions(+), 0 deletions(-)
 
 diff --git a/Makefile b/Makefile
 index ddf5be9..df6045a 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -561,6 +561,10 @@ else
  KBUILD_CFLAGS+= -O2
  endif
  
 +ifdef CONFIG_DISABLE_GCC_AUTOMATIC_INLINING
 +KBUILD_CFLAGS+= -fno-inline-small-functions
 +endif
 +
  include $(srctree)/arch/$(SRCARCH)/Makefile
  
  ifdef CONFIG_READABLE_ASM
 diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
 index 2403a63..c8fd50f 100644
 --- a/lib/Kconfig.debug
 +++ b/lib/Kconfig.debug
 @@ -1265,6 +1265,17 @@ config LATENCYTOP
  source mm/Kconfig.debug
  source kernel/trace/Kconfig
  
 +config DISABLE_GCC_AUTOMATIC_INLINING
 + bool Disable gcc automatic inlining

Could we please call this option for:
config CC_DISABLE_AUTOMATIC_INLINING

We have at least a few other options following that naming scheme.
And today we have no options named *GCC_*

Sam
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/