Very detailed Moose model ? (at the level of statement)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Very detailed Moose model ? (at the level of statement)

Nicolas Anquetil

It might be interesting in some cases to have very detailed moose
models, at the level of single instruction
(there is a loop, its test compares variable x to 5, ...)

That would generates incredibly huge models, of course, but for
localized tasks it could be useful.

Was there some work along these lines at any point in time?

Or are we the only one to think it could be useful?

nicolas
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
cbc
Reply | Threaded
Open this post in threaded view
|

Re: Very detailed Moose model ? (at the level of statement)

cbc
On Thu, Sep 6, 2012 at 8:56 AM, Nicolas Anquetil
<[hidden email]> wrote:

>
> It might be interesting in some cases to have very detailed moose models, at
> the level of single instruction
> (there is a loop, its test compares variable x to 5, ...)
>
> That would generates incredibly huge models, of course, but for localized
> tasks it could be useful.
>
> Was there some work along these lines at any point in time?
>
> Or are we the only one to think it could be useful?
>
> nicolas
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

Personally, I would like to be able to track the movement of data
through the code - where it was first entered, what
methods/classes/interfaces/whatever it passed through, where it
finally ended up.  I've been meaning to ask if the moose model (or
MSE?) was conceived for such analysis, or is it targetted at a larger
scale view (which is what I think I've seen).

So, thanks for asking.  That's roughly what I'd like to know, too.

-Chris
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: Very detailed Moose model ? (at the level of statement)

Tudor Girba-2
In reply to this post by Nicolas Anquetil
Hi Nicolas,

Of course it can be interesting.

Are you hinting towards AST information? Or do you have in mind a more
relaxed, but more general model?

If it is the former, in Smalltalk the AST is already available :). In
other languages you would have to implement it.

In projects where PetitParser is being used to import sources, the AST
is most likely provided (because for less than it is needed for
import). For example, I guess that the Delphi implementation will
offer it (right, Stephan? :)). Also, I built a couple of such projects
for custom languages and there I have a full AST that is available on
demand from the FAMIX model.

For other languages, like Java, we would need to serialize this AST
from the external parser. It would definitely be a very welcome
addition.

As for the size of the model, the AST could also be loaded on demand
for a restricted amount of entities. For example, suppose that each
source file (or source entity) would have an associated AST file. In
that case, we could load the AST on demand just for the interesting
parts.

Cheers,
Doru


On Thu, Sep 6, 2012 at 5:56 PM, Nicolas Anquetil
<[hidden email]> wrote:

>
> It might be interesting in some cases to have very detailed moose models, at
> the level of single instruction
> (there is a loop, its test compares variable x to 5, ...)
>
> That would generates incredibly huge models, of course, but for localized
> tasks it could be useful.
>
> Was there some work along these lines at any point in time?
>
> Or are we the only one to think it could be useful?
>
> nicolas
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev



--
www.tudorgirba.com

"Every thing has its own flow"
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev