control flow graph

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

control flow graph

Stephane Ducasse-3
Hi

I'm experimenting in building a control flow graph of pharo methods
and I would like to know if you have ideas about what we can do
with them to support our development environment.

Stef

Reply | Threaded
Open this post in threaded view
|

Re: control flow graph

Clément Béra
I used that in the past on intermediate representations, I feel it is very useful to directly edit the code of methods with large control flows since when you have many closing brackets ] ] ] ] you never know where to write your code. Now it's specific to some use-cases such as algorithms where you write methods with large control flows, in most methods due to object oriented programming convention the control flow is not that big. In this context other things could be possible (Smart suggestions to move code out of loops, etc.)






On Fri, Feb 23, 2018 at 11:37 AM, Stephane Ducasse <[hidden email]> wrote:
Hi

I'm experimenting in building a control flow graph of pharo methods
and I would like to know if you have ideas about what we can do
with them to support our development environment.

Stef




--
Clément Béra
Pharo consortium engineer
Bâtiment B 40, avenue Halley 59650 Villeneuve d'Ascq
Reply | Threaded
Open this post in threaded view
|

Re: control flow graph

Peter Uhnak
It would be cool to have the graph for a method as a Calypso tool, so you can see them side by side :)

On Fri, Feb 23, 2018 at 11:47 AM, Clément Bera <[hidden email]> wrote:
I used that in the past on intermediate representations, I feel it is very useful to directly edit the code of methods with large control flows since when you have many closing brackets ] ] ] ] you never know where to write your code. Now it's specific to some use-cases such as algorithms where you write methods with large control flows, in most methods due to object oriented programming convention the control flow is not that big. In this context other things could be possible (Smart suggestions to move code out of loops, etc.)






On Fri, Feb 23, 2018 at 11:37 AM, Stephane Ducasse <[hidden email]> wrote:
Hi

I'm experimenting in building a control flow graph of pharo methods
and I would like to know if you have ideas about what we can do
with them to support our development environment.

Stef




--
Clément Béra
Pharo consortium engineer

Reply | Threaded
Open this post in threaded view
|

Re: control flow graph

Stephane Ducasse-3
Tx. I was thinking about

x = 3
  ifTrue: [^ 66]
  ifFalse: [^ 88].
^ 666

kind of analysis.
Anyway for now I just continue to do it and we will see



On Fri, Feb 23, 2018 at 2:27 PM, Peter Uhnák <[hidden email]> wrote:

> It would be cool to have the graph for a method as a Calypso tool, so you
> can see them side by side :)
>
> On Fri, Feb 23, 2018 at 11:47 AM, Clément Bera <[hidden email]>
> wrote:
>>
>> I used that in the past on intermediate representations, I feel it is very
>> useful to directly edit the code of methods with large control flows since
>> when you have many closing brackets ] ] ] ] you never know where to write
>> your code. Now it's specific to some use-cases such as algorithms where you
>> write methods with large control flows, in most methods due to object
>> oriented programming convention the control flow is not that big. In this
>> context other things could be possible (Smart suggestions to move code out
>> of loops, etc.)
>>
>>
>>
>>
>>
>>
>> On Fri, Feb 23, 2018 at 11:37 AM, Stephane Ducasse
>> <[hidden email]> wrote:
>>>
>>> Hi
>>>
>>> I'm experimenting in building a control flow graph of pharo methods
>>> and I would like to know if you have ideas about what we can do
>>> with them to support our development environment.
>>>
>>> Stef
>>>
>>
>>
>>
>> --
>> Clément Béra
>> Pharo consortium engineer
>> https://clementbera.wordpress.com/
>> Bâtiment B 40, avenue Halley 59650 Villeneuve d'Ascq
>
>

Reply | Threaded
Open this post in threaded view
|

Re: control flow graph

Stephane Ducasse-3
In reply to this post by Clément Béra
Clement this analysis can be done without a control flow no?


On Fri, Feb 23, 2018 at 11:47 AM, Clément Bera <[hidden email]> wrote:

> I used that in the past on intermediate representations, I feel it is very
> useful to directly edit the code of methods with large control flows since
> when you have many closing brackets ] ] ] ] you never know where to write
> your code. Now it's specific to some use-cases such as algorithms where you
> write methods with large control flows, in most methods due to object
> oriented programming convention the control flow is not that big. In this
> context other things could be possible (Smart suggestions to move code out
> of loops, etc.)
>
>
>
>
>
>
> On Fri, Feb 23, 2018 at 11:37 AM, Stephane Ducasse <[hidden email]>
> wrote:
>>
>> Hi
>>
>> I'm experimenting in building a control flow graph of pharo methods
>> and I would like to know if you have ideas about what we can do
>> with them to support our development environment.
>>
>> Stef
>>
>
>
>
> --
> Clément Béra
> Pharo consortium engineer
> https://clementbera.wordpress.com/
> Bâtiment B 40, avenue Halley 59650 Villeneuve d'Ascq

Reply | Threaded
Open this post in threaded view
|

Re: control flow graph

Clément Béra
The control flow is just a visualisation, everything can be done without it, it's just way more convenient to look at.

