Method and system for identifying and removing dead codes from a computer program
Abstract:
A system and method for identifying and removing dead-code from a computer program of an independent service is provided. The method includes: retrieving information related to the code of the service, wherein the retrieved information includes at least static and dynamic dependencies information of classes of the service; constructing a static dependencies graph, wherein nodes of the static dependencies graph are classes, and directed edges depict static dependencies between classes; classifying classes based on the static dependencies; constructing a first subgraph to include classes classified as internal-pure-static (IPS) classes; detecting external-dead-class candidates by traversing the subgraph; adding external-dead-class candidates to a dead code cut (DCC) set; and removing at least one class included in the DCC set from the code of the service.
Information query
Patent Agency Ranking
0/0