On Sun, Aug 29, 2010 at 2:02 AM, Greg Freemyer wrote:
>
> http://lxr.linux.no/#linux+v2.6.35/Documentation/CodingStyle#L692
>
> You can see they complain about over use of inline, especially since
> gcc will find the obvious cases on its own.
>
> This was really interesting Greg.Thanks for making
On Sat, Aug 28, 2010 at 1:05 PM, James Bond wrote:
>
>
> On Sat, Aug 28, 2010 at 5:39 PM, Greg Freemyer
> wrote:
>>
>> http://gcc.gnu.org/onlinedocs/gcc-4.1.1/gcc/Inline.html
>>
>> note the last sentence of that doc
>>
>> GCC does not inline any functions when not optimizing
>> unle
On Sat, Aug 28, 2010 at 5:39 PM, Greg Freemyer wrote:
>
> http://gcc.gnu.org/onlinedocs/gcc-4.1.1/gcc/Inline.html
>
> note the last sentence of that doc
>
> GCC does not inline any functions when not optimizing
> unless you specify the `always_inline' attribute for the function,
> li
On Sat, Aug 28, 2010 at 5:39 PM, Greg Freemyer wrote:
>
> HTH (Hope That Helps)
> Greg
>
> Hi Greg yes.Thanks for the wonderful explanation yes it did helped.
--
To be yourself in a world that is constantly trying to make you something
else is the greatest accomplishment
On Fri, Aug 27, 2010 at 11:41 PM, James Bond wrote:
> Hi,
> Stephan thanks a lot for the link.
> I also have a small doubt.Please see if you can resolve
>
> As per my understanding
>
> 1) Defining any function as static tells the compiler that the
> function can only be used in the file the functi
On Sat, Aug 28, 2010 at 12:06 PM, James Bond wrote:
> No not yet clear.
>
To make a function call CPU has to save registers and pass on ret
instructions when ever the function call ends
if we have a small fucntion which is used in a file and a function
call via CPU then over head of saving flag
On Fri, Aug 27, 2010 at 10:53 PM, James Bond wrote:
>
>
>
> Hi,
> I am new to kernel development.
> So after being able to have some basic understand of some things I just went
> through source code.
> I was going through a file known as
> linux-2.6.34/kernel/timer.c and found following code.
> I
On Sat, Aug 28, 2010 at 11:07 AM, Mulyadi Santosa wrote:
>
> casual "inline" is at the mercy of compiler to decide, whether to
> really inline the functions or not.
>
> while "always inline"...you surely have the good guess now :D
>
> No not yet clear.
--
To be yourself in a world that is cons
On 8/28/2010 11:07 AM, Mulyadi Santosa wrote:
On Sat, Aug 28, 2010 at 12:19, James Bond wrote:
Please don't top post :)
What is that top post I never came across such a thing in timer code?
top post is a way to put your reply on top of the quoted previous
message...while what we do in kerne
On Sat, Aug 28, 2010 at 10:41 AM, Mulyadi Santosa wrote:
> On Sat, Aug 28, 2010 at 12:09, Tapas Mishra
> wrote:
> > Sorry in previous post I did not made clear actually what I wanted to
> > say is if you have a function is used at 10 places and you declare it
> > inline 10 times then there would
On Sat, Aug 28, 2010 at 12:19, James Bond wrote:
>> Please don't top post :)
>>
> What is that top post I never came across such a thing in timer code?
top post is a way to put your reply on top of the quoted previous
message...while what we do in kernelnewbies is the other way around...
>> That
On Sat, Aug 28, 2010 at 12:09, Tapas Mishra wrote:
> Sorry in previous post I did not made clear actually what I wanted to
> say is if you have a function is used at 10 places and you declare it
> inline 10 times then there would be cache miss more and then it will
> have disadvantage.
Please don
Sorry in previous post I did not made clear actually what I wanted to
say is if you have a function is used at 10 places and you declare it
inline 10 times then there would be cache miss more and then it will
have disadvantage.
On Sat, Aug 28, 2010 at 10:37 AM, Tapas Mishra wrote:
> I forgot to m
What I understand with respect to static and inline functions is
To make a function call CPU has to save registers and pass on ret
instructions when ever the function call ends
if we have a small fucntion which is used in a file and a function
call via CPU then over head of saving flag registers
Hi..
Sorry for crossing ,...
On Sat, Aug 28, 2010 at 11:23, James Bond wrote:
>> > 1) Defining any function as static tells the compiler that the
>> > function can only be used in the file the function was defined in
>> >
>> Yes.
>>
> So why is that used in the code timer.c?
>
>
AFAIK, static
On Sat, Aug 28, 2010 at 9:44 AM, zeal wrote:
> On Sat, Aug 28, 2010 at 11:41 AM, James Bond
> wrote:
> > Hi,
> > Stephan thanks a lot for the link.
> > I also have a small doubt.Please see if you can resolve
> >
> > As per my understanding
> >
> > 1) Defining any function as static tells the com
On Sat, Aug 28, 2010 at 11:41 AM, James Bond wrote:
> Hi,
> Stephan thanks a lot for the link.
> I also have a small doubt.Please see if you can resolve
>
> As per my understanding
>
> 1) Defining any function as static tells the compiler that the
> function can only be used in the file the functi
Hi,
Stephan thanks a lot for the link.
I also have a small doubt.Please see if you can resolve
As per my understanding
1) Defining any function as static tells the compiler that the
function can only be used in the file the function was defined in
2) inline function is that, even though you can
> Please give some online link to what you said I will go through it.
http://www.google.com/search?hl=en&client=firefox-a&hs=yTX&rls=org.mozilla%3Aen-US%3Aofficial&channel=s&q=dennis+ritchie+c+pdf&cts=1282966271211&aq=2sx&aqi=g-s1g-sx9&aql=&oq=denis+ritc&gs_rfai=
Say a short prayer every time
On Sat, Aug 28, 2010 at 1:51 AM, Greg Freemyer wrote:
>
> in the kernel use advance C constructs which even advanced user space
> C programmers find hard to grasp. Questions about those types of
> usage are very appropriate for this list and will often be better
> addressed in kernel specific boo
On Fri, Aug 27, 2010 at 1:23 PM, James Bond wrote:
>
> Hi,
> I am new to kernel development.
> So after being able to have some basic understand of some things I just went
> through source code.
> I was going through a file known as
> linux-2.6.34/kernel/timer.c and found following code.
> I want
Hi,
I am new to kernel development.
So after being able to have some basic understand of some things I just went
through source code.
I was going through a file known as
linux-2.6.34/kernel/timer.c and found following code.
I want to understand what is it doing.
What should I be reading to be able
22 matches
Mail list logo