Trace Size vs. Parallelism in Trace-and-Replay Debugging of Shared-Memory Programs

Execution replay is a debugging strategy in which a program is run over and over on an input that manifests bugs. For explicitly parallel shared-memory programs, execution replay requires support of special tools --- because these programs can be nondeterministic, their executions can differ from run to run on the same input. For such programs, executions must be traced before they can be replayed for debugging. We present improvements over our past work on an adaptive tracing strategy that records only a fraction of the execution''s shared-memory references. Our past approach makes run-time-tracing decisions by detecting and tracing exactly the nontransitive dynamic data dependences among the execution''s shared data. Tracing the nontransitive dependences provides sufficient information for a replay. In this paper we show that tracing exactly these dependences is not necessary. Instead, we present two algorithms that introduce and trace artificial dependences among some events that are actually independent. These artificial dependences reduce trace size, but introduce additional event orderings that can reduce the amount of parallelism achievable during replay. We present one algorithm that always adds dependences guaranteed not to be on the critical path and thus do not slow replay. Another algorithm adds as many dependences as possible, slowing replay but reducing trace size further. Experiments show that we can improve the already high trace reduction of our past technique by up to two more orders of magnitude, without slowing replay. Our new techniques usually trace only 0.00025 - 0.2 reduction over past techniques which trace every access.

[1]  Stephen K. Wismath,et al.  Characterizing bar line-of-sight graphs , 1985, SCG '85.

[2]  Leonidas J. Guibas,et al.  Visibility and intersection problems in plane geometry , 1989, Discret. Comput. Geom..

[3]  Leonidas J. Guibas,et al.  Optimal Point Location in a Monotone Subdivision , 1986, SIAM J. Comput..

[4]  Thomas J. LeBlanc,et al.  Debugging Parallel Programs with Instant Replay , 1987, IEEE Transactions on Computers.

[5]  Roberto Tamassia,et al.  An Incremental Reconstruction Method for Dynamic Planar Point Location , 1991, Inf. Process. Lett..

[6]  V. T. Rajan,et al.  NC-Algorithms for Minimum Link Path and Related Problems , 1995, J. Algorithms.

[7]  Kurt Mehlhorn,et al.  Dynamic point location in general subdivisions , 1992, SODA '92.

[8]  D. T. Lee,et al.  Euclidean shortest paths in the presence of rectilinear barriers , 1984, Networks.

[9]  Edith Schonberg,et al.  An empirical comparison of monitoring algorithms for access anomaly detection , 2011, PPOPP '90.

[10]  Colin J. Fidge,et al.  Partial orders for parallel debugging , 1988, PADD '88.

[11]  Michael T. Goodrich,et al.  Topology B-Trees and Their Applications , 1995, WADS.

[12]  Francis Y. L. Chin,et al.  Optimal Algorithms for the Intersection and the Minimum Distance Problems Between Planar Polygons , 1983, IEEE Transactions on Computers.

[13]  Norishige Chiba,et al.  A Linear Algorithm for Embedding Planar Graphs Using PQ-Trees , 1985, J. Comput. Syst. Sci..

[14]  David G. Kirkpatrick,et al.  Determining the Separation of Preprocessed Polyhedra - A Unified Approach , 1990, ICALP.

[15]  Jyh-Jong Tsay,et al.  External-memory computational geometry , 1993, Proceedings of 1993 IEEE 34th Annual Foundations of Computer Science.

[16]  Robert E. Tarjan,et al.  Rectilinear planar layouts and bipolar orientations of planar graphs , 1986, Discret. Comput. Geom..

[17]  Ioannis G. Tollis,et al.  Area requirement and symmetry display of planar upward drawings , 1992, Discret. Comput. Geom..

[18]  A LintonMark,et al.  Supporting reverse execution for parallel programs , 1988 .

[19]  James A. Storer,et al.  On minimal-node-cost planar embeddings , 1984, Networks.

[20]  Jeffrey Scott Vitter,et al.  Deterministic distribution sort in shared and distributed memory multiprocessors , 1993, SPAA '93.

[21]  David G. Kirkpatrick,et al.  Optimal Search in Planar Subdivisions , 1983, SIAM J. Comput..

[22]  Mark A. Linton,et al.  Supporting reverse execution for parallel programs , 1988, PADD '88.

[23]  Mark de Berg,et al.  Finding Shortest Paths in the Presence of Orthogonal Obstacles Using a Combined L1 and Link Metric , 1990, SWAT.

[24]  Roberto Tamassia,et al.  Algorithms for Plane Representations of Acyclic Digraphs , 1988, Theor. Comput. Sci..

[25]  Y ChinFrancis,et al.  Efficient parallel algorithms for some graph problems , 1982 .

[26]  Franco P. Preparata,et al.  A New Approach to Planar Point Location , 1981, SIAM J. Comput..

[27]  R. H. B. Netzer,et al.  Adaptive message logging for incremental replay of message-passing programs , 1993, Supercomputing '93.

[28]  James A. Storer,et al.  Minimizing turns for discrete movement in the interior of a polygon , 1987, IEEE J. Robotics Autom..

