This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [C++ PATCH] Fix finish_function recursion (PR c++/37189)


Jakub Jelinek wrote:
The problem is that the discovery of OpenMP implicitly determined variables
is done at gimplification time.  If a variable is implicitly determined
as firstprivate and it has a class type, we need its copy ctor and dtor, but
it is possible it needs to be synthetized.  This leads to calling
cp_genericize while in the gimplifier for another function, which is fatal.

I don't see why that needs to be fatal. It looks like we already have the code to handle saving outer context, just need to take out the assert.


So this patch instead will defer all mark_used calls encountered during finish_function
call until the end of that function.

This would mean that we can't inline these synthesized [cd]tors.


Jason


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]