This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/54052] g++ takes excessive time in opt and generate phase; can lead to Segmentation Fault when not enough memory available
- From: "redi at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 22 Aug 2017 09:16:50 +0000
- Subject: [Bug c++/54052] g++ takes excessive time in opt and generate phase; can lead to Segmentation Fault when not enough memory available
- Auto-submitted: auto-generated
- References: <bug-54052-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54052
--- Comment #7 from Jonathan Wakely <redi at gcc dot gnu.org> ---
(In reply to Eric Gallager from comment #6)
> Doesn't ICE for me, just takes an inordinately long time to compile (once I
> add -fpermissive):
You should have used -m32 not -fpermissive, the preprocessed source was created
on i686-pc-cygwin i.e. an ILP32 target. That's why you got those warnings on
x86_64.
> Extra diagnostic checks enabled; compiler may run slowly.
> Configure with --enable-checking=release to disable checks.
It's expected that compilation takes longer when those checks are enabled.
The code has an unreasonably large expression, so it's not entirely surprising
that it takes unreasonable long to optimize.