Changeset 2677 for src/Cminor
- Timestamp:
- Feb 19, 2013, 12:23:50 PM (7 years ago)
- Location:
- src/Cminor
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Cminor/Cminor_abstract.ma
r2601 r2677 23 23 λs. match s with 24 24 [ State _ _ _ _ _ _ _ _ _ _ ⇒ cl_other 25 | Callstate _ _ _ _ ⇒ cl_call25 | Callstate _ _ _ _ _ ⇒ cl_call 26 26 | Returnstate _ _ _ ⇒ cl_return 27 27 | Finalstate _ ⇒ cl_other -
src/Cminor/Cminor_semantics.ma
r2645 r2677 69 69 state 70 70 | Callstate: 71 ∀ vf: val. (* fn pointer; only used for instrumentation, not the semantics *) 71 72 ∀ fd: fundef internal_function. 72 73 ∀ args: list val. … … 297 298 ! fd ← opt_to_res … (msg BadFunctionValue) (find_funct … ge vf); 298 299 ! 〈tr',vargs〉 ← trace_map_inv … (λe. match e return λe.match e with [ mk_DPair _ _ ⇒ ? ] → ? with [ mk_DPair ty e ⇒ λp. eval_expr ge ? e en p sp m ]) args ?; 299 return 〈tr ⧺ tr', Callstate fd vargs m (Scall dst f sp en ? fInv k ? st)〉300 return 〈tr ⧺ tr', Callstate vf fd vargs m (Scall dst f sp en ? fInv k ? st)〉 300 301 (* 301 302 | St_tailcall ef args ⇒ λInv. … … 327 328 return 〈Echarge l, State f s' en fInv ? m sp k ? st〉 328 329 ] Inv) 329 | Callstate fd args m st ⇒330 | Callstate _ fd args m st ⇒ 330 331 match fd with 331 332 [ Internal f ⇒ err_to_io ?? (trace × state) ( … … 424 425 do b ← opt_to_res ? (msg MainMissing) (find_symbol … ge (prog_main ?? p)); 425 426 do f ← opt_to_res ? (msg MainMissing) (find_funct_ptr … ge b); 426 OK ? (Callstate f (nil ?) m SStop).427 OK ? (Callstate (Vptr (mk_pointer b zero_offset)) f (nil ?) m SStop). 427 428 428 429 definition Cminor_fullexec : fullexec io_out io_in ≝ … … 438 439 do b ← opt_to_res ? (msg MainMissing) (find_symbol … ge (prog_main ?? p)); 439 440 do f ← opt_to_res ? (msg MainMissing) (find_funct_ptr … ge b); 440 OK ? (Callstate f (nil ?) m SStop).441 OK ? (Callstate (Vptr (mk_pointer b zero_offset)) f (nil ?) m SStop). 441 442 442 443 definition Cminor_noinit_fullexec : fullexec io_out io_in ≝
Note: See TracChangeset
for help on using the changeset viewer.