[llvm-dev] [PGO] cmake: Check for opagent.h when building with -DLLVM_USE_OPROFILE=ON

Sedat Dilek via llvm-dev llvm-dev at lists.llvm.org
Wed Jul 27 02:16:29 PDT 2016


[ CC llvm-dev ]

Hi Chris,

please see <https://llvm.org/bugs/show_bug.cgi?id=28736>.


Regards,
- Sedat -

On Tue, Jul 26, 2016 at 5:57 PM, Chris Bieneman <cbieneman at apple.com> wrote:
> Correct me if I'm wrong, but it sounds to me like you are requesting that we
> update our CMake to produce an error during configuration if
> LLVM_USE_OPROFILE=On and opagent.h is unavailable. Is that correct?
>
> If so can you please file a bug report on llvm.org/bugs?
>
> If I've misunderstood can you please clarify what you're looking for?
>
> Thanks,
> -Chris
>
> On Jul 24, 2016, at 6:45 AM, Sedat Dilek via llvm-dev
> <llvm-dev at lists.llvm.org> wrote:
>
> Hi,
>
> I am building a llvm-toolchain v3.8.1 and use...
>
> PGO_CMAKE_OPTS="-DLLVM_USE_OPROFILE=ON"
>
> ...in my build-script (see file-attachments).
>
> My build stopped saying... <opagent.h> not found.
>
> [1] says...
>
> 00024 #include <opagent.h>
>
> So, it is possible to check for the existence of <opagent.h> in the
> cmake/configure stage *before* starting the build.
> It is not very pleasant to see the build breaking.
>
> NOTE: Ubuntu/precise has no official oprofile package available which
> ships "/usr/include/opagent.h".
>
> I did not check if upstream has a fix or workaround for this.
>
> Thanks.
>
> Regards,
> - Sedat -
>
> [1] http://llvm.org/docs/doxygen/html/OProfileWrapper_8h_source.html
>
> P.S.: Note2myself: Backporting oprofile v0.9.9
>
> For backporting oprofile v0.9.9 from Ubuntu/trusty I needed
> libiberty-dev from kubuntu-ppa/backports PPA software repository.
> Furthermore, hack around to disable the build of oprofile-gui and
> java-related libs (see attached diff-file).
>
> [2]
> https://urldefense.proofpoint.com/v2/url?u=http-3A__packages.ubuntu.com_search-3Fkeywords-3Dlibiberty&d=CwIBaQ&c=Hw-EJUFt2_D9PK5csBJ29kRV40HqSDXWTLPyZ6W8u84&r=dWrPZAu_nw7X1B2qlMCbvg&m=9W5G3_97OY2qaxaaOfMgFXtUWjDHFRH0fp-Jb-HMVZA&s=9qWuwUQM3KyZnIRtquZXS6Lc80i_iTphh-MAOy0tBhs&e=
> [3]
> https://urldefense.proofpoint.com/v2/url?u=http-3A__www.ubuntuupdates.org_package_kubuntu-2Dppa-5Fbackports_precise_main_base_libiberty-2Ddev&d=CwIBaQ&c=Hw-EJUFt2_D9PK5csBJ29kRV40HqSDXWTLPyZ6W8u84&r=dWrPZAu_nw7X1B2qlMCbvg&m=9W5G3_97OY2qaxaaOfMgFXtUWjDHFRH0fp-Jb-HMVZA&s=H0YNZHvWbfZwZ3dJ9nn1p88eLJQ4UGBOexEGH4qnZrU&e=
>
> <oprofile_debian.diff>
>
> <build_llvm-toolchain.sh>
>
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev


More information about the llvm-dev mailing list