Control-flow analysis: Difference between revisions

Content deleted Content added
this is one of the wierdest articles in Wikipedia; probably written by people who don't know what they're writing about. Here's a link to what an article like this should cover: material found in most compiler books
Line 1:
{{rewrite}}
In [[computer science]], '''control flow analysis''' is a [[static code analysis]] technique for determining the [[control flow]] of a program. The control flow is expressed as a [[control flow graph]] (CFG). The term "control flow analysis" was introduced independently by [[Neil D. Jones]]<ref>{{citation
| author = Neil D. Jones
Line 15 ⟶ 16:
| year = 1988
| doi = 10.1145/53990.54007
}}</ref> For both [[functional programming language]]s and [[object-oriented programming language]]s, the term CFA, and elaborations such as ''k''-CFA, refer to specific algorithms that compute control flow.{{dubious}}
 
For many [[imperative programming language]]s, the control flow of a program is explicit in a program's source code. As a result, control-flow analysis implicitly usually refers to a [[static analysis]] technique for determining the receiver(s) of function or method calls in computer programs written in a [[higher-order programming language]]. For example, in a programming language with [[higher-order functions]] like [[Scheme (programming language)|Scheme]], the target of a function call may not be explicit: in the isolated expression
Line 23 ⟶ 24:
it is unclear to which procedure <code>f</code> may refer. To determine the possible targets, a control-flow analysis must consider where this expression could be invoked, and what argument it may receive.
 
Techniques such as [[abstract interpretation]], [[constraint solving]] and [[type system]]s may be used to compute control-flow analysis.<ref>Flemming Nielson, Hanne Riis Nielson & Chris Hankin (1999). ''Principles of Program Analysis''. Springer.</ref>{{dubious}}
 
== See also ==
Line 32 ⟶ 33:
 
[[Category:Control-flow analysis| ]]
 
== External links ==
* http://pages.cs.wisc.edu/~cs701-1/NOTES/3.CONTROL-FLOW-ANALYSIS.html