[svn:parrot] r43774 - trunk/src/ops

bacek at svn.parrot.org bacek at svn.parrot.org
Mon Feb 8 10:57:45 UTC 2010


Author: bacek
Date: Mon Feb  8 10:57:43 2010
New Revision: 43774
URL: https://trac.parrot.org/parrot/changeset/43774

Log:
Revert r43414. RetContinuation doesn't kill itself anymore after invoke.

Modified:
   trunk/src/ops/core.ops
   trunk/src/ops/object.ops

Modified: trunk/src/ops/core.ops
==============================================================================
--- trunk/src/ops/core.ops	Mon Feb  8 08:31:25 2010	(r43773)
+++ trunk/src/ops/core.ops	Mon Feb  8 10:57:43 2010	(r43774)
@@ -467,14 +467,6 @@
 
     Parrot_pcc_merge_signature_for_tailcall(interp, parent_call_sig, this_call_sig);
 
-    /* Detach continuation from current CallContext to avoid marking dead object. */
-    /* RetContinuation will kill itself after invoke */
-    if (interp->current_cont->vtable->base_type == enum_class_RetContinuation
-        && Parrot_pcc_do_run_ops(interp, p)) {
-        PMC_cont(interp->current_cont)->from_ctx = parent_ctx;
-        Parrot_pcc_set_continuation(interp, ctx, PMCNULL);
-    }
-
     SUB_FLAG_TAILCALL_SET(interp->current_cont);
     dest = VTABLE_invoke(interp, p, dest);
     goto ADDRESS(dest);

Modified: trunk/src/ops/object.ops
==============================================================================
--- trunk/src/ops/object.ops	Mon Feb  8 08:31:25 2010	(r43773)
+++ trunk/src/ops/object.ops	Mon Feb  8 10:57:43 2010	(r43774)
@@ -138,15 +138,6 @@
     else {
         interp->current_cont = Parrot_pcc_get_continuation(interp, CURRENT_CONTEXT(interp));
         PObj_get_FLAGS(interp->current_cont) |= SUB_FLAG_TAILCALL;
-        /* Detach continuation from current CallContext to avoid marking dead object. */
-        /* RetContinuation will kill itself after invoke */
-        if (interp->current_cont->vtable->base_type == enum_class_RetContinuation
-            && Parrot_pcc_do_run_ops(interp, method_pmc)) {
-            PMC * const ctx             = CURRENT_CONTEXT(interp);
-            PMC * const parent_ctx      = Parrot_pcc_get_caller_ctx(interp, ctx);
-            PMC_cont(interp->current_cont)->from_ctx = parent_ctx;
-            Parrot_pcc_set_continuation(interp, ctx, PMCNULL);
-        }
         interp->current_object = object;
         dest = (opcode_t *)VTABLE_invoke(interp, method_pmc, next);
     }
@@ -162,15 +153,6 @@
 
     interp->current_cont = Parrot_pcc_get_continuation(interp, CURRENT_CONTEXT(interp));
     PObj_get_FLAGS(interp->current_cont) |= SUB_FLAG_TAILCALL;
-    /* Detach continuation from current CallContext to avoid marking dead object. */
-    /* RetContinuation will kill itself after invoke */
-    if (interp->current_cont->vtable->base_type == enum_class_RetContinuation
-        && Parrot_pcc_do_run_ops(interp, method_pmc)) {
-        PMC * const ctx             = CURRENT_CONTEXT(interp);
-        PMC * const parent_ctx      = Parrot_pcc_get_caller_ctx(interp, ctx);
-        PMC_cont(interp->current_cont)->from_ctx = parent_ctx;
-        Parrot_pcc_set_continuation(interp, ctx, PMCNULL);
-    }
 
     interp->current_object = object;
     dest = (opcode_t *)VTABLE_invoke(interp, method_pmc, next);


More information about the parrot-commits mailing list