Shmuel Sagiv

dblp:s/SSagiv · also Mooly Sagiv · DBLP profile ↗
← Back
157ranked-venue papers
12as first author
10since 2021 · last 2024
0000-0002-0723-1309ORCID · verified

Domains — the database's venue-derived domains; a paper can count in several

Software engineering, systems software and programming languages · 130 · 9 first-author · 7 since 2021Theory of computation · 33 · 4 first-author · 3 since 2021Artificial intelligence and machine learning · 7Systems, architecture and hardware · 5 · 1 since 2021Security and privacy · 2 · 1 since 2021Databases, data management, data science and information retrieval · 2Graphics, computer vision, multimedia, augmented reality and games · 2Computer networks · 1Applied, interdisciplinary, general and emerging computing · 1
YearPublicationVenuePosition
2024 Harnessing SMT Solvers for Reasoning about DeFi Protocols
Shmuel Sagiv
FMCAD1
2024 Practical Verification of Smart Contracts using Memory Splitting
abstract
SMT-based verification of low-level code requires modeling and reasoning about memory operations. Prior work has shown that optimizing memory representations is beneficial for scaling verification—pointer analysis, for example can be used to split memory into disjoint regions leading to faster SMT solving. However, these techniques are mostly designed for C and C++ programs with explicit operations for memory allocation which are not present in all languages. For instance, on the Ethereum virtual machine, memory is simply a monolithic array of bytes which can be freely accessed by Ethereum bytecode, and there is no allocation primitive. In this paper, we present a memory splitting transformation guided by a conservative memory analysis for Ethereum bytecode generated by the Solidity compiler. The analysis consists of two phases: recovering memory allocation and memory regions, followed by a pointer analysis. The goal of the analysis is to enable memory splitting which in turn speeds up verification. We have implemented both the analysis and the memory splitting transformation as part of a verification tool, CertoraProver, and show that the transformation speeds up SMT solving by up to 120× and additionally mitigates 16 timeouts when used on 229 real-world smart contract verification tasks.
Shelly Grossman, John Toman, Alexander Bakst, Sameer Arora, Shmuel Sagiv, Chandrakana Nandi
Proc. ACM Program. Lang.5
2023 Counterexample Driven Quantifier Instantiations with Applications to Distributed Protocols
abstract
Formally verifying infinite-state systems can be a daunting task, especially when it comes to reasoning about quantifiers. In particular, quantifier alternations in conjunction with function symbols can create function cycles that result in infinitely many ground terms, making it difficult for solvers to instantiate quantifiers and causing them to diverge. This can leave users with no useful information on how to proceed. To address this issue, we propose an interactive verification methodology that uses a relational abstraction technique to mitigate solver divergence in the presence of quantifiers. This technique abstracts functions in the verification conditions (VCs) as one-to-one relations, which avoids the creation of function cycles and the resulting proliferation of ground terms. Relational abstraction is sound and guarantees correctness if the solver cannot find counter-models. However, it may also lead to false counterexamples, which can be addressed by refining the abstraction and requiring the existence of corresponding elements. In the domain of distributed protocols, we can refine the abstraction by diagnosing counterexamples and manually instantiating elements in the range of the original function. If the verification conditions are correct, there always exist finitely many refinement steps that eliminate all spurious counter-models, making the approach complete. We applied this approach in Ivy to verify the safety properties of consensus protocols and found that: (1) most verification goals can be automatically verified using relational abstraction, while SMT solvers often diverge when given the original VC, (2) only a few manual instantiations were needed, and the counterexamples provided valuable guidance for the user compared to timeouts produced by the traditional approach, and (3) the technique can be used to derive efficient low-level implementations of tricky algorithms.
Orr Tamir, Marcelo Taube, Kenneth L. McMillan, Sharon Shoham, Jon Howell, Guy Golan-Gueta, Shmuel Sagiv
Proc. ACM Program. Lang.7
2023 Relaxed Effective Callback Freedom: A Parametric Correctness Condition for Sequential Modules With Callbacks
abstract
Callbacks are an essential mechanism for event-driven programming. Unfortunately, callbacks make reasoning challenging because they introduce behaviors where calls to the module are interleaved. We present a parametric method that, from a particular invariant of the program, allows reducing the problem of verifying the invariant in the presence of callbacks, to the callback-free setting. Intuitively, we allow callbacks to introduce behaviors that cannot be produced by callback free executions, as long as they do not affect correctness. A chief insight is that the user is aware of the potential effect of the callbacks on the program state. To this end, we present a parametric verification technique which accepts this insight as a relation between callback and callback free executions. We implemented our approach and applied it successfully to a large set of real-world programs.
Elvira Albert, Shelly Grossman, Noam Rinetzky, Clara Rodríguez-Núñez, Albert Rubio, Shmuel Sagiv
IEEE Trans. Dependable Secur. Comput.6
2022 Blockaid: Data Access Policy Enforcement for Web Applications
Eric Sheng, Michael Alan Chang, Aurojit Panda, Shmuel Sagiv, Scott Shenker
OSDI5
2022 Property-directed reachability as abstract interpretation in the monotone theory
abstract
Inferring inductive invariants is one of the main challenges of formal verification. The theory of abstract interpretation provides a rich framework to devise invariant inference algorithms. One of the latest breakthroughs in invariant inference is property-directed reachability (PDR), but the research community views PDR and abstract interpretation as mostly unrelated techniques. This paper shows that, surprisingly, propositional PDR can be formulated as an abstract interpretation algorithm in a logical domain. More precisely, we define a version of PDR, called Λ-PDR, in which all generalizations of counterexamples are used to strengthen a frame. In this way, there is no need to refine frames after their creation, because all the possible supporting facts are included in advance. We analyze this algorithm using notions from Bshouty’s monotone theory, originally developed in the context of exact learning. We show that there is an inherent overapproximation between the algorithm’s frames that is related to the monotone theory. We then define a new abstract domain in which the best abstract transformer performs this overapproximation, and show that it captures the invariant inference process, i.e., Λ-PDR corresponds to Kleene iterations with the best transformer in this abstract domain. We provide some sufficient conditions for when this process converges in a small number of iterations, with sometimes an exponential gap from the number of iterations required for naive exact forward reachability. These results provide a firm theoretical foundation for the benefits of how PDR tackles forward reachability.
Yotam M. Y. Feldman, Shmuel Sagiv, Sharon Shoham, James R. Wilcox
Proc. ACM Program. Lang.2
2021 Summing up Smart Transitions
abstract
Abstract Some of the most significant high-level properties of currencies are the sums of certain account balances. Properties of such sums can ensure the integrity of currencies and transactions. For example, the sum of balances should not be changed by a transfer operation. Currencies manipulated by code present a verification challenge to mathematically prove their integrity by reasoning about computer programs that operate over them, e.g., in Solidity. The ability to reason about sums is essential: even the simplest ERC-20 token standard of the Ethereum community provides a way to access the total supply of balances. Unfortunately, reasoning about code written against this interface is non-trivial: the number of addresses is unbounded, and establishing global invariants like the preservation of the sum of the balances by operations like transfer requires higher-order reasoning. In particular, automated reasoners do not provide ways to specify summations of arbitrary length. In this paper, we present a generalization of first-order logic which can express the unbounded sum of balances. We prove the decidablity of one of our extensions and the undecidability of a slightly richer one. We introduce first-order encodings to automate reasoning over software transitions with summations. We demonstrate the applicability of our results by using SMT solvers and first-order provers for validating the correctness of common transitions in smart contracts.
Neta Elad, Sophie Rain, Neil Immerman, Laura Kovács, Shmuel Sagiv
CAV (1)5
2021 Cloud-Scale Runtime Verification of Serverless Applications
abstract
Serverless platforms aim to simplify the deployment, scaling, and management of cloud applications. Serverless applications are inherently distributed, and are executed using shortlived ephemeral processes. The use of short-lived ephemeral processes simplifies application scaling and management, but also means that existing approaches to monitoring distributed systems and detecting bugs cannot be applied to serverless applications. In this paper we propose Watchtower, a framework that enables runtime monitoring of serverless applications. Watchtower takes program properties as inputs, and can detect cases where applications violate these properties. We design Watchtower to minimize application changes, and to scale at the same rate as the application. We achieve the former by instrumenting libraries rather than application code, and the latter by structuring Watchtower as a serverless application. Once a bug is found, developers can use the Watchtower debugger to identify and address the root cause of the bug.
Kalev Alpernas, Aurojit Panda, Leonid Ryzhyk, Shmuel Sagiv
SoCC4
2021 Temporal prophecy for proving temporal properties of infinite-state systems
abstract
Abstract Various verification techniques for temporal properties transform temporal verification to safety verification. For infinite-state systems, these transformations are inherently imprecise. That is, for some instances, the temporal property holds, but the resulting safety property does not. This paper introduces a mechanism for tackling this imprecision. This mechanism, which we call temporal prophecy, is inspired by prophecy variables. Temporal prophecy refines an infinite-state system using first-order linear temporal logic formulas, via a suitable tableau construction. For a specific liveness-to-safety transformation based on first-order logic, we show that using temporal prophecy strictly increases the precision. Furthermore, temporal prophecy leads to robustness of the proof method, which is manifested by a cut elimination theorem. We integrate our approach into the Ivy deductive verification system, and show that it can handle challenging temporal verification examples.
Oded Padon, Jochen Hoenicke, Kenneth L. McMillan, Andreas Podelski, Shmuel Sagiv, Sharon Shoham
Formal Methods Syst. Des.5
2021 Learning the boundary of inductive invariants
abstract
We study the complexity of invariant inference and its connections to exact concept learning. We define a condition on invariants and their geometry, called the fence condition, which permits applying theoretical results from exact concept learning to answer open problems in invariant inference theory. The condition requires the invariant's boundary---the states whose Hamming distance from the invariant is one---to be backwards reachable from the bad states in a small number of steps. Using this condition, we obtain the first polynomial complexity result for an interpolation-based invariant inference algorithm, efficiently inferring monotone DNF invariants with access to a SAT solver as an oracle. We further harness Bshouty's seminal result in concept learning to efficiently infer invariants of a larger syntactic class of invariants beyond monotone DNF. Lastly, we consider the robustness of inference under program transformations. We show that some simple transformations preserve the fence condition, and that it is sensitive to more complex transformations.
Yotam M. Y. Feldman, Shmuel Sagiv, Sharon Shoham, James R. Wilcox
Proc. ACM Program. Lang.2
2020 Taming callbacks for smart contract modularity
abstract
Callbacks are an effective programming discipline for implementing event-driven programming, especially in environments like Ethereum which forbid shared global state and concurrency. Callbacks allow a callee to delegate the execution back to the caller. Though effective, they can lead to subtle mistakes principally in open environments where callbacks can be added in a new code. Indeed, several high profile bugs in smart contracts exploit callbacks. We present the first static technique ensuring modularity in the presence of callbacks and apply it to verify prominent smart contracts. Modularity ensures that external calls to other contracts cannot affect the behavior of the contract. Importantly, modularity is guaranteed without restricting programming. In general, checking modularity is undecidable—even for programs without loops. This paper describes an effective technique for soundly ensuring modularity harnessing SMT solvers. The main idea is to define a constructive version of modularity using commutativity and projection operations on program segments. We believe that this approach is also accessible to programmers, since counterexamples to modularity can be generated automatically by the SMT solvers, allowing programmers to understand and fix the error. We implemented our approach in order to demonstrate the precision of the modularity analysis and applied it to real smart contracts, including a subset of the 150 most active contracts in Ethereum. Our implementation decompiles bytecode programs into an intermediate representation and then implements the modularity checking using SMT queries. Overall, we argue that our experimental results indicate that the method can be applied to many realistic contracts, and that it is able to prove modularity where other methods fail.
Elvira Albert, Shelly Grossman, Noam Rinetzky, Clara Rodríguez-Núñez, Albert Rubio, Shmuel Sagiv
Proc. ACM Program. Lang.6
2020 Complexity and information in invariant inference
abstract
This paper addresses the complexity of SAT-based invariant inference, a prominent approach to safety verification. We consider the problem of inferring an inductive invariant of polynomial length given a transition system and a safety property. We analyze the complexity of this problem in a black-box model, called the Hoare-query model, which is general enough to capture algorithms such as IC3/PDR and its variants. An algorithm in this model learns about the system's reachable states by querying the validity of Hoare triples. We show that in general an algorithm in the Hoare-query model requires an exponential number of queries. Our lower bound is information-theoretic and applies even to computationally unrestricted algorithms, showing that no choice of generalization from the partial information obtained in a polynomial number of Hoare queries can lead to an efficient invariant inference procedure in this class. We then show, for the first time, that by utilizing rich Hoare queries, as done in PDR, inference can be exponentially more efficient than approaches such as ICE learning, which only utilize inductiveness checks of candidates. We do so by constructing a class of transition systems for which a simple version of PDR with a single frame infers invariants in a polynomial number of queries, whereas every algorithm using only inductiveness checks and counterexamples requires an exponential number of queries. Our results also shed light on connections and differences with the classical theory of exact concept learning with queries, and imply that learning from counterexamples to induction is harder than classical exact learning from labeled examples. This demonstrates that the convergence rate of Counterexample-Guided Inductive Synthesis depends on the form of counterexamples.
Yotam M. Y. Feldman, Neil Immerman, Shmuel Sagiv, Sharon Shoham
Proc. ACM Program. Lang.3
2019 Inferring Inductive Invariants from Phase Structures
abstract
Infinite-state systems such as distributed protocols are challenging to verify using interactive theorem provers or automatic verification tools. Of these techniques, deductive verification is highly expressive but requires the user to annotate the system with inductive invariants . To relieve the user from this labor-intensive and challenging task, invariant inference aims to find inductive invariants automatically. Unfortunately, when applied to infinite-state systems such as distributed protocols, existing inference techniques often diverge, which limits their applicability. This paper proposes user-guided invariant inference based on phase invariants , which capture the different logical phases of the protocol. Users conveys their intuition by specifying a phase structure , an automaton with edges labeled by program transitions; the tool automatically infers assertions that hold in the automaton’s states, resulting in a full safety proof. The additional structure from phases guides the inference procedure towards finding an invariant. Our results show that user guidance by phase structures facilitates successful inference beyond the state of the art. We find that phase structures are pleasantly well matched to the intuitive reasoning routinely used by domain experts to understand why distributed protocols are correct, so that providing a phase structure reuses this existing intuition.
Yotam M. Y. Feldman, James R. Wilcox, Sharon Shoham, Shmuel Sagiv
CAV (2)4
2019 Synthesizing Cluster Management Code for Distributed Systems
abstract
Management planes for data-center systems are complicated to develop, test, maintain, and evolve. They routinely grapple with hard combinatorial optimization problems like load balancing, placement, scheduling, rolling upgrades and configuration management. To tackle these problems, developers are left with two bad choices: (i) develop ad-hoc mechanisms for systems to solve these optimization problems, or (ii) use specialized solvers that require steep engineering effort.
Lalith Suresh 0001, João Loff, Nina Narodytska, Leonid Ryzhyk, Shmuel Sagiv, Brian Oki
HotOS5
2019 Simple and precise static analysis of untrusted Linux kernel extensions
abstract
Extended Berkeley Packet Filter (eBPF) is a Linux subsystem that allows safely executing untrusted user-defined extensions inside the kernel. It relies on static analysis to protect the kernel against buggy and malicious extensions. As the eBPF ecosystem evolves to support more complex and diverse extensions, the limitations of its current verifier, including high rate of false positives, poor scalability, and lack of support for loops, have become a major barrier for developers.
Elazar Gershuni, Nadav Amit, Arie Gurfinkel, Nina Narodytska, Jorge A. Navas, Noam Rinetzky, Leonid Ryzhyk, Shmuel Sagiv
PLDI8
2019 Some complexity results for stateful network verification
Kalev Alpernas, Aurojit Panda, Alexander Moshe Rabinovich, Shmuel Sagiv, Scott Shenker, Sharon Shoham, Yaron Velner
Formal Methods Syst. Des.4
2019 Bounded Quantifier Instantiation for Checking Inductive Invariants
abstract
We consider the problem of checking whether a proposed invariant $\varphi$ expressed in first-order logic with quantifier alternation is inductive, i.e. preserved by a piece of code. While the problem is undecidable, modern SMT solvers can sometimes solve it automatically. However, they employ powerful quantifier instantiation methods that may diverge, especially when $\varphi$ is not preserved. A notable difficulty arises due to counterexamples of infinite size. This paper studies Bounded-Horizon instantiation, a natural method for guaranteeing the termination of SMT solvers. The method bounds the depth of terms used in the quantifier instantiation process. We show that this method is surprisingly powerful for checking quantified invariants in uninterpreted domains. Furthermore, by producing partial models it can help the user diagnose the case when $\varphi$ is not inductive, especially when the underlying reason is the existence of infinite counterexamples. Our main technical result is that Bounded-Horizon is at least as powerful as instrumentation, which is a manual method to guarantee convergence of the solver by modifying the program so that it admits a purely universal invariant. We show that with a bound of 1 we can simulate a natural class of instrumentations, without the need to modify the code and in a fully automatic way. We also report on a prototype implementation on top of Z3, which we used to verify several examples by Bounded-Horizon of bound 1.
Yotam M. Y. Feldman, Oded Padon, Neil Immerman, Shmuel Sagiv, Sharon Shoham
Log. Methods Comput. Sci.4
2018 Verifying Properties of Binarized Deep Neural Networks
abstract
Understanding properties of deep neural networks is an important challenge in deep learning. In this paper, we take a step in this direction by proposing a rigorous way of verifying properties of a popular class of neural networks, Binarized Neural Networks, using the well-developed means of Boolean satisfiability. Our main contribution is a construction that creates a representation of a binarized neural network as a Boolean formula. Our encoding is the first exact Boolean representation of a deep neural network. Using this encoding, we leverage the power of modern SAT solvers along with a proposed counterexample-guided search procedure to verify various properties of these networks. A particular focus will be on the critical property of robustness to adversarial perturbations. For this property, our experimental results demonstrate that our approach scales to medium-size deep neural networks used in image classification tasks. To the best of our knowledge, this is the first work on verifying properties of deep neural networks using an exact Boolean encoding of the network.
Nina Narodytska, Shiva Prasad Kasiviswanathan, Leonid Ryzhyk, Shmuel Sagiv, Toby Walsh
AAAI4
2018 Temporal Prophecy for Proving Temporal Properties of Infinite-State Systems
abstract
Various verification techniques for temporal properties transform temporal verification to safety verification. For infinite-state systems, these transformations are inherently imprecise. That is, for some instances, the temporal property holds, but the resulting safety property does not. This paper introduces a mechanism for tackling this imprecision. This mechanism, which we call temporal prophecy, is inspired by prophecy variables. Temporal prophecy refines an infinite-state system using first-order linear temporal logic formulas, via a suitable tableau construction. For a specific liveness-to-safety transformation based on first-order logic, we show that using temporal prophecy strictly increases the precision. Furthermore, temporal prophecy leads to robustness of the proof method, which is manifested by a cut elimination theorem. We integrate our approach into the Ivy deductive verification system, and show that it can handle challenging temporal verification examples.
Oded Padon, Jochen Hoenicke, Kenneth L. McMillan, Andreas Podelski, Shmuel Sagiv, Sharon Shoham
FMCAD5
2018 Core-Guided Minimal Correction Set and Core Enumeration
abstract
A set of constraints is unsatisfiable if there is no solution that satisfies these constraints. To analyse unsatisfiable problems, the user needs to understand where inconsistencies come from and how they can be repaired. Minimal unsatisfiable cores and correction sets are important subsets of constraints that enable such analysis. In this work, we propose a new algorithm for extracting minimal unsatisfiable cores and correction sets simultaneously. Building on top of the relaxation and strengthening framework, we introduce novel techniques for extracting these sets. Our new solver significantly outperforms several state of the art algorithms on common benchmarks when it comes to extracting correction sets and compares favorably on core extraction.
Nina Narodytska, Nikolaj S. Bjørner, Maria-Cristina V. Marinescu, Shmuel Sagiv
IJCAI4
2018 Modularity for decidability of deductive verification with applications to distributed systems
abstract
Proof automation can substantially increase productivity in formal verification of complex systems. However, unpredictablility of automated provers in handling quantified formulas presents a major hurdle to usability of these tools. We propose to solve this problem not by improving the provers, but by using a modular proof methodology that allows us to produce decidable verification conditions. Decidability greatly improves predictability of proof automation, resulting in a more practical verification approach. We apply this methodology to develop verified implementations of distributed protocols, demonstrating its effectiveness.
Marcelo Taube, Giuliano Losa, Kenneth L. McMillan, Oded Padon, Shmuel Sagiv, Sharon Shoham, James R. Wilcox, Doug Woos
PLDI5
2018 Abstract Interpretation of Stateful Networks
Kalev Alpernas, Roman Manevich, Aurojit Panda, Shmuel Sagiv, Scott Shenker, Sharon Shoham, Yaron Velner
SAS4
2018 Constrained Image Generation Using Binarized Neural Networks with Decision Procedures
Svyatoslav Korneev, Nina Narodytska, Luca Pulina, Armando Tacchella, Nikolaj S. Bjørner, Shmuel Sagiv
SAT6
2018 Secure serverless computing using dynamic information flow control
abstract
The rise of serverless computing provides an opportunity to rethink cloud security. We present an approach for securing serverless systems using a novel form of dynamic information flow control (IFC). We show that in serverless applications, the termination channel found in most existing IFC systems can be arbitrarily amplified via multiple concurrent requests, necessitating a stronger termination-sensitive non-interference guarantee, which we achieve using a combination of static labeling of serverless processes and dynamic faceted labeling of persistent data. We describe our implementation of this approach on top of JavaScript for AWS Lambda and OpenWhisk serverless platforms, and present three realistic case studies showing that it can enforce important IFC security properties with modest overhead.
Kalev Alpernas, Cormac Flanagan, Sadjad Fouladi, Leonid Ryzhyk, Shmuel Sagiv, Thomas Schmitz 0001, Keith Winstein
Proc. ACM Program. Lang.5
2018 Online detection of effectively callback free objects with applications to smart contracts
abstract
Callbacks are essential in many programming environments, but drastically complicate program understanding and reasoning because they allow to mutate object's local states by external objects in unexpected fashions, thus breaking modularity. The famous DAO bug in the cryptocurrency framework Ethereum, employed callbacks to steal $150M. We define the notion of Effectively Callback Free (ECF) objects in order to allow callbacks without preventing modular reasoning. An object is ECF in a given execution trace if there exists an equivalent execution trace without callbacks to this object. An object is ECF if it is ECF in every possible execution trace. We study the decidability of dynamically checking ECF in a given execution trace and statically checking if an object is ECF. We also show that dynamically checking ECF in Ethereum is feasible and can be done online. By running the history of all execution traces in Ethereum, we were able to verify that virtually all existing contract executions, excluding these of the DAO or of contracts with similar known vulnerabilities, are ECF. Finally, we show that ECF, whether it is verified dynamically or statically, enables modular reasoning about objects with encapsulated state.
Shelly Grossman, Ittai Abraham, Guy Golan-Gueta, Yan Michalevsky, Noam Rinetzky, Shmuel Sagiv, Yoni Zohar
Proc. ACM Program. Lang.6
2018 Reducing liveness to safety in first-order logic
abstract
We develop a new technique for verifying temporal properties of infinite-state (distributed) systems. The main idea is to reduce the temporal verification problem to the problem of verifying the safety of infinite-state systems expressed in first-order logic. This allows to leverage existing techniques for safety verification to verify temporal properties of interesting distributed protocols, including some that have not been mechanically verified before. We model infinite-state systems using first-order logic, and use first-order temporal logic (FO-LTL) to specify temporal properties. This general formalism allows to naturally model distributed systems, while supporting both unbounded-parallelism (where the system is allowed to dynamically create processes), and infinite-state per process. The traditional approach for verifying temporal properties of infinite-state systems employs well-founded relations (e.g. using linear arithmetic ranking functions). In contrast, our approach is based the idea of fair cycle detection. In finite-state systems, temporal verification can always be reduced to fair cycle detection (a system contains a fair cycle if it revisits a state after satisfying all fairness constraints). However, with both infinitely many states and infinitely many fairness constraints, a straightforward reduction to fair cycle detection is unsound. To regain soundness, we augment the infinite-state transition system by a dynamically computed finite set, that exploits the locality of transitions. This set lets us define a form of fair cycle detection that is sound in the presence of both infinitely many states, and infinitely many fairness constraints. Our approach allows a new style of temporal verification that does not explicitly involve ranking functions. This fits well with pure first-order verification which does not explicitly reason about numerical values. In particular, it can be used with effectively propositional first-order logic (EPR), in which case checking verification conditions is decidable. We applied our technique to verify temporal properties of several interesting protocols. To the best of our knowledge, we have obtained the first mechanized liveness proof for both TLB Shootdown, and Stoppable Paxos.
Oded Padon, Jochen Hoenicke, Giuliano Losa, Andreas Podelski, Shmuel Sagiv, Sharon Shoham
Proc. ACM Program. Lang.5
2017 Verifying Equivalence of Spark Programs
Shelly Grossman, Sara Cohen, Shachar Itzhaky, Noam Rinetzky, Shmuel Sagiv
CAV (2)5
2017 Verification in the Age of Microservices
abstract
Many large applications are now built using collections of microservices, each of which is deployed in isolated containers and which interact with each other through the use of remote procedure calls (RPCs). The use of microservices improves scalability -- each component of an application can be scaled independently -- and deployability. However, such applications are inherently distributed and current tools do not provide mechanisms to reason about and ensure their global behavior. In this paper we argue that recent advances in formal methods and software packet processing pave the path towards building mechanisms that can ensure correctness for such systems, both when they are being built and at runtime. These techniques impose minimal runtime overheads and are amenable to production deployments.
Aurojit Panda, Shmuel Sagiv, Scott Shenker
HotOS2
2017 On the Automated Verification of Web Applications with Embedded SQL
abstract
A large number of web applications is based on a relational database together with a program, typically a script, that enables the user to interact with the database through embedded SQL queries and commands. In this paper, we introduce a method for formal automated verification of such systems which connects database theory to mainstream program analysis. We identify a fragment of SQL which captures the behavior of the queries in our case studies, is algorithmically decidable, and facilitates the construction of weakest preconditions. Thus, we can integrate the analysis of SQL queries into a program analysis tool chain. To this end, we implement a new decision procedure for the SQL fragment that we introduce. We demonstrate practical applicability of our results with three case studies, a web administrator, a simple firewall, and a conference management system.
Shachar Itzhaky, Tomer Kotek, Noam Rinetzky, Shmuel Sagiv, Orr Tamir, Helmut Veith, Florian Zuleger
ICDT4
2017 Verifying Reachability in Networks with Mutable Datapaths
Aurojit Panda, Ori Lahav 0001, Katerina J. Argyraki, Shmuel Sagiv, Scott Shenker
NSDI4
2017 Bounded Quantifier Instantiation for Checking Inductive Invariants
Yotam M. Y. Feldman, Oded Padon, Neil Immerman, Shmuel Sagiv, Sharon Shoham
TACAS (1)4
2017 Property Directed Reachability for Proving Absence of Concurrent Modification Errors
Asya Frumkin, Yotam M. Y. Feldman, Ondrej Lhoták, Oded Padon, Shmuel Sagiv, Sharon Shoham
VMCAI5
2017 Conjunctive Abstract Interpretation Using Paramodulation
Or Ozeri, Oded Padon, Noam Rinetzky, Shmuel Sagiv
VMCAI4
2017 Paxos made EPR: decidable reasoning about distributed protocols
abstract
Distributed protocols such as Paxos play an important role in many computer systems. Therefore, a bug in a distributed protocol may have tremendous effects. Accordingly, a lot of effort has been invested in verifying such protocols. However, checking invariants of such protocols is undecidable and hard in practice, as it requires reasoning about an unbounded number of nodes and messages. Moreover, protocol actions and invariants involve both quantifier alternations and higher-order concepts such as set cardinalities and arithmetic. This paper makes a step towards automatic verification of such protocols. We aim at a technique that can verify correct protocols and identify bugs in incorrect protocols. To this end, we develop a methodology for deductive verification based on effectively propositional logic (EPR)—a decidable fragment of first-order logic (also known as the Bernays-Schönfinkel-Ramsey class). In addition to decidability, EPR also enjoys the finite model property, allowing to display violations as finite structures which are intuitive for users. Our methodology involves modeling protocols using general (uninterpreted) first-order logic, and then systematically transforming the model to obtain a model and an inductive invariant that are decidable to check. The steps of the transformations are also mechanically checked, ensuring the soundness of the method. We have used our methodology to verify the safety of Paxos, and several of its variants, including Multi-Paxos, Vertical Paxos, Fast Paxos, Flexible Paxos and Stoppable Paxos. To the best of our knowledge, this work is the first to verify these protocols using a decidable logic, and the first formal verification of Vertical Paxos, Fast Paxos and Stoppable Paxos.
Oded Padon, Giuliano Losa, Shmuel Sagiv, Sharon Shoham
Proc. ACM Program. Lang.3
2017 Synthesis of circular compositional program proofs via abduction
Isil Dillig, Thomas Dillig, Boyang Li 0002, Kenneth L. McMillan, Shmuel Sagiv
Int. J. Softw. Tools Technol. Transf.5
2016 Simple Invariants for Proving the Safety of Distributed Protocols (Invited Talk)
abstract
Safety of a distributed protocol means that the protocol never reaches a bad state, e.g., a state where two nodes become leaders in a leader-election protocol. Proving safety is obviously undecidable since such protocols are run by an unbounded number of nodes, and their safety needs to be established for any number of nodes. I will describe a deductive approach for proving safety, based on the concept of universally quantified inductive invariants—an adaptation of the mathematical concept of induction to the domain of programs. In the deductive approach, the programmer specifies a candidate inductive invariant and the system automatically checks if it is inductive. By restricting the invariants to be universally quantified, this approach can be effectively implemented with a SAT solver. This is a joint work with Ken McMillan (Microsoft Research), Oded Padon (Tel Aviv University), Aurojit Panda (UC Berkeley), and Sharon Shoham (Tel Aviv University) and was integrated into the IVY system. The work is inspired by Shachar Itzhaky's thesis.
Shmuel Sagiv
FSTTCS1
2016 Ivy: safety verification by interactive generalization
abstract
Despite several decades of research, the problem of formal verification of infinite-state systems has resisted effective automation. We describe a system --- Ivy --- for interactively verifying safety of infinite-state systems. Ivy's key principle is that whenever verification fails, Ivy graphically displays a concrete counterexample to induction. The user then interactively guides generalization from this counterexample. This process continues until an inductive invariant is found. Ivy searches for universally quantified invariants, and uses a restricted modeling language. This ensures that all verification conditions can be checked algorithmically. All user interactions are performed using graphical models, easing the user's task. We describe our initial experience with verifying several distributed protocols.
Oded Padon, Kenneth L. McMillan, Aurojit Panda, Shmuel Sagiv, Sharon Shoham
PLDI4
2016 Decidability of inferring inductive invariants
abstract
Induction is a successful approach for verification of hardware and software systems. A common practice is to model a system using logical formulas, and then use a decision procedure to verify that some logical formula is an inductive safety invariant for the system. A key ingredient in this approach is coming up with the inductive invariant, which is known as invariant inference. This is a major difficulty, and it is often left for humans or addressed by sound but incomplete abstract interpretation. This paper is motivated by the problem of inductive invariants in shape analysis and in distributed protocols. This paper approaches the general problem of inferring first-order inductive invariants by restricting the language L of candidate invariants. Notice that the problem of invariant inference in a restricted language L differs from the safety problem, since a system may be safe and still not have any inductive invariant in L that proves safety. Clearly, if L is finite (and if testing an inductive invariant is decidable), then inferring invariants in L is decidable. This paper presents some interesting cases when inferring inductive invariants in L is decidable even when L is an infinite language of universal formulas. Decidability is obtained by restricting L and defining a suitable well-quasi-order on the state space. We also present some undecidability results that show that our restrictions are necessary. We further present a framework for systematically constructing infinite languages while keeping the invariant inference problem decidable. We illustrate our approach by showing the decidability of inferring invariants for programs manipulating linked-lists, and for distributed protocols.
Oded Padon, Neil Immerman, Sharon Shoham, Aleksandr Karbyshev, Shmuel Sagiv
POPL5
2016 Some Complexity Results for Stateful Network Verification
Yaron Velner, Kalev Alpernas, Aurojit Panda, Alexander Moshe Rabinovich, Shmuel Sagiv, Scott Shenker, Sharon Shoham
TACAS5
2015 Composing concurrency control
abstract
Concurrency control poses significant challenges when composing computations over multiple data-structures (objects) with different concurrency-control implementations. We formalize the usually desired requirements (serializability, abort-safety, deadlock-safety, and opacity) as well as stronger versions of these properties that enable composition. We show how to compose protocols satisfying these properties so that the resulting combined protocol also satisfies these properties. Our approach generalizes well-known protocols (such as two-phase-locking and two-phase-commit) and leads to new protocols. We apply this theory to show how we can safely compose optimistic and pessimistic concurrency control. For example, we show how we can execute a transaction that accesses two objects, one controlled by an STM and another by locking.
Ofri Ziv, Alex Aiken, Guy Golan-Gueta, G. Ramalingam, Shmuel Sagiv
PLDI5
2015 Decentralizing SDN Policies
abstract
Software-defined networking (SDN) is a new paradigm for operating and managing computer networks. SDN enables logically-centralized control over network devices through a "controller" --- software that operates independently of the network hardware. Network operators can run both in-house and third-party SDN programs on top of the controller, e.g., to specify routing and access control policies.
Oded Padon, Neil Immerman, Aleksandr Karbyshev, Ori Lahav 0001, Shmuel Sagiv, Sharon Shoham
POPL5
2015 Automatic scalable atomicity via semantic locking
abstract
In this paper, we consider concurrent programs in which the shared state consists of instances of linearizable ADTs (abstract data types). We present an automated approach to concurrency control that addresses a common need: the need to atomically execute a code fragment, which may contain multiple ADT operations on multiple ADT instances. We present a synthesis algorithm that automatically enforces atomicity of given code fragments (in a client program) by inserting pessimistic synchronization that guarantees atomicity and deadlock-freedom (without using any rollback mechanism). Our algorithm takes a commutativity specification as an extra input. This specification indicates for every pair of ADT operations the conditions under which the operations commute. Our algorithm enables greater parallelism by permitting commuting operations to execute concurrently. We have implemented the synthesis algorithm in a Java compiler, and applied it to several Java programs. Our results show that our approach produces efficient and scalable synchronization.
Guy Golan-Gueta, G. Ramalingam, Shmuel Sagiv, Eran Yahav
PPoPP3
2015 Modularity in Lattices: A Case Study on the Correspondence Between Top-Down and Bottom-Up Analysis
Ghila Castelnuovo, Mayur Naik, Noam Rinetzky, Shmuel Sagiv, Hongseok Yang
SAS4
2014 Property-Directed Shape Analysis
Shachar Itzhaky, Nikolaj S. Bjørner, Thomas W. Reps, Shmuel Sagiv, Aditya V. Thakur
CAV4
2014 Checking Linearizability of Encapsulated Extended Operations
Oren Zomer, Guy Golan-Gueta, G. Ramalingam, Shmuel Sagiv
ESOP4
2014 Verifying atomicity via data independence
abstract
We present a technique for automatically verifying atomicity of composed concurrent operations. The main observation behind our approach is that many composed concurrent operations which occur in practice are data-independent. That is, the control-flow of the composed operation does not depend on specific input values. While verifying data-independence is undecidable in the general case, we provide succint sufficient conditions that can be used to establish a composed operation as data-independent. We show that for the common case of concurrent maps, data-independence reduces the hard problem of verifying linearizability to a verification problem that can be solved efficiently with a bounded number of keys and values. We implemented our approach in a tool called VINE and evaluated it on all composed operations from 57 real-world applications (112 composed operations). We show that many composed operations (49 out of 112) are data-independent, and automatically verify 30 of them as linearizable and the rest 19 as having violations of linearizability that could be repaired and then subsequently automatically verified. Moreover, we show that the remaining 63 operations are not linearizable, thus indicating that data independence does not limit the expressiveness of writing realistic linearizable composed operations.
Ohad Shacham, Eran Yahav, Guy Golan-Gueta, Alex Aiken, Nathan Bronson, Shmuel Sagiv, Martin T. Vechev
ISSTA6
2014 VeriCon: towards verifying controller programs in software-defined networks
abstract
Software-defined networking (SDN) is a new paradigm for operating and managing computer networks. SDN enables logically-centralized control over network devices through a "controller" software that operates independently from the network hardware, and can be viewed as the network operating system. Network operators can run both inhouse and third-party SDN programs (often called applications) on top of the controller, e.g., to specify routing and access control policies. SDN opens up the possibility of applying formal methods to prove the correctness of computer networks. Indeed, recently much effort has been invested in applying finite state model checking to check that SDN programs behave correctly. However, in general, scaling these methods to large networks is challenging and, moreover, they cannot guarantee the absence of errors.
Thomas Ball 0001, Nikolaj S. Bjørner, Aaron Gember, Shachar Itzhaky, Aleksandr Karbyshev, Shmuel Sagiv, Michael Schapira, Asaf Valadarsky
PLDI6
2014 Modular reasoning about heap paths via effectively propositional formulas
abstract
First order logic with transitive closure, and separation logic enable elegant interactive verification of heap-manipulating programs. However, undecidabilty results and high asymptotic complexity of checking validity preclude complete automatic verification of such programs, even when loop invariants and procedure contracts are specified as formulas in these logics. This paper tackles the problem of procedure-modular verification of reachability properties of heap-manipulating programs using efficient decision procedures that are complete: that is, a SAT solver must generate a counterexample whenever a program does not satisfy its specification. By (a) requiring each procedure modifies a fixed set of heap partitions and creates a bounded amount of heap sharing, and (b) restricting program contracts and loop invariants to use only deterministic paths in the heap, we show that heap reachability updates can be described in a simple manner. The restrictions force program specifications and verification conditions to lie within a fragment of first-order logic with transitive closure that is reducible to effectively propositional logic, and hence facilitate sound, complete and efficient verification. We implemented a tool atop Z3 and report on preliminary experiments that establish the correctness of several programs that manipulate linked data structures.
Shachar Itzhaky, Anindya Banerjee 0001, Neil Immerman, Ori Lahav 0001, Aleksandar Nanevski, Shmuel Sagiv
POPL6
2014 Automatic semantic locking
abstract
In this paper, we consider concurrent programs in which the shared state consists of instances of linearizable ADTs (abstract data types). We develop a novel automated approach to concurrency control that addresses a common need: the need to atomically execute a code fragment, which may contain multiple ADT operations on multiple ADT instances. In our approach, each ADT implements ADT-specific semantic locking operations that serve to exploit the semantics of ADT operations. We develop a synthesis algorithm that automatically inserts calls to these locking operations in a set of given code fragments (in a client program) to ensure that these code fragments execute atomically without deadlocks, and without rollbacks.
Guy Golan-Gueta, G. Ramalingam, Shmuel Sagiv, Eran Yahav
PPoPP3
2013 Effectively-Propositional Reasoning about Reachability in Linked Data Structures
Shachar Itzhaky, Anindya Banerjee 0001, Neil Immerman, Aleksandar Nanevski, Shmuel Sagiv
CAV5
2013 Solving Geometry Problems Using a Combination of Symbolic and Numerical Reasoning
Shachar Itzhaky, Sumit Gulwani, Neil Immerman, Shmuel Sagiv
LPAR4
2013 Turning nondeterminism into parallelism
abstract
Nondeterminism is a useful and prevalent concept in the design and implementation of software systems. An important property of nondeterminism is its latent parallelism: A nondeterministic action can evaluate to multiple behaviors. If at least one of these behaviors does not conflict with concurrent tasks, then there is an admissible execution of the action in parallel with these tasks. Unfortunately, existing implementations of the atomic paradigm - optimistic as well as pessimistic - are unable to fully exhaust the parallelism potential of nondeterministic actions, lacking the means to guide concurrent tasks toward nondeterministic choices that minimize interference.
Omer Tripp, Eric Koskinen, Shmuel Sagiv
OOPSLA3
2013 Concurrent libraries with foresight
abstract
Linearizable libraries provide operations that appear to execute atomically. Clients, however, may need to execute a sequence of operations (a composite operation) atomically. We consider the problem of extending a linearizable library to support arbitrary atomic composite operations by clients. We introduce a novel approach in which the concurrent library ensures atomicity of composite operations by exploiting information (foresight) provided by its clients. We use a correctness condition, based on a notion of dynamic right-movers, that guarantees that composite operations execute atomically without deadlocks, and without using rollbacks.
Guy Golan-Gueta, G. Ramalingam, Shmuel Sagiv, Eran Yahav
PLDI3
2013 Synthesis of Circular Compositional Program Proofs via Abduction
Boyang Li 0002, Isil Dillig, Thomas Dillig, Kenneth L. McMillan, Shmuel Sagiv
TACAS5
2012 Eventually Consistent Transactions
Sebastian Burckhardt, Daan Leijen, Manuel Fähndrich, Shmuel Sagiv
ESOP4
2012 Reasoning about Lock Placements
Peter Hawkins, Alex Aiken, Kathleen Fisher, Martin C. Rinard, Shmuel Sagiv
ESOP5
2012 Understanding the behavior of database operations under program control
abstract
Applications that combine general program logic with persistent databases (e.g., three-tier applications) often suffer large performance penalties from poor use of the database. We introduce a program analysis technique that combines information flow in the program with commutativity analysis of its database operations to produce a unified dependency graph for database statements, which provides programmers with a high-level view of how costly database operations are and how they are connected in the program. As an example application of our analysis we describe three optimizations that can be discovered by examining the structure of the dependency graph; each helps remove communication latency from the critical path of a multi-tier system. We implement our technique in a tool for Java applications using JDBC and experimentally validate it using the multi-tier component of the Dacapo benchmark.
Juan M. Tamayo, Alex Aiken, Nathan Bronson, Shmuel Sagiv
OOPSLA4
2012 Concurrent data representation synthesis
abstract
We describe an approach for synthesizing data representations for concurrent programs. Our compiler takes as input a program written using concurrent relations and synthesizes a representation of the relations as sets of cooperating data structures as well as the placement and acquisition of locks to synchronize concurrent access to those data structures. The resulting code is correct by construction: individual relational operations are implemented correctly and the aggregate set of operations is serializable and deadlock free. The relational specification also permits a high-level optimizer to choose the best performing of many possible legal data representations and locking strategies, which we demonstrate with an experiment autotuning a graph benchmark.
Peter Hawkins, Alex Aiken, Kathleen Fisher, Martin C. Rinard, Shmuel Sagiv
PLDI5
2012 JANUS: exploiting parallelism via hindsight
abstract
This paper addresses the problem of reducing unnecessary conflicts in optimistic synchronization. Optimistic synchronization must ensure that any two concurrently executing transactions that commit are properly synchronized. Conflict detection is an approximate check for this condition. For efficiency, the traditional approach to conflict detection conservatively checks that the memory locations mutually accessed by two concurrent transactions are accessed only for reading.
Omer Tripp, Roman Manevich, John Field, Shmuel Sagiv
PLDI4
2012 Abstractions from tests
abstract
We present a framework for leveraging dynamic analysis to find good abstractions for static analysis. A static analysis in our framework is parametrised. Our main insight is to directly and efficiently compute from a concrete trace, a necessary condition on the parameter configurations to prove a given query, and thereby prune the space of parameter configurations that the static analysis must consider. We provide constructive algorithms for two instance analyses in our framework: a flow- and context-sensitive thread-escape analysis and a flow- and context-insensitive points-to analysis. We show the efficacy of these analyses, and our approach, on six Java programs comprising two million bytecodes: the thread-escape analysis resolves 80% of queries on average, disproving 28% and proving 52%; the points-to analysis resolves 99% of queries on average, disproving 29% and proving 70%.
Mayur Naik, Hongseok Yang, Ghila Castelnuovo, Shmuel Sagiv
POPL4
2011 Automatic fine-grain locking using shape properties
abstract
We present a technique for automatically adding fine-grain locking to an abstract data type that is implemented using a dynamic forest -i.e., the data structures may be mutated, even to the point of violating forestness temporarily during the execution of a method of the ADT. Our automatic technique is based on Domination Locking, a novel locking protocol. Domination locking is designed specifically for software concurrency control, and in particular is designed for object-oriented software with destructive pointer updates. Domination locking is a strict generalization of existing locking protocols for dynamically changing graphs. We show our technique can successfully add fine-grain locking to libraries where manually performing locking is extremely challenging. We show that automatic fine-grain locking is more efficient than coarse-grain locking, and obtains similar performance to hand-crafted fine-grain locking.
Guy Golan-Gueta, Nathan Bronson, Alex Aiken, G. Ramalingam, Shmuel Sagiv, Eran Yahav
OOPSLA5
2011 Testing atomicity of composed concurrent operations
abstract
We address the problem of testing atomicity of composed concurrent operations. Concurrent libraries help programmers exploit parallel hardware by providing scalable concurrent operations with the illusion that each operation is executed atomically. However, client code often needs to compose atomic operations in such a way that the resulting composite operation is also atomic while preserving scalability. We present a novel technique for testing the atomicity of client code composing scalable concurrent operations. The challenge in testing this kind of client code is that a bug may occur very rarely and only on a particular interleaving with a specific thread configuration. Our technique is based on modular testing of client code in the presence of an adversarial environment; we use commutativity specifications to drastically reduce the number of executions explored to detect a bug. We implemented our approach in a tool called COLT, and evaluated its effectiveness on a range of 51 real-world concurrent Java programs. Using COLT, we found 56 atomicity violations in Apache Tomcat, Cassandra, MyFaces Trinidad, and other applications.
Ohad Shacham, Nathan Bronson, Alex Aiken, Shmuel Sagiv, Martin T. Vechev, Eran Yahav
OOPSLA4
2011 HAWKEYE: effective discovery of dataflow impediments to parallelization
abstract
Parallelization transformations are an important vehicle for improving the performance and scalability of a software system. Utilizing concurrency requires that the developer first identify a suitable parallelization scope: one that poses as a performance bottleneck, and at the same time, exhibits considerable available parallelism. However, having identified a candidate scope, the developer still needs to ensure the correctness of the transformation. This is a difficult undertaking, where a major source of complication lies in tracking down sequential dependencies that inhibit parallelization and addressing them.
Omer Tripp, Greta Yorsh, John Field, Shmuel Sagiv
OOPSLA4
2011 Precise and compact modular procedure summaries for heap manipulating programs
abstract
We present a strictly bottom-up, summary-based, and precise heap analysis targeted for program verification that performs strong updates to heap locations at call sites. We first present a theory of heap decompositions that forms the basis of our approach; we then describe a full analysis algorithm that is fully symbolic and efficient. We demonstrate the precision and scalability of our approach for verification of real C and C++ programs.
Isil Dillig, Thomas Dillig, Alex Aiken, Shmuel Sagiv
PLDI4
2011 Data representation synthesis
abstract
We consider the problem of specifying combinations of data structures with complex sharing in a manner that is both declarative and results in provably correct code. In our approach, abstract data types are specified using relational algebra and functional dependencies. We describe a language of decompositions that permit the user to specify different concrete representations for relations, and show that operations on concrete representations soundly implement their relational specification. It is easy to incorporate data representations synthesized by our compiler into existing systems, leading to code that is simpler, correct by construction, and comparable in performance to the code it replaces.
Peter Hawkins, Alex Aiken, Kathleen Fisher, Martin C. Rinard, Shmuel Sagiv
PLDI5
2010 Data Structure Fusion
Peter Hawkins, Alex Aiken, Kathleen Fisher, Martin C. Rinard, Shmuel Sagiv
APLAS5
2010 Specifying and verifying sparse matrix codes
abstract
Sparse matrix formats are typically implemented with low-level imperative programs. The optimized nature of these implementations hides the structural organization of the sparse format and complicates its verification. We define a variable-free functional language (LL) in which even advanced formats can be expressed naturally, as a pipeline-style composition of smaller construction steps. We translate LL programs to Isabelle/HOL and describe a proof system based on parametric predicates for tracking relationship between mathematical vectors and their concrete representations. This proof theory automatically verifies full functional correctness of many formats. We show that it is reusable and extensible to hierarchical sparse formats.
Gilad Arnold, Johannes Hölzl, Ali Sinan Köksal, Rastislav Bodík, Shmuel Sagiv
ICFP5
2010 A simple inductive synthesis methodology and its applications
abstract
Given a high-level specification and a low-level programming language, our goal is to automatically synthesize an efficient program that meets the specification. In this paper, we present a new algorithmic methodology for inductive synthesis that allows us to do this.
Shachar Itzhaky, Sumit Gulwani, Neil Immerman, Shmuel Sagiv
OOPSLA4
2010 A dynamic evaluation of the precision of static heap abstractions
abstract
The quality of a static analysis of heap-manipulating programs is largely determined by its heap abstraction. Object allocation sites are a commonly-used abstraction, but are too coarse for some clients. The goal of this paper is to investigate how various refinements of allocation sites can improve precision. In particular, we consider abstractions that use call stack, object recency, and heap connectivity information. We measure the precision of these abstractions dynamically for four different clients motivated by concurrency and on nine Java programs chosen from the DaCapo benchmark suite. Our dynamic results shed new light on aspects of heap abstractions that matter for precision, which allows us to more effectively navigate the large space of possible heap abstractions
Percy Liang, Omer Tripp, Mayur Naik, Shmuel Sagiv
OOPSLA4
2010 Statically Inferring Complex Heap, Array, and Numeric Invariants
Bill McCloskey, Thomas W. Reps, Shmuel Sagiv
SAS3
2010 Field-sensitive program dependence analysis
abstract
Statement st transitively depends on statement stseed if the execution of stseed may affect the execution of st. Computing transitive program dependences is a fundamental operation in many automatic software analysis tools. Existing tools find it challenging to compute transitive dependences for programs manipulating large aggregate structure variables, and their limitations adversely affect analysis of certain important classes of software systems, e.g., large-scale enterprise resource planning (ERP) systems.
Shay Litvak, Nurit Dor, Rastislav Bodík, Noam Rinetzky, Shmuel Sagiv
SIGSOFT FSE5
2010 Decidable fragments of many-sorted logic
Aharon Abadi, Alexander Moshe Rabinovich, Shmuel Sagiv
J. Symb. Comput.3
2010 A relational approach to interprocedural shape analysis
abstract
This article addresses the verification of properties of imperative programs with recursive procedure calls, heap-allocated storage, and destructive updating of pointer-valued fields, that is, interprocedural shape analysis . The article makes three contributions. — It introduces a new method for abstracting relations over memory configurations for use in abstract interpretation. — It shows how this method furnishes the elements needed for a compositional approach to shape analysis. In particular, abstracted relations are used to represent the shape transformation performed by a sequence of operations, and an overapproximation to relational composition can be performed using the meet operation of the domain of abstracted relations. — It applies these ideas in a new algorithm for context-sensitive interprocedural shape analysis. The algorithm creates procedure summaries using abstracted relations over memory configurations, and the meet-based composition operation provides a way to apply the summary transformer for a procedure P at each call site from which P is called. The algorithm has been applied successfully to establish properties of both (i) recursive programs that manipulate lists and (ii) recursive programs that manipulate binary trees.
Bertrand Jeannet, Alexey Loginov, Thomas W. Reps, Shmuel Sagiv
ACM Trans. Program. Lang. Syst.4
2010 Finite differencing of logical formulas for static analysis
abstract
This article concerns mechanisms for maintaining the value of an instrumentation relation (also known as a derived relation or view ), defined via a logical formula over core relations, in response to changes in the values of the core relations. It presents an algorithm for transforming the instrumentation relation's defining formula into a relation-maintenance formula that captures what the instrumentation relation's new value should be. The algorithm runs in time linear in the size of the defining formula. The technique applies to program analysis problems in which the semantics of statements is expressed using logical formulas that describe changes to core relation values. It provides a way to obtain values of the instrumentation relations that reflect the changes in core relation values produced by executing a given statement. We present experimental evidence that our technique is an effective one: for a variety of benchmarks, the relation-maintenance formulas produced automatically using our approach yield the same precision as the best available hand-crafted ones.
Thomas W. Reps, Shmuel Sagiv, Alexey Loginov
ACM Trans. Program. Lang. Syst.2
2010 Verifying safety properties of concurrent heap-manipulating programs
abstract
We provide a parametric framework for verifying safety properties of concurrent heap-manipulating programs. The framework combines thread-scheduling information with information about the shape of the heap. This leads to verification algorithms that are more precise than existing techniques. The framework also provides a precise shape-analysis algorithm for concurrent programs. In contrast to most existing verification techniques, we do not put a bound on the number of allocated objects. The framework produces interesting results even when analyzing programs with an unbounded number of threads. The framework is applied to successfully verify the following properties of a concurrent program: —Concurrent manipulation of linked-list based ADT preserves the ADT datatype invariant. —The program does not perform inconsistent updates due to interference. —The program does not reach a deadlock. —The program does not produce runtime errors due to illegal thread interactions. We also found bugs in erroneous programs violating such properties. A prototype of our framework has been implemented and applied to small, but interesting, example programs.
Eran Yahav, Shmuel Sagiv
ACM Trans. Program. Lang. Syst.2
2009 Abstract Transformers for Thread Correlation Analysis
Michal Segalov, Tal Lev-Ami, Roman Manevich, G. Ramalingam, Shmuel Sagiv
APLAS5
2009 Generalizing DPLL to Richer Logics
Kenneth L. McMillan, Andreas Kuehlmann, Shmuel Sagiv
CAV3
2009 A combination framework for tracking partition sizes
abstract
We describe an abstract interpretation based framework for proving relationships between sizes of memory partitions. Instances of this framework can prove traditional properties such as memory safety and program termination but can also establish upper bounds on usage of dynamically allocated memory. Our framework also stands out in its ability to prove properties of programs manipulating both heap and arrays which is considered a difficult task. Technically, we define an abstract domain that is parameterized by an abstract domain for tracking memory partitions (sets of memory locations) and by a numerical abstract domain for tracking relationships between cardinalities of the partitions. We describe algorithms to construct the transfer functions for the abstract domain in terms of the corresponding transfer functions of the parameterized abstract domains. A prototype of the framework was implemented and used to prove interesting properties of realistic programs, including programs that could not have been automatically analyzed before.
Sumit Gulwani, Tal Lev-Ami, Shmuel Sagiv
POPL3
2009 Thread-Modular Shape Analysis
Shmuel Sagiv
VMCAI1
2009 Self-stabilization preserving compiler
abstract
Self-stabilization is an elegant approach for designing fault tolerant systems. A system is considered self-stabilizing if, starting in any state, it converges to the desired behavior. Self-stabilizing algorithms were designed for solving fundamental distributed tasks, such as leader election, token circulation and communication network protocols. The algorithms were expressed using guarded commands or pseudo-code. The realization of these algorithms requires the existence of a (self-stabilizing) infrastructure such as a self-stabilizing microprocessor and a self-stabilizing operating system for their execution. Moreover, the high-level description of the algorithms needs to be converted into machine language of the microprocessor. In this article, we present our design for a self-stabilization preserving compiler. The compiler we designed and implemented transforms programs written in a language similar to the abstract state machine (ASM). The compiler preserves the stabilization property of the high level program.
Shlomi Dolev, Yinnon A. Haviv, Shmuel Sagiv
ACM Trans. Program. Lang. Syst.3
2008 Thread Quantification for Concurrent Shape Analysis
Josh Berdine, Tal Lev-Ami, Roman Manevich, G. Ramalingam, Shmuel Sagiv
CAV5
2008 Proving Conditional Termination
Byron Cook, Sumit Gulwani, Tal Lev-Ami, Andrey Rybalchenko, Shmuel Sagiv
CAV5
2008 Ranking Abstractions
Aziem Chawdhary, Byron Cook, Sumit Gulwani, Shmuel Sagiv, Hongseok Yang
ESOP4
2008 Customization change impact analysis for erp professionals via program slicing
abstract
We describe a new tool that automatically identifies impact of customization changes, i.e., how changes affect software behavior. As opposed to existing static analysis tools that aim at aiding programmers or improve performance, our tool is designed for end-users without prior knowledge in programming. We utilize state-of-the-art static analysis algorithms for the programs within an Enterprise Resource Planning system (ERP). Key challenges in analyzing real world ERP programs are their significant size and the interdependency between programs. In particular, we describe and compare three customization change impact analyses for real-world programs, and a balancing algorithm built upon the three independent analyses. This paper presents PanayaImpactAnalysis (PanayaIA), a web on-demand tool, providing ERP professionals a clear view of the impact of a customization change on the system. In addition we report empirical results of PanayaIA when used by end-users on an ERP system of tens of millions LOCs.
Nurit Dor, Tal Lev-Ami, Shay Litvak, Shmuel Sagiv, Dror Weiss
ISSTA4
2008 Heap Decomposition for Concurrent Shape Analysis
Roman Manevich, Tal Lev-Ami, Shmuel Sagiv, G. Ramalingam, Josh Berdine
SAS3
2008 On the complexity of partially-flow-sensitive alias analysis
abstract
We introduce the notion of apartially-flow-sensitive analysis based on the number of read and write operations that are guaranteed to be analyzed in a sequential manner. We study the complexity of partially-flow-sensitive alias analysis and show that precise alias analysis with a very limited flow-sensitivity is as hard as precise flow-sensitive alias analysis, both when dynamic memory allocation is allowed, as well as in the absence of dynamic memory allocation.
Noam Rinetzky, G. Ramalingam, Shmuel Sagiv, Eran Yahav
ACM Trans. Program. Lang. Syst.3
2007 Local Reasoning for Storable Locks and Threads
Alexey Gotsman, Josh Berdine, Byron Cook, Noam Rinetzky, Shmuel Sagiv
APLAS5
2007 Labelled Clauses
Tal Lev-Ami, Christoph Weidenbach, Thomas W. Reps, Shmuel Sagiv
CADE4
2007 Comparison Under Abstraction for Verifying Linearizability
Daphna Amit, Noam Rinetzky, Thomas W. Reps, Shmuel Sagiv, Eran Yahav
CAV4
2007 Leaping Loops in the Presence of Abstraction
Thomas Ball 0001, Orna Kupferman, Shmuel Sagiv
CAV3
2007 Revamping TVLA: Making Parametric Shape Analysis Competitive
Igor Bogudlov, Tal Lev-Ami, Thomas W. Reps, Shmuel Sagiv
CAV4
2007 Modular Shape Analysis for Dynamically Encapsulated Programs
Noam Rinetzky, Arnd Poetzsch-Heffter, G. Ramalingam, Shmuel Sagiv, Eran Yahav
ESOP4
2007 Decidable Fragments of Many-Sorted Logic
Aharon Abadi, Alexander Moshe Rabinovich, Shmuel Sagiv
LPAR3
2007 Thread-modular shape analysis
abstract
We present the first shape analysis for multithreaded programs that avoids the explicit enumeration of execution-interleavings. Our approach is to automatically infer a resource invariant associated with each lock that describes the part of the heap protected by the lock. This allows us to use a sequential shape analysis on each thread. We show that resource invariants of a certain class can be characterized as least fixed points and computed via repeated applications of shape analysis only on each individual thread. Based on this approach, we have implemented a thread-modular shape analysis tool and applied it to concurrent heap-manipulating code from Windows device drivers.
Alexey Gotsman, Josh Berdine, Byron Cook, Shmuel Sagiv
PLDI4
2007 Shape Analysis by Graph Decomposition
Roman Manevich, Josh Berdine, Byron Cook, G. Ramalingam, Shmuel Sagiv
TACAS5
2007 Constructing Specialized Shape Analyses for Uniform Change
Tal Lev-Ami, Shmuel Sagiv, Neil Immerman, Thomas W. Reps
VMCAI2
2007 Scaling model checking of dataraces using dynamic information
Ohad Shacham, Shmuel Sagiv, Assaf Schuster
J. Parallel Distributed Comput.2
2007 Logical characterizations of heap abstractions
abstract
Shape analysis concerns the problem of determining “shape invariants” for programs that perform destructive updating on dynamically allocated storage. In recent work, we have shown how shape analysis can be performed using an abstract interpretation based on three-valued first-order logic. In that work, concrete stores are finite two-valued logical structures, and the sets of stores that can possibly arise during execution are represented (conservatively) using a certain family of finite three-valued logical structures. In this article, we show how three-valued structures that arise in shape analysis can be characterized using formulas in first-order logic with transitive closure. We also define a nonstandard (“supervaluational”) semantics for three-valued first-order logic that is more precise than a conventional three-valued semantics, and demonstrate that the supervaluational semantics can be implemented using existing theorem provers.
Greta Yorsh, Thomas W. Reps, Shmuel Sagiv, Reinhard Wilhelm
ACM Trans. Comput. Log.3
2007 Introduction to special ESOP'05 issue
abstract
No abstract available.
Shmuel Sagiv
ACM Trans. Program. Lang. Syst.1
2006 Abstraction for Shape Analysis with Fast and Precise Transformers
Tal Lev-Ami, Neil Immerman, Shmuel Sagiv
CAV3
2006 A Logic of Reachable Patterns in Linked Data-Structures
Greta Yorsh, Alexander Moshe Rabinovich, Shmuel Sagiv, Antoine Meyer, Ahmed Bouajjani
FoSSaCS3
2006 Testing, abstraction, theorem proving: better together!
abstract
We present a method for static program analysis that leverages tests and concrete program executions. State abstractions generalize the set of program states obtained from concrete executions. A theorem prover then checks that the generalized set of concrete states covers all potential executions and satisfies additional safety properties. Our method finds the same potential errors as the mostprecise abstract interpreter for a given abstraction and is potentially more efficient. Additionally, it provides a new way to tune the performance of the analysis by alternating between concrete execution and theorem proving. We have implemented our technique in a prototype for checking properties of C# programs.
Greta Yorsh, Thomas Ball 0001, Shmuel Sagiv
ISSTA3
2006 Automated Verification of the Deutsch-Schorr-Waite Tree-Traversal Algorithm
Alexey Loginov, Thomas W. Reps, Shmuel Sagiv
SAS3
2006 Combining Shape Analyses by Intersecting Abstractions
Gilad Arnold, Roman Manevich, Shmuel Sagiv, Ran Shaham
VMCAI3
2006 Install-Time Vaccination of Windows Executables to Defend against Stack Smashing Attacks
abstract
Stack smashing is still one of the most popular techniques for computer system attack. In this work, we present an anti-stack-smashing defense technique for Microsoft Windows systems. Our approach works at install-time, and does not rely on having access to the source-code: The user decides when and which executables to vaccinate. Our technique consists of instrumenting a given executable with a mechanism to detect stack smashing attacks. We developed a prototype implementing our technique and verified that it successfully defends against actual exploit code. We then extended our prototype to vaccinate DLLs, multithreaded applications, and DLLs used by multithreaded applications, which present significant additional complications. We present promising performance results measured on SPEC2000 benchmarks: Vaccinated executables were no more than 8 percent slower than their un-vaccinated originals.
Danny Nebenzahl, Shmuel Sagiv, Avishai Wool
IEEE Trans. Dependable Secur. Comput.2
2005 Simulating Reachability Using First-Order Logic with Applications to Verification of Linked Data Structures
Tal Lev-Ami, Neil Immerman, Thomas W. Reps, Shmuel Sagiv, Siddharth Srivastava 0001, Greta Yorsh
CADE4
2005 Abstraction Refinement via Inductive Learning
Alexey Loginov, Thomas W. Reps, Shmuel Sagiv
CAV3
2005 Optimizing C Multithreaded Memory Management Using Thread-Local Storage
Yair Sade, Shmuel Sagiv, Ran Shaham
CC2
2005 A framework for numeric analysis of array operations
abstract
Automatic discovery of relationships among values of array elements is a challenging problem due to the unbounded nature of arrays. We present a framework for analyzing array operations that is capable of capturing numeric properties of array elements.In particular, the analysis is able to establish that all array elements are initialized by an array-initialization loop, as well as to discover numeric constraints on the values of initialized elements.The analysis is based on the combination of canonical abstraction and summarizing numeric domains. We describe a prototype implementation of the analysis and discuss our experience with applying the prototype to several examples, including the verification of correctness of an insertion-sort procedure.
Denis Gopan, Thomas W. Reps, Shmuel Sagiv
POPL3
2005 A semantics for procedure local heaps and its abstractions
abstract
The goal of this work is to develop compile-time algorithms for automatically verifying properties of imperative programs that manipulate dynamically allocated storage. The paper presents an analysis method that uses a characterization of a procedure's behavior in which parts of the heap not relevant to the procedure are ignored. The paper has two main parts: The first part introduces a non-standard concrete semantics, LSL, in which called procedures are only passed parts of the heap. In this semantics, objects are treated specially when they separate the "local heap" that can be mutated by a procedure from the rest of the heap, which---from the viewpoint of that procedure---is non-accessible and immutable. The second part concerns abstract interpretation of LSL and develops a new static-analysis algorithm using canonical abstraction.
Noam Rinetzky, Jörg Kreiker, Thomas W. Reps, Shmuel Sagiv, Reinhard Wilhelm
POPL4
2005 Scaling model checking of dataraces using dynamic information
abstract
Dataraces in multithreaded programs often indicate severe bugs and can cause unexpected behaviors when different thread interleavings are executed. Because dataraces are a cause for concern, many works have dealt with the problem of detecting them. Works based on dynamic techniques either report errors only for dataraces that occur in the current interleaving, which limits their usefulness, or produce many spurious dataraces. Works based on model checking search exhaustively for dataraces and thus can reveal even those that occur in rarely executed paths. However, the applicability of model checking is limited because the large number of thread interleavings in realistic multithreaded programs causes state space explosion. In this work, we combine the two techniques in a hybrid scheme which overcomes these difficulties and enjoys the advantages of both worlds. Our hybrid technique succeeds in providing thread interleavings that prove the existence of dataraces in realistic programs. The programs we experimented with cannot be checked using either an ordinary industrial strength model checker or bounded model checking.
Ohad Shacham, Shmuel Sagiv, Assaf Schuster
PPoPP2
2005 Interprocedural Shape Analysis for Cutpoint-Free Programs
Noam Rinetzky, Shmuel Sagiv, Eran Yahav
SAS2
2005 Predicate Abstraction and Canonical Abstraction for Singly-Linked Lists
Roman Manevich, Eran Yahav, G. Ramalingam, Shmuel Sagiv
VMCAI4
2005 Establishing local temporal heap safety properties with applications to compile-time memory management
Ran Shaham, Eran Yahav, Elliot K. Kolodner, Shmuel Sagiv
Sci. Comput. Program.4
2004 Verification via Structure Simulation
Neil Immerman, Alexander Moshe Rabinovich, Thomas W. Reps, Shmuel Sagiv, Greta Yorsh
CAV4
2004 Static Program Analysis via 3-Valued Logic
Thomas W. Reps, Shmuel Sagiv, Reinhard Wilhelm
CAV2
2004 A Relational Approach to Interprocedural Shape Analysis
Bertrand Jeannet, Alexey Loginov, Thomas W. Reps, Shmuel Sagiv
SAS4
2004 Partially Disjunctive Heap Abstraction
Roman Manevich, Shmuel Sagiv, G. Ramalingam, John Field
SAS2
2004 Numeric Domains with Summarized Dimensions
Denis Gopan, Frank DiMaio, Nurit Dor, Thomas W. Reps, Shmuel Sagiv
TACAS5
2004 Symbolically Computing Most-Precise Abstract Operations for Shape Analysis
Greta Yorsh, Thomas W. Reps, Shmuel Sagiv
TACAS3
2004 Symbolic Implementation of the Best Transformer
Thomas W. Reps, Shmuel Sagiv, Greta Yorsh
VMCAI2
2004 On the Expressive Power of Canonical Abstraction
Shmuel Sagiv
VMCAI1
2003 Finite Differencing of Logical Formulas for Static Analysis
Thomas W. Reps, Shmuel Sagiv, Alexey Loginov
ESOP2
2003 Verifying Temporal Heap Properties Specified via Evolution Logic
Eran Yahav, Thomas W. Reps, Shmuel Sagiv, Reinhard Wilhelm
ESOP3
2003 CSSV: towards a realistic tool for statically detecting all buffer overflows in C
Nurit Dor, Michael Rodeh, Shmuel Sagiv
PLDI3
2003 Establishing Local Temporal Heap Safety Properties with Applications to Compile-Time Memory Management
Ran Shaham, Eran Yahav, Elliot K. Kolodner, Shmuel Sagiv
SAS4
2002 Online Subpath Profiling
David Oren, Yossi Matias, Shmuel Sagiv
CC3
2002 Semantic Minimization of 3-Valued Propositional Formulae
abstract
This paper presents an algorithm for a non-standard logic-minimization problem that arises in 3-valued propositional logic. The problem is motivated by the potential for obtaining better answers in applications that use 3-valued logic. An answer of 0 or 1 provides precise (definite) information; an answer of 1/2 provides imprecise (indefinite) information. By replacing a formula /spl phi/ with a "better" formula /spl psi/, we may improve the precision of the answers obtained. In this paper we give an algorithm that always produces a formula that is "best" (in a certain well-defined sense).
Thomas W. Reps, Alexey Loginov, Shmuel Sagiv
LICS3
2002 Deriving Specialized Program Analyses for Certifying Component-Client Conformance
abstract
We are concerned with the problem of statically certifying (verifying) whether the client of a software component conforms to the component's constraints for correct usage. We show how conformance certification can be efficiently carried out in a staged fashion for certain classes of first-order safety (FOS) specifications, which can express relationship requirements among potentially unbounded collections of runtime objects. In the first stage of the certification process, we systematically derive an abstraction that is used to model the component state during analysis of arbitrary clients. In general, the derived abstraction will utilize first-order predicates, rather than the propositions often used by model checkers. In the second stage, the generated abstraction is incorporated into a static analysis engine to produce a certifier. In the final stage, the resulting certifier is applied to a client to conservatively determine whether the client violates the component's constraints. Unlike verification approaches that analyze a specification and client code together, our technique can take advantage of computationally-intensive symbolic techniques during the abstraction generation phase, without affecting the performance of client analysis. Using as a running example the Concurrent Modification Problem (CMP), which arises when certain classes defined by the Java Collections Framework are misused, we describe several different classes of certifiers with varying time/space/precision tradeoffs. Of particular note are precise, polynomial-time, flow- and context-sensitive certifiers for certain classes of FOS specifications and client programs. Finally, we evaluate a prototype implementation of a certifier for CMP on a variety of test programs. The results of the evaluation show that our approach, though conservative, yields very few "false alarms," with acceptable performance.
G. Ramalingam, Alex Varshavsky, John Field, Deepak Goyal, Shmuel Sagiv
PLDI5
2002 Compactly Representing First-Order Structures for Static Analysis
Roman Manevich, G. Ramalingam, John Field, Deepak Goyal, Shmuel Sagiv
SAS5
2002 Parametric shape analysis via 3-valued logic
abstract
Shape analysis concerns the problem of determining "shape invariants" for programs that perform destructive updating on dynamically allocated storage. This article presents a parametric framework for shape analysis that can be instantiated in different ways to create different shape-analysis algorithms that provide varying degrees of efficiency and precision. A key innovation of the work is that the stores that can possibly arise during execution are represented (conservatively) using 3-valued logical structures. The framework is instantiated in different ways by varying the predicates used in the 3-valued logic. The class of programs to which a given instantiation of the framework can be applied is not limited a priori (i.e., as in some work on shape analysis, to programs that manipulate only lists, trees, DAGS, etc.); each instantiation of the framework can be applied to any program, but may produce imprecise results (albeit conservative ones) due to the set of predicates employed.
Shmuel Sagiv, Thomas W. Reps, Reinhard Wilhelm
ACM Trans. Program. Lang. Syst.1
2001 Interprocedural Shape Analysis for Recursive Programs
Noam Rinetzky, Shmuel Sagiv
CC2
2001 Heap Profiling for Space-Efficient Java
abstract
We present a heap-profiling tool for exploring the potential for space savings in Java programs. The output of the tool is used to direct rewriting of application source code in a way that allows more timely garbage collection (GC) of objects, thus saving space. The rewriting can also avoid allocating some objects that are never used.
Ran Shaham, Elliot K. Kolodner, Shmuel Sagiv
PLDI3
2001 Cleanness Checking of String Manipulations in C Programs via Integer Analysis
Nurit Dor, Michael Rodeh, Shmuel Sagiv
SAS3
2001 Kleene's Logic with Equality
Flemming Nielson, Hanne Riis Nielson, Shmuel Sagiv
Inf. Process. Lett.3
2000 Automatic Removal of Array Memory Leaks in Java
Ran Shaham, Elliot K. Kolodner, Shmuel Sagiv
CC3
2000 Shape Analysis
Reinhard Wilhelm, Shmuel Sagiv, Thomas W. Reps
CC2
2000 A Kleene Analysis of Mobile Ambients
Flemming Nielson, Hanne Riis Nielson, Shmuel Sagiv
ESOP3
2000 Putting static analysis to work for verification: A case study
abstract
A method for finding bugs in code is presented. For given small numbers j and k, the code of a procedure is translated into a rela-tional formula whose models represent all execution traces that involve at most j heap cells and k loop iterations. This formula is conjoined with the negation of the procedure's specification. The models of the resulting formula, obtained using a constraint solver, are counterexamples: executions of the code that violate the specification.
Tal Lev-Ami, Thomas W. Reps, Shmuel Sagiv, Reinhard Wilhelm
ISSTA3
2000 On the Effectiveness of GC in Java
abstract
We study the effectiveness of garbage collection (GC) algorithms by measuring the time difference between the actual collection time of an object and the potential earliest collection time for that object. Our ultimate goal is to use this study in order to develop static analysis techniques that can be used together with GC to allow earlier reclamation of objects. The results may also be used to pinpoint application source code that could be rewritten in a way that would allow more timely GC.
Ran Shaham, Elliot K. Kolodner, Shmuel Sagiv
ISMM3
2000 Checking Cleanness in Linked Lists
Nurit Dor, Michael Rodeh, Shmuel Sagiv
SAS3
2000 TVLA: A System for Implementing Static Analyses
Tal Lev-Ami, Shmuel Sagiv
SAS2
1999 A Decidable Logic for Describing Linked Data Structures
Michael Benedikt, Thomas W. Reps, Shmuel Sagiv
ESOP3
1999 Parametric Shape Analysis via 3-Valued Logic
abstract
We present a family of abstract-interpretation algorithms that are capable of determining "shape invariants" of programs that perform destructive updating on dynamically allocated storage. The main idea is to represent the stores that can possibly arise during execution using three-valued logical structures.
Shmuel Sagiv, Thomas W. Reps, Reinhard Wilhelm
POPL1
1999 Finding Circular Attributes in Attribute Grammars
abstract
The problem of finding the circular attributes in an grammar is considered. Two algorithms are proposed: the first is polynomial but yields conservative results while the second is exact but is potentially expontial. It is also shown that finding the circular attributes is harder than testing circularity.
Michael Rodeh, Shmuel Sagiv
J. ACM2
1998 Building a Bridge between Pointer Aliases and Program Dependences
John L. Ross, Shmuel Sagiv
ESOP2
1998 Detecting Memory Errors via Static Pointer Analysis (Preliminary Experience)
abstract
Programs which manipulate pointers are hard to debug. Pointer analysis algorithms (originally aimed at optimizing compilers) may provide some remedy by identifying potential errors such as dereferencing NULL pointers by statically analyzing the behavior of programs on all their input data. Our goal is to identify the "core program analysis techniques" that can be used when developing realistic tools which detect memory errors at compile time without generating too many false alarms. Our preliminary experience indicates that the following techniques are necessary: (i) finding aliases between pointers, (ii) flow sensitive techniques that account for the program control flow constructs, (iii) partial interpretation of conditional statements, (iv) analysis of the relationships between pointers, and sometimes (v) analysis of the underlying data structures manipulated by the C program. We show that a combination of these techniques can yield better results than those achieved by state of the...
Nurit Dor, Michael Rodeh, Shmuel Sagiv
PASTE3
1998 Edge Profiling versus Path Profiling: The Showdown
abstract
Edge profiles are the traditional control flow profile of choice for profile-directed compilation. They have been the basis of path-based optimizations that select paths, even though edge profiles contain strictly less information than path profiles. Recent work on path profiling has suggested that path profiles are superior to edge profiles in practice.We present theoretic and algorithmic results that may be used to determine when an edge profile is a good predictor of hot paths (and what those hot paths are) and when it is a poor predictor. Our algorithms efficiently compute sets of definitely and potentially hot paths in a graph annotated with an edge profile. A definitely hot path has a frequency greater than some non-zero lower bound in all path profiles that induce a given edge profile.Experiments on the SPEC95 benchmarks show that a huge percentage of the execution frequency in these programs is dominated by definitely hot paths (on average, 84% for FORTRAN benchmarks and 76% for C benchmarks). We also show that various hot path selection algorithms based on edge profiles work extremely well in most cases, but that path profiling is needed in some cases. These results indicate the usefulness of our algorithms for characterizing edge profiles and selecting hot paths.
Thomas Ball 0001, Peter Mataga, Shmuel Sagiv
POPL3
1998 A Logic-Based Approach to Program Flow Analysis
Shmuel Sagiv, Nissim Francez, Michael Rodeh, Reinhard Wilhelm
Acta Informatica1
1998 Solving Shape-Analysis Problems in Languages with Destructive Updating
abstract
This article concerns the static analysis of programs that perform destructive updating on heap-allocated storage. We give an algorithm that uses finite shape graphs to approximate conservatively the possible “shapes” that heap-allocated structures in a program can take on. For certain programs, our technique is able to determine such properties as (1) when the input to the program is a list, the output is also a list and (2) when the input to the program is a tree, the output is also a tree. For example, the method can determine that “listness” is preserved by (1) a program that performs list reversal via destructive updating of the input list and (2) a program that searches a list and splices a new element into the list. None of the previously known methods that use graphs to model the program's store are capable of determining that “listness” is preserved on these examples (or examples of similar complexity). In contrast with most previous work, our shape analysis algorithm is even accurate for certain programs that update cyclic data structures; that is, it is sometimes able to show that when the input to the program is a circular list, the output is also a circular list. For example, the shape-analysis algorithm can determine that an insertion into a circular list preserves “circular listness.”
Shmuel Sagiv, Thomas W. Reps, Reinhard Wilhelm
ACM Trans. Program. Lang. Syst.1
1996 Solving Shape-Analysis Problems in Languages with Destructive Updating
abstract
This paper concerns the static analysis of programs that perform destructive updating on heap-allocated storage. We give an algorithm that conservatively solves this problem by using a finite shape-graph to approximate the possible "shapes" that heap-allocated structures in a program can take on. In contrast with previous work, our method is even accurate for certain programs that update cyclic data structures. For example, our method can determine that when the input to a program that searches a list and splices in a new element is a possibly circular list, the output is a possibly circular list.
Shmuel Sagiv, Thomas W. Reps, Reinhard Wilhelm
POPL1
1996 Precise Interprocedural Dataflow Analysis with Applications to Constant Propagation
Shmuel Sagiv, Thomas W. Reps, Susan Horwitz
Theor. Comput. Sci.1
1995 Precise Interprocedural Dataflow Analysis via Graph Reachability
abstract
The paper shows how a large class of interprocedural dataflow-analysis problems can be solved precisely in polynomial time by transforming them into a special kind of graph-reachability problem. The only restrictions are that the set of dataflow facts must be a finite set, and that the dataflow functions must distribute over the confluence operator (either union or intersection). This class of probable problems includes—but is not limited to—the classical separable problems (also known as “gen/kill” or “bit-vector” problems)—e.g., reaching definitions, available expressions, and live variables. In addition, the class of problems that our techniques handle includes many non-separable problems, including truly-live variables, copy constant propagation, and possibly-uninitialized variables.
Thomas W. Reps, Susan Horwitz, Shmuel Sagiv
POPL3
1995 Demand Interprocedural Dataflow Analysis
abstract
article Demand interprocedural dataflow analysis Share on Authors: Susan Horwitz Computer Sciences Department, Univ. of Wisconsin, 1210 W. Dayton Street, Madison, WI Computer Sciences Department, Univ. of Wisconsin, 1210 W. Dayton Street, Madison, WIView Profile , Thomas Reps Computer Sciences Department, Univ. of Wisconsin, 1210 W. Dayton Street, Madison, WI Computer Sciences Department, Univ. of Wisconsin, 1210 W. Dayton Street, Madison, WIView Profile , Mooly Sagiv Computer Sciences Department, Univ. of Wisconsin, 1210 W. Dayton Street, Madison, WI and IBM Scientific Center, Haifa, Israel Computer Sciences Department, Univ. of Wisconsin, 1210 W. Dayton Street, Madison, WI and IBM Scientific Center, Haifa, IsraelView Profile Authors Info & Claims ACM SIGSOFT Software Engineering NotesVolume 20Issue 4Oct. 1995 pp 104–115https://doi.org/10.1145/222132.222146Online:01 October 1995Publication History 150citation853DownloadsMetricsTotal Citations150Total Downloads853Last 12 Months37Last 6 weeks1 Get Citation AlertsNew Citation Alert added!This alert has been successfully added and will be sent to:You will be notified whenever a record that you have chosen has been cited.To manage your alert preferences, click on the button below.Manage my AlertsNew Citation Alert!Please log in to your account Save to BinderSave to BinderCreate a New BinderNameCancelCreateExport CitationPublisher SiteGet Access
Susan Horwitz, Thomas W. Reps, Shmuel Sagiv
SIGSOFT FSE3
1994 Speeding up Slicing
abstract
Program slicing is a fundamental operation for many software engineering tools. Currently, the most efficient algorithm for interprocedural slicing is one that uses a program representation called the system dependence graph. This paper defines a new algorithm for slicing with system dependence graphs that is asymptotically faster than the previous one. A preliminary experimental study indicates that the new algorithm is also significantly faster in practice, providing roughly a 6-fold speedup on examples of 348 to 757 lines.
Thomas W. Reps, Susan Horwitz, Shmuel Sagiv, Genevieve Rosay
SIGSOFT FSE3
1992 Proving Safety of Speculative Load Instructions at Compile Time
David Bernstein, Michael Rodeh, Shmuel Sagiv
ESOP3
1989 Resolving Circularity in Attribute Grammars with Applications to Data Flow Analysis
abstract
Circular attribute grammars appear in many data flow analysis problems. As one way of making the notion useful, an automatic translation of circular attribute grammars to equivalent non-circular attribute grammars is presented. It is shown that for circular attribute grammars that arise in many data flow analysis problems, the translation does not increase the asymptotic complexity of the semantic equations. Therefore, the translation may be used in conjunction with any evaluator generator to automate the development of efficient data flow analysis algorithms. As a result, the integration of such algorithms with other parts of a compiler becomes easier.
Shmuel Sagiv, Orit Edelstein, Nissim Francez, Michael Rodeh
POPL1