Skip to main content

Overloading Is NP-Complete

A Tutorial Dedicated to Dexter Kozen

  • Chapter

Part of the Lecture Notes in Computer Science book series (LNPSE,volume 7230)

Abstract

We show that overloading is NP-complete. This solves exercise 6.25 in the 1986 version of the Dragon book.

Keywords

  • Constraint System
  • 3SAT Problem
  • Type Rule
  • Type Inference
  • Type Environment

These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

This is a preview of subscription content, access via your institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (Canada)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   39.99
Price excludes VAT (Canada)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   54.99
Price excludes VAT (Canada)
  • Compact, lightweight 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

Learn about institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Aho, A.V., Sethi, R.I., Ullman, J.D.: Compilers: Principles, Techniques, and Tools, 2nd edn. Addison-Wesley, Reading (1986)

    Google Scholar 

  2. Camarao, C., Figueiredo, L., Vasconcellos, C.: Constraint-set satisfiability for overloading. In: Proceedings of PPDP (2004)

    Google Scholar 

  3. Cardelli, L., Wegner, P.: On understanding types, data abstraction, and polymorphism. ACM Computing Surveys 17(4), 471–522 (1985)

    CrossRef  Google Scholar 

  4. Castagna, G., Ghelli, G., Longo, G.: A calculus for overloaded functions with subtyping. Information and Computation 117(1), 115–135 (1995)

    CrossRef  MathSciNet  MATH  Google Scholar 

  5. Coppo, M., Dezani-Ciancaglini, M., Venneri, B.: Principal type schemes and lambda-calculus semantics. In: Seldin, J., Hindley, J. (eds.) To H. B. Curry: Essays on Combinatory Logic, Lambda Calculus and Formalism, pp. 535–560. Academic Press (1980)

    Google Scholar 

  6. Garey, M.R., Johnson, D.S.: Computers and Intractability. Freeman (1979)

    Google Scholar 

  7. Gosling, J., Joy, B., Steele, G., Bracha, G.: Java Language Specification. 3rd edn. (2005), http://java.sun.com/docs/books/jls/third_edition/html/classes.html#8.4.9

  8. Higham, D.J., Higham, N.J.: MATLAB Guide. 2nd edn. SIAM (2005)

    Google Scholar 

  9. Roger Hindley, J.: Types with intersection: An introduction. Formal Aspects of Computing 4, 470–486 (1991)

    CrossRef  Google Scholar 

  10. Kozen, D., Palsberg, J., Schwartzbach, M.I.: Efficient inference of partial types. Journal of Computer and System Sciences 49(2), 306–324 (1994); Preliminary version in Proceedings of FOCS 1992

    CrossRef  MathSciNet  MATH  Google Scholar 

  11. Mathaikutty, D.A., Shukla, S.K.: Metamodeling-Driven IP Reuse for SoC Integration and Microprocessor Design. Artech House (2009)

    Google Scholar 

  12. MathWorks. Product documentation, matlab compiler (2011), http://www.mathworks.com/help/techdoc/matlab_prog/f2-38133.html

  13. Paterson, M.S., Wegman, M.N.: Linear unification. Journal of Computer and System Sciences 16, 158–167 (1978)

    CrossRef  MathSciNet  MATH  Google Scholar 

  14. Schaefer, T.J.: The complexity of satisfiability problems. In: Proceedings of the 10th Annual ACM Symposium on Theory of Computing (STOC 1995), pp. 216–226 (1978)

    Google Scholar 

  15. Smith, G.: Polymorphic Type Inference for Languages with Overloading and Subtyping. PhD thesis, Cornell University (1991)

    Google Scholar 

  16. Smith, G.S.: Principal type schemes for functional programs with overloading and subtyping. Science of Computer Programming 23, 197–226 (1994)

    CrossRef  MathSciNet  MATH  Google Scholar 

  17. Vachharajani, M., Vachharajani, N., Malik, S., August, D.I.: Facilitating reuse in hardware models with enhanced type inference. In: Proceedings of IEEE/ACM/IFIP Second International Conference on Hardware/Software Codesign and System Synthesis (1994)

    Google Scholar 

  18. Volpano, D.: Haskell-style overloading is NP-hard. In: Proceedings of ICCL 1994, Fifth IEEE International Conference on Computer Languages, pp. 88–95 (May 1994)

    Google Scholar 

  19. Volpano, D.: Lower bounds on type checking overloading. Information Processing Letters 57, 9–14 (1996)

    CrossRef  MathSciNet  MATH  Google Scholar 

  20. Volpano, D., Smith, G.: On the Complexity of ML Typability with Overloading. In: Hughes, J. (ed.) FPCA 1991. LNCS, vol. 523, pp. 15–28. Springer, Heidelberg (1991)

    CrossRef  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and Permissions

Copyright information

© 2012 Springer-Verlag Berlin Heidelberg

About this chapter

Cite this chapter

Palsberg, J. (2012). Overloading Is NP-Complete. In: Constable, R.L., Silva, A. (eds) Logic and Program Semantics. Lecture Notes in Computer Science, vol 7230. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-29485-3_13

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-29485-3_13

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-29484-6

  • Online ISBN: 978-3-642-29485-3

  • eBook Packages: Computer ScienceComputer Science (R0)