MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/rust/comments/7m99wo/outperforming_rust_with_functional_programming/drwambu/?context=9999
r/rust • u/steveklabnik1 rust • Dec 26 '17
90 comments sorted by
View all comments
96
The author makes some incorrect claims about the Rust and the C here, specifically that things are heap allocated. I haven't dug in to figure out the details of why we're slower here though.
35 u/[deleted] Dec 26 '17 The author makes some incorrect claims about the Rust and the C here, specifically that things are heap allocated.I updated the blog post. It should be correct now.I haven't dug in to figure out the details of why we're slower here though.In the case of the generated Rust I still have no idea. In the case of C/ATS, it seems to arise from n != 1 instead of n > 1. 20 u/viraptor Dec 27 '17 Your blog still says "Here, we do something that is not possible to do in C..." -2 u/[deleted] Dec 27 '17 edited Dec 27 '17 Because it isn't possible to do in C. ATS has better safety guarantees. 0 u/bobogei81123 Dec 29 '17 I'm curious what "we do something that is not possible to do in C - we safely stack-allocate a function argument."Honestly, I can't think of a case that violates memory safety in C if no pointers/arrays are used.
35
The author makes some incorrect claims about the Rust and the C here, specifically that things are heap allocated.
I updated the blog post. It should be correct now.
I haven't dug in to figure out the details of why we're slower here though.
In the case of the generated Rust I still have no idea. In the case of C/ATS, it seems to arise from n != 1 instead of n > 1.
n != 1
n > 1
20 u/viraptor Dec 27 '17 Your blog still says "Here, we do something that is not possible to do in C..." -2 u/[deleted] Dec 27 '17 edited Dec 27 '17 Because it isn't possible to do in C. ATS has better safety guarantees. 0 u/bobogei81123 Dec 29 '17 I'm curious what "we do something that is not possible to do in C - we safely stack-allocate a function argument."Honestly, I can't think of a case that violates memory safety in C if no pointers/arrays are used.
20
Your blog still says "Here, we do something that is not possible to do in C..."
-2 u/[deleted] Dec 27 '17 edited Dec 27 '17 Because it isn't possible to do in C. ATS has better safety guarantees. 0 u/bobogei81123 Dec 29 '17 I'm curious what "we do something that is not possible to do in C - we safely stack-allocate a function argument."Honestly, I can't think of a case that violates memory safety in C if no pointers/arrays are used.
-2
Because it isn't possible to do in C. ATS has better safety guarantees.
0 u/bobogei81123 Dec 29 '17 I'm curious what "we do something that is not possible to do in C - we safely stack-allocate a function argument."Honestly, I can't think of a case that violates memory safety in C if no pointers/arrays are used.
0
I'm curious what "we do something that is not possible to do in C - we safely stack-allocate a function argument."
Honestly, I can't think of a case that violates memory safety in C if no pointers/arrays are used.
96
u/steveklabnik1 rust Dec 26 '17
The author makes some incorrect claims about the Rust and the C here, specifically that things are heap allocated. I haven't dug in to figure out the details of why we're slower here though.