WPP - History

It has ever been seen as an integral part of Project WOOP to implement a tool that would incorporate the theoretical results gathered. Research work on discrete loops had been finished at the end of the year 1993, and this was considered a good starting point for the actual implementation. Ada95 had been chosen to serve as the vehicle for this new kind of loop, a decision that was mainly due to the reliability and maintainability of that programming language. One of the things we needed in order to augment Ada95 with the concept of discrete loops was some sort of translation mechanism that would provide programmers with a way of using them in their own code. Since our resources were too limited (as resources are in general) to build a full-fledged discrete loop - augmented Ada95 compiler, we decided to achieve this by means of a precompiler that would translate discrete loops into semantically equivalent Ada95 code. It would still have to perform syntactic as well as semantic analysis on its input, but it saved us from the burden of (object) code generation. Our first plan was to start with an Ada95-parser generated by ayacc, but back in those days it was impossible to compile ayacc and aflex with GNAT. In this way we decided to built on the source-code of GNAT itself, thus becoming one of the first GNAT-fiddlers (as Robert Dewar, one of GNAT's creators, put it) in history.

Another beast that suited our needs was Wolfram Research's MATHEMATICA), a commercial package for computer algebra. Among its advantages over similar programs are its inherent functional programming language as well as its well- documented communication protocol. Our precompiler makes use of it in order to solve equations and recurrence relations that occur when striving for those upper bounds of discrete loops. Later on in the development of our tool we decided to call it 'preprocessor' instead of 'precompiler', but this was only done for the sake of the resulting acronym ('WPP'). Since this three-letter combination seems to be a little tedious to be spelled, we propose to spell it as 'double U double P' or 'double (UP)' for short. WPP can do most of the things now that have been introduced in (discloop paper). The few remaining features are usually described in sections starting with 'a smart compiler is free to perform whatever ... in order to achieve ...', but I stopped worrying about them. WPP can derive upper bounds for the number of iterations for many kinds of discrete loops, and it can also serve as the base for future extensions addressing real-time recursions and object-oriented programming.