Commit Graph

170 Commits

Author SHA1 Message Date
Léonard Gérard 7b281317f4 fix scalarize 2011-11-20 22:37:00 +01:00
Léonard Gérard 9d8a0be512 Improve scalarize 2011-11-18 12:33:37 +01:00
Léonard Gérard efa6b5cf70 Correct scalarize and java load_conf 2011-11-18 12:32:37 +01:00
Léonard Gérard be28156de9 Add a simplify pass to Obc 2011-11-18 12:32:37 +01:00
Léonard Gérard 9274ef24aa Java support type alias. 2011-11-18 12:32:37 +01:00
Léonard Gérard 35a9a24467 Correct obc_mapfold 2011-11-18 12:32:37 +01:00
Léonard Gérard 2a6dab836a Add alias to obc vd. 2011-11-18 12:32:37 +01:00
Léonard Gérard fa956a00ad Remarques pour Control 2011-11-18 12:32:37 +01:00
Léonard Gérard bdd85f5f81 mapfold over var_ident. 2011-11-18 12:32:36 +01:00
Léonard Gérard 3e64635f95 optimize the control at the end to maximize profit
Indeed, some examples showed that memory allocation could trigger a profit-full deadcode removal for the control. See Downscaler.down avec -flatten.
2011-11-03 00:43:36 +01:00
Léonard Gérard 919eaa72e1 Fix floating point printing. 2011-11-02 16:08:51 +01:00
Léonard Gérard 50487f9296 Fix java main to deal with unit return type. 2011-11-02 16:07:19 +01:00
Léonard Gérard 04263a126b Correct small bug in java initialized arrays. 2011-11-02 16:04:47 +01:00
Léonard Gérard ef4478e37e removed some stupid warnings. 2011-10-14 13:33:34 +02:00
Cédric Pasteur 175c8e34ff Fixed control fusion 2011-10-05 10:49:51 +02:00
Cédric Pasteur 36c1c7252e Fixed memalloc application with fields 2011-09-15 16:55:17 +02:00
Cédric Pasteur 1c43a8b1ac Fixed code generation for constant arrays 2011-09-14 09:08:28 +02:00
Cédric Pasteur 1d6b68cef6 Fix syntax for ocaml < 3.12 2011-09-09 17:03:54 +02:00
Cédric Pasteur 4d912e9349 Added more options for memalloc
There is now three options for memory allocation:
  - -only-linear activates only the linear 
annotations (with typing and code generation)
  - -only-memalloc does only memory allocation
  - -memalloc does both

When linear typing is not activated, linearity 
annotations are ignored (the signature in the .epi
does not contain the annotations)
2011-09-09 16:05:44 +02:00
Cédric Pasteur eb18342c33 Do not forget to also traverse local linear vars 2011-09-09 16:00:21 +02:00
Cédric Pasteur b0bb7ad39f Fixed problem with application of memalloc 2011-09-09 15:53:15 +02:00
Cédric Pasteur c550b09805 Fixed code generated for alias types to arrays 2011-09-09 13:54:29 +02:00
Cédric Pasteur 53043b403c Small fixes in the C backend 2011-09-07 13:24:33 +02:00
Cédric Pasteur 732a956855 Adapt to the (not so) new extvalues 2011-09-06 15:56:07 +02:00
Cédric Pasteur eec957cc6a Use underscores for generated variables 2011-09-06 14:42:34 +02:00
Cédric Pasteur 2147402a20 Const should be declared static
Otherwise the C compiler complains about multiple
definitions of the same symbol
2011-09-06 14:31:14 +02:00
Cédric Pasteur 4cd506f3db Added c ast for constant
Also print only short names for struct fields
2011-09-06 14:20:57 +02:00
Cédric Pasteur 8cc879be7a Generate code from interface (.epi) files
It includes the definition of types, constants
and prototypes defined in the interface.
2011-09-06 11:55:06 +02:00
Cédric Pasteur da8956e247 Revert changes
Bring back cvarlist_of_ovarlist with a more 
explicit name to show its specificity
2011-07-22 10:52:31 +02:00
Brice Gelineau 9fb42a5feb Removed unused functions in C generation 2011-07-21 18:01:32 +02:00
Cédric Pasteur a52e80bcad Fixed some TODOs 2011-07-21 11:54:52 +02:00
Cédric Pasteur 7d95b95ed7 Merge branch 'memalloc' into decade
Conflicts:
	compiler/global/signature.ml
	compiler/heptagon/analysis/typing.ml
	compiler/heptagon/hept_printer.ml
	compiler/heptagon/hept_utils.ml
	compiler/heptagon/heptagon.ml
	compiler/heptagon/parsing/hept_parser.mly
	compiler/heptagon/parsing/hept_parsetree.ml
	compiler/heptagon/parsing/hept_scoping.ml
	compiler/heptagon/transformations/switch.ml
	compiler/main/hept2mls.ml
	compiler/minils/minils.ml
	compiler/minils/mls_printer.ml
	compiler/obc/c/cgen.ml
	compiler/obc/control.ml
	compiler/utilities/misc.mli