[29]  Robert E. Tarjan,et al.  A data structure for dynamic trees , 1981, STOC '81.

[30]  Barton P. Miller,et al.  Optimal tracing and replay for debugging message-passing parallel programs , 1992, Supercomputing '92.

[31]  Yi-Jen Chiang,et al.  Experiments on the Practical I/O Efficiency of Geometric Algorithms: Distribution Sweep vs. Plane Sweep , 1995, WADS.

[32]  D. T. Lee,et al.  Location of a point in a planar subdivision and its applications , 1976, STOC '76.

[33]  Roberto Tamassia,et al.  Dynamic Planar Point Location with Optimal Query Time , 1990, Theor. Comput. Sci..

[34]  Sridhar Ramaswamy,et al.  OODB indexing by class-division , 1995, SIGMOD '95.

[35]  Roberto Tamassia,et al.  Incremental planarity testing , 1989, 30th Annual Symposium on Foundations of Computer Science.

[36]  Takao Asano,et al.  A new point-location algorithm and its practical efficiency: comparison with existing algorithms , 1984, TOGS.

[37]  Robert E. Tarjan,et al.  Biased Search Trees , 1985, SIAM J. Comput..

[38]  Siu-Wing Cheng,et al.  Space-efficient ray-shooting and intersection searching: algorithms, dynamization, and applications , 1991, SODA '91.

[39]  Andrzej Lingas,et al.  AnO(n logn) algorithm for computing the link center of a simple polygon , 1992, Discret. Comput. Geom..

[40]  Greg N. Frederickson,et al.  A data structure for dynamically maintaining rooted trees , 1997, SODA '93.

[41]  Douglas Comer,et al.  Ubiquitous B-Tree , 1979, CSUR.

[42]  Richard H. Carver,et al.  Reproducible Testing of Concurrent Programs Based on Shared Variables , 1986, ICDCS.

[43]  Michael Ian Shamos,et al.  Computational geometry: an introduction , 1985 .

[44]  Roberto Tamassia,et al.  A unified approach to dynamic point location, ray shooting, and shortest paths in planar maps , 1996, SODA '93.

[45]  Michael T. Goodrich,et al.  Dynamic ray shooting and shortest paths via balanced geodesic triangulations , 1993, SCG '93.

[46]  Alberto Marchetti-Spaccamela,et al.  Memory Paging for Connectivity and Path Problems in Graphs , 1993, J. Graph Algorithms Appl..

[47]  Micha Sharir,et al.  Computing the link center of a simple polygon , 1987, SCG '87.

[48]  Jian Xu,et al.  Adaptive independent checkpointing for reducing rollback propagation , 1993, Proceedings of 1993 5th IEEE Symposium on Parallel and Distributed Processing.

[49]  Yan Ke,et al.  An efficient algorithm for link-distance problems , 1989, SCG '89.

[50]  Herbert Edelsbrunner,et al.  Computing the Extreme Distances Between Two Convex Polygons , 1985, J. Algorithms.

[51]  Mariette Yvinec,et al.  Computation of the axial view of a set of isothetic parallelepipeds , 1990, TOGS.

[52]  Bernard Chazelle,et al.  Intersection of convex objects in two and three dimensions , 1987, JACM.

[53]  Subir Kumar Ghosh Computing the Visibility Polygon from a Convex Set and Related Problems , 1991, J. Algorithms.

[54]  Israel Koren,et al.  Floorplans, planar graphs and layouts , 1988 .

[55]  Jon Louis Bentley,et al.  Experiments on traveling salesman heuristics , 1990, SODA '90.

[56]  Sridhar Ramaswamy,et al.  Path Caching: A Technique for Optimal External Searching , 1994, PODS 1994.

[57]  David R. Karger,et al.  Global min-cuts in RNC, and other ramifications of a simple min-out algorithm , 1993, SODA '93.

[58]  Anoop Gupta,et al.  SPLASH: Stanford parallel applications for shared-memory , 1992, CARN.

[59]  Kurt Mehlhorn,et al.  Dynamization of geometric data structures , 1985, SCG '85.

[60]  Roberto Tamassia,et al.  Fully Dynamic Point Location in a Monotone Subdivision , 1989, SIAM J. Comput..

[61]  Ioannis G. Tollis,et al.  Representations of Graphs on a Cylinder , 1991, SIAM J. Discret. Math..

[62]  D. E. Vengro A transparent parallel I/O environment , 1994 .

[63]  Bernard Chazelle Triangulating a simple polygon in linear time , 1991, Discret. Comput. Geom..

[64]  Thomas H. Cormen,et al.  Asymptotically tight bounds for performing BMMC permutations on parallel disk systems , 1993, SPAA '93.

[65]  Roberto Tamassia,et al.  A unified approach to visibility representations of planar graphs , 1986, Discret. Comput. Geom..

[66]  Roberto Tamassia,et al.  A Dynamic Data Structure for Planar Graph Embedding (Extended Abstract) , 1988, ICALP.

[67]  Edward F. Grove,et al.  External-memory graph algorithms , 1995, SODA '95.

