Commit Graph

417 Commits

Author SHA1 Message Date
Neil Brown
78f9fb6196 Added support in recordFields for channel bundles (which are similar enough to records) 2009-03-23 18:59:41 +00:00
Neil Brown
04108613d9 Added support to a couple of functions for the IsClaimed SpecType 2009-03-23 18:56:48 +00:00
Neil Brown
41805aaacf Changed the ChanEnd constructor to only keep information about its shared-ness, not about the whole channel 2009-03-23 18:40:28 +00:00
Neil Brown
8af024e08d Fixed a ShowCode comment and added a missing case 2009-03-23 15:55:15 +00:00
Neil Brown
8492dc03d4 Introduced a ShareMode in the AST, and used it in the channel attributes (rather than Bool) 2009-03-22 22:29:39 +00:00
Neil Brown
0a97946fbf Fixed various type-checking things related to mobile types 2009-03-22 21:05:36 +00:00
Neil Brown
4f6050069c Moved isMobileType into the Types module where it belongs 2009-03-22 18:26:14 +00:00
Neil Brown
03f1b2d115 Added a few more mobile things (DEFINED keyword, an intrinsic) 2009-03-20 20:53:51 +00:00
Neil Brown
3a7b2aaaf4 Added a function for getting the attributes of a record type 2009-03-20 19:10:11 +00:00
Neil Brown
1044a94730 Changed most of the rest of Tock (except some tests) to understand the new record attributes 2009-03-20 15:18:29 +00:00
Neil Brown
65550b705e Added an AllSizesVariable item to the AST so that the backend inserts the right code for mobiles and non-mobiles 2009-03-20 11:31:14 +00:00
Neil Brown
65875f523f Added mobile cloning rather than using dereferencing to copy mobiles 2009-03-19 16:47:31 +00:00
Neil Brown
8e5e73e3a2 Fixed the support in the backends for mobile channel stuff 2009-03-19 15:23:35 +00:00
Neil Brown
ca61da25cf Added a function to the Types module to allow you to easily change the type of a SpecType 2009-03-19 15:13:00 +00:00
Neil Brown
0d5c8f28fd Fixed a couple of helper functions to navigate through mobile arrays properly 2009-02-27 17:09:14 +00:00
Neil Brown
2a2ce367ca Added some missing cases in the ShowCode module 2009-02-27 17:02:34 +00:00
Neil Brown
4055746e19 Fixed typeOfVariable to handle directed inferred variables 2009-02-10 22:20:02 +00:00
Neil Brown
24fa36ccda Modified the test harness so that it gives a meta tag on failure (in case we want it) 2009-02-10 21:33:53 +00:00
Neil Brown
93af6b85a4 Updated the comments on the product* functions in the Utils module 2009-02-09 23:10:29 +00:00
Neil Brown
0e95d5d15e Added a couple more functions to the Utils module 2009-02-09 22:25:12 +00:00
Neil Brown
904b913ebd Added another helper function to the Utils module 2009-02-09 16:57:02 +00:00
Neil Brown
9c4b8e8df1 Changed tocktest so you can pass it -v options for use with the automatic tests 2009-02-08 16:33:53 +00:00
Neil Brown
091acfa848 Added a new helper function to Utils for joining pairs of lists with pairs of lists 2009-02-07 18:45:56 +00:00
Neil Brown
56a10b403f Added a new function, filterMapByKey, to the Utils module 2009-02-05 15:52:43 +00:00
Neil Brown
bb6937433f Fixed the TestUtils module by removing some of the old range stuff 2009-02-03 11:52:12 +00:00
Neil Brown
ec1341849d Added a ShowOccam instance for A.Dimension 2009-02-02 23:51:15 +00:00
Neil Brown
8de2dbca88 Adjusted the modules in common to match the new array constructor change 2009-02-01 21:52:13 +00:00
Neil Brown
4f83187549 Fixed up all the tests in light of the new recursive procs 2009-01-29 00:56:32 +00:00
Neil Brown
10e6b4ce02 Updated all the tests to work with the new recursive functions 2009-01-29 00:34:12 +00:00
Neil Brown
594d7ef242 Tweaked various code in the common and checks directory to work with the new step count in the For replicator 2009-01-28 23:43:16 +00:00
Neil Brown
d4f1ac2797 Added nearly all the remaining intrinsic functions (all the *TOSTRING and STRINGTO*, except for floating-point types) 2009-01-27 17:00:28 +00:00
Neil Brown
f4f08e09aa Fixed the RAN/DRAN intrinsic 2009-01-27 13:50:42 +00:00
Neil Brown
9b1368ffe7 Implemented all but one (RAN) of the intrinsic functions in appendix N by mapping them directly to the C versions 2009-01-27 13:38:00 +00:00
Neil Brown
c19039e90e Added the definitions of most of the intrinsics from the occam 2.1 manual (but not yet the implementations) 2009-01-25 18:54:57 +00:00
Neil Brown
7337978dcf Added many more intrinsics to the list of occam intrinsics 2009-01-23 19:19:36 +00:00
Neil Brown
c2aaf2fcf7 Provided more helpful errors in the test harness when something is wrong 2009-01-23 14:42:46 +00:00
Neil Brown
d806931fbf Revamped the TestHarness framework to allow multiple substitutions in a test prologue 2009-01-20 23:43:07 +00:00
Neil Brown
9145c993ea Fixed the constant folding to use a type for Int based on the compilation target rather than just assuming Int32
However, it is possible that there will still be a problem if the C and C++ compiler have different int sizes, because the constant folding has to know the type at compile time, and thus we have to arbitrarily choose to use the C version.  In future, we could perhaps swap all Ints for the appropriate substiution (e.g. Int64) at run-time, based on the flags and prior knowledge about C/C++ int sizes
2009-01-23 15:50:06 +00:00
Neil Brown
2a8ee9a420 Fixed a bug in the constant folding, where anything divided by -1 was being evaluated to zero 2009-01-23 15:48:39 +00:00
Neil Brown
de80ab467e Fixed the common Types module to work with the new channel-ends 2009-01-20 17:27:37 +00:00
Neil Brown
336c5abe3c Fixed the ShowCode module to work with the new channel-ends 2009-01-20 17:27:10 +00:00
Neil Brown
ee62c604fc Renamed our permutations function to permutation to avoid a conflict with a new GHC 6.10 function 2008-11-28 11:28:39 +00:00
Neil Brown
09e0e46ec2 Added some comments to my changes to GenericUtils 2008-11-25 18:06:14 +00:00
Neil Brown
0e7a6c5b98 Added a NameSource field for NameDef that indicates where a name comes from 2008-11-25 17:36:42 +00:00
Neil Brown
e117422c31 Added a couple more tests for checkUnusedVar which has revealed two bugs
One of these bugs is that array variables are counted as unused when they are used subscripted.  I think that should be solved when we flip back to the listify approach.

The second bug is more interesting, as it is triggered only in a certain arrangement with an IF.  It's either a bug in the flow-graph building or in the varsTouchedAfter code.
2008-11-20 15:06:36 +00:00
Neil Brown
5f01f12d43 Adjusted testOccamPassWarn to enable all warnings when testing a pass 2008-11-20 14:20:36 +00:00
Neil Brown
6cbdc0e13b Finally merged the list of warnings into CompState rather than having its own StateT monad 2008-11-20 13:35:44 +00:00
Neil Brown
f88c671cf7 Added a set of enabled warnings to CompState 2008-11-20 13:17:05 +00:00
Neil Brown
38374320a3 Moved the remainder of the checkInitVar tests over to the new system 2008-11-19 17:25:02 +00:00
Neil Brown
3b57d43eb6 Moved more of the checkInitVar tests to the new system 2008-11-19 17:08:17 +00:00