skip to main content
research-article
Free Access

Algorithms for Algebraic Path Properties in Concurrent Systems of Constant Treewidth Components

Published:05 July 2018Publication History
Skip Abstract Section

Abstract

We study algorithmic questions wrt algebraic path properties in concurrent systems, where the transitions of the system are labeled from a complete, closed semiring. The algebraic path properties can model dataflow analysis problems, the shortest path problem, and many other natural problems that arise in program analysis. We consider that each component of the concurrent system is a graph with constant treewidth, a property satisfied by the controlflow graphs of most programs. We allow for multiple possible queries, which arise naturally in demand driven dataflow analysis. The study of multiple queries allows us to consider the tradeoff between the resource usage of the one-time preprocessing and for each individual query. The traditional approach constructs the product graph of all components and applies the best-known graph algorithm on the product. In this approach, even the answer to a single query requires the transitive closure (i.e., the results of all possible queries), which provides no room for tradeoff between preprocessing and query time.

Our main contributions are algorithms that significantly improve the worst-case running time of the traditional approach, and provide various tradeoffs depending on the number of queries. For example, in a concurrent system of two components, the traditional approach requires hexic time in the worst case for answering one query as well as computing the transitive closure, whereas we show that with one-time preprocessing in almost cubic time, each subsequent query can be answered in at most linear time, and even the transitive closure can be computed in almost quartic time. Furthermore, we establish conditional optimality results showing that the worst-case running time of our algorithms cannot be improved without achieving major breakthroughs in graph algorithms (i.e., improving the worst-case bound for the shortest path problem in general graphs). Preliminary experimental results show that our algorithms perform favorably on several benchmarks.

