autofdo doesnt compile.
Markuze opened this issue · 6 comments
[3/17] Building CXX object CMakeFiles/perfdata_reader.dir/perfdata_reader.cc.o
FAILED: CMakeFiles/perfdata_reader.dir/perfdata_reader.cc.o
/usr/bin/c++ -DHAVE_LLVM=1 -DLLVM_GETELFFILE_RET_REFERENCE=1 -DLLVM_VERSION_MAJOR=14 -DLLVM_VERSION_MINOR=0 -I/usr/lib/llvm-14/include -I../ -I../third_party/glog/src -I../third_party/abseil -I../third_party/perf_data_converter/src -I../third_party/perf_data_converter/src/quipper -I. -Ithird_party/glog -I../third_party/googletest/googletest/include -I../third_party/googletest/googlemock/include -I../util/regexp -O3 -DNDEBUG -std=gnu++17 -MD -MT CMakeFiles/perfdata_reader.dir/perfdata_reader.cc.o -MF CMakeFiles/perfdata_reader.dir/perfdata_reader.cc.o.d -o CMakeFiles/perfdata_reader.dir/perfdata_reader.cc.o -c ../perfdata_reader.cc
../perfdata_reader.cc: In function ‘llvm::Optional<std::set<std::__cxx11::basic_string > > devtools_crosstool_autofdo::FindFileNameInPerfDataWithFileBuildId(const string&, const quipper::PerfReader&, devtools_crosstool_autofdo::BinaryPerfInfo*)’:
../perfdata_reader.cc:268:17: error: could not convert ‘std::nullopt’ from ‘const std::nullopt_t’ to ‘llvm::Optional<std::set<std::__cxx11::basic_string > >’
268 | return std::nullopt;
| ^~~~~~~
| |
Tried both llvm-11 and llvm-14, seeing different issues.
These are steps on debian bullseye
git clone --recursive https://github.com/google/autofdo.git
cd autofdo
mkdir build
cd build
# Note: "-DCMAKE_INSTALL_PREFIX=." must be used, because there is a bug in the basil cmakelist.
cmake -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=. -DLLVM_PATH=/lib/llvm-14/ ../
ninja
ninja test
Hi Markuze, we recently merged PR #155 to make the tool buildable against the newest llvm. So would you be able to build a newest llvm and pass the path to "-DLLVM_PATH="?
Hope it would help.
Nah, straight up been coming back about every month or so see if this crap is working yet. This software has never, worked, 99% won't compile. Absolute garbage.
I was able to successfully build the autofdo tool(branch 2022.09.merge) using LLVM 15, and Propeller is working well for optimizing MySQL with the create_llvm_prof tool.
I also faced with this problem. Have you solved it?Could your solution