(**************************************************************************) (* ___ *) (* ||M|| *) (* ||A|| A project by Andrea Asperti *) (* ||T|| *) (* ||I|| Developers: *) (* ||T|| The HELM team. *) (* ||A|| http://helm.cs.unibo.it *) (* \ / *) (* \ / This file is distributed under the terms of the *) (* v GNU General Public License Version 2 *) (* *) (**************************************************************************) include "RTLabs/RTLabsToRTL.ma". include "common/StatusSimulation.ma". include "joint/Traces.ma". include "RTLabs/RTLabs_abstract.ma". include "RTL/RTL_semantics.ma". include "RTLabs/MeasurableToStructured.ma". (* for make_ext_initial_state *) definition RTLabsToRTLstacksizes_ok : (ident → option ℕ) → RTLabs_program → Prop ≝ λstack_sizes,p. All … (λi_f.let 〈i, f〉 ≝ i_f in match f with [ External _ ⇒ True | Internal def ⇒ ∃sz.stack_sizes i = Some ? sz ∧ f_stacksize … def ≤ sz ]) (prog_funct … p). axiom RTLabsToRTL_ok : ∀stacksizes : ident → option ℕ. ∀cost. ∀p_in : RTLabs_program. RTLabsToRTLstacksizes_ok stacksizes p_in → let p_out ≝ rtlabs_to_rtl cost p_in in ∀init_in.make_ext_initial_state p_in = OK … init_in → ∃init_out : state_pc RTL_semantics_separate. make_initial_state (mk_prog_params RTL_semantics_separate p_out stacksizes) = OK ? init_out ∧ ∃[1] R. status_simulation_with_init (RTLabs_status (make_global … p_in)) (joint_status RTL_semantics_separate p_out stacksizes) R init_in init_out.