Searcharxiv⌕ Search

arXiv subjects

João Saraiva

Publications and source records attributed to João Saraiva.

14 recordsLinked to original sources

The Green Side of the Lua

The United Nations' 2030 Agenda for Sustainable Development highlights the importance of energy-efficient software to reduce the global carbon footprint. Programming languages and execution models strongly influence software energy consumption, with interpreted languages generally being less efficient than compiled ones. Lua illustrates this trade-off: despite its popularity, it is less energy-efficient than greener and faster languages such as C. This paper presents an empirical study of Lua's runtime performance and energy efficiency across 25 official interpreter versions and just-in-time (JIT) compilers. Using a comprehensive benchmark suite, we measure execution time and energy consumption to analyze Lua's evolution, the impact of JIT compilation, and comparisons with other languages. Results show that all LuaJIT compilers significantly outperform standard Lua interpreters. The most efficient LuaJIT consumes about seven times less energy and runs seven times faster than the best Lua interpreter. Moreover, LuaJIT approaches C's efficiency, using roughly six times more energy and running about eight times slower, demonstrating the substantial benefits of JIT compilation for improving both performance and energy efficiency in interpreted languages.

cs.SE↗

Greening AI-enabled Systems with Software Engineering: A Research Agenda for Environmentally Sustainable AI Practices

The environmental impact of Artificial Intelligence (AI)-enabled systems is increasing rapidly, and software engineering plays a critical role in developing sustainable solutions. The "Greening AI with Software Engineering" CECAM-Lorentz workshop (no. 1358, 2025) funded by the Centre Européen de Calcul Atomique et Moléculaire and the Lorentz Center, provided an interdisciplinary forum for 29 participants, from practitioners to academics, to share knowledge, ideas, practices, and current results dedicated to advancing green software and AI research. The workshop was held February 3-7, 2025, in Lausanne, Switzerland. Through keynotes, flash talks, and collaborative discussions, participants identified and prioritized key challenges for the field. These included energy assessment and standardization, benchmarking practices, sustainability-aware architectures, runtime adaptation, empirical methodologies, and education. This report presents a research agenda emerging from the workshop, outlining open research directions and practical recommendations to guide the development of environmentally sustainable AI-enabled systems rooted in software engineering principles.

cs.SE↗

Resistive Plate Chambers for brain PET imaging and particle tracking and timing (TOF-tracker)

In this work we explore readout architectures for the simultaneous high-resolution timing and bidimensional tracking of charged particles with Resistive Plate Chambers (TOF-tracker) and for the accurate detection of gamma rays for PET imaging. On 625 $cm^2$ of active area we obtained a time resolution of 61 ps $σ$ and bidimensional position resolution below 150 $μ$m $σ$ for the tracking and timing of charged particles from cosmic rays. An intrinsic precision of 0.49 mm FWHM was determined for the localization of a small $β^+$ source via the detection of its annihilation radiation.

physics.ins-det↗

A Large-Area RPC Detector for Muography

A muon telescope equipped with four Resistive Plate Chambers of 2 m$^{2}$ per plane was tested with the muon scattering tomography technique. The telescope was operated during several hours with high atomic number materials located at its center with two detector planes on each side. With an intrinsic efficiency above 98%, spatial resolution around 1 cm and detector planes spaced by 45 cm, it was possible to identify the presence of a 5 cm thick tungsten block in 10 minutes of acquisition. The results obtained after five hours of acquisition are also presented in this communication.

physics.ins-det↗

An RPC-PET brain scanner demonstrator: first results

We present first results from a Positron Emission Tomography (PET) scanner demonstrator based on Resistive Plate Chambers and specialized for brain imaging. The device features a 30 cm wide cubic field-of-view and each detector comprises 40 gas gaps with 3D location of the interaction point of the photon. Besides other imagery, we show that the reconstructed image resolution, as evaluated by a hot-rod phantom, is sub-millimetric, which is beyond the state-of-the-art of the standard PET technology for this application.

physics.ins-det↗

Advances Towards a Large-Area, Ultra-Low-Gas-Consumption RPC Detector

Large Resistive Plate Chamber systems have their roots in High Energy Physics experiments at the European Organization for Nuclear Research: ATLAS, CMS and ALICE, where hundreds of square meters of both trigger and timing RPCs have been deployed. These devices operate with complex gas systems, equipped with re-circulation and purification units, which require a fresh gas supply of the order of 6 cm$^{3}$/min/m$^{2}$, creating logistical, technical and financial problems. In this communication, we present a new concept in the construction of RPCs which allowed us to operate a detector at ultra-low gas flow regime. With this new approach, the glass stack is encapsulated in a tight plastic box made of polypropylene, which presents excellent water vapor blocking properties as well as a good protection against atmospheric gases.

physics.ins-det↗

Energy Efficiency of Web Browsers in the Android Ecosystem

This paper presents an empirical study regarding the energy consumption of the most used web browsers on the Android ecosystem. In order to properly compare the web browsers in terms of energy consumption, we defined a set of typical usage scenarios to be replicated in the different browsers, executed in the same testing environment and conditions. The results of our study show that there are significant differences in terms of energy consumption among the considered browsers. Furthermore, we conclude that some browsers are energy efficient in several user actions, but energy greedy in other ones, allowing us to conclude that no browser is universally more efficient for all usage scenarios.

cs.SE↗

Zipping Strategies and Attribute Grammars

