Giter VIP home page Giter VIP logo

durin's Introduction

Durin

Durin ("Dependent Unboxed higher-oRder Intermediate Notation", inspired by Thorin) is an optimizing functional intermediate representation and compiler backend. Unlike other IRs, Durin is dependently typed, because it's a simple way to express rich polymorphism. As Thorin is higher-order in order to optimize first-class functions, Durin is dependently typed in order to optimize polymorphism.

With dependent types, partial inlining (the primary transformation in Thorin) is monomorphization. So, Durin monomorphizes as an optimization, in the same way and using the same heuristics as inlining.

Durin currently has a basic LLVM backend, and supports passing things around unboxed as much as possible. Since it's dependently typed, it actually passes around types at runtime (as sizes, like Sixten), so a polymorphic function can work with, for example, unboxed arrays of any type without needing monomorphization, boxing, or extra information in values. It will figure out what needs to be boxed (and how much - some things need to be boxed but don't need GC) after monomorphization and inlining (once they're implemented), so it should be able to box as little as possible.

Durin is designed as the backend for Pika, but it should work with other typed functional languages as well.

durin's People

Contributors

naalit avatar

Stargazers

Boxiu Lee avatar Paul deGrandis avatar  avatar Mark Barbone avatar Amir M. Saeid avatar Andrejs Agejevs avatar Nikita avatar Brendan Zabarauskas avatar Albert ten Napel avatar Alcides Fonseca avatar  avatar jadon avatar Moritz Göckel avatar

Watchers

James Cloos avatar Albert ten Napel avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.