On Feb 24, 2018 09:08, "Stephane Ducasse" <[hidden email]> wrote:
Clement this analysis can be done without a control flow no?


On Fri, Feb 23, 2018 at 11:47 AM, Clément Bera <[hidden email]> wrote:
> I used that in the past on intermediate representations, I feel it is very
> useful to directly edit the code of methods with large control flows since
> when you have many closing brackets ] ] ] ] you never know where to write
> your code. Now it's specific to some use-cases such as algorithms where you
> write methods with large control flows, in most methods due to object
> oriented programming convention the control flow is not that big. In this
> context other things could be possible (Smart suggestions to move code out
> of loops, etc.)
>
>
>
>
>
>
> On Fri, Feb 23, 2018 at 11:37 AM, Stephane Ducasse <[hidden email]>
> wrote:
>>
>> Hi
>>
>> I'm experimenting in building a control flow graph of pharo methods
>> and I would like to know if you have ideas about what we can do
>> with them to support our development environment.
>>
>> Stef
>>
>
>
>
> --
> Clément Béra
> Pharo consortium engineer
> https://clementbera.wordpress.com/
> Bâtiment B 40, avenue Halley 59650 Villeneuve d'Ascq

Reply | Threaded
Open this post in threaded view
|

Re: control flow graph

Tudor Girba-2
What kind of visualization would you have in mind?

Doru


> On Feb 24, 2018, at 11:51 AM, Clément Bera <[hidden email]> wrote:
>
> The control flow is just a visualisation, everything can be done without it, it's just way more convenient to look at.
>
> On Feb 24, 2018 09:08, "Stephane Ducasse" <[hidden email]> wrote:
> Clement this analysis can be done without a control flow no?
>
>
> On Fri, Feb 23, 2018 at 11:47 AM, Clément Bera <[hidden email]> wrote:
> > I used that in the past on intermediate representations, I feel it is very
> > useful to directly edit the code of methods with large control flows since
> > when you have many closing brackets ] ] ] ] you never know where to write
> > your code. Now it's specific to some use-cases such as algorithms where you
> > write methods with large control flows, in most methods due to object
> > oriented programming convention the control flow is not that big. In this
> > context other things could be possible (Smart suggestions to move code out
> > of loops, etc.)
> >
> >
> >
> >
> >
> >
> > On Fri, Feb 23, 2018 at 11:37 AM, Stephane Ducasse <[hidden email]>
> > wrote:
> >>
> >> Hi
> >>
> >> I'm experimenting in building a control flow graph of pharo methods
> >> and I would like to know if you have ideas about what we can do
> >> with them to support our development environment.
> >>
> >> Stef
> >>
> >
> >
> >
> > --
> > Clément Béra
> > Pharo consortium engineer
> > https://clementbera.wordpress.com/
> > Bâtiment B 40, avenue Halley 59650 Villeneuve d'Ascq
>

--
www.tudorgirba.com
www.feenk.com

"When people care, great things can happen."





Reply | Threaded
Open this post in threaded view
|

Re: control flow graph

Stephane Ducasse-3
In reply to this post by Clément Béra
Yes I know but closing counting closing brackets are easier to do on the AST.
Now I imagine that variable reachability is easier with control flow.
A control flow is an dedicated abstraction over a program. Now people I met
want to use it to support clone detection between different language
because this is an abstraction.
And I'm curious to see what we can do if we have this kind of trees.

stef

On Sat, Feb 24, 2018 at 11:51 AM, Clément Bera <[hidden email]> wrote:

> The control flow is just a visualisation, everything can be done without it,
> it's just way more convenient to look at.
>
> On Feb 24, 2018 09:08, "Stephane Ducasse" <[hidden email]> wrote:
>>
>> Clement this analysis can be done without a control flow no?
>>
>>
>> On Fri, Feb 23, 2018 at 11:47 AM, Clément Bera <[hidden email]>
>> wrote:
>> > I used that in the past on intermediate representations, I feel it is
>> > very
>> > useful to directly edit the code of methods with large control flows
>> > since
>> > when you have many closing brackets ] ] ] ] you never know where to
>> > write
>> > your code. Now it's specific to some use-cases such as algorithms where
>> > you
>> > write methods with large control flows, in most methods due to object
>> > oriented programming convention the control flow is not that big. In
>> > this
>> > context other things could be possible (Smart suggestions to move code
>> > out
>> > of loops, etc.)
>> >
>> >
>> >
>> >
>> >
>> >
>> > On Fri, Feb 23, 2018 at 11:37 AM, Stephane Ducasse
>> > <[hidden email]>
>> > wrote:
>> >>
>> >> Hi
>> >>
>> >> I'm experimenting in building a control flow graph of pharo methods
>> >> and I would like to know if you have ideas about what we can do
>> >> with them to support our development environment.
>> >>
>> >> Stef
>> >>
>> >
>> >
>> >
>> > --
>> > Clément Béra
>> > Pharo consortium engineer
>> > https://clementbera.wordpress.com/
>> > Bâtiment B 40, avenue Halley 59650 Villeneuve d'Ascq
>>
>