probinson added a comment.
In http://reviews.llvm.org/D20647#462797, @Ilod wrote:
> There is no longer a flag to treat implicit and explicit inline functions
> exactly the same way, I don't kow if it's really useful (it can be if we want
> to use the threshold difference between InlineHint and
Ilod updated this revision to Diff 61318.
Ilod added a comment.
New patch, which instead add NoInline to function not marked (implicitly or
explicitly) inline, when we use the -finline-hint-functions flag (effectily
inlining only implicitly and explicitly inline functions). Also adds support
fo
probinson added a subscriber: probinson.
probinson added a comment.
I'm still bemused that Clang thinks of a defined-in-class method and a method
marked with 'inline' as significantly different things. But given that it
does, a way to make them be treated the same will be nice.
==
rnk added a comment.
In http://reviews.llvm.org/D20647#460520, @Ilod wrote:
> I don't think weak linkage defines this.
Right, sorry, normal external linkage is the obvious case. I was hung up
thinking about cases like this:
volatile int x;
template
struct A {
void f();
void g()
Ilod added a comment.
I don't think weak linkage defines this.
For example, in:
struct A {
inline int foo() { return 0; }
int bar() { return 1; }
int baz();
};
int A::baz() { return 2; }
With /Ob1, we should inline foo and bar, but never baz. But baz doesn't have
weak linkage
rnk added a comment.
Can't we implement /Ob1 by applying noinline to every non-inline specified
function with weak linkage?
http://reviews.llvm.org/D20647
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman
Ilod added a reviewer: rnk.
Ilod updated this revision to Diff 61029.
Ilod added a comment.
Updated to head revision, and pinging this.
http://reviews.llvm.org/D20647
Files:
include/clang/Driver/Options.td
include/clang/Frontend/CodeGenOptions.def
lib/CodeGen/CodeGenFunction.cpp
lib/Fro
Ilod created this revision.
Ilod added a subscriber: cfe-commits.
Add two flags (-finline-implicit-hint and -fno-inline-implicit-hint) to allow
to add InlineHint on implicitly inline functions (constexpr and member
functions of class that was defined in the class body).
This is needed to add sup