Commit Graph

79 Commits

Author SHA1 Message Date
Antoine Grimod 6af9ddf394 added pass to check validity of automata and disable flattening of automaton branch because of incorrect code resulting from it 2022-12-16 01:04:09 +01:00
Antoine Grimod 1b3af051b3 adding automaton translation pass to list of executed passes 2022-12-16 00:06:51 +01:00
Benjamin_Loison b4ae058bf6 Remove unused variable new_locvars in src/passes.ml 2022-12-16 00:04:57 +01:00
Benjamin_Loison 0c8da12afe Correct typo in verification that nodes always have arguments and make the main having such a verification too, as in Lustre 2022-12-16 00:00:11 +01:00
Antoine Grimod 21d2d0c9bb fix type error in code 2022-12-15 23:48:02 +01:00
Antoine Grimod de294df84a Translation of automaton to lustre almost finished 2022-12-15 23:39:01 +01:00
Benjamin_Loison bfca80bb8b Avoid crashes that can occur when using when with a statement that may crash if the when condition doesn't hold
For instance

```
node main () returns (o: int);
var i: int;
let
    i = 0;
    o = (1 / i) when false;
tel
```

used to crash with for instance:

```
Floating point exception
136
```

now returns `0` but in fact this value wouldn't be used in theory as the `when` condition doesn't hold.
2022-12-15 23:22:15 +01:00
dsac 74f8a3c3e1 [parser] functions other that main → args required 2022-12-15 22:14:59 +01:00
dsac 0d5e045671 [parser] foirbid calling auxiliary nodes with no arguments 2022-12-15 22:07:16 +01:00
dsac 97c6020414 [parser] avoid conflicts between local, input and output variables 2022-12-15 21:42:21 +01:00
Benjamin_Loison bc8c752649 Add a comment concerning pp_resvars to avoid declaring multiple times two arrays while two would be enough 2022-12-15 21:05:20 +01:00
dsac eceeb3c157 [fix] identation error 2022-12-15 20:37:05 +01:00
Benjamin_Loison ca271eaf66 Correct typos in src/passes.ml and src/test.node 2022-12-15 20:13:18 +01:00
Benjamin_Loison 72ba196142 Merge branch 'master' of https://gitea.lemnoslife.com/Benjamin_Loison/Synchronous_reactive_systems 2022-12-15 19:52:02 +01:00
Benjamin_Loison 1a06fc9a6a Add reset support in C 2022-12-15 19:51:46 +01:00
Arnaud DABY-SEESARAM 8582337774 [passes] pass to check the typing tags of the program / expressions 2022-12-15 18:33:04 +01:00
Arnaud DABY-SEESARAM db5c584435 [passes] fix for the equation ordering pass 2022-12-15 17:40:15 +01:00
Arnaud DABY-SEESARAM 6459c54159 [passes] ordering equations 2022-12-15 17:11:19 +01:00
Arnaud DABY-SEESARAM 9151a6e29a [tests] adding the -test option to duplicate sanity checks 2022-12-15 17:11:19 +01:00
Arnaud DABY-SEESARAM 19fd3bc1b9 Merge remote-tracking branch 'origin/master' 2022-12-15 16:18:17 +01:00
Arnaud DABY-SEESARAM 38a7325097 [beamer] slide 7 2022-12-15 16:17:47 +01:00
Benjamin_Loison 342aba4426 Correct copy-pasted int and bool cases 2022-12-15 16:08:22 +01:00
dsac e84a6e387d [beamer] proto 0 2022-12-15 11:40:29 +01:00
dsac ed5f94f821 [simu] wip 2022-12-15 09:13:59 +01:00
dsac e75d525a6d [passes] linearisation des équations 2022-12-15 09:13:28 +01:00
dsac 73d5ed7726 [parser] avoid redefinition of nodes 2022-12-14 18:41:59 +01:00
Arnaud DABY-SEESARAM 79f0c7d223 [passes] never redefine an input 2022-12-13 18:15:48 +01:00
Arnaud DABY-SEESARAM f3416582be [passes] correction of the check not re-init of variables 2022-12-13 18:08:11 +01:00
Benjamin_Loison c441f8b1a6 Correct typo in comment in src/config.ml 2022-12-13 16:03:05 +01:00
Antoine Grimod b4cc3ae756 "pretty" print for automaton 2022-12-13 15:57:27 +01:00
Arnaud DABY-SEESARAM e5ac9a719d [passes] check unicity of the assignations for each var 2022-12-13 15:55:21 +01:00
Arnaud DABY-SEESARAM 69b963c305 [gitfix] rebase fix 2022-12-13 15:04:53 +01:00
Antoine Grimod bb017afe39 added automaton to ast 2022-12-13 15:03:41 +01:00
Arnaud DABY-SEESARAM ad1f529863 [typo] adding newline 2022-12-13 14:57:55 +01:00
Arnaud DABY-SEESARAM 51ed84504f [pre propagation] done. 2022-12-13 14:25:48 +01:00
Antoine Grimod e9d586dfe7 adding automaton 2022-12-13 11:51:46 +01:00
Arnaud DABY-SEESARAM c4ad75e4cb [passes] auxiliary functions 2022-12-13 11:46:04 +01:00
Arnaud DABY-SEESARAM 19be2200f3 Catch syntax errors 2022-12-13 11:43:23 +01:00
Arnaud DABY-SEESARAM 8ef4d035a3 Reject programs with var initialized twice 2022-12-13 10:26:55 +01:00
Arnaud DABY-SEESARAM ef0effeb1f improvement over error messages (with code ;) ) 2022-12-13 10:26:55 +01:00
Benjamin_Loison 298e88f1a5 Simplify ETriOp case in src/ast_to_c.ml 2022-12-11 22:25:11 +01:00
Benjamin_Loison 014110791d Remove useless prefix from pp_expression_aux and pp_expression_list functions in src/ast_to_c.ml 2022-12-11 20:07:28 +01:00
Benjamin_Loison cbddd63927 Format the code to make it shorter and more readable 2022-12-11 19:53:23 +01:00
Benjamin_Loison 241f3dcbc0 Add pre support in C 2022-12-11 19:28:41 +01:00
Benjamin_Loison c0c29e1df7 Add assignement support for tuples 2022-12-11 18:45:30 +01:00
Benjamin_Loison da823ac3c8 Add -> support in C 2022-12-10 21:17:32 +01:00
Benjamin_Loison 38f58f7558 Unitfy pp_varlist, pp_argvarlist and pp_decvarlist 2022-12-10 20:51:52 +01:00
Benjamin_Loison eac8c6893c Add support to multiple local variables in C 2022-12-10 20:30:32 +01:00
Benjamin_Loison 363f5043a0 Add node call support in C 2022-12-10 20:22:11 +01:00
Benjamin_Loison 5a54f897b1 Add indentation to pp_equations in src/ast_to_c.ml 2022-12-10 19:27:18 +01:00