GithubHelp home page GithubHelp logo

Performance about wist HOT 5 CLOSED

willowtreeapps avatar willowtreeapps commented on August 17, 2024
Performance

from wist.

Comments (5)

nishtahir avatar nishtahir commented on August 17, 2024

Thanks for sharing your feedback. We have been experiencing similar performance issues as well although not quite as bad as what you are seeing.

A roughly 500 line *.brs takes 12.06s on a similar Macbook pro.

The root cause seems to be mostly associated with the antlr JS runtime just being much slower than other platforms or possibly some optimizations we can make in the grammar

antlr/antlr4#1540

One option I plan on investigating is to compile the grammar for a C++ target and cross compile it to a wasm module as mentioned here

antlr/antlr4#1375

Any thoughts? @vannuysm

from wist.

cdthompson avatar cdthompson commented on August 17, 2024

I did the minimum to get emscripten solution parsing, but didn't incorporate the listeners for linting rules. It brought the time for my above test case down to 2s but seems there's a lot of work to expose the listeners across the C++/JS boundary. For now I'm going to focus on using wist in a CI environment exclusively, then perhaps later come back to helping improve this. I'll leave this issue open and let you both decide whether to track it or close.

from wist.

nishtahir avatar nishtahir commented on August 17, 2024

I did mostly the same thing here. My results were similar to yours with ~1.5s to parse a 1000 line*.brs file. I'm currently in the process of writing a wrapper around the generated ANTLR AST so we can plugin the rules engine.

from wist.

nishtahir avatar nishtahir commented on August 17, 2024

So far we have some parts of wist ported over to use emscripten. i've created a branch experimental/web-assembly-parser for this.

from wist.

cdthompson avatar cdthompson commented on August 17, 2024

Thanks for this effort

from wist.

Related Issues (20)

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.