This Article 
 Bibliographic References 
 Add to: 
Solving Computation Slicing Using Predicate Detection
December 2007 (vol. 18 no. 12)
pp. 1700-1713
Given a distributed computation and a global predicate, predicate detection involves determining whether there exists at least one consistent cut (or global state) of the computation that satisfies the predicate. On the other hand, computation slicing is concerned with computing the smallest subcomputation--with the least number of consistent cuts--that contains all consistent cuts of the computation satisfying the predicate. In this paper, we investigate the relationship between predicate detection and computation slicing and show that the two problems are equivalent. Specifically, given an algorithm to detect a predicate b in a computation C, we derive an algorithm to compute the slice of C with respect to b. The time-complexity of the (derived) slicing algorithm is O(n|E|T), where n is the number of processes and E is the set of events, and O(T) is the time-complexity of the detection algorithm. We discuss how the "equivalence" result of this paper can be utilized to derive a faster algorithm for solving the general predicate detection problem in many cases.Slicing algorithms described in our earlier papers are all off-line in nature. In this paper, we also present two on-line algorithms for computing the slice. The first algorithm can be used to compute the slice for a general predicate. Its amortized time-complexity is O(n(c + n)T), where c is the average concurrency in the computation and O(T) is the time-complexity of the detection algorithm. The second algorithm can be used to compute the slice for a regular predicate. Its amortized time-complexity is only O(n^2).

[1] N. Mittal, A. Sen, V.K. Garg, and R. Atreya, “Finding Satisfying Global States: All for One and One for All,” Proc. 18th Int'l Parallel and Distributed Processing Symp. (IPDPS '04), Apr. 2004.
[2] S.D. Stoller and F. Schneider, “Faster Possibility Detection by Combining Two Approaches,” Proc. Ninth Int'l Workshop Distributed Algorithms (WDAG '95), pp. 318-332, Sept. 1995.
[3] V.K. Garg, Elements of Distributed Computing. John Wiley & Sons, 2002.
[4] N. Mittal and V.K. Garg, “On Detecting Global Predicates in Distributed Computations,” Proc. 21st IEEE Int'l Conf. Distributed Computing Systems (ICDCS '01), pp. 3-10, Apr. 2001.
[5] C. Chase and V.K. Garg, “On Techniques and Their Limitations for the Global Predicate Detection Problem,” Proc. Ninth Int'l Workshop Distributed Algorithms (WDAG '95), pp. 303-317, Sept. 1995.
[6] N. Mittal and V.K. Garg, “Techniques and Applications of Computation Slicing,” Distributed Computing, vol. 17, no. 3, pp.251-277, Feb. 2005.
[7] M. Weiser, “Programmers Use Slices When Debugging,” Comm. ACM, vol. 25, no. 7, pp. 446-452, 1982.
[8] G. Venkatesh, “Experimental Results from Dynamic Slicing of C Programs,” ACM Trans. Programming Languages and Systems, vol. 17, no. 2, pp. 197-216, 1995.
[9] B. Korel and J. Rilling, “Application of Dynamic Slicing in Program Debugging,” Proc. Third Int'l Workshop Automatic Debugging (AADEBUG '97), M. Kamkar, ed., pp. 43-57, May 1997.
[10] J. Cheng, “Slicing Concurrent Programs—A Graph-Theoretical Approach,” Proc. First Int'l Workshop Automated and Algorithmic Debugging (AADEBUG '93), pp. 223-240, 1993.
[11] H.F. Li, J. Rilling, and D. Goswami, “Granularity-Driven Dynamic Predicate Slicing Algorithms for Message Passing Systems,” Automated Software Eng., vol. 11, no. 1, pp. 63-89, Jan. 2004.
[12] S.A. Cook, “The Complexity of Theorem Proving Procedures,” Proc. Third Ann. ACM Symp. Theory of Computing (STOC '71), pp.151-158, 1971.
[13] A. Sen and V.K. Garg, “Formal Verification of Simulation Traces Using Computation Slicing,” IEEE Trans. Computers, vol. 56, no. 4, pp. 511-527, Apr. 2007.
[14] S.D. Stoller, L. Unnikrishnan, and Y.A. Liu, “Efficient Detection of Global Properties in Distributed Systems Using Partial-Order Methods,” Proc. 12th Int'l Conf. Computer Aided Verification (CAV'00), pp. 264-279, July 2000.
[15] S. Alagar and S. Venkatesan, “Techniques to Tackle State Explosion in Global Predicate Detection,” IEEE Trans. Software Eng., vol. 27, no. 8, pp. 704-714, Aug. 2001.
[16] A. Sen and V.K. Garg, “Partial Order Trace Analyzer (POTA) for Distributed Programs,” Proc. Third Workshop Runtime Verification (RV '03), vol. 89, 2003.
[17] A.D. Kshemkalyani, “A Framework for Viewing Atomic Events in Distributed Computations,” Theoretical Computer Science, vol. 196, nos. 1-2, pp. 45-70, Apr. 1998.
[18] L. Lamport, “Time, Clocks and the Ordering of Events in a Distributed System,” Comm. ACM, vol. 21, no. 7, pp. 558-565, July 1978.
[19] K.M. Chandy and L. Lamport, “Distributed Snapshots: Determining Global States of Distributed Systems,” ACM Trans. Computer Systems, vol. 3, no. 1, pp. 63-75, Feb. 1985.
[20] B. Charron-Bost, C. Delporte-Gallet, and H. Fauconnier, “Local and Temporal Predicates in Distributed Systems,” ACM Trans. Programming Languages and Systems, vol. 17, no. 1, pp. 157-179, 1995.
[21] A. Sen and V.K. Garg, “Detecting Temporal Logic Predicates in the Happened-Before Model,” Proc. 16th Int'l Parallel and Distributed Processing Symp. (IPDPS '02), Apr. 2002.
[22] F. Mattern, “Virtual Time and Global States of Distributed Systems,” Parallel and Distributed Algorithms: Proc. Third Int'l Workshop Distributed Algorithms (WDAG '89), pp. 215-226, 1989.
[23] C.J. Fidge, “Logical Time in Distributed Computing Systems,” Computer, vol. 24, no. 8, pp. 28-33, Aug. 1991.
[24] R. Cooper and K. Marzullo, “Consistent Detection of Global Predicates,” Proc. ACM/ONR Workshop Parallel and Distributed Debugging (WPDD '91), pp. 163-173, 1991.
[25] A. Sen and V.K. Garg, “On Checking Whether a Predicate Definitely Holds,” Proc. Third Workshop Formal Approaches to Testing of Software (FATES '03), pp. 15-29, July 2003.
[26] A. Tarafdar and V.K. Garg, “Predicate Control: Synchronization in Distributed Computations with Look Ahead,” J. Parallel and Distributed Computing, vol. 64, no. 2, pp. 219-237, Feb. 2004.

Index Terms:
program trace analysis, predicate detection, computation slicing, testing and debugging
Neeraj Mittal, Alper Sen, Vijay K. Garg, "Solving Computation Slicing Using Predicate Detection," IEEE Transactions on Parallel and Distributed Systems, vol. 18, no. 12, pp. 1700-1713, Dec. 2007, doi:10.1109/TPDS.2007.1077
Usage of this product signifies your acceptance of the Terms of Use.