Giter Site home page Giter Site logo

lean-4-hackers's People

Contributors

agentultra avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar

Forkers

chadbrewbaker

lean-4-hackers's Issues

Measuring lean overhead?

The Lean4 version is about 10x slower than BSD wc on Apple Silicon. I will have to dig in tomorrow but I am guessing it is a combination of buffer size (5 seems small), and overhead in converting the buffer to a list before passing.

% /usr/bin/time -l cat mobydick.txt | ./build/bin/WordCount-lean
        0.08 real         0.00 user         0.00 sys
             1605632  maximum resident set size
                   0  average shared memory size
                   0  average unshared data size
                   0  average unshared stack size
                 180  page reclaims
                   2  page faults
                   0  swaps
                   0  block input operations
                   0  block output operations
                   0  messages sent
                   0  messages received
                   0  signals received
                  34  voluntary context switches
                  13  involuntary context switches
             7072637  instructions retired
             3438399  cycles elapsed
             1131264  peak memory footprint
Characters: 1276235 / Words: 218951 / Lines: 22317
% /usr/bin/time -l cat mobydick.txt | wc                        
        0.00 real         0.00 user         0.00 sys
             1605632  maximum resident set size
                   0  average shared memory size
                   0  average unshared data size
                   0  average unshared stack size
                 176  page reclaims
                   0  page faults
                   0  swaps
                   0  block input operations
                   0  block output operations
                   0  messages sent
                   0  messages received
                   0  signals received
                 130  voluntary context switches
                   2  involuntary context switches
             6196961  instructions retired
             3683665  cycles elapsed
             1114816  peak memory footprint
   22316  215864 1276235

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.