octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Octave compiler


From: JD Cole
Subject: Re: Octave compiler
Date: Mon, 23 Feb 2004 02:07:24 -0800
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20031007

Well,
One possibility would be to do some nifty type dependency analysis. For my parallel processing musings I'm in the process of implementing control and data dependency graphs. This kind of program representation should facilitate determining variable types throughout the .m. However, it may be necessary to impose at least some restrictions on the user. I'm thinking of a snippet like the following which would cause bumps in streamlining C++:

a = 10;
b = 23 * a;

a = "My name is George";
printf("%s",a);

As you all are aware, multiple uses for variables is highly frowned upon when they are the same type, let alone when they are different, e.g. integer and string. But this a comonly used feature in Octave/Matlab so perhaps variables such as these are just left "generic" in the converted code.

JD

Paul Thomas wrote:

Yes, that is what I was getting at - or explicit type declaration. I had more than once wondered if the language would benefit from optional type assertion in some shape or form. This, however, brings to mind the discussion,a few months back, of passing arguments by reference or by value. Compatability with the other product makes them very undesirable. Equally, to judge by the other products performance on basic interpretation/evaluation, intelligence must exist..... I have started analysing typical .m functions to see how intelligence might be manifested in either interpreters or compilers.

Paul T





reply via email to

[Prev in Thread] Current Thread [Next in Thread]