Documentation

Miri.Interpreter.Unwind

Pinned shims/unwind.rs: handle_miri_start_unwind, handle_catch_unwind, handle_stack_pop_unwind; machine.rs::after_stack_pop (profiling omitted). Payload tokens are an internal representation of Thread::unwind_payloads: actual typed immediates live in the arena and are removed when popped. They are neither addresses nor allocation identities. Compiler/function-call and memory operations remain required source operations.

Exact initial empty payload vector representation.

Equations
Instances For
    Instances For
      structure Miri.Interpreter.Unwind.Hooks (K Extra C Other : Type) :
      Instances For
        def Miri.Interpreter.Unwind.pushPayload {K Extra C Other : Type} (h : Hooks K Extra C Other) (payload : RvalueImmTy Memory.Provenance) :

        Push after reading the complete typed immediate. Source fields in the active thread and the arena are committed together.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          def Miri.Interpreter.Unwind.popPayload {K Extra C Other : Type} (h : Hooks K Extra C Other) :

          Pop before resolving the catch function, as in the source. Missing or ambiguous arena data is a representation obligation, never a fake payload.

          Equations
          • One or more equations did not get rendered due to their size.
          Instances For
            def Miri.Interpreter.Unwind.handleStartUnwind {K Extra C Other : Type} (h : Hooks K Extra C Other) (choice : C) (payload : OpTy Memory.Provenance) :

            This operation only stores the payload. Its caller's unwind continuation initiates unwinding; there is no invented jump here.

            Equations
            Instances For
              def Miri.Interpreter.Unwind.handleCatchUnwind {K Extra C Other : Type} (h : Hooks K Extra C Other) (choice : C) (tryFn data catchFn : OpTy Memory.Provenance) (dest : RuntimePlace Memory.Provenance) (ret : Option MIR.BasicBlockId) :

              Source argument order, forced destination before calls, and post-call zero write are retained. The metadata is installed on the frame active after the try call, only for PanicStrategy::Unwind.

              Equations
              • One or more equations did not get rendered due to their size.
              Instances For
                def Miri.Interpreter.Unwind.afterStackPop {K Extra C Other : Type} (h : Hooks K Extra C Other) (choice : C) (extra : MachineHooks.FrameExtra) (unwinding : Bool) :

                Source after-pop hook. The true return value is written before the payload is popped. A pushed catch frame returns NoJump, preventing the old frame's continuation from being followed by ControlFlow.

                Equations
                • One or more equations did not get rendered due to their size.
                Instances For
                  def Miri.Interpreter.Unwind.userHooks {K Extra C Other : Type} (base : Hooks K (User Extra) C Other) :
                  Hooks K (User Extra) C Other

                  The default concrete user-extension lens for payload storage.

                  Equations
                  • One or more equations did not get rendered due to their size.
                  Instances For