Live data from Hacker News

Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

blog.rust-lang.org

121–130 of 135 posts

Re: Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

#121
post #117
post #112

Earlier quoted context omitted.

"Idiomatic" in whose opinion? "Idiomatic" is a slogan not a well-defined property. The reason for people to bother adding "idiomatic" versions, is that other people really do work through looking at the source code "on an individual basis, one at a time."

This exact thread came up last year when we started talking about the shootout and haskell. And Its always the same people who bring up the shootout and defend the existing entries. Please stop bringing up the shootout (esp when haskell is mentioned) and dragging everyone through this conversation again. Benchmarks are great to debate but this one is causing more harm than good; let's talk about other benchmarks.

>>Please stop bringing up the shootout…I didn't!

Your accusation is completely wrong!

(And it hasn't been called that for over 7 years.)

Re: Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

#123
post #112

Earlier quoted context omitted.

It doesn't exclude "idiomatic" versions, but the data is presented so as to make them useless. How do I compare "idiomatic" rust to "idiomatic" haskell? All you can get is "here's the fastest versions from each language". If you want to compare any other version you have to do it on an individual basis, one at a time. So there's absolutely no reason for people to bother adding "idiomatic" versions.

"Idiomatic" in whose opinion? "Idiomatic" is a slogan not a well-defined property. The reason for people to bother adding "idiomatic" versions, is that other people really do work through looking at the source code "on an individual basis, one at a time."

>"Idiomatic" in whose opinion?

That's the point I'm making. People constantly dismiss the results they don't like as "unidiomatic" and embrace they ones they do as "idiomatic".

>is that other people really do work through looking at the source code "on an individual basis, one at a time."

Except that people don't bother adding them, so your reasoning for why isn't relevant. If you want to claim the shootout is useful for this, you need to allow for grouping benchmarks together to be presented against the "standard" ones. Let Bob and Sally submit "Bob and Sally version of Foo benchmarks" and let me compare them against Foo and against other languages.

Re: Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

#124
post #113

Earlier quoted context omitted.

>And yet, the programs don't all perform the same. Because they don't all use pcre. Duh? >The GHC version has been updated so many times since the last programs were contributed, that I hope the code would look better if it was written to use the latest greatest Haskell. Why on earth would the code change because of a new compiler release? Do people rewrite the C one every time a new GCC is released? And the code loo…

>>Because they don't all use pcre. Duh? "Duh?" because you haven't looked at the code? http://benchmarksgame.alioth.debian.org/u64q/program.php?tes... http://benchmarksgame.alioth.debian.org/u64q/program.php?tes... >>Why on earth would the code change because of a new compiler release? New GHC releases (and libraries) have in the past provided new ways to write the code. >>what "better" do you want? Any "better" that…

>"Duh?" because you haven't looked at the code?

Me: "Not all use pcre" You: "Two that use pcre"

What on earth is that supposed to show?

>Any "better" that 6 or 7 releases has provided.

You have some weird ideas about haskell/ghc.

Re: Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

#125
post #113

Earlier quoted context omitted.

>>Because they don't all use pcre. Duh? "Duh?" because you haven't looked at the code? http://benchmarksgame.alioth.debian.org/u64q/program.php?tes... http://benchmarksgame.alioth.debian.org/u64q/program.php?tes... >>Why on earth would the code change because of a new compiler release? New GHC releases (and libraries) have in the past provided new ways to write the code. >>what "better" do you want? Any "better" that…

>"Duh?" because you haven't looked at the code? Me: "Not all use pcre" You: "Two that use pcre" What on earth is that supposed to show? >Any "better" that 6 or 7 releases has provided. You have some weird ideas about haskell/ghc.

>>What on earth is that supposed to show?Those two that both use pcre don't perform the same.

>>You have some weird ideas about haskell/ghc.If I have, I got them from seeing programs being re-written when new stuff became available.

Re: Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

#126
post #112

Earlier quoted context omitted.

"Idiomatic" in whose opinion? "Idiomatic" is a slogan not a well-defined property. The reason for people to bother adding "idiomatic" versions, is that other people really do work through looking at the source code "on an individual basis, one at a time."

>"Idiomatic" in whose opinion? That's the point I'm making. People constantly dismiss the results they don't like as "unidiomatic" and embrace they ones they do as "idiomatic". >is that other people really do work through looking at the source code "on an individual basis, one at a time." Except that people don't bother adding them, so your reasoning for why isn't relevant. If you want to claim the shootout is useful…

>>Except that people don't bother adding them …I already provided links to two programs and you're still saying that people don't bother adding them.

Re: Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

#127
post #73

Earlier quoted context omitted.

>fannkuch-redux heavily utilizes unsafe operations on a mutable vector. They are just not bounds checked. That is not "writing C in Haskell". >binary-trees uses artificial strictness for the sake of the benchmark What on earth is "artificial strictness"? Forcing evaluation when you need something to be evaluated immediately is not artificial, not unidiomatic, and not "writing C in Haskell". >Nine of the ten Haskell i…

The Rust code is both safer and faster at the cost of more keystrokes. I'm not certain the point of writing unsafe code in Haskell when there are better tools for the job. Haskell is fast enough as is and using it to hammer screws just reeks of wrong tool for the job.

As an aside, if your interested in safer and faster I'm benchmarking some of the ATS2 code examples[0] which were created for (but not yet in[1][2]) the computer language benchmarks game. It seems to beat C and C++ in some (many?) cases and create TINY binaries. I was trying to benchmark all the examples but got tired of doing it ;) Here are a couple anyway:

Pidigits:

    $ patscc -I/home/cody/sources/ATS-Postiats-contrib/contrib -pipe -O3 -fomit-frame-pointer -march=native pidigits.dats -o bin/pidigits.ats_run -lgmp
    $ gcc -pipe -Wall -O3 -fomit-frame-pointer -march=native  pidigits.c -o bin/pidigits.gcc_run -lgmp
    $ time ./bin/pidigits.gcc_run 10000 > /dev/null
    
    real	0m0.969s
    user	0m0.963s
    sys	0m0.004s
    $ time ./bin/pidigits.ats_run 10000 > /dev/null
    
    real	0m0.972s
    user	0m0.968s
    sys	0m0.004s
    $ ls -larth bin/pidigits.*
    -rwxrwxr-x 1 cody cody 15K Dec 13 18:59 bin/pidigits.ats_run
    -rwxrwxr-x 1 cody cody 14K Dec 13 18:59 bin/pidigits.gcc_run

k-nucleotide:

    $ g++ -c -pipe -O3 -fomit-frame-pointer -march=native -std=c++0x k-nucleotide_gpp3.c++ 
    $ $(PATSCC) -DATS_MEMALLOC_LIBC -pipe -O3 -fomit-frame-pointer -march=native -std=c99 k-nucleotide.dats 
    $ patscc -DATS_MEMALLOC_LIBC -pipe -O3 -fomit-frame-pointer -march=native -std=c99 k-nucleotide.dats 
    $ time ./k-nucleotide_gpp3 
[0]: https://github.com/githwxi/ATS-Postiats-contrib/tree/master/...

[1]: https://alioth.debian.org/forum/forum.php?thread_id=14942&fo...

[2]: https://groups.google.com/forum/#!topic/ats-lang-users/QdwKp...

Re: Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

#128
post #96

Earlier quoted context omitted.

How is indexing an array OK with functional programming of the level of purity Haskell strives for (not to mention without bounds checking)? In "Real World Haskell" they advise you to forgo of arrays, and even has a chapter "Life without arrays", saying "arrays and hash tables are often used as collections indexed by key, and in Haskell we use trees for that purpose".

> How is it not? That is a complete non-sequitur and makes no sense. What sort of definition of functional programming are you using that you think it restricts what data types you are allowed to use? The normal definition of functional programming, in which not all data structures used in imperative programming are idiomatic (or even considered "functional"). For starters, mutable data structures would be considered…

>The normal definition of functional programming, in which not all data structures used in imperative programming are idiomatic

I can't find any reference anywhere to any sort of definition like that. Or even one that mentions restricting data structures or memory layout at all. The only "normal" definitions I can find are: "functions are first class" which is a pretty weak definition and doesn't really exclude much these days, and: "the return values of functions depend only on the functions arguments" which is what everyone in the haskell world thinks of as "functional programming". Neither of these definitions exclude arrays.

>For starters, mutable data structures would be considered not purely functional

A data structure can not be functional or imperative. Only what you do with it. Mutation is perfectly fine if it is localized (remember the function's return value needs to only depend on its arguments, nothing more).

Re: Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

#129
post #126

Earlier quoted context omitted.

>"Idiomatic" in whose opinion? That's the point I'm making. People constantly dismiss the results they don't like as "unidiomatic" and embrace they ones they do as "idiomatic". >is that other people really do work through looking at the source code "on an individual basis, one at a time." Except that people don't bother adding them, so your reasoning for why isn't relevant. If you want to claim the shootout is useful…

>>Except that people don't bother adding them … I already provided links to two programs and you're still saying that people don't bother adding them.

Do you think that is contradictory for some reason?

Re: Yehuda Katz and Steve Klabnik Are Joining the Rust Core Team

#130
post #125

Earlier quoted context omitted.

>"Duh?" because you haven't looked at the code? Me: "Not all use pcre" You: "Two that use pcre" What on earth is that supposed to show? >Any "better" that 6 or 7 releases has provided. You have some weird ideas about haskell/ghc.

>>What on earth is that supposed to show? Those two that both use pcre don't perform the same. >>You have some weird ideas about haskell/ghc. If I have, I got them from seeing programs being re-written when new stuff became available.

You got them from seeing someone writing a faster version. The part where you thought it had anything to do with "new stuff" is entirely your own imagination
Post reply on HN