References

  1. Amir Abboud and Virginia Vassilevska Williams. 2014. Popular conjectures imply strong lower bounds for dynamic problems. In Proceedings of the IEEE Symposium on Foundations of Computer Science (FOCS’14). 434--443. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Amir Abboud, Virginia Vassilevska Williams, and Huacheng Yu. 2015. Matching triangles and basing hardness on an extremely popular conjecture. In Proceedings of the ACM Symposium on Theory of Computing (STOC’15). 41--50. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Rajeev Alur, Sampath Kannan, and Mihalis Yannakakis. 1999. Communicating hierarchical state machines. In Proceedings of the International Conference on Applied Linguistics (ICAL’99). Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Stefan Arnborg and Andrzej Proskurowski. 1989. Linear time algorithms for NP-hard problems restricted to partial k-trees. Discr. Appl. Math. 23, 1 (1989), 11--24. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Wayne A. Babich and Mehdi Jazayeri. 1978. The method of attributes for data flow analysis. Acta Inform. 10, 3 (1978). Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. R. Bellman. 1958. On a routing problem. Quart. Appl. Math. 16, 1 (1958), 87--90.Google ScholarGoogle ScholarCross RefCross Ref
  7. M. W. Bern, E. L. Lawler, and A. L. Wong. 1987. Linear-time computation of optimal subgraphs of decomposable graphs. J. Algor. 8, 2 (1987), 216--235. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. Stephen M. Blackburn et al. 2006. The DaCapo benchmarks: Java benchmarking development and analysis. In Proceedings of the ACM SIGPLAN International Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA’06). Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Hans L. Bodlaender. 2005. Discovering treewidth. In SOFSEM 2005: Theory and Practice of Computer Science. LNCS, Vol. 3381. Springer. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Hans L. Bodlaender. 1988. Dynamic programming on graphs with bounded treewidth. In Proceedings of the International Colloquium on Automata, Languages, and Programming (ICALP’88). Springer. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Hans L. Bodlaender. 1993. A tourist guide through treewidth. Acta Cybern. 11, 1 (1993), 1--13.Google ScholarGoogle Scholar
  12. Hans L. Bodlaender. 1996. A linear-time algorithm for finding tree-decompositions of small treewidth. SIAM J. Comput. 25, 6 (1996), 1305--1317. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Hans L. Bodlaender and Torben Hagerup. 1998. Parallel algorithms with optimal speedup for bounded treewidth. SIAM J. Comput. 27, 6 (1998), 1725--1746. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. Ahmed Bouajjani, Javier Esparza, Stefan Schwoon, and Jan Strejček. 2005. Reachability analysis of multithreaded software with asynchronous communication. In Proceedings of the IARCS Annual Conference on Foundations of Software Technology and Theoretical Computer Science (FSTTCS’05). Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Ahmed Bouajjani, Javier Esparza, and Tayssir Touili. 2003. A generic approach to the static analysis of concurrent programs with procedures. In Proceedings of the 30th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL’03). Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. Patricia Bouyer, Uli Fahrenberg, Kim G. Larsen, Nicolas Markey, and Jiří Srba. 2008. Infinite runs in weighted timed automata with energy constraints. In Formal Modeling and Analysis of Timed Systems. Lecture Notes in Computer Science, Vol. 5215. Springer, Berlin, 33--47. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. Bernd Burgstaller, Johann Blieberger, and Bernhard Scholz. 2004. On the tree width of ada programs. In Proceedings of the International Conference on Reliable Software Technologies (Ada-Europe’04).Google ScholarGoogle ScholarCross RefCross Ref
  18. Pavol Cerny, Edmund M. Clarke, Thomas A. Henzinger, Arjun Radhakrishna, Leonid Ryzhyk, Roopsha Samanta, and Thorsten Tarrach. 2015. From non-preemptive to preemptive scheduling using synchronization synthesis. In Proceedings of the International Conference on Computer-Aided Verification (CAV’15).Google ScholarGoogle ScholarCross RefCross Ref
  19. Pavol Cerny, Thomas A. Henzinger, and Arjun Radhakrishna. 2013. Quantitative abstraction refinement. In Proceedings of the 1st Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL’13). 115--128. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Krishnendu Chatterjee, Laurent Doyen, and Thomas A. Henzinger. 2010. Quantitative languages. ACM Trans. Comput. Log. 11, 4 (2010). Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Krishnendu Chatterjee, Amir Kafshdar Goharshady, Rasmus Ibsen-Jensen, and Andreas Pavlogiannis. 2016. Algorithms for algebraic path properties in concurrent systems of constant treewidth components. In Proceedings of the 1st Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL’16). 733--747. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. Krishnendu Chatterjee, Rasmus Ibsen-Jensen, and Andreas Pavlogiannis. 2015a. Faster algorithms for quantitative verification in constant treewidth graphs. In Proceedings of the International Conference on Computer-Aided Verification (CAV’15).Google ScholarGoogle ScholarCross RefCross Ref
  23. Krishnendu Chatterjee, Rasmus Ibsen-Jensen, Andreas Pavlogiannis, and Prateesh Goyal. 2015b. Faster algorithms for algebraic path properties in recursive state machines with constant treewidth. In Proceedings of the 1st Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL’15). Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. K. Chatterjee and J. Lacki. 2013. Faster algorithms for Markov decision processes with low treewidth. In Proceedings of the International Conference on Computer-Aided Verification (CAV’13).Google ScholarGoogle Scholar
  25. Krishnendu Chatterjee, Andreas Pavlogiannis, and Yaron Velner. 2015c. Quantitative interprocedural analysis. In Proceedings of the Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL’15). Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. Shiva Chaudhuri and Christos D. Zaroliagis. 1995. Shortest paths in digraphs of small treewidth. part I: Sequential algorithms. Algorithmica 27, 3 (1995), 212--226.Google ScholarGoogle ScholarCross RefCross Ref
  27. Ravi Chugh, Jan W. Voung, Ranjit Jhala, and Sorin Lerner. 2008. Dataflow analysis for concurrent programs using datarace detection. In Proceedings of the 29th ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI’08). Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. Brouno Courcelle. 1990. Graph rewriting: An algebraic and logic approach. In Handbook of Theoretical Computer Science, Vol. B. MIT Press, Cambridge, MA. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. Arnab De, Deepak D’Souza, and Rupesh Nasre. 2011. Dataflow analysis for datarace-free programs. In Proceedings of the 20th European Conference on Programming Languages and Systems: Part of the Joint European Conferences on Theory and Practice of Software (ESOP’11/ETAPS’11). Springer-Verlag, 196--215. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. Evelyn Duesterwald, Rajiv Gupta, and Mary Lou Soffa. 1995. Demand-driven computation of interprocedural data flow. In Proceedings of the 1st Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL’95). Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. Matthew B. Dwyer, Lori A. Clarke, Jamieson M. Cobleigh, and Gleb Naumovich. 2004. Flow analysis for verifying properties of concurrent software systems. ACM Trans. Softw. Eng. Methodol. 13, 4 (2004), 359--430. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. M. Elberfeld, A. Jakoby, and T. Tantau. 2010. Logspace versions of the theorems of bodlaender and courcelle. In Proceedings of the IEEE Symposium on Foundations of Computer Science (FOCS’10). Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. Azadeh Farzan, Zachary Kincaid, and Andreas Podelski. 2013. Inductive data flow graphs. In Proceedings of the Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL’13). Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. Azadeh Farzan and P. Madhusudan. 2007. Causal dataflow analysis for concurrent programs. In Proceedings of the 13th International Conference on Tools and Algorithms for the Construction and Analysis of Systems (TACAS’07). Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. Robert W. Floyd. 1962. Algorithm 97: Shortest path. Commun. ACM (1962). Google ScholarGoogle ScholarDigital LibraryDigital Library
  36. Lester R. Ford. 1956. Network Flow Theory. Report P-923, The Rand Corporation. (1956).Google ScholarGoogle Scholar
  37. Dirk Grunwald and Harini Srinivasan. 1993. Data flow equations for explicitly parallel programs. In Proceedings of the 4th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPOPP’93). Google ScholarGoogle ScholarDigital LibraryDigital Library
  38. J. Gustedt, O. Maehle, and J. Telle. 2002. The treewidth of java programs. In Algorithm Engineering and Experiments. Springer. Google ScholarGoogle ScholarDigital LibraryDigital Library
  39. Rudolf Halin. 1976. S-functions for graphs. J. Geom. 8, 1 (1976), 171--186.Google ScholarGoogle ScholarCross RefCross Ref
  40. David Harel, Orna Kupferman, and Moshe Y. Vardi. 1997. On the complexity of verifying concurrent transition systems. In Proceedings of the International Conference on Concurrency Theory (CONCUR’97). Google ScholarGoogle ScholarDigital LibraryDigital Library
  41. D. Harel and R. Tarjan. 1984. Fast algorithms for finding nearest common ancestors. SIAM J. Comput. 13, 2 (1984), 338--355. Google ScholarGoogle ScholarDigital LibraryDigital Library
  42. Monika Henzinger, Sebastian Krinninger, Danupon Nanongkai, and Thatchaphol Saranurak. 2015. Unifying and strengthening hardness for dynamic problems via the online matrix-vector multiplication conjecture. In Proceedings of the ACM Symposium on Theory of Computing (STOC’15). 21--30. Google ScholarGoogle ScholarDigital LibraryDigital Library
  43. Susan Horwitz, Thomas Reps, and Mooly Sagiv. 1995. Demand interprocedural dataflow analysis. SIGSOFT Softw. Eng. Notes (1995). Google ScholarGoogle ScholarDigital LibraryDigital Library
  44. Donald B. Johnson. 1977. Efficient algorithms for shortest paths in sparse networks. J. ACM 24, 1 (1977), 1--13. Google ScholarGoogle ScholarDigital LibraryDigital Library
  45. Vineet Kahlon, Sriram Sankaranarayanan, and Aarti Gupta. 2013. Static analysis for concurrent programs with applications to data race detection. Int. J. Softw. Tools Technol. Trans. 15, 4 (2013), 321--336. Google ScholarGoogle ScholarDigital LibraryDigital Library
  46. Vineet Kahlon, Nishant Sinha, Erik Kruus, and Yun Zhang. 2009. Static data race detection for concurrent programs with asynchronous calls. In Proceedings of the the 7th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on The Foundations of Software Engineering (ESEC/FSE’09). 13--22. Google ScholarGoogle ScholarDigital LibraryDigital Library
  47. Richard M. Karp. 1978. A characterization of the minimum cycle mean in a digraph. Discr. Math. 23, 3 (1978), 309--311.Google ScholarGoogle ScholarCross RefCross Ref
  48. Gary A. Kildall. 1973. A unified approach to global program optimization. In Proceedings of the 1st Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL’73). Google ScholarGoogle ScholarDigital LibraryDigital Library
  49. S. C. Kleene. 1956. Representation of events in nerve nets and finite automata. Automata Studies (1956).Google ScholarGoogle Scholar
  50. Jens Knoop, Bernhard Steffen, and Jürgen Vollmer. 1996. Parallelism for free: Efficient and optimal bitvector analyses for parallel programs. ACM Trans. Program. Lang. Syst. 18, 3 (1996), 268--299. Google ScholarGoogle ScholarDigital LibraryDigital Library
  51. Philipp Klaus Krause. 2013. Optimal register allocation in polynomial time. In Compiler Construction, Ranjit Jhala and Koen De Bosschere (Eds.). Google ScholarGoogle ScholarDigital LibraryDigital Library
  52. Salvatore La Torre, P. Madhusudan, and Gennaro Parlato. 2008. Context-bounded analysis of concurrent queue systems. In Proceedings of the International Conference on Tools and Algorithms for the Construction and Analysis of Systems (TACAS’08). Google ScholarGoogle ScholarDigital LibraryDigital Library
  53. Akash Lal, Shaz Qadeer, and Shuvendu K. Lahiri. 2012. A solver for reachability modulo theories. In Proceedings of the International Conference on Computer-Aided Verification (CAV’12). Google ScholarGoogle ScholarDigital LibraryDigital Library
  54. Akash Lal and Thomas Reps. 2009. Reducing concurrent analysis under a context bound to sequential analysis. Form. Methods Syst. Des. 35, 1 (2009), 73--97. Google ScholarGoogle ScholarDigital LibraryDigital Library
  55. Akash Lal, Tayssir Touili, Nicholas Kidd, and Thomas Reps. 2008. Interprocedural analysis of concurrent programs under a context bound. In Proceedings of the International Conference on Tools and Algorithms for the Construction and Analysis of Systems (TACAS’08). Google ScholarGoogle ScholarDigital LibraryDigital Library
  56. Eugene Lawler. 1976. Combinatorial Optimization: Networks and Matroids. Saunders College Publishing.Google ScholarGoogle Scholar
  57. Daniel J. Lehmann. 1977. Algebraic structures for transitive closure. Theoretical Computer Science (1977).Google ScholarGoogle Scholar
  58. P. Madhusudan and Gennaro Parlato. 2011. The tree width of auxiliary storage. In Proceedings of the 1st Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL’11). Google ScholarGoogle ScholarDigital LibraryDigital Library
  59. Nomair A. Naeem, Ondřej Lhoták, and Jonathan Rodriguez. 2010. Practical extensions to the IFDS algorithm. In Proceedings of the International Conference on Compiler Construction (CC’10). Google ScholarGoogle ScholarDigital LibraryDigital Library
  60. Jan Obdrzálek. 2003. Fast Mu-calculus model checking when tree-width is bounded. In Proceedings of the International Conference on Computer-Aided Verification (CAV’03).Google ScholarGoogle ScholarCross RefCross Ref
  61. Shaz Qadeer and Jakob Rehof. 2005. Context-bounded model checking of concurrent software. In Proceedings of the International Conference on Tools and Algorithms for the Construction and Analysis of Systems (TACAS’05). Google ScholarGoogle ScholarDigital LibraryDigital Library
  62. Bruce A. Reed. 1992. Finding approximate separators and computing tree width quickly. In Proceedings of the ACM Symposium on Theory of Computing (STOC’92). Google ScholarGoogle ScholarDigital LibraryDigital Library
  63. Thomas W. Reps. 1995. Demand interprocedural program analysis using logic databases. In Applications of Logic Databases. Vol. 296.Google ScholarGoogle Scholar
  64. Thomas Reps. 1997. Program analysis via graph reachability. In Proceedings of the 1997 International Symposium on Logic Programming (ILPS’97). Google ScholarGoogle ScholarDigital LibraryDigital Library
  65. Thomas Reps, Susan Horwitz, and Mooly Sagiv. 1995. Precise interprocedural dataflow analysis via graph reachability. In Proceedings of the 1st Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL’95). Google ScholarGoogle ScholarDigital LibraryDigital Library
  66. Neil Robertson and P. D. Seymour. 1984. Graph minors. III. Planar tree-width. J. Combin. Theor. Ser. B (1984).Google ScholarGoogle Scholar
  67. Mooly Sagiv, Thomas Reps, and Susan Horwitz. 1996. Precise interprocedural dataflow analysis with applications to constant propagation. Theor. Comput. Sci. (1996). Google ScholarGoogle ScholarDigital LibraryDigital Library
  68. Dejvuth Suwimonteerabuth, Javier Esparza, and Stefan Schwoon. 2008. Symbolic context-bounded analysis of multithreaded java programs. In Proceedings of the Conference on Service Process Improvement Network (SPIN’08).Google ScholarGoogle ScholarDigital LibraryDigital Library
  69. Mikkel Thorup. 1998. All structured programs have small tree width and good register allocation. Information and Computation 142, 2 (1998), 159--181. Google ScholarGoogle ScholarDigital LibraryDigital Library
  70. Raja Vallée-Rai, Phong Co, Etienne Gagnon, Laurie Hendren, Patrick Lam, and Vijay Sundaresan. 1999. Soot - A java bytecode optimization framework. In Proceedings of the Centre for Advanced Studies Conference (CASCON’99). IBM Press.Google ScholarGoogle Scholar
  71. Thomas van Dijk, Jan-Pieter van den Heuvel, and Wouter Slob. 2006. Computing Treewidth with LibTW. Technical Report. University of Utrecht.Google ScholarGoogle Scholar
  72. A. Viterbi. 1967. Error bounds for convolutional codes and an asymptotically optimum decoding algorithm. IEEE Trans. Inf. Theor. 13, 2 (1967), 260--269. Google ScholarGoogle ScholarDigital LibraryDigital Library
  73. Stephen Warshall. 1962. A theorem on boolean matrices. J. ACM 9, 1 (1962), 11--12. Google ScholarGoogle ScholarDigital LibraryDigital Library
  74. Reinhard Wilhelm, Jakob Engblom, Andreas Ermedahl, Niklas Holsti, Stephan Thesing, David B. Whalley, Guillem Bernat, Christian Ferdinand, Reinhold Heckmann, Tulika Mitra, Frank Mueller, Isabelle Puaut, Peter P. Puschner, Jan Staschulat, and Per Stenström. 2008. The worst-case execution-time problem - Overview of methods and survey of tools. ACM Trans. Embedded Comput. Syst. 7, 3 (2008). Google ScholarGoogle ScholarDigital LibraryDigital Library
  75. Dacong Yan, Guoqing Xu, and Atanas Rountev. 2011. Demand-driven context-sensitive alias analysis for java. In Proceedings of the 2011 International Symposium on Software Testing and Analysis (ISSTA’11). Google ScholarGoogle ScholarDigital LibraryDigital Library
  76. Xin Yuan, Rajiv Gupta, and Rami Melhem. 1997. Demand-driven data flow analysis for communication optimization. Parallel Process. Lett. 7, 4 (1997), 359--370.Google ScholarGoogle ScholarCross RefCross Ref
  77. Frank Kenneth Zadeck. 1984. Incremental data flow analysis in a structured program editor. In Proceedings of the Special Interest Group on Programming Languages (SIGPLAN’84).Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Algorithms for Algebraic Path Properties in Concurrent Systems of Constant Treewidth Components

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in

      Full Access

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader

      HTML Format

      View this article in HTML Format .

      View HTML Format
      About Cookies On This Site

      We use cookies to ensure that we give you the best experience on our website.

      Learn more

      Got it!