https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119930

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|c++                         |tree-optimization

--- Comment #13 from Jason Merrill <jason at gcc dot gnu.org> ---
(In reply to Sam James from comment #10)
> It goes back to r15-5595-g27778979c9a1e3 (i.e.
> -fno-assume-sane-operators-new-delete works).

Ah, you mean -fno-assume-sane-operators-new-delete makes the testcase succeed,
as indeed it does; I initially read that as a description of the commit.

Looking at the difference in tree dumps, modref1 is notably different with that
flag.

It looks like initializing the coroutineA capture in coroutineB is discarded
with -fassume-sane:

+ - Analyzing store: D.9530.__coroutine_A
+   - Read-only or local, ignoring.

and so when we call coroutineB op() and it tries to resume coroutineA, the
pointer to it is missing.

Changing component to tree-optimization.

Reply via email to