Live data from Hacker News

Microsoft seeks Rust developers to rewrite core C# code

theregister.com

21–30 of 256 posts

Re: Microsoft seeks Rust developers to rewrite core C# code

#21
post #6

What's the point of rewriting from C# to Rust, as C# is performant enough and already has memory safety? What will offset the huge rewrite cost?

> C# is performant enough

until it isn't. At Microsoft's scale, I imagine performance is actually a major concern for certain pieces of applications.

Re: Microsoft seeks Rust developers to rewrite core C# code

#22
post #2

I upvote almost any post "in Rust" here (yeah that's me) but this story went bit too far. It was just one job posting and so many sites acts like MS is going to ditch C#.

That’s funny because I downvote almost any “in Rust” post here!

C# — and garbage collected languages in general — aren’t going anywhere. With the shift to Arm, languages compiled for a runtime interpreter will get even more important for Microsoft.

Re: Microsoft seeks Rust developers to rewrite core C# code

#24
post #11

Earlier quoted context omitted.

C# doesn't have ownership/lifetimes and the kind of safety that comes with them. Also, at the scale of Microsoft’s core global services, when you are paying for the processing, fast enough (or “CPU efficient enough”) isn't the same as with common apps. Even small efficiency gains are going to yield sufficient savings to be worth a fair amount of developer time.

> C# doesn't have ownership/lifetimes and the kind of safety that comes with them. Could you elaborate? C# has a garbage collector for tracking resources.

[deleted]

Re: Microsoft seeks Rust developers to rewrite core C# code

#25
post #4

Can they start by not needing a multiple gigabyte download and admin rights to get the rust compiler to work on Windows?

Does C# not require a multiple gigabyte download and admin rights?

FWIW I've gotten rust working with the GCC build tools on windows without admin rights, thought it's admittedly somewhat janky.

Re: Microsoft seeks Rust developers to rewrite core C# code

#26
post #4

Can they start by not needing a multiple gigabyte download and admin rights to get the rust compiler to work on Windows?

Is that needed because the compiler accesses some higher privileged APIs?

Why would a compiler needs any privileges, it's like a text editor

Re: Microsoft seeks Rust developers to rewrite core C# code

#27
post #6

What's the point of rewriting from C# to Rust, as C# is performant enough and already has memory safety? What will offset the huge rewrite cost?

C# doesn't have ownership/lifetimes and the kind of safety that comes with them. Also, at the scale of Microsoft’s core global services, when you are paying for the processing, fast enough (or “CPU efficient enough”) isn't the same as with common apps. Even small efficiency gains are going to yield sufficient savings to be worth a fair amount of developer time.

> C# doesn't have ownership/lifetimes and the kind of safety that comes with them.

I believe .net Core has supported several forms of escape analysis for quite a while.

Re: Microsoft seeks Rust developers to rewrite core C# code

#28
post #6

What's the point of rewriting from C# to Rust, as C# is performant enough and already has memory safety? What will offset the huge rewrite cost?

C# doesn't have ownership/lifetimes and the kind of safety that comes with them. Also, at the scale of Microsoft’s core global services, when you are paying for the processing, fast enough (or “CPU efficient enough”) isn't the same as with common apps. Even small efficiency gains are going to yield sufficient savings to be worth a fair amount of developer time.

Almost all of the services I've seen at Microsoft were built in C#

Re: Microsoft seeks Rust developers to rewrite core C# code

#29
post #11

Earlier quoted context omitted.

> C# doesn't have ownership/lifetimes and the kind of safety that comes with them. Could you elaborate? C# has a garbage collector for tracking resources.

I think the parent post is wrong. This rewrite probably has more to do with performance, "fearless concurrency", and/or developer happiness. C# is safe.

thread safe?

Re: Microsoft seeks Rust developers to rewrite core C# code

#30

Earlier quoted context omitted.

I think the parent post is wrong. This rewrite probably has more to do with performance, "fearless concurrency", and/or developer happiness. C# is safe.

thread safe?

It isn't, but neither is rust.

Safe rust is safe from data races, but that's just one kind of potential thread safety issue -- one of the simpler kinds. It's not nothing, but not anywhere close to thread-safe.

Post reply on HN