Nothing Special   »   [go: up one dir, main page]

Skip to main content

Liveness

  • Chapter
  • First Online:
SSA-based Compiler Design

Abstract

The role of liveness analysis is to determine, for all variables, the set of program points where these variables are live, i.e., where their values are potentially used by subsequent operations. For strict SSA form programs, the live range of a variable has valuable properties that can be expressed in terms of the loop nesting forest of the CFG and its corresponding directed acyclic graph, the forward-CFG. A direct consequence of this property is the possible design of a data-flow algorithm that, as opposed to standard approaches, computes liveness sets without the requirement of any iteration to reach a fixed point: at most, two passes over the CFG are necessary. Another application of this property is the design of a simple liveness check algorithm, which in contrast to classical data-flow analysis, does not provide the set of variables live at a block, but provides a query system to answer questions such as “Is variable v live at location q?” After detailing the aforementioned property, this chapter illustrates how the use of strict SSA can both simplify and accelerate liveness analysis. For this purpose, several liveness set and liveness check algorithms are provided.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Subscribe and save

Springer+ Basic
$34.99 /Month
  • Get 10 units per month
  • Download Article/Chapter or eBook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

eBook
USD 15.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 15.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info
Hardcover Book
USD 119.99
Price excludes VAT (USA)
  • Durable hardcover edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Similar content being viewed by others

References

  1. Aho, A. V., Sethi, R., & Ullman, J. D. (1986). Compilers: Principles, techniques, and tools. Addison-Wesley series in computer science/World student series edition.

    Google Scholar 

  2. Janssen, J., & Corporaal, H. (1997). Making graphs reducible with controlled node splitting. ACM Transactions on Programming Language and Systems, 19, 1031–1052.

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Fabrice Rastello .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2022 The Author(s), under exclusive license to Springer Nature Switzerland AG

About this chapter

Check for updates. Verify currency and authenticity via CrossMark

Cite this chapter

Boissinot, B., Rastello, F. (2022). Liveness. In: Rastello, F., Bouchez Tichadou, F. (eds) SSA-based Compiler Design. Springer, Cham. https://doi.org/10.1007/978-3-030-80515-9_9

Download citation

  • DOI: https://doi.org/10.1007/978-3-030-80515-9_9

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-030-80514-2

  • Online ISBN: 978-3-030-80515-9

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics