News for hackers. Stuff that matters.
Re:Python’s Weak Performance Matters by willtim on Wednesday February 07, 2018 @01:51AM (#16322701)
GHC Haskell is an advanced optimising compiler, which can get very near the speed of C and C++. However, to write fast programs, one must use the right data structures and algorithms. Often this means array-based strings and streaming IO, unfortunately many Haskell textbooks don't tend to cover this.
Re:Python’s Weak Performance Matters by luispedrocoelho on Wednesday February 07, 2018 @02:01AM (#16322738)
Yep, my Haskell usage is "conduit all the way down".

I even wrote up a few utilities to make use of multiple threads while working at a high level: https://hackage.haskell.org/package/conduit-algorithms-0.0.7...

Re:Python’s Weak Performance Matters by bjoli on Wednesday February 07, 2018 @05:15AM (#16323456)
All comparisons of Haskell and C I have seen where Haskell has been near the performance of C(++) has always compared a highly optimised Haskell program to a moderately fast c program.

I have found that most managed languages generally come within 2-5 times slower than C and C++. Which is good enough for me.

Re:Python’s Weak Performance Matters by imtringued on Wednesday February 07, 2018 @07:52AM (#16324054)
The JVM is fast enough for me but for some reason any JVM project requires hundreds of megabytes of RAM even for the simplest things.

cpp webserver + sqlite database + cygwin overhead? 9MB RAM lua worker + websocket client? 4MB RAM JVM server + static html page + websocket relay + kurento api? 500MB RAM

With the exception of the cpp webserver none of these tasks are CPU or memory intensive yet the JVM is still off by orders of magnitude.

It's ok if it's the only application running on a server with multiple users but there is just a single user and that's me.

Re:Python’s Weak Performance Matters by willtim on Wednesday February 07, 2018 @08:07AM (#16324106)
Have you tried specifying a smaller maximum heap size? The biggest memory issue IMHO, is that Java and the JVM do not specialise any "generic" code and so there can be a lot of unnecessary boxing going on.