skip to main content
research-article

Energy types

Published:19 October 2012Publication History
Skip Abstract Section

Abstract

This paper presents a novel type system to promote and facilitate energy-aware programming. Energy Types is built upon a key insight into today's energy-efficient systems and applications: despite the popular perception that energy and power can only be described in joules and watts, real-world energy management is often based on discrete phases and modes, which in turn can be reasoned about by type systems very effectively. A phase characterizes a distinct pattern of program workload, and a mode represents an energy state the program is expected to execute in. This paper describes a programming model where phases and modes can be intuitively specified by programmers or inferred by the compiler as type information. It demonstrates how a type-based approach to reasoning about phases and modes can help promote energy efficiency. The soundness of our type system and the invariants related to inter-phase and inter-mode interactions are rigorously proved. Energy Types is implemented as the core of a prototyped object-oriented language ET for smartphone programming. Preliminary studies show ET can lead to significant energy savings for Android Apps.

References

  1. http://developer.android.com.Google ScholarGoogle Scholar
  2. M. Abadi, L. Cardelli, B. Pierce, and G. Plotkin. Dynamic typing in a statically-typed language. In POPL '89: Proceedings of the 16th ACM SIGPLAN-SIGACT symposium on Principles of programming languages, pages 213--227, 1989. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Alexander Aiken, Edward L. Wimmers, and T. K. Lakshman. Soft typing with conditional types. In POPL '94: Proceedings of the 21st ACM SIGPLAN-SIGACT symposium on Principles of programming languages, pages 163--173, 1994. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Woongki Baek and Trishul M. Chilimbi. Green: a framework for supporting energy-conscious programming using controlled approximation. In PLDI '10: Proceedings of the 2010 ACM SIGPLAN conference on Programming language design and implementation, pages 198--209, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Paul Barham, Boris Dragovic, Keir Fraser, Steven Hand, Tim Harris, Alex Ho, Rolf Neugebauer, Ian Pratt, and Andrew Warfield. Xen and the art of virtualization. In Proceedings of the nineteenth ACM symposium on Operating systems principles, SOSP '03, pages 164--177, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Michael Carbin, Deokhwan Kim, Sasa Misailovic, and Mar-tin C. Rinard. Proving acceptability properties of relaxed non-deterministic approximate programs. In PLDI, pages 169--180, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Anantha P. Chandrakasan, Samuel Sheng, and Robert W. Brodersen. Low power cmos digital design. IEEE Journal of Solid State Circuits, 27:473--484, 1992.Google ScholarGoogle ScholarCross RefCross Ref
  8. Ashutosh S. Dhodapkar and James E. Smith. Managing multi-configuration hardware via dynamic working set analysis. In ISCA '02: Proceedings of the 29th annual international symposium on Computer architecture, pages 233--244, Washington, DC, USA, 2002. IEEE Computer Society. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Carla Schlatter Ellis. The case for higher-level power manage-ment. In HOTOS '99: Proceedings of the The Seventh Work-shop on Hot Topics in Operating Systems, page 162, Washing-ton, DC, USA, 1999. IEEE Computer Society. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Hadi Esmaeilzadeh, Adrian Sampson, Luis Ceze, and Doug Burger. Architecture support for disciplined approximate programming. In ASPLOS'12, pages 301--312, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Michael Furr, Jong-hoon (David) An, and Jeffrey S. Foster. Profile-guided static typing for dynamic scripting languages. In OOPSLA '09: Proceeding of the 24th ACM SIGPLAN conference on Object oriented programming systems languages and applications, pages 283--300, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. JanHoffmann, Klaus Aehlig, andMartinHofmann. Multivari-ate amortized resource analysis. In POPL '11, pages 357--370, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Chung-Hsing Hsu and Ulrich Kremer. The design, implementation, and evaluation of a compiler algorithm for cpu energy reduction. In PLDI '03: Proceedings of the ACM SIGPLAN 2003 conference on Programming language design and implementation, pages 38-48, New York, NY, USA, 2003. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. Atsushi Igarashi, Benjamin Pierce, and Philip Wadler. Featherweight java - a minimal core calculus for java and gj. In TOPLAS, pages 132--146, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Atsushi Igarashi and Mirko Viroli. Variant parametric types: A flexible subtyping scheme for generics. TOPLAS, 28(5):795--847, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. Canturk Isci, Gilberto Contreras, and Margaret Martonosi. Live, runtime phasemonitoring and prediction on real systems with application to dynamic power management. In MICRO 39: Proceedings of the 39th Annual IEEE/ACM International Symposium on Microarchitecture, pages 359--370, Washington, DC, USA, 2006. IEEE Computer Society. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. Canturk Isci and Margaret Martonosi. Identifying program power phase behavior using power vectors. In Workshop on Workload Characterization, 2003.Google ScholarGoogle ScholarCross RefCross Ref
  18. M. Kandemir, N. Vijaykrishnan, M. J. Irwin, and W. Ye. Influence of compiler optimizations on system power. In DAC '00: Proceedings of the 37th Annual Design Automation Conference, pages 304--307, New York, NY, USA, 2000. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. Stefanos Kaxiras and Margaret Martonosi. Computer Architecture Techniques for Power-Efficiency. Morgan and Clay-pool Publishers, 1st edition, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Kenneth Knowles and Cormac Flanagan. Hybrid type checking. ACM Trans. Program. Lang. Syst., 32(2):1--34, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Song Liu, Karthik Pattabiraman, Thomas Moscibroda, and Benjamin G. Zorn. Flikker: saving dram refresh-power through critical data partitioning. In ASPLOS, pages 213--224, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. Yung-Hsiang Lu, Luca Benini, and Giovanni De Micheli. Requester-aware power reduction. In Proceedings of the International Symposium on System Synthesis, pages 18--24, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Grigorios Magklis, Michael L. Scott, Greg Semeraro, David H. Albonesi, and Steven Dropsho. Profile-based dynamic voltage and frequency scaling for a multiple clock do-main microprocessor. In ISCA '03, pages 14--27, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. Geoffrey Mainland, Greg Morrisett, and Matt Welsh. Flask: staged functional programming for sensor networks. In ICFP '08: Proceeding of the 13th ACMSIGPLAN international conference on Functional programming, pages 335--346, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. Ana Milanova, Atanas Rountev, and Barbara G. Ryder. Parameterized object sensitivity for points-to analysis for java. TOSEM, 14:1--41, January 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. Sasa Misailovic, Stelios Sidiroglou, Henry Hoffmann, and Martin Rinard. Quality of service profiling. In ICSE '10: Proceedings of the 32nd ACM/IEEE International Conference on Software Engineering, pages 25--34, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. James Noble, John Potter, and Jan Vitek. Flexible alias protection. In ECOOP'98, Brussels, Belgium, July 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. Nathaniel Nystrom, Michael R. Clarkson, and Andrew C. Myers. Polyglot: An extensible compiler framework for java. In CC'03, pages 138--152, April 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. Trevor Pering, Tom Burd, and Robert Brodersen. The simulation and evaluation of dynamic voltage scaling algorithms. In ISLPED '98: Proceedings of the 1998 international symposium on Low power electronics and design, pages 76--81, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. A. Sampson, W. Dietl, E. Fortuna, D. Gnanapragasam, L. Ceze, and D. Grossman. EnerJ: Approximate Data Types for Safe and General Low-Power Computation. In Programming Language Design and Implementation (PLDI), June 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. Timothy Sherwood, Suleyman Sair, and Brad Calder. Phase tracking and prediction. In ISCA '03: Proceedings of the 30th annual international symposium on Computer architecture, pages 336--349, New York, NY, USA, 2003. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. Jeremy Siek and Walid Taha. Gradual typing for objects. In ECOOP '07: Proceedings of the 21st European conference on ECOOP 2007, pages 2-27, Berlin, Heidelberg, 2007. Springer-Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. V. Silva. Pro Android Games. Apress Series. Apress, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. Jacob Sorber, Alexander Kostadinov, Matthew Garber, Matthew Brennan, Mark D. Corner, and Emery D. Berger. Eon: a language and runtime system for perpetual systems. In SenSys '07: Proceedings of the 5th international conference on Embedded networked sensor systems, pages 161--174, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. Ching-Long Su and Alvin M. Despain. Cache design trade-offs for power and performance optimization: a case study. In ISLPED '95: Proceedings of the 1995 international symposium on Low power design, pages 63--68, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  36. Mads Tofte and Jean-Pierre Talpin. Region-based memory management. Information and Computation, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  37. Energy Types. http://www.cs.binghamton.edu/~davidL/et/.Google ScholarGoogle Scholar
  38. Mark Weiser, Brent Welch, Alan Demers, and Scott Shenker. Scheduling for reduced cpu energy. In OSDI '94: Proceedings of the 1st USENIX conference on Operating Systems Design and Implementation, page 2, Berkeley, CA, USA, 1994. USENIX Association. Google ScholarGoogle ScholarDigital LibraryDigital Library
  39. Qiang Wu, Philo Juang, Margaret Martonosi, and Douglas W. Clark. Formal online methods for voltage/frequency control in multiple clock domain microprocessors. In ASPLOS-XI, pages 248--259, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  40. Fen Xie, Margaret Martonosi, and Sharad Malik. Compile-time dynamic voltage scaling settings: opportunities and limits. In PLDI '03: Proceedings of the ACM SIGPLAN 2003 conference on Programming language design and implementation, pages 49--62, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  41. Steve Zdancewic and Andrew C. Myers. Robust declassification. In Proc. IEEE Computer Security Foundations Workshop, pages 15-23. IEEE Computer Society Press, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Energy types

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in

      Full Access

      • Published in

        cover image ACM SIGPLAN Notices
        ACM SIGPLAN Notices  Volume 47, Issue 10
        OOPSLA '12
        October 2012
        1011 pages
        ISSN:0362-1340
        EISSN:1558-1160
        DOI:10.1145/2398857
        Issue’s Table of Contents
        • cover image ACM Conferences
          OOPSLA '12: Proceedings of the ACM international conference on Object oriented programming systems languages and applications
          October 2012
          1052 pages
          ISBN:9781450315616
          DOI:10.1145/2384616

        Copyright © 2012 ACM

        Publisher

        Association for Computing Machinery

        New York, NY, United States

        Publication History

        • Published: 19 October 2012

        Check for updates

        Qualifiers

        • research-article

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader
      About Cookies On This Site

      We use cookies to ensure that we give you the best experience on our website.

      Learn more

      Got it!