[llvm-bugs] [Bug 52089] New: PostgreSQL-Support Profile Guide Optimization

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Oct 5 23:26:13 PDT 2021


https://bugs.llvm.org/show_bug.cgi?id=52089

            Bug ID: 52089
           Summary: PostgreSQL-Support Profile Guide Optimization
           Product: new-bugs
           Version: 12.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: hpcresearch.mspk at gmail.com
                CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org

Followed the below steps on Profile Guide Optimization with Clang on Postgresql
13.3 Environment.
And test benchmark environment used HammedDB v4.2.

Build LLVM:
==========
 wget
https://github.com/llvm/llvm-project/archive/refs/tags/llvmorg-12.0.1.tar.gz
 mkdir build_llvm
 cd build_llvm
 cmake ../llvm-project-llvmorg-12.0.1/llvm/ -DCMAKE_INSTALL_PREFIX=/home/llvm
-DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra;compiler-rt"
 make -j8 && make -j8 install

 Build Postgres with LLVM-Clang:
 ==============================
 $ CC=clang CXX=clang++ ../configure --prefix=<path-to-install> CFLAGS='-O3 
-fprofile-instr-generate' CXXFLAGS='-O3  -std=c++14 -stdlib=libc++
-fprofile-instr-generate'  
2.Run HammerDB client(tpcc-schmea + test run(vu's).  
3. default.profraw created in  PostgreSQL(<path-to-install>)
4.  convert the “raw” profile format by clang.(the merge
command:llvm-profdata tool) 
5. llvm-profdata merge -output=code.profdata code- default.profraw 
warning: default.profraw: Failed to uncompress data (zlib)
 error: No profiles could be merged.(step5)

We have done similar exercise with GCC, it is working there. Checked with
Postgres team and their response:
"I see no reason to believe that this is Postgres' problem to fix.
Try filing a bug with the Clang people."

Reference Link: 
https://www.postgresql.org/message-id/17200-d5d5c376327f7197@postgresql.org
https://www.postgresql.org/message-id/2834314.1632836376%40sss.pgh.pa.us

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20211006/65713d71/attachment.html>


More information about the llvm-bugs mailing list