![]() |
Procedure to analyse source code
Hi,
I am new to programming world. i have been assigned to analyse some C-source code and provided with Source insite software. The problem is that i don't have any experiance with code analysis and its consuming lot of time in analysing even a small function. Can u please let me know if there is any good procedure to analyse programs... I will be eagerly waiting for the solution.. |
PM-ing people with a dummy subject then asking them the same question in your post is not going to get you any help
|
You've been very vague here. To what end are you analysing the code exactly?
|
I am analysing at abstract level.. give a general idea for analysing the code..
|
Ok that's a start, but you'll still need to say why you are analysing the code. What do you hope to learn?
|
Something like this??
http://java-source.net/open-source/c...alyzers/qj-pro |
I am analysing the code to upgrade the features of current code. I have to go through each data structure and function. once i am done with this i have make changes in the existing code. since this is my first time i am going very slow. i want some clean and efficient process to follow. I tryed to go through all data structures but i couldn't understand why many of variables r used. I also tryed to go through functions but was not able findout when the perticular variable has to be changed and when should not be changed.
|
It sounds like you are working with some badly commented code, I don't envy you.
I am afraid I don't know of any formal analysis procedure, perhaps other here might know of some. But if I were assigned that task I would think your first two steps would be to a) get very familiar with the overall purpose of the code and how it works before getting into the small details like when are individual variables changed. And b) you will need a comprehensive test environment which can verify the existing code works for the different input scenarios. This would mean that when you start to make changes you can check quickly (and ideally automatically) that you haven't broken anything that used to work. I must admit that I am a little wary because of your first statement, "I am new to programming world." Reading and understanding someone else's code is generally considered harder than writing it yourself, this MS blog post sums it up nicely. So you are going to need that good testing environment where you can experiment with the existing code. Perhaps you can tell us more which might be helpful? |
| All times are GMT -5. The time now is 3:05 AM. |
Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC