Saturday, February 12, 2011

An Idea of a Contingent programming language

In an effort to improve the programmable logic of some programs I propose to code with a new construct called the contingent method. This method is executed if certain conditions do not meet. It brings in a different kind of coding discipline and if certain part of the code does not work you end up with a different set of systems implementation. You may say that this sounds similar to a fault tolerant language but wait till you read the end of the post.

Here is an example:
HelloWorld
main()
{
printf("Hello World");
exit(0);
}
contingent()
{
exit (1)
}

Explaining HelloWorld in a simplistic way: Try printing Hello World and If you can't print it return 1. Let’s see what we mean by "can't".

It may sound similar to exceptions handling but the construct used there is exception and it can be related to an error with the machine or programming error. Here we are saying that it’s not an error that you could not execute Hello World but for some reason a certain unknown condition could not be satisfied for you to execute the HelloWorld code. What are the examples of unknown conditions it could be anything of the following:

1. You do not have OS time left to execute the code, due to changing system priorities for the program that you are running. e.g. you are running HelloWorld but suddenly you receive a chat message on your chat software and thus display is not available to print HelloWorld. In this case contingent piece of code is invoked.

2. You are not compliant to execute the code. Due to certain system overload parameters let’s say Hello cannot be used at this time on display (let's assume that the system has a policy and a device driver code continually check if there are contingent policy related violations)

3. User defined. We allow user to define what it means to be contingent for a given program making it behave differently when certain conditions do not meet. If no conditions apply the code works just fine like the usual program.

Some of the benefits are providing Risk mitigation capabilities at the functional level. If there are certain actions taken by the software contingent programming model will enable resource allocation as per the contingent actions demands and scale as per the requirements. We also provide by design a strategic avoidance model.

Thursday, February 3, 2011

Objective of this blog

Reconfigurable systems is a topic dealt with at large by scientist and researchers all over the scientific community. My interests will highlight some of the specific areas of interests in software products that can be of benefit to the readers. The views expressed in this blog are solely on my own. The embedded links in the blog are for general reading and try to further elaborate my opinion. I welcome comments and please do enjoy reading.