Automatic PGO - Initial implementation (1/N)
dnovillo at google.com
Thu Sep 26 04:55:26 PDT 2013
On Wed, Sep 25, 2013 at 8:54 PM, Evan Cheng <evan.cheng at apple.com> wrote:
> Hmm. Scalar transformation seems *wrong* but you are right it can't an analysis pass. A couple of ideas:
> 1. Can we implement it not as a pass but a utility that clients can use?
> 2. Move it to lib/Transform/Instrumentation?
One hard requirement for this feature is to be enabled as a regular
compiler option. Users are expecting this interface:
$ clang -O2 -fauto-profile foo.cc -o foo
(the actual name of the flag is irrelevant, of course)
I am not sure what you mean by utility in the context of LLVM. Can I
implement utilities so that the above interface works? Similarly for
the instrumentation case. This pass does not generate instrumentation
code, but it does generate IR metadata. If we want to consider that a
form of instrumentation, and we can keep the user interface, then I
don't really mind where it ends up in.
More information about the llvm-commits