On Wed, Aug 18, 2021 at 4:54 PM lijiang <liji...@redhat.com> wrote: > > > On Wed, Aug 18, 2021 at 2:28 PM lijiang <liji...@redhat.com> wrote: > >> >> >> On Wed, Aug 18, 2021 at 11:02 AM Dave Young <dyo...@redhat.com> wrote: >> >>> Add Kazu in cc list >>> On Wed, 18 Aug 2021 at 10:45, lijiang <liji...@redhat.com> wrote: >>> > >>> > Hi, >>> > >>> > In Fedora crash.spec, currently the LTO is disabled as below: >>> > >>> > +# This package has an internal copy of GDB which has broken configure >>> code for >>> > +# INTDIV0_RAISES_SIGFPE and MUST_REINSTALL_SIGHANDLERS >>> > +# Updating that code properly seems nontrivial and best left to the >>> package >>> > +# maintainer. >>> > +# Disable LTO >>> >>> Hi Lianbo, the above words seem to suggest disable LTO intentionally, >>> >> >> Yes. I copied the above words from the Fedora crash.spec. >> >> >>> I know the upstream crash tool is working on gdb 10.x integration, >>> maybe the above is eased already with the latest gdb update? >>> >>> After crash is updated to gdb-10.2, the rpm packages have been successfully built with the LTO flag, so far I have tested it on x86_64 and ppc64le, they can work well.
Thanks. Lianbo > >> It doesn't enable LTO on upstream by default. >> > >> >>> >>> > +%define _lto_cflags %{nil} >>> > >>> > commit: c6fc69dae3a2 ("Disable LTO") >>> > >>> > I tried to remove the macro "%define _lto_cflags %{nil}" from the >>> crash.spec, and then build the rpm packages, But I didn't see the lto flag >>> such as "-flto" or "-ffat-lto-objects" during the whole build stage, and >>> the build process passed without any error reports. >>> > >>> >> >> I did the above build test on Fedora rawhide. >> > > So far I have enabled the LTO for Fedora crash, but I got some compilation > errors on ppc64le as below, and the rpm build has been successfully built > on other architectures such as x86_64/s390x/aarch64. > > ../readline/search.c:55:17: note: code may be misoptimized unless > '-fno-strict-aliasing' is used > {standard input}: Assembler messages: > {standard input}:3623: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:3627: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:3648: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:3652: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:3698: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:3701: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:3908: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:3920: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:4033: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:4054: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:4085: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:4086: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:4120: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:4155: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:4170: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:9811: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:10022: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > {standard input}:10278: Error: can't resolve `.toc1' {.toc1 section} - > `.LCTOC1' {*UND* section} > > > Thanks. > > Lianbo > > > >> > >> >>> > I'm wondering if it could rely on the redhat-rpm-config macro or >>> it(LTO flag) can take effect when the toolchain is clang(not gcc)? Any >>> thoughts? >>> >>> The question seems about how to enable LTO instead of if it is ok to >>> enable LTO. Maybe Jeff and others can provide some inputs >>> >>> >> Thank you for helping to clarify this, Dave. >> >> > >>> > Thanks. >>> > Lianbo >>> > >>> > >>> > >>> > But >>> >>> Thanks >>> Dave >>> >>>
_______________________________________________ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure