Game develo0per here. Name one (1 (uno)) __good__ reason why I should use Rust over C++

Game develo0per here. Name one (1 (uno)) __good__ reason why I should use Rust over C++.

Attached: Mandi.png (1166x806, 656K)

Other urls found in this thread:

lmgtfy.com/?q=unique pointers
youtube.com/watch?v=UDcy9zUwTkE
twitter.com/AnonBabble

you want to use lots of multithreading and strong memory ownership semantics makes that easier to reason about.

I think the GSL is replicating this in C++ with a template library.

they both kinda suck, in very different ways

There is no reason to use Rust.
It's a meme language and anyone promoting Rust on this board is satirical, it's a joke.

This is the correct answer.

Use C# instead.

>garbage collected language
>gamedev

Attached: i.jpg (640x782, 62K)

>Segmentation Fault

>he says while the popularity is booming

I suspect rust may end up being faster than c++.One of the main problems with the optimiser for c/c++ is that it frequently can't prove that two pointers don't refer to the same thing. The ownership stuff in rust might solve this problem..

>pointers
It is very easy to avoid using pointers in C++, and having two pointers referring to the same thing is intentional and you don't need to prove anything, usually they are given a similar label.

>I suspect rust may end up being faster than c++

Attached: 97a.jpg (500x374, 47K)

I was more thinking of the optimiser - the aliasing problem is frequently cited as the biggest problem with writing effective optimisers for C/C++ - Specifically, any optimisation that changes the order of instructions past a pointer access, it generally needs to prove the optimisation won't have any side effects elsewhere.

Now, I'll grant you that the recommended C++ idioms abstract that away from the programmer, but it's mostly in the form of templates, and the compiler itself probably can't make use of it.

There was a talk at Cppcon about trying to replicate the ownership/borrows checking with templates, but that wouldn't help the compiler, necessarily.

Rust trannies will suck you off.

yo js is HUGE right now
you should go and join them

>One of the main problems with the optimiser for c/c++ is that it frequently can't prove that two pointers don't refer to the same thing
Please tell me this is satire.

No? This is the main reason high performance computing people still use fortran - it doesn't have the aliasing problem.

Sounds uncomfortable

No, I have standards.

then rust isn't for you

free head? noice

lmgtfy.com/?q=unique pointers

>game dev here
yikes

Attached: 1517857216998.png (1000x700, 85K)

>Game develo0per here

Attached: image.jpg (400x400, 114K)

god forbid people wanting to actually use technology and not just shitpost about there riced out linux

C++ just needs to add restrict.

>solve actually interesting problems
>never give 2 shits about code safety and convoluted spaghetti bollocks enterprise devs have to deal with
>have a number of great FOSS engines to work with
>best community ever, getting answers is as easy as starting debate somewhere
>don't have to be a FOSS fag and keep all my code proprietary
>casually earn thousands of dollars passively from old games
>pretty much this happens when you enter a room of people, you get universal respect for being a game dev youtube.com/watch?v=UDcy9zUwTkE
Comfiest job ever

>best community ever

Attached: image.jpg (613x531, 213K)

It really is, gamedevs have accepted universal goodness and we help each other out like real bros. Heck half of my knowledge comes from discussing shit with gamedevs

Also best programmers apart from compiler and OS devs. And maybe some NASA guys or whatever. Definitely in the upper layers of skill and ability

Attached: brofist_by_awitan-d41mc1e.jpg (972x760, 354K)

Who is she?

AVGN movie gal

Attached: AVGN_Movie_Teaser.png (700x325, 266K)

GameDevs are CS frauds. They just use hacked solutions because why spend less time on making the game itself? If you want the C++ pros, look no where else besides hedge fund/HFT devs.

Name one good reason why anyone should use C++.

>muh hacked solutions
I don't see you complaining when the game actually runs

>what is Unity

Horrible framework populated by 99% newbies and 1% professionals and no middle ground between them?

>only applies if you're making an actual fully fledged game
>lol, you will always write spaghetti at some point of being a programmer
>they're priced free, but there's no freedom nor open source-ness
>easy getting answers >Unity's documentation is completely fucked, Unreal is convoluted, everything else is shit
>you probably won't get any money from it
>above
>lol