[68]  Richard J. Lipton,et al.  Multidimensional Searching Problems , 1976, SIAM J. Comput..

[69]  Robert E. Tarjan,et al.  Planar point location using persistent search trees , 1986, CACM.

[70]  Barton P. Miller,et al.  Improving the accuracy of data race detection , 1991, PPOPP '91.

[71]  S. Suri Minimum link paths in polygons and related problems , 1987 .

[72]  Subhash Suri,et al.  On some link distance problems in a simple polygon , 1990, IEEE Trans. Robotics Autom..

[73]  John H. Reif,et al.  An efficient output-sensitive hidden surface removal algorithm and its parallelization , 1988, SCG '88.

[74]  Robert E. Tarjan,et al.  Finding Biconnected Components and Computing Tree Functions in Logarithmic Parallel Time (Extended Summary) , 1984, FOCS.

[75]  Anil Maheshwari,et al.  Parallel Algorithms for All Minimum Link Paths and Link Center Problems , 1992, SWAT.

[76]  Thomas H. Cormen,et al.  Virtual memory for data-parallel computing , 1993 .

[77]  Alok Aggarwal,et al.  The input/output complexity of sorting and related problems , 1988, CACM.

[78]  Robert H. B. Netzer Optimal tracing and replay for debugging shared-memory parallel programs , 1993, PADD '93.

[79]  Jörg-Rüdiger Sack,et al.  An O(n log n) Algorithm for Computing a Link Center in a Simple Polygon , 1989, STACS.

[80]  David G. Kirkpatrick,et al.  Efficient computation of continuous skeletons , 1979, 20th Annual Symposium on Foundations of Computer Science (sfcs 1979).

[81]  Claire Mathieu,et al.  The Maximum Size of Dynamic Data Structures , 1991, SIAM J. Comput..

[82]  Thomas H. Cormen Fast Permuting on Disk Arrays , 1993, J. Parallel Distributed Comput..

[83]  Bengt J. Nilsson,et al.  Computing the Rectilinear Link Diameter of a Polygon , 1991, Workshop on Computational Geometry.

[84]  Mark de Berg,et al.  On Rectilinear Link Distance , 1991, Comput. Geom..

[85]  Uzi Vishkin,et al.  Recursive Star-Tree Parallel Data Structure , 1993, SIAM J. Comput..

[86]  Esther M. Arkin,et al.  Computing a shortest k-link path in a polygon , 1992, Proceedings., 33rd Annual Symposium on Foundations of Computer Science.

[87]  Roberto Tamassia,et al.  On Embedding a Graph in the Grid with the Minimum Number of Bends , 1987, SIAM J. Comput..

[88]  Nancy M. Amato An Optimal Algorithm for Finding the Separation of Simple Polygons , 1993, WADS.

[89]  Roberto Tamassia,et al.  Dynamization of the trapezoid method for planar point location in monotone subdivisions , 1992, Int. J. Comput. Geom. Appl..

[90]  Uzi Vishkin,et al.  Parallel Ear Decomposition Search (EDS) and st-Numbering in Graphs , 1986, Theor. Comput. Sci..

[91]  Mark H. Overmars,et al.  Range searching in a set of line segments , 1985, SCG '85.

[92]  Jon Louis Bentley,et al.  K-d trees for semidynamic point sets , 1990, SCG '90.

[93]  Jeffrey Scott Vitter,et al.  Paradigms for optimal sorting with multiple disks , 1993, [1993] Proceedings of the Twenty-sixth Hawaii International Conference on System Sciences.

[94]  Jeffrey Scott Vitter,et al.  Parallel Transitive Closure and Point Location in Planar Structures , 1991, SIAM J. Comput..

[95]  Binhai Zhu,et al.  Further Computational Geometry in Secondary Memory , 1994, ISAAC.

[96]  Andrzej Lingas,et al.  Parallel algorithms for rectilinear link distance problems , 1993, [1993] Proceedings Seventh International Parallel Processing Symposium.

[97]  Jon Jouis Bentley,et al.  Fast Algorithms for Geometric Traveling Salesman Problems , 1992, INFORMS J. Comput..

[98]  Esther M. Arkin,et al.  Optimal link path queries in a simple polygon , 1992, SODA '92.

[99]  S. Suri A linear time algorithm with minimum link paths inside a simple polygon , 1986 .

[100]  Gary L. Miller,et al.  A Simple Randomized Parallel Algorithm for List-Ranking , 1990, Inf. Process. Lett..

[101]  Leonidas J. Guibas,et al.  Optimal shortest path queries in a simple polygon , 1987, SCG '87.

[102]  Joseph S. B. Mitchell,et al.  Minimum-link paths among obstacles in the plane , 1990, SCG '90.

[103]  Sridhar Ramaswamy,et al.  The P-range tree: a new data structure for range searching in secondary memory , 1995, SODA '95.

[104]  Richard H. Carver,et al.  Debugging Concurrent Ada Programs by Deterministic Execution , 1991, IEEE Trans. Software Eng..

[105]  Philip N. Klein,et al.  A randomized linear-time algorithm for finding minimum spanning trees , 1994, STOC '94.