Strategic term rewriting and attribute grammars are two powerful programming techniques widely used in language engineering. The former, relies on strategies to apply term rewrite rules in defining language transformations, while the latter is suitable to express context-dependent language processing algorithms. Each of these techniques, however, is usually implemented by its own powerful and large language processor system. As a result, it makes such systems harder to extend and to combine. In this paper, we present the embedding of both strategic tree rewriting and attribute grammars in a zipper-based, purely functional setting. Zippers provide a simple, but generic tree-walk mechanism that is the building block technique we use to express the purely-functional embedding of both techniques. The embedding of the two techniques in the same setting has several advantages: First, we easily combine/zip attribute grammars and strategies, thus providing language engineers the best of the two worlds. Second, the combined embedding is easier to maintain and extend since it is written in a concise and uniform setting. This results in a very small library which is able to express advanced (static) analysis and transformation tasks. We show the expressive power of our library in optimizing Haskell let expressions, expressing several Haskell refactorings and solving several language processing tasks of the LDTA Tool Challenge.

cs.PL↗

Green Software Lab: Towards an Engineering Discipline for Green Software

This report describes the research goals and results of the Green Software Lab (GSL) research project. This was a project funded by Fundação para a Ciência e a Tecnologia (FCT) -- the Portuguese research foundation -- under reference POCI-01-0145-FEDER-016718, that ran from January 2016 till July 2020. This report includes the complete document reporting the results achieved during the project execution, which was submitted to FCT for evaluation on July 2020. It describes the goals of the project, and the different research tasks presenting the deliverables of each of them. It also presents the management and result dissemination work performed during the project's execution. The document includes also a self assessment of the achieved results, and a complete list of scientific publications describing the contributions of the project. Finally, this document includes the FCT evaluation report.

cs.SE↗

Tabula: A Language to Model Spreadsheet Tables

Spreadsheets provide a flexible and easy to use software development environment, but that leads to error proneness. Work has been done to prevent errors in spreadsheets, including using models to specify distinct parts of a spreadsheet as it is done with model-driven software development. Previous model languages for spreadsheets offer a limited expressiveness, and cannot model several features present in most real world spreadsheets. In this paper, the modeling language Tabula is introduced. It extends previous spreadsheet models with features like type constraints and nested classes with repetitions. Tabula is not only more expressive than other models but it can also be extended with more features. Moreover, Tabula includes a bidirectional transformation engine that guarantees synchronization after an update either in the model or spreadsheet.

cs.SE↗

The Influence of the Java Collection Framework on Overall Energy Consumption

This paper presents a detailed study of the energy consumption of the different Java Collection Framework (JFC) implementations. For each method of an implementation in this framework, we present its energy consumption when handling different amounts of data. Knowing the greenest methods for each implementation, we present an energy optimization approach for Java programs: based on calls to JFC methods in the source code of a program, we select the greenest implementation. Finally, we present preliminary results of optimizing a set of Java programs where we obtained 6.2% energy savings.

cs.SE↗

Towards the Design and Implementation of Aspect-Oriented Programming for Spreadsheets

A spreadsheet usually starts as a simple and single-user software artifact, but, as frequent as in other software systems, quickly evolves into a complex system developed by many actors. Often, different users work on different aspects of the same spreadsheet: while a secretary may be only involved in adding plain data to the spreadsheet, an accountant may define new business rules, while an engineer may need to adapt the spreadsheet content so it can be used by other software systems. Unfortunately, spreadsheet systems do not offer modular mechanisms, and as a consequence, some of the previous tasks may be defined by adding intrusive "code" to the spreadsheet. In this paper we go through the design and implementation of an aspect-oriented language for spreadsheets so that users can work on different aspects of a spreadsheet in a modular way. For example, aspects can be defined in order to introduce new business rules to an existing spreadsheet, or to manipulate the spreadsheet data to be ported to another system. Aspects are defined as aspect-oriented program specifications that are dynamically woven into the underlying spreadsheet by an aspect weaver. In this aspect-oriented style of spreadsheet development, different users develop, or reuse, aspects without adding intrusive code to the original spreadsheet. Such code is added/executed by the spreadsheet weaving mechanism proposed in this paper.

cs.SE↗

Querying Spreadsheets: An Empirical Study

One of the most important assets of any company is being able to easily access information on itself and on its business. In this line, it has been observed that this important information is often stored in one of the millions of spreadsheets created every year, due to simplicity in using and manipulating such an artifact. Unfortunately, in many cases it is quite difficult to retrieve the intended information from a spreadsheet: information is often stored in a huge unstructured matrix, with no care for readability or comprehensiveness. In an attempt to aid users in the task of extracting information from a spreadsheet, researchers have been working on models, languages and tools to query. In this paper we present an empirical study evaluating such proposals assessing their usage to query spreadsheets. We investigate the use of the Google Query Function, textual model-driven querying, and visual model-driven querying. To compare these different querying approaches we present an empirical study whose results show that the end-users' productivity increases when using model-driven queries, specially using its visual representation.

cs.SE↗

An Empirical Study on End-users Productivity Using Model-based Spreadsheets

Spreadsheets are widely used, and studies have shown that most end-user spreadsheets contain nontrivial errors. To improve end-users productivity, recent research proposes the use of a model-driven engineering approach to spreadsheets. In this paper we conduct the first systematic empirical study to assess the effectiveness and efficiency of this approach. A set of spreadsheet end users worked with two different model-based spreadsheets, and we present and analyze here the results achieved.

cs.HC↗