This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: -fobey-inline (was Re: gcc and inlining)



On Sat, 15 Mar 2003, Robert Dewar wrote:


Let me remind you that we are discussing the effects of a change in
behaviour of our C compiler.  What Ada programmers do or don't do may be
influenced by the behaviour of Ada compilers and might therefore not be
entirely relevant.


Correct. My old copy of the manual states that inline 'directs' the compiler to inline the function.

More broadly, the C philosophy is that in C we allow the programmer to make mistakes,
on the basis that if they wanted to program in modula-2 and have mother decide everything for them
they would have done so.

Mostly, the compiler may make the right decision, but sometimes it does not.
For those cases the programmer should be able to override. It is not just about efficiency,
but also the size of the stack etc, all sorts of things the compiler may not know.

Tim Josling




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]