Giter Club home page Giter Club logo

sisal-is's Introduction

Modernized Sisal Interpreter (MSInt) Build Status

Sisal with type inference and indent structuring!

Current status: early alpha (some programs work but test coverage is very low)

How does it look like

The main difference between ordinary Sisal and this version that is does not require types to be explicitly specified and uses indents instead of end function stuff:

  conv = f(m, a, n, x)
    for i in [1..n-m+1]
    returns array of for j in [1..m]
        returns sum of a[j] * x[i+j-1]

  main = f(m, cycles)
    let
      a = for i in [1.. m] returns array of i
      x = for i in [1.. m * cycles] returns array of i
    in
      conv( m, a, m * cycles, x )

Please read language overview if you want to know more.

A set of test programs with results is available here. More complex examples are here.

Supported constraints

  • f (function)
  • let in
  • if elseif else
  • for in
  • for while
  • for repeat
  • arithmetics + - * / %

Standard reductions

  • sum, product, array, stream, last, max, min

Deployment

to setup:

npm install

or

make setup

to run tests:

make test

to compile:

make compile

to run sisal program:

node ./build/sisal.js <program.sis>

to output computation graph in graphML format:

node ./build/sisal.js <program.sis> --graph

for example:

node ./build/sisal.js ./test/programs/if.sis --graph

Feedback

Please, feel free to create issue or make contribution to this software!

sisal-is's People

Contributors

parsifal-47 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

sisal-is's Issues

Excess input ports

Source Code:

Main = f(M)
  let
    a = 0
    b = 0
  in
    a, b

Error: there is only function parameter and IR1 image shows that there three input ports.

Some comparison with Scala?

I was a 1990's user of SISAL for dataflow-machine simulators... But I can't remember. In nowadays I am using Scala, that have similar features and is so popular. There are some document with some comparisons?


Example of similar constructions to be compared: FFT 2D, Scala and SISAL.
PS: looking for simple cases; a complete and optimized Scala implementation is not simple.

Excess edges

Source Code:

Main = f(M)
  let
    A = 1
  in
    A + A

Error:
These edges are excess.

<edge source="n0" target="n0::n1" sourceport="in1" targetport="in0" />
<edge source="n0" target="n0::n1" sourceport="in1" targetport="in1" />

Port names

It is useful to know port's kind (for complex nodes)

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.