2011-07-21 08:50:45 +02:00
Léonard Gérard 13955147ca patch java wrong merge. 2011-07-08 15:25:00 +02:00
Léonard Gérard 0518ecafe6 Merge branch 'multidimensional' into decade
Conflicts:
	compiler/obc/c/cgen.ml
	compiler/obc/java/java_main.ml
2011-07-08 11:36:46 +02:00
Léonard Gérard ab3823874c Feature: Java main will give bin args as static params to the main.
consider having a main node like this one:

node main<<i : int; b : bool>> () returns...

Then if to call the generated program, you'll need ot give an int and a bool.
Furthermore, if you give an additional arg, it'll be used as the wanted
iteration number.
Conflicts:

	compiler/obc/java/java_main.ml
2011-07-08 11:26:05 +02:00
Léonard Gérard 4ac4347dc8 Add an error (in java main) when the specified main node is incorrect.
Conflicts:

	compiler/obc/java/java_main.ml
2011-07-08 11:18:39 +02:00
Brice Gelineau 10115684d9 bugfix for reset calls in C 2011-07-08 10:51:10 +02:00
Brice Gelineau b6aecf9869 Bugfix for reset calls in C 2011-07-07 16:18:25 +02:00
Cédric Pasteur 34b65c1234 Do not generate for loops
These loops are already present in the Obc code.
2011-07-05 18:08:21 +02:00
Cédric Pasteur bb6b9868b0 Use the variable type to add or not an indirection 2011-07-05 17:46:43 +02:00
Léonard Gérard 5837f3906f Multidimensional iterators in java. 2011-06-28 17:50:42 +02:00
Léonard Gérard c5fbcbe765 removing white spaces 2011-06-28 17:50:42 +02:00
Brice Gelineau c70d34ec06 Preliminary version of multidimensional iterators. 2011-06-28 17:50:42 +02:00
Léonard Gérard 83b0182874 Merge branch 'clocked_inputs' into decade
Conflicts:
	compiler/heptagon/analysis/typing.ml
	compiler/heptagon/parsing/hept_scoping.ml
	compiler/heptagon/parsing/hept_static_scoping.ml
	compiler/main/mls2obc.ml
	compiler/obc/c/cmain.ml
2011-06-28 14:46:43 +02:00
Léonard Gérard 46ed39b7b3 Remove some warnings. 2011-06-09 14:40:31 +02:00
Adrien Guatto 4794045208 Reworked Obc AST: from right patterns to extvalues.
I introduced a notion of extended values in Obc expressions,
replacing the Epattern constructor. Patterns may now only
occur at their rightful place, on the left of an assignment.

This change allows to index global constant arrays.
2011-05-30 16:25:00 +02:00
Brice Gelineau 938e8897b2 n-ary Sarray_power Earray_fill 2011-05-26 18:43:30 +02:00
Léonard Gérard 2a2b363bf7 Real asynchronous resets. 2011-05-26 15:56:59 +02:00
Léonard Gérard 87dc76f113 Code formating fixes (typos, tabs, spaces at endofline,...) 2011-05-26 15:56:59 +02:00
Léonard Gérard 4c2a5121e4 remove useless ml folder. 2011-05-26 15:56:59 +02:00