4,125 research outputs found

    Scaling up algorithmic debugging with virtual execution trees

    Full text link
    Declarative debugging is a powerful debugging technique that has been adapted to practically all programming languages. However, the technique suffers from important scalability problems in both time and memory. With realistic programs the huge size of the execution tree handled makes the debugging session impractical and too slow to be productive. In this work, we present a new architecture for declarative debuggers in which we adapt the technique to work with incomplete execution trees. This allows us to avoid the problem of loading the whole execution tree in main memory and solve the memory scalability problems. We also provide the technique with the ability to debug execution trees that are only partially generated. This allows the programmer to start the debugging session even before the execution tree is computed. This solves the time scalability problems. We have implemented the technique and show its practicality with several experiments conducted with real applications.Insa Cabrera, D.; Silva Galiana, JF. (2011). Scaling up algorithmic debugging with virtual execution trees. En Logic-Based Program Synthesis and Transformation. Springer Verlag (Germany). 6564:149-163. doi:10.1007/978-3-642-20551-4_10S1491636564Av-Ron, E.: Top-Down Diagnosis of Prolog Programs. PhD thesis, Weizmanm Institute (1984)Binks, D.: Declarative Debugging in Gödel. PhD thesis, University of Bristol (1995)Caballero, R.: A Declarative Debugger of Incorrect Answers for Constraint Functional-Logic Programs. In: Proc. of the 2005 ACM SIGPLAN Workshop on Curry and Functional Logic Programming (WCFLP 2005), pp. 8–13. ACM Press, New York (2005)Caballero, R.: Algorithmic Debugging of Java Programs. In: Proc. of the 2006 Workshop on Functional Logic Programming (WFLP 2006). Electronic Notes in Theoretical Computer Science, pp. 63–76 (2006)Caballero, R., Martí-Oliet, N., Riesco, A., Verdejo, A.: A declarative debugger for maude functional modules. Electronic Notes Theoretical Computer Science 238(3), 63–81 (2009)Davie, T., Chitil, O.: Hat-delta: One Right Does Make a Wrong. In: Seventh Symposium on Trends in Functional Programming, TFP 2006 (April 2006)Girgis, H., Jayaraman, B.: JavaDD: a Declarative Debugger for Java. Technical Report 2006-07, University at Buffalo (March 2006)Kokai, G., Nilson, J., Niss, C.: GIDTS: A Graphical Programming Environment for Prolog. In: Workshop on Program Analysis For Software Tools and Engineering (PASTE 1999), pp. 95–104. ACM Press, New York (1999)MacLarty, I.: Practical Declarative Debugging of Mercury Programs. PhD thesis, Department of Computer Science and Software Engineering, The University of Melbourne (2005)Sun Microsystems. Java Platform Debugger Architecture - JPDA (2010), http://java.sun.com/javase/technologies/core/toolsapis/jpda/Nilsson, H., Fritzson, P.: Algorithmic Debugging for Lazy Functional Languages. Journal of Functional Programming 4(3), 337–370 (1994)Shapiro, E.Y.: Algorithmic Program Debugging. MIT Press, Cambridge (1982)Silva, J.: An Empirical Evaluation of Algorithmic Debugging Strategies. Technical Report DSIC-II/10/09, UPV (2009), http://www.dsic.upv.es/~jsilva/research.htm#techsSilva, J.: Algorithmic debugging strategies. In: Proc. of International Symposium on Logic-based Program Synthesis and Transformation (LOPSTR 2006), pp. 134–140 (2006)Silva, J.: A Comparative Study of Algorithmic Debugging Strategies. In: Puebla, G. (ed.) LOPSTR 2006. LNCS, vol. 4407, pp. 143–159. Springer, Heidelberg (2007

    A New Hybrid Debugging Architecture for Eclipse

    Full text link
    The final publication is available at Springer via http://dx.doi.org/10.1007/978-3-319-14125-1_11[EN] During many years, print debugging has been the most used method for debugging. Nowadays, however, industrial languages come with a trace debugger that allows programmers to trace computations step by step using breakpoints and state viewers. Almost all modern programming environments include a trace debugger that allows us to inspect the state of a computation in any given point. Nevertheless, this debugging method has been criticized for being completely manual and time-consuming. Other debugging techniques have appeared to solve some of the problems of Trace Debugging, but they suffer from other problems such as scalability. In this work we present a new hybrid debugging technique. It is based on a combination of Trace Debugging, Algorithmic Debugging and Omniscient Debugging to produce a synergy that exploits the best properties and strong points of each technique. We describe the architecture of our hybrid debugger and our implementation that has been integrated into Eclipse as a plugin.This work has been partially supported by the Spanish Ministerio de Economía y Competitividad (Secretaria de Estado de Investigación, Desarrollo e Innovación) under grant TIN2008-06622-003-02 and by the Generalitat Valenciana under grant PROMETEO/2011/052. David Insa was partially supported by the Spanish Ministerio de Educación under FPU grant AP2010-4415.González, J.; Insa Cabrera, D.; Silva Galiana, JF. (2013). A New Hybrid Debugging Architecture for Eclipse. En Logic-Based Program Synthesis and Transformation. Springer. 183-201. doi:10.1007/978-3-319-14125-1_11S183201Swi-prolog (1987). http://www.swi-prolog.org/Netbeans (1999). http://www.netbeans.org/Eclipse (2003). http://www.eclipse.org/Omnicore codeguide (2007). http://www.omnicore.com/en/codeguide.htmBorland JBuilder (2008). http://www.embarcadero.com/products/jbuilder/Sicstus prolog spider ide (2009). https://sicstus.sics.se/spider/Caballero, R.: A Declarative Debugger of Incorrect Answers for Constraint Functional-Logic Programs. In: Proceedings of the 2005 ACM-SIGPLAN Workshop on Curry and Functional Logic Programming (WCFLP 2005), pp. 8–13. ACM Press, New York (2005)Davie, T., Chitil, O.: Hat-delta: One Right Does Make a Wrong. In: Proceedings of the 7th Symposium on Trends in Functional Programming (TFP 2006) (April 2006)Gestwicki, P., Jayaraman, B.: JIVE: Java Interactive Visualization Environment. In: Companion to the 19th Annual ACM-SIGPLAN Conference on Object-Oriented Programming Systems, Languages, and Applications (OOPSLA 2004), pp. 226–228. ACM Press, New York (2004)Giammona, D.: ORACLE ADF - Putting It Together. Technical report, ADF Declarative Debugger Archives (November 2009)Girgis, H., Jayaraman, B.: JavaDD: a Declarative Debugger for Java. Technical report,University at Buffalo (2006)González, F., De Miguel, R., Serrano, S.: Depurador Declarativo de Programas Java. Technical report, Universidad Complutense de Madrid (2006). http://eprints.ucm.es/9114/Hermanns, C., Kuchen, H.: Hybrid Debugging of Java Programs. In: Escalona, M.J., Cordeiro, J., Shishkov, B. (eds.) ICSOFT 2011. CCIS, vol. 303, pp. 91–107. Springer, Heidelberg (2013)Montebello, M., Abela, C.: Design and Implementation of a Backward-In-Time. In: Chaudhri, A.B., Jeckle, M., Rahm, E., Unland, R. (eds.) NODe-WS 2002. LNCS, vol. 2593, pp. 46–58. Springer, Heidelberg (2003)Insa, D., Silva, J.: An Algorithmic Debugger for Java. In: Proceedings of the 26th IEEE International Conference on Software Maintenance (ICSM 2010), pp. 1–6 (2010)Insa, D., Silva, J.: Scaling Up Algorithmic Debugging with Virtual Execution Trees. In: Alpuente, M. (ed.) LOPSTR 2010. LNCS, vol. 6564, pp. 149–163. Springer, Heidelberg (2011)Insa, D., Silva, J.: loops2recursion Java Library (2013). http://www.dsic.upv.es/~jsilva/loops2recursion/Kouh, H.-J., Yoo, W.-H.: The Efficient Debugging System for Locating Logical Errors in Java Programs. In: Kumar, V., Gavrilova, M.L., Kenneth Tan, C.J., L’Ecuyer, P. (eds.) ICCSA 2003. LNCS, vol. 2667, pp. 684–693. Springer, Heidelberg (2003)B. Lewis. Debugging Backwards in Time. Available in the Computing Research Repository 2003, ( http://arxiv.org/abs/cs.SE/0310016 ), cs.SE/0310016Lienhard, A., Gîrba, T., Wang, J.: Practical Object-Oriented Back-in-Time Debugging. In: Vitek, J. (ed.) ECOOP 2008. LNCS, vol. 5142, pp. 592–615. Springer, Heidelberg (2008)S. Microsystems. Java Platform Debugger Architecture - JPDA (2010). http://java.sun.com/javase/technologies/core/toolsapis/jpda/Mirghasemi, S., Barton, J., Petitpierre, C.: Debugging by lastChange. Technical report (2011). http://people.epfl.ch/salman.mirghasemiNilsson, H.: Declarative Debugging for Lazy Functional Languages. PhD thesis, Linköping, Sweden (May 1998)Nilsson, H., Fritzson, P.: Algorithmic Debugging for Lazy Functional Languages. Journal of Functional Programming 4(3), 337–370 (1994)Pothier, G.: Towards Practical Omniscient Debugging. PhD thesis, University of Chile (June 2011)Shapiro, E.: Algorithmic Program Debugging. MIT Press (1982)Silva, J.: A Survey on Algorithmic Debugging Strategies. Advances in Engineering Software 42(11), 976–991 (2011

    Instrumenting self-modifying code

    Full text link
    Adding small code snippets at key points to existing code fragments is called instrumentation. It is an established technique to debug certain otherwise hard to solve faults, such as memory management issues and data races. Dynamic instrumentation can already be used to analyse code which is loaded or even generated at run time.With the advent of environments such as the Java Virtual Machine with optimizing Just-In-Time compilers, a new obstacle arises: self-modifying code. In order to instrument this kind of code correctly, one must be able to detect modifications and adapt the instrumentation code accordingly, preferably without incurring a high penalty speedwise. In this paper we propose an innovative technique that uses the hardware page protection mechanism of modern processors to detect such modifications. We also show how an instrumentor can adapt the instrumented version depending on the kind of modificiations as well as an experimental evaluation of said techniques.Comment: In M. Ronsse, K. De Bosschere (eds), proceedings of the Fifth International Workshop on Automated Debugging (AADEBUG 2003), September 2003, Ghent. cs.SE/030902

    Optimal divide and query

    Full text link
    Algorithmic debugging is a semi-automatic debugging technique that allows the programmer to precisely identify the location of bugs without the need to inspect the source code. The technique has been successfully adapted to all paradigms and mature implementations have been released for languages such as Haskell, Prolog or Java. During three decades, the algorithm introduced by Shapiro and later improved by Hirunkitti has been thought optimal. In this paper we first show that this algorithm is not optimal, and moreover, in some situations it is unable to find all possible solutions, thus it is incomplete. Then, we present a new version of the algorithm that is proven optimal, and we introduce some equations that allow the algorithm to identify all optimal solutions.This work has been partially supported by the Spanish Ministerio de Ciencia e Innovación under grant TIN2008-06622-C03-02 and by the Generalitat Valenciana under grant PROMETEO/2011/052.Insa Cabrera, D.; Silva Galiana, JF. (2011). Optimal divide and query. En Progress in Artificial Intelligence. Springer Verlag (Germany). 7026:224-238. https://doi.org/10.1007/978-3-642-24769-9_17S2242387026Braßel, B., Huch, F.: The Kiel Curry system KiCS. In: Proc of 17th International Conference on Applications of Declarative Programming and Knowledge Management (INAP 2007) and 21st Workshop on (Constraint) Logic Programming (WLP 2007), pp. 215–223. Technical Report 434, University of Würzburg (2007)Caballero, R.: A Declarative Debugger of Incorrect Answers for Constraint Functional-Logic Programs. In: Proc. of the 2005 ACM SIGPLAN Workshop on Curry and Functional Logic Programming (WCFLP 2005), pp. 8–13. ACM Press, New York (2005)Caballero, R.: Algorithmic Debugging of Java Programs. In: Proc. of the 2006 Workshop on Functional Logic Programming (WFLP 2006). Electronic Notes in Theoretical Computer Science, pp. 63–76 (2006)Caballero, R., Martí-Oliet, N., Riesco, A., Verdejo, A.: A Declarative Debugger for Maude Functional Modules. Electronic Notes in Theoretical Computer Science 238, 63–81 (2009)Davie, T., Chitil, O.: Hat-delta: One Right Does Make a Wrong. In: Seventh Symposium on Trends in Functional Programming, TFP 2006 (April 2006)Fritzson, P., Shahmehri, N., Kamkar, M., Gyimóthy, T.: Generalized Algorithmic Debugging and Testing. LOPLAS 1(4), 303–322 (1992)Hirunkitti, V., Hogger, C.J.: A Generalised Query Minimisation for Program Debugging. In: Adsul, B. (ed.) AADEBUG 1993. LNCS, vol. 749, pp. 153–170. Springer, Heidelberg (1993)Insa, D., Silva, J.: An Algorithmic Debugger for Java. In: Proc. of the 26th IEEE International Conference on Software Maintenance, pp. 1–6 (2010)Insa, D., Silva, J.: Optimal Divide and Query (extended version). Available in the Computing Research Repository (July 2011), http://arxiv.org/abs/1107.0350Lloyd, J.W.: Declarative Error Diagnosis. New Gen. Comput. 5(2), 133–154 (1987)Luo, Y., Chitil, O.: Algorithmic debugging and trusted functions. Technical report 10-07, University of Kent, Computing Laboratory, UK (August 2007)Lux, W.: Münster Curry User’s Guide (release 0.9.10 of May 10, 2006), http://danae.uni-muenster.de/~lux/curry/user.pdfMacLarty, I.: Practical Declarative Debugging of Mercury Programs. PhD thesis, Department of Computer Science and Software Engineering, The University of Melbourne (2005)Naish, L., Dart, P.W., Zobel, J.: The NU-Prolog Debugging Environment. In: Porto, A. (ed.) Proceedings of the Sixth International Conference on Logic Programming, Lisboa, Portugal, pp. 521–536 (June 1989)Nilsson, H.: Declarative Debugging for Lazy Functional Languages. PhD thesis, Linköping, Sweden (May 1998)Pope, B.: A Declarative Debugger for Haskell. PhD thesis, The University of Melbourne, Australia (2006)Shapiro, E.: Algorithmic Program Debugging. MIT Press (1982)Silva, J.: A Comparative Study of Algorithmic Debugging Strategies. In: Puebla, G. (ed.) LOPSTR 2006. LNCS, vol. 4407, pp. 143–159. Springer, Heidelberg (2007)Silva, J.: An Empirical Evaluation of Algorithmic Debugging Strategies. Technical Report DSIC-II/10/09, UPV (2009), http://www.dsic.upv.es/~jsilva/research.htm#tech

    Speeding Up Algorithmic Debugging Using Balanced Execution Trees

    Full text link
    Algorithmic debugging is a debugging technique that uses a data structure representing all computations performed during the execution of a program. This data structure is the so-called Execution Tree and it strongly influences the performance of the technique. In this work we present a transformation that automatically improves the structure of the execution trees by collapsing and projecting some strategic nodes. This improvement in the structure implies a better behavior and performance of the standard algorithms that traverse it. We prove that the transformation is sound in the sense that all the bugs found after the transformation are real bugs; and if at least one bug is detectable before the transformation, then at least one bug will also be detectable after the transformation. We have implemented the technique and performed several experiments with real applications. The experimental results confirm the usefulness of the technique.This work has been partially supported by the Spanish Ministerio de Ciencia e Innovación under grants TIN2008-06622-C03-02 and TIN2012-39391-004-04, by the Generalitat Valenciana under grant ACOMP/2009/017, and by the Comunidad de Madrid under grant S2009/TIC-1465. David Insa has been partially supported by the Spanish Ministerio de Educación under grant AP2010-4415.Silva, J.; Insa Cabrera, D.; Riesco, A. (2013). Speeding Up Algorithmic Debugging Using Balanced Execution Trees. En Tests and Proofs. Springer. 133-151. https://doi.org/10.1007/978-3-642-38916-0_8S133151Binks, D.: Declarative Debugging in Gödel. PhD thesis, University of Bristol (1995)Caballero, R.: A Declarative Debugger of Incorrect Answers for Constraint Functional-Logic Programs. In: Proc. of the 2005 ACM SIGPLAN Workshop on Curry and Functional Logic Programming, WCFLP 2005, pp. 8–13. ACM Press (2005)Caballero, R., Hermanns, C., Kuchen, H.: Algorithmic debugging of Java programs. In: López-Fraguas, F.J. (ed.) Proc. of the 15th Workshop on Functional and (Constraint) Logic Programming, WFLP 2006, Madrid, Spain. ENTCS, vol. 177, pp. 75–89. Elsevier (2007)Calejo, M.: A Framework for Declarative Prolog Debugging. PhD thesis, New University of Lisbon (1992)Davie, T., Chitil, O.: Hat-delta: One Right Does Make a Wrong. In: Seventh Symposium on Trends in Functional Programming, TFP 2006 (April 2006)Hirunkitti, V., Hogger, C.J.: A Generalised Query Minimisation for Program Debugging. In: Fritzson, P.A. (ed.) AADEBUG 1993. LNCS, vol. 749, pp. 153–170. Springer, Heidelberg (1993)Insa, D., Silva, J.: Scaling up algorithmic debugging with virtual execution trees. In: Alpuente, M. (ed.) LOPSTR 2010. LNCS, vol. 6564, pp. 149–163. Springer, Heidelberg (2011)Insa, D., Silva, J., Riesco, A.: Speeding up algorithmic debugging using balanced execution trees—detailed results. Technical Report 04/13, Departamento de Sistemas Informáticos y Computación (April 2013)Kokai, G., Nilson, J., Niss, C.: GIDTS: A Graphical Programming Environment for Prolog. In: Workshop on Program Analysis For Software Tools and Engineering, PASTE 1999, pp. 95–104. ACM Press (1999)MacLarty, I.: Practical Declarative Debugging of Mercury Programs. PhD thesis, Department of Computer Science and Software Engineering, University of Melbourne (2005)Maeji, M., Kanamori, T.: Top-Down Zooming Diagnosis of Logic Programs. Technical Report TR-290, Japan (1987)Nilsson, H.: Declarative Debugging for Lazy Functional Languages. PhD thesis, Linköping, Sweden (May 1998)Nilsson, H., Fritzson, P.: Algorithmic Debugging for Lazy Functional Languages. Journal of Functional Programming 4(3), 337–370 (1994)Shapiro, E.Y.: Algorithmic Program Debugging. MIT Press (1982)Silva, J.: A Survey on Algorithmic Debugging Strategies. Advances in Engineering Software 42(11), 976–991 (2011
    • …
    corecore