GithubHelp home page GithubHelp logo

Comments (8)

cartazio avatar cartazio commented on June 3, 2024

whats the performance delta one way vs the other?

does this happen if you use vector head? (the bundle rep sometimes fuses better i'm told )

from vector.

takano-akio avatar takano-akio commented on June 3, 2024

Here are some benchmark results:

https://gist.github.com/takano-akio/e3c4c3c56ecc72b60b3d

In summary, the bad version is about 4.9x slower than the good one, with both versions of vector.

from vector.

cartazio avatar cartazio commented on June 3, 2024

how does the code optimize with vector HEAD/master?

from vector.

takano-akio avatar takano-akio commented on June 3, 2024

@cartazio I'm not sure that I understand the question. Would you like to see the optimized core, or something else?

from vector.

glguy avatar glguy commented on June 3, 2024

@cartazio The "Stream" constructors optimize away in GHC 7.10.1-rc1 and GHC 7.11.20150120

from vector.

cartazio avatar cartazio commented on June 3, 2024

@glguy in which case, its not really a bug on the vector side, but variability in how ghc optimizes, right?

from vector.

cartazio avatar cartazio commented on June 3, 2024

i've tried running your example code "good" vs "bad" benchmark locally with the most recent release of vector 0.11 on ghc 8.0.1 on os x with O2 optimization, and the timings seem to be essentially the same (only a ~ 10% difference but the total range of the times all lies in 80-100 microseconds)

so pending a code example that reproduces it with recent vector and ghc, i'm closing this and marking it invalid for now

from vector.

cartazio avatar cartazio commented on June 3, 2024

(that said, I really do appreciate that you provided code for the purposes of this bug)

from vector.

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.