Marcel Hlopko, Jan Kurs, J. Vraný, Claus Gittinger
After decades of development in programming languages and programming environments, Smalltalk is still one of few environments that provide advanced features and is still widely used in the industry. However, as Java became prevalent, the ability to call Java code from Smalltalk and vice versa becomes important. Traditional approaches to integrate the Java and Smalltalk languages are through low-level communication between separate Java and Smalltalk virtual machines. We are not aware of any attempt to execute and integrate the Java language directly in the Smalltalk environment. A direct integration allows for very tight and almost seamless integration of the languages and their objects within a single environment. Yet integration and language interoperability impose challenging issues related to method naming conventions, method overloading, exception handling and thread-locking mechanisms. In this paper we describe ways to overcome these challenges and to integrate Java into the Smalltalk environment. Using techniques described in this paper, the programmer can call Java code from Smalltalk using standard Smalltalk idioms while the semantics of each language remains preserved. We present STX:LIBJAVA --- an implementation of Java virtual machine within Smalltalk/X --- as a validation of our approach.
{"title":"On the integration of Smalltalk and Java: practical experience with STX:LIBJAVA","authors":"Marcel Hlopko, Jan Kurs, J. Vraný, Claus Gittinger","doi":"10.1145/2448963.2448968","DOIUrl":"https://doi.org/10.1145/2448963.2448968","url":null,"abstract":"After decades of development in programming languages and programming environments, Smalltalk is still one of few environments that provide advanced features and is still widely used in the industry. However, as Java became prevalent, the ability to call Java code from Smalltalk and vice versa becomes important. Traditional approaches to integrate the Java and Smalltalk languages are through low-level communication between separate Java and Smalltalk virtual machines. We are not aware of any attempt to execute and integrate the Java language directly in the Smalltalk environment. A direct integration allows for very tight and almost seamless integration of the languages and their objects within a single environment. Yet integration and language interoperability impose challenging issues related to method naming conventions, method overloading, exception handling and thread-locking mechanisms.\u0000 In this paper we describe ways to overcome these challenges and to integrate Java into the Smalltalk environment. Using techniques described in this paper, the programmer can call Java code from Smalltalk using standard Smalltalk idioms while the semantics of each language remains preserved. We present STX:LIBJAVA --- an implementation of Java virtual machine within Smalltalk/X --- as a validation of our approach.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"55 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2012-08-28","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"129306836","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Refactoring is a crucial activity in agile software development. As a consequence, automated tools are expected to support refactoring, both for reducing the developer's effort as well as for avoiding errors due to manual changes. In this context, the chosen programming language has a major impact on the level of support that an automated refactoring tool can offer. One important aspect of a programming language concerning the automation of refactoring is the type system. While a static type system, present in languages such as Java, provides information about dependencies in the program, the dynamic type system of the Smalltalk programming language offers little information that can be used by automated refactoring tools. This paper focuses on the challenges in the context of refactoring raised by the dynamic type system of Smalltalk. It highlights the problems caused by the absence of static type information and proposes the use of static code analysis for performing type inference to gather information about the dependencies in the program's source code. It explains the mechanism of the static code analysis using sample code and presents a prototype of an enhanced refactoring tool, which uses the structural information extracted through static code analysis. Empirical samples build the base for evaluating the effectiveness of the approach.
{"title":"Refactoring support for Smalltalk using static type inference","authors":"Martin Unterholzner","doi":"10.1145/2448963.2448964","DOIUrl":"https://doi.org/10.1145/2448963.2448964","url":null,"abstract":"Refactoring is a crucial activity in agile software development. As a consequence, automated tools are expected to support refactoring, both for reducing the developer's effort as well as for avoiding errors due to manual changes. In this context, the chosen programming language has a major impact on the level of support that an automated refactoring tool can offer. One important aspect of a programming language concerning the automation of refactoring is the type system. While a static type system, present in languages such as Java, provides information about dependencies in the program, the dynamic type system of the Smalltalk programming language offers little information that can be used by automated refactoring tools.\u0000 This paper focuses on the challenges in the context of refactoring raised by the dynamic type system of Smalltalk. It highlights the problems caused by the absence of static type information and proposes the use of static code analysis for performing type inference to gather information about the dependencies in the program's source code. It explains the mechanism of the static code analysis using sample code and presents a prototype of an enhanced refactoring tool, which uses the structural information extracted through static code analysis. Empirical samples build the base for evaluating the effectiveness of the approach.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"90 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2012-08-28","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"134344498","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Continuous software change may inadvertently introduce a drop in performance at runtime. The longer the performance loss remains undiscovered, the harder it is to address. Current profilers do not efficiently support performance comparison across multiple software versions. As a consequence, identifying the cause of a slow execution caused by a software change is often carried out in an ad-hoc fashion. We propose multidimensional profiling as a way to repeatedly profile a software execution by varying some variables of the execution context. Having explicit execution variation points is key to understanding precisely how a performance aspect evolves along with the version history of the software. We present the key ingredients to make multidimensional profiling effective, and sketch the design of Rizel, an implementation in the Pharo programming language.
{"title":"Tracking down software changes responsible for performance loss","authors":"Juan Pablo Sandoval Alcocer","doi":"10.1145/2448963.2448966","DOIUrl":"https://doi.org/10.1145/2448963.2448966","url":null,"abstract":"Continuous software change may inadvertently introduce a drop in performance at runtime. The longer the performance loss remains undiscovered, the harder it is to address. Current profilers do not efficiently support performance comparison across multiple software versions. As a consequence, identifying the cause of a slow execution caused by a software change is often carried out in an ad-hoc fashion.\u0000 We propose multidimensional profiling as a way to repeatedly profile a software execution by varying some variables of the execution context. Having explicit execution variation points is key to understanding precisely how a performance aspect evolves along with the version history of the software. We present the key ingredients to make multidimensional profiling effective, and sketch the design of Rizel, an implementation in the Pharo programming language.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"15 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2012-08-28","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"131050319","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Implementing UIs is often a tedious task. To address this, UI Builders have been proposed to support the description of widgets, their location, and their logic. A missing aspect of UI Builders is however the ability to reuse and compose widget logic. In our experience, this leads to a significant amount of duplication in UI code. To address this issue, we built Spec: a UIBuilder for Pharo with a focus on reuse. With Spec, widget properties are defined declaratively and attached to specific classes known as composable classes. A composable class defines its own widget description as well as the model-widget bridge and widget interaction logic. This paper presents Spec, showing how it enables seamless reuse of widgets and how these can be customized. After presenting Spec and its implementation, we discuss how its use in Pharo 2.0 has cut in half the amount of lines of code of six of its tools, mostly through reuse. This shows that Spec meets its goals of allowing reuse and composition of widget logic.
{"title":"Spec: a framework for the specification and reuse of UIs and their models","authors":"Benjamin Van Ryseghem, Stéphane Ducasse, J. Fabry","doi":"10.1145/2448963.2448965","DOIUrl":"https://doi.org/10.1145/2448963.2448965","url":null,"abstract":"Implementing UIs is often a tedious task. To address this, UI Builders have been proposed to support the description of widgets, their location, and their logic. A missing aspect of UI Builders is however the ability to reuse and compose widget logic. In our experience, this leads to a significant amount of duplication in UI code. To address this issue, we built Spec: a UIBuilder for Pharo with a focus on reuse. With Spec, widget properties are defined declaratively and attached to specific classes known as composable classes. A composable class defines its own widget description as well as the model-widget bridge and widget interaction logic. This paper presents Spec, showing how it enables seamless reuse of widgets and how these can be customized. After presenting Spec and its implementation, we discuss how its use in Pharo 2.0 has cut in half the amount of lines of code of six of its tools, mostly through reuse. This shows that Spec meets its goals of allowing reuse and composition of widget logic.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"73 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2012-08-28","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"127395918","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Automated random testing is a proven way to identify bugs and precondition violations, and this even in well tested libraries. In the context of statically typed languages, current automated random testing tools heavily take advantage of static method declaration (argument types, thrown exceptions) to constrain input domains while testing and to identify errors. For such reason, automated random testing has not been investigated in the context of dynamically typed languages. In this paper we present the key challenges that have to be addressed to support automated testing in dynamic languages.
{"title":"Challenges to support automated random testing for dynamically typed languages","authors":"Stéphane Ducasse, M. Oriol, Alexandre Bergel","doi":"10.1145/2166929.2166938","DOIUrl":"https://doi.org/10.1145/2166929.2166938","url":null,"abstract":"Automated random testing is a proven way to identify bugs and precondition violations, and this even in well tested libraries. In the context of statically typed languages, current automated random testing tools heavily take advantage of static method declaration (argument types, thrown exceptions) to constrain input domains while testing and to identify errors. For such reason, automated random testing has not been investigated in the context of dynamically typed languages. In this paper we present the key challenges that have to be addressed to support automated testing in dynamic languages.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"27 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2011-08-23","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"114214827","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Mondrian, an open-source visualization engine, uses a number of caches to avoid redundant computation. These caches are structured along Mondrian purpose: generating static two-dimensional visualizations. We have noticed that the caches are meaningless for the evolution being made on Mondrian. Using aspect-oriented programming, we have refactored these caches into well defined aspects to address the evolution problem. We have achieved it without paying the price of runtime problems.
{"title":"Memoization aspects: a case study","authors":"S. Vidal, C. Marcos, Alexandre Bergel, G. Arévalo","doi":"10.1145/2166929.2166935","DOIUrl":"https://doi.org/10.1145/2166929.2166935","url":null,"abstract":"Mondrian, an open-source visualization engine, uses a number of caches to avoid redundant computation. These caches are structured along Mondrian purpose: generating static two-dimensional visualizations. We have noticed that the caches are meaningless for the evolution being made on Mondrian. Using aspect-oriented programming, we have refactored these caches into well defined aspects to address the evolution problem. We have achieved it without paying the price of runtime problems.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"14 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2011-08-23","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"133553044","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
The integrated circuit industry continues to progress rapidly deepening the gap in between the technological breakthroughs and the electronic design automation industry. This gap is even more problematic in the context of physical design, the last automation level between applications and the technology. The challenges of meeting the physical and performance constraints necessitate innovation at the algorithmic level, and at the methodological level. This study presents a methodological approach to physical design automation relying on model-driven engineering. Relying on the flexibility, and adaptability of the Smalltalk environment we propose an agile framework enabling fast physical design tool-flow prototyping. We illustrate our approach by using the Madeo FPGA toolkit as a legacy codebase that is incrementally changed to adopt this model-driven development strategy. Some pragmatic achievements are presented to illustrate the principal axes of this approach: algorithmic improvements through plug-and-play routines, domain-model extension for emerging technologies, as well as model evolution toward a meta-described environment.
{"title":"MDE-based FPGA physical design: fast model-driven prototyping with Smalltalk","authors":"C. Teodorov, Loïc Lagadec","doi":"10.1145/2166929.2166936","DOIUrl":"https://doi.org/10.1145/2166929.2166936","url":null,"abstract":"The integrated circuit industry continues to progress rapidly deepening the gap in between the technological breakthroughs and the electronic design automation industry. This gap is even more problematic in the context of physical design, the last automation level between applications and the technology. The challenges of meeting the physical and performance constraints necessitate innovation at the algorithmic level, and at the methodological level.\u0000 This study presents a methodological approach to physical design automation relying on model-driven engineering. Relying on the flexibility, and adaptability of the Smalltalk environment we propose an agile framework enabling fast physical design tool-flow prototyping. We illustrate our approach by using the Madeo FPGA toolkit as a legacy codebase that is incrementally changed to adopt this model-driven development strategy.\u0000 Some pragmatic achievements are presented to illustrate the principal axes of this approach: algorithmic improvements through plug-and-play routines, domain-model extension for emerging technologies, as well as model evolution toward a meta-described environment.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"524 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2011-08-23","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"130603577","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Applications that need to be updated but cannot be easily restarted must be updated at run-time. We evaluate the reflective facilities of Smalltalk with respect to dynamic software and the state-of-the-art in this field. We conclude that while fine for debugging, the existing reflective facilities are not appropriate for dynamically updating production systems under constant load. We propose to enable dynamic updates by introducing first-class contexts as a mechanism to allow multiple versions of objects to coexist. Object states can be dynamically migrated from one context to another, and can be kept in sync with the help of bidirectional transformations. We demonstrate our approach with ActiveContext, an extension of Smalltalk with first-class contexts. ActiveContext eliminates the need for a system to be quiescent for it to be updated. ActiveContext is realized in Pinocchio, an experimental Smalltalk implementation that fully reifies the VM to enable radical extensions. We illustrate dynamic updates in ActiveContext with a typical use case, present initial benchmarks, and discuss future performance improvements.
{"title":"Using first-class contexts to realize dynamic software updates","authors":"Erwann Wernli, David Gurtner, Oscar Nierstrasz","doi":"10.1145/2166929.2166931","DOIUrl":"https://doi.org/10.1145/2166929.2166931","url":null,"abstract":"Applications that need to be updated but cannot be easily restarted must be updated at run-time. We evaluate the reflective facilities of Smalltalk with respect to dynamic software and the state-of-the-art in this field. We conclude that while fine for debugging, the existing reflective facilities are not appropriate for dynamically updating production systems under constant load. We propose to enable dynamic updates by introducing first-class contexts as a mechanism to allow multiple versions of objects to coexist. Object states can be dynamically migrated from one context to another, and can be kept in sync with the help of bidirectional transformations. We demonstrate our approach with ActiveContext, an extension of Smalltalk with first-class contexts. ActiveContext eliminates the need for a system to be quiescent for it to be updated. ActiveContext is realized in Pinocchio, an experimental Smalltalk implementation that fully reifies the VM to enable radical extensions. We illustrate dynamic updates in ActiveContext with a typical use case, present initial benchmarks, and discuss future performance improvements.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"36 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2011-08-23","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"132093309","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
P. Spacek, C. Dony, Chouki Tibermacine, L. Fabresse
The component-based development paradigm brings various solutions for software reusability and better modular structure of applications. When applied in programming language context it changes the way dependencies and connections between software pieces are expressed. In this paper we present the Smalltalk implementation of "Exil", a component-based architecture description and programming language that makes it possible to use component related concepts (ports, interfaces, services,...) at design and if wished at programming time. This proposal enables Smalltalk users to develop their applications in the component-oriented style.
{"title":"A Smalltalk implementation of Exil, a component-based programming language","authors":"P. Spacek, C. Dony, Chouki Tibermacine, L. Fabresse","doi":"10.1145/2166929.2166932","DOIUrl":"https://doi.org/10.1145/2166929.2166932","url":null,"abstract":"The component-based development paradigm brings various solutions for software reusability and better modular structure of applications. When applied in programming language context it changes the way dependencies and connections between software pieces are expressed. In this paper we present the Smalltalk implementation of \"Exil\", a component-based architecture description and programming language that makes it possible to use component related concepts (ports, interfaces, services,...) at design and if wished at programming time. This proposal enables Smalltalk users to develop their applications in the component-oriented style.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"90 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2011-08-23","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"128602670","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Carla F. Griggio, Germán Leiva, G. Polito, Gisela Decuzzi, Nicolás Passerini
This paper describes the features that a programming environment should have in order to help learning the object-oriented programming (OOP) paradigm and let students get the skills needed to build software using objects very quickly. This proposal is centered on providing graphical tools to help understand the concepts of the paradigm and let students create objects before they are presented the class concept [14]. The object, message and reference concepts are considered of primary importance during the teaching process, allowing quick acquisition of both theory and practice of concepts such as delegation, polymorphism and composition [7]. Additionally, a current implementation of the proposed software and the experience gained so far using it for teaching at universities and work trainings. Finally, we describe possible extensions to the proposed software that are currently under study.
{"title":"A programming environment supporting a prototype-based introduction to OOP","authors":"Carla F. Griggio, Germán Leiva, G. Polito, Gisela Decuzzi, Nicolás Passerini","doi":"10.1145/2166929.2166934","DOIUrl":"https://doi.org/10.1145/2166929.2166934","url":null,"abstract":"This paper describes the features that a programming environment should have in order to help learning the object-oriented programming (OOP) paradigm and let students get the skills needed to build software using objects very quickly. This proposal is centered on providing graphical tools to help understand the concepts of the paradigm and let students create objects before they are presented the class concept [14]. The object, message and reference concepts are considered of primary importance during the teaching process, allowing quick acquisition of both theory and practice of concepts such as delegation, polymorphism and composition [7]. Additionally, a current implementation of the proposed software and the experience gained so far using it for teaching at universities and work trainings. Finally, we describe possible extensions to the proposed software that are currently under study.","PeriodicalId":393791,"journal":{"name":"International Workshop on Smalltalk Technologies","volume":"48 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2011-08-23","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"115828115","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}