No just keep using C++, it is the white man's language.

>why are nearly 50% of games made in Unity

minimum viable product sells
popular != good

rust considers all x86 SIMD performance intrinsics "unsafe" and making a game in rust involves downloading 20 crates that are all just wrappers around C and C++ libraries with "unsafe{}" wrapped around each function.

just use C or C++ and cut out the ridiculous middle man that is rust

rust is just another meme language that is fighting for relevancy on social media

>rust considers all x86 SIMD performance intrinsics "unsafe" and making a game in rust involves downloading 20 crates that are all just wrappers around C and C++ libraries with "unsafe{}" wrapped around each function.
That's fucking hilarious

There is none. We just tell gullible people to learn Rust to see if they are stupid enough to fall for it.

>making a game in rust involves downloading 20 crates that are all just wrappers around C and C++ libraries with "unsafe{}" wrapped around each function.
RUST IS LITERALLY A GLUE LANGUAGE
BTFO

I don't see how those two things are mutually exclusive.

You shouldn't, the ecosystem is still fucking miles away from being anywhere useable. Rust is still super young, so you should only be touching it purely for educational/hobbyist purposes.

i cant

GC is non-deterministic
In game dev you want as deterministic behavior as you can possibly have

They get exposed on Digital Foundary analysis videos.

The Chad Nim is the best of all worlds
>generics
>inline asm
>best ffi of any language
>iterators
>strong, statically typed
>macros, power of Lisp
>very fast
>garbage collected by default with optional manual memory management
>garbage collector is configurable
>async, futures
>small binaries
>fast compile times

Attached: nim.jpg (900x506, 65K)

thanks breh

[citation needed]

Apparently you don't

>unironically invoking Digital Foundry as an authority on anything except how to be corrupt hacks

Attached: file.png (480x360, 198K)

>GC is non-deterministic
oh so we are just saying stupid shit randomly
macos is good
python is fast
gentoo is a viable desktop operating system
i could go on

Seething sepples retard

a piece of shit.

Enjoy your FPS drops i guess...?

Enjoy your memory leaks I guess

>implying its not all unoptimized throwaway asset flips

made me reply/10

>memory leaks
A meme

To be extremely pedantic, garbage collection is completely deterministic. Given the state of the program, the specs of the machine, and the GC algorithm, you'll always know when you'll pauses to collect garbage. GC pauses just *seem* to occur randomly in practice.

Not all garbage collectors need to stop the world, and there are methods to make GC pauses less frequent and more predictable.

It just werks.
Next question.

Its not when you have a 10000+ line codebase. It gets really hard to keep track of everything + unit testing is also not easy when you have shit coverage(like most games have, not only because of shit devs but because time, budget and technological limitations)
Im partly memeing tho, I do think garbage collected languages are sometimes better, just not because they are more "deterministic". No program is deterministic if it handles or stores information from the "real world" as its state. Or if it has state like at all. But this is not a big deal, error correction and exception handling exists for this very reason.

>garbage collected languages
i meant NOT garbage collecting languages

Don't be retarded, you can still have aliasing with unique pointers.

since .net 4 there is mainly non-blocking GC.
>non-deterministic
the fuck, how would anything even work if it was such?

t. writing game with .net core and DX 11 (sharpDX) and don't have any random pauses happening due GC.

I lol'ed

Do you at least pool your memory

/thread

What is pinvoke()

You can force GC since .net 2.

why rust gets broken so fast? few months ago it worked on slackware without QT5, not anymore

Attached: slackpenguinlogo.jpg (655x771, 45K)

if needed (large objects that need to be moved to old generation asap), but usually i just use background loading and let GC to do its shuffling which isn't performance hit unless CPU is choking already.

>you want your entire team to collectively decide that rust is fucking retarded and then decide to switch back to c++

>sepples
>industry giant
>decades of experience
>pioneered by leaders in industry and academia
>requires high IQ and good posture
>works on ancient codebases like hebrew scriptures
>big dick IQ flex with template metafaggotry

>rust
>babby lang
>written by a literal whomstve
>retarded syntax
>sandbox faggotry, not proven in bigger codebases