diff options
author | xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e> | 2009-11-10 12:50:57 +0000 |
---|---|---|
committer | xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e> | 2009-11-10 12:50:57 +0000 |
commit | 74487f079dd56663f97f9731cea328931857495c (patch) | |
tree | 9de10b895da39adffaf66bff983d6ed573898068 /backend/Machabstr.v | |
parent | 0486654fac91947fec93d18a0738dd7aa10bcf96 (diff) | |
download | compcert-74487f079dd56663f97f9731cea328931857495c.tar.gz compcert-74487f079dd56663f97f9731cea328931857495c.zip |
Added support for jump tables in back end.
git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@1171 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'backend/Machabstr.v')
-rw-r--r-- | backend/Machabstr.v | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/backend/Machabstr.v b/backend/Machabstr.v index aa17cd44..a2630a2b 100644 --- a/backend/Machabstr.v +++ b/backend/Machabstr.v @@ -282,6 +282,13 @@ Inductive step: state -> trace -> state -> Prop := eval_condition cond rs##args = Some false -> step (State s f sp (Mcond cond args lbl :: c) rs fr m) E0 (State s f sp c rs fr m) + | exec_Mjumptable: + forall s f sp arg tbl c rs fr m n lbl c', + rs arg = Vint n -> + list_nth_z tbl (Int.signed n) = Some lbl -> + find_label lbl f.(fn_code) = Some c' -> + step (State s f sp (Mjumptable arg tbl :: c) rs fr m) + E0 (State s f sp c' rs fr m) | exec_Mreturn: forall s f stk soff c rs fr m, step (State s f (Vptr stk soff) (Mreturn :: c) rs fr m) |