[llvm] Add function feature extraction analysis
authorMircea Trofin <mtrofin@google.com>
Tue, 26 May 2020 19:07:08 +0000 (12:07 -0700)
committerMircea Trofin <mtrofin@google.com>
Wed, 27 May 2020 20:38:50 +0000 (13:38 -0700)
commit98ef93eabd768e51aa58c7623a9fe220ab471715
tree468a9f4a0523bfcf85039fe1a1e2afb26c990dcd
parentfa342b5c8054dad4cfd1032ac580d71f0f4943d3
[llvm] Add function feature extraction analysis

Summary:
This patch introduces an analysis pass to extract function features,
which will be needed by the ML InlineAdvisor.

RFC: http://lists.llvm.org/pipermail/llvm-dev/2020-April/140763.html

Reviewers: davidxl, dblaikie, jdoerfert

Subscribers: mgorny, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D80579
llvm/include/llvm/Analysis/ML/InlineFeaturesAnalysis.h [new file with mode: 0644]
llvm/lib/Analysis/CMakeLists.txt
llvm/lib/Analysis/ML/CMakeLists.txt [new file with mode: 0644]
llvm/lib/Analysis/ML/InlineFeaturesAnalysis.cpp [new file with mode: 0644]
llvm/lib/Passes/PassBuilder.cpp
llvm/lib/Passes/PassRegistry.def
llvm/unittests/Analysis/CMakeLists.txt
llvm/unittests/Analysis/ML/CMakeLists.txt [new file with mode: 0644]
llvm/unittests/Analysis/ML/InlineFeaturesAnalysisTest.cpp [new file with mode: 0644]