Author Topic: FlowCharts from Source Code  (Read 11159 times)

Offline ThomasG

  • Multiple posting newcomer
  • *
  • Posts: 12
FlowCharts from Source Code
« on: January 05, 2006, 09:06:03 pm »
Hi,

I got a huge project assigned for maintenance. In order to get an idea what is going on, I would like to chart out the project or at least parts of it.

Can you guys give some advices? Maybe some software packages that can do the job?

Thanks,
Thomas

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: FlowCharts from Source Code
« Reply #1 on: January 05, 2006, 11:31:24 pm »
Hello,

Did you try a fast Google search :)? For example this is what I get.

Michael

Offline ThomasG

  • Multiple posting newcomer
  • *
  • Posts: 12
Re: FlowCharts from Source Code
« Reply #2 on: January 06, 2006, 03:37:17 pm »
Hi,

yes I did a search on google. I even tried most of these programs. But so far I couldn't find one that is really satisfying. The programs are either limited in functionality or are very expensive. Now I'm curious if these kind of tools are even used by open source developer. Since I couldn't find any open source solution I'm tempted to say it's not a commonly used tool.

Maybe you guys can point out methods on how get a grip on unknown programs/source code.

Thanks in advance.

Thomas

Offline Ceniza

  • Developer
  • Lives here!
  • *****
  • Posts: 1442
    • CenizaSOFT
Re: FlowCharts from Source Code
« Reply #3 on: January 06, 2006, 04:37:28 pm »
If the program is well structured and designed it should just be a matter of reading comments and follow the code, if that isn't the case it'll just be a nightmare, even with a flowchart.

Offline ThomasG

  • Multiple posting newcomer
  • *
  • Posts: 12
Re: FlowCharts from Source Code
« Reply #4 on: January 06, 2006, 05:59:54 pm »
Yeah, you are right, unfurtunately it's "structured" in a way only the original programmer can understand what's going on because he programmed it over the last 20 years.

I guess there is only the hard way of trial and error to figure out the source code and the refactor it.

Thanks,
Thomas

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: FlowCharts from Source Code
« Reply #5 on: January 06, 2006, 06:14:01 pm »
You can also try to search in sourceforge, if you find something useful. May be also in wxCode (but I am not sure).

Michael

Offline Game_Ender

  • Lives here!
  • ****
  • Posts: 551
Re: FlowCharts from Source Code
« Reply #6 on: January 06, 2006, 06:29:41 pm »
The reason those tools are expensive is because the of the difficulties of the C++ language.  It is quite hard to parse and work with, which is why leads to much longer tool developement time, and it is why you won't find much in the way of open source tools that work with it.  I know Umbrello is able to generate class diagrams from C++ code.

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: FlowCharts from Source Code
« Reply #7 on: January 06, 2006, 06:39:51 pm »
I know Umbrello is able to generate class diagrams from C++ code.

Umbrello looks interesting :), but it works only under Linux, or?

Michael

Offline rudin

  • Multiple posting newcomer
  • *
  • Posts: 19
Re: FlowCharts from Source Code
« Reply #8 on: January 06, 2006, 07:02:02 pm »
Maybe StarUML (http://staruml.tigris.org) can help you refactor your code. It runs on Windows, freeware, and open source.

Offline Ceniza

  • Developer
  • Lives here!
  • *****
  • Posts: 1442
    • CenizaSOFT
Re: FlowCharts from Source Code
« Reply #9 on: January 06, 2006, 07:05:47 pm »
Well, Umbrello is for KDE, and two ways to bring KDE to Windows are: Cygwin and Virtualization.

Tricky to get working under Windows anyway.

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: FlowCharts from Source Code
« Reply #10 on: January 06, 2006, 08:14:05 pm »
Well, Umbrello is for KDE, and two ways to bring KDE to Windows are: Cygwin and Virtualization.

Cygwin is relatively huge. I have tried it for sometimes, but not liked too much. MinGW/MYSYS is IMHO better :), at least for what I needed it. Virtualization is a bit new concept for me :oops:.

I have not tried it, but may be StarUML (suggested by rudin) is a better option under Windows. A search within Tigris.org could also lead to some interesting alternatives.

Michael

Offline ThomasG

  • Multiple posting newcomer
  • *
  • Posts: 12
Re: FlowCharts from Source Code
« Reply #11 on: January 06, 2006, 08:46:57 pm »
Thanks, I will try out the suggested programs. I don't care if Linux or Windows, have both running and use whatever does the job done.

I would already happy with a tool that gets plain C right. I just had another look at the code, haven't seen that many goto's since my days of programming BASIC on my Sharp E500s pocket calculator. Any help/tool/hint is appreciated.

Thomas