[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #1 from Tomasz Kłoczko --- Last detail. I'm adding -Os to %build_cflags

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 Andrew Pinski changed: What|Removed |Added Keywords||memory-hog --- Comment #2 from Andrew P

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #3 from Tomasz Kłoczko --- This box has 256GB of RAM and ZERO swap.

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #4 from Tomasz Kłoczko --- Other detail is that produces DSO libfabric.so.1.18.1 without LTO has only 1340096 bytest so question is why lto needs in this case +10GB of RAM?🤔

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #5 from Tomasz Kłoczko --- +100GB

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread marxin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 Martin Liška changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|---

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #7 from Tomasz Kłoczko --- Hmm .. Martin even if that can be fixed in libfabric code does it still mean that it something wrong with LO optimisation? Sorry for asking maybe dumb question but this situation is not clear for me :)

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #8 from Andrew Pinski --- (In reply to Tomasz Kłoczko from comment #7) > Hmm .. Martin even if that can be fixed in libfabric code does it still mean > that it something wrong with LO optimisation? > Sorry for asking maybe dumb quest

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #9 from Tomasz Kłoczko --- (In reply to Andrew Pinski from comment #8) [..] > Basically with the flatten attribute and lto, every function needs to there > and cloned and inlined causing a lot of memory and time really. > Functions b

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #10 from Andrew Pinski --- (In reply to Tomasz Kłoczko from comment #9) > (In reply to Andrew Pinski from comment #8) > [..] > > Basically with the flatten attribute and lto, every function needs to there > > and cloned and inlined c

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #11 from Tomasz Kłoczko --- (In reply to Andrew Pinski from comment #10) > The flatten attribute is designed to override all heuristics in the compiler > that is designed to not cause the gignatic memory usage and compile time. > Bas

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-01 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #12 from Andrew Pinski --- (In reply to Tomasz Kłoczko from comment #11) > (In reply to Andrew Pinski from comment #10) > > The flatten attribute is designed to override all heuristics in the compiler > > that is designed to not caus

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #13 from Tomasz Kłoczko --- Thank you for the explanation.

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #14 from Richard Biener --- In addition to that, -flto-partition=none is almost never a good idea either. Note I think that we should honor flatten only during early inlining to avoid all kinds of funny behavior when applying cross

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #15 from Tomasz Kłoczko --- (In reply to Richard Biener from comment #14) > In addition to that, -flto-partition=none is almost never a good idea either. > > Note I think that we should honor flatten only during early inlining to >

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread marxin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #16 from Martin Liška --- > Issue is that in few cases AFAIK it is only solution to some still > unresolved LTO issues :/ Well, in most cases it's used for symbol versioning which is implemented by assembly directives. However, we o

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #17 from Tomasz Kłoczko --- (In reply to Martin Liška from comment #16) [..] > Well, in most cases it's used for symbol versioning which is implemented by > assembly directives. However, we offer symver function attribute that > surv

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread marxin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #18 from Martin Liška --- > It should not be so hard to fix that. Am I right? Do you mean the usage of symver attribute? No, it's quite a straightforward transformation many projects have already done.

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #19 from Tomasz Kłoczko --- (In reply to Martin Liška from comment #18) > > It should not be so hard to fix that. Am I right? > > Do you mean the usage of symver attribute? No, it's quite a straightforward > transformation many proj

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread marxin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #20 from Martin Liška --- > No, no .. I mean IIRC therea are few cases when versioned sym file is > incorrectly handled if -flto-partition=none is not used. I'm not aware of any..

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #21 from Tomasz Kłoczko --- FYI I've opened libfabric ticket https://github.com/ofiwg/libfabric/issues/7916 Thank you one more time for all your explanations :)

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-02 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #22 from Tomasz Kłoczko --- (In reply to Martin Liška from comment #6) > Doctor it hurts! Then don't do it. Sorry, seriously, it's caused by the > flatten attribute and I can reproduce it for our openSUSE package. If may I ask yet a

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-03 Thread marxin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #23 from Martin Liška --- > If may I ask yet another question 😋 Sure, don't hesitate ;) > Martin can you tell how did you manage to diagnose that it was exactly that > cause in this case? I noticed we spent time in inliner (perf t

[Bug lto/106499] LTO runs forever in libfabric 1.15.1 linking

2022-08-03 Thread kloczko.tomasz at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106499 --- Comment #24 from Tomasz Kłoczko --- Thank you :)