A
A
AUgryumov2017-05-27 20:09:26
Iron
AUgryumov, 2017-05-27 20:09:26

Rust in autopilots for cars?

In recent years, self-driving cars have become increasingly popular. What programming languages ​​are used in this area? C / C ++ may not be safe enough (memory leaks, crashes), you can’t write image recognition in Assembler. Python and Java will run very slowly. I may be wrong, maybe I don't know some tools. Is Rust the ideal choice? It is relatively safe, has a good speed, allows you to write both at a low and at a high level.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
D
devalone, 2017-05-27
@devalone

C/C++ may not be secure enough (memory leaks, crashes)

Memory leaks do not come from C ++, but from the programmer's lack of competence, in modern C ++ memory is perfectly managed by containers and smart pointers (with the help of magic, as in Java, only better) and knowing them it is difficult to write a leak, and manual control is still left for those where maximum performance is required. Crashes, again, most often occur due to incorrect memory access (for example, accessing freed memory) and these problems are again solved in modern C ++. But if you really want to shoot yourself in the foot, C++ certainly lets you do it.
You write, but it makes no sense, and there are much more chances to make a mistake and accidentally shoot yourself in the leg.
Speed ​​is a relative concept; in real-time systems, the reaction speed is important, i.e. if something similar to a person appeared ahead, the system should react in no more than a few ms. In python and Java, this can be prevented, for example, by sudden garbage collection.

X
xmoonlight, 2017-05-27
@xmoonlight

The question is similar to a call for a global transition of all coders to Rust.
And it was necessary to call for a detailed study of all the risks of such systems: the logic of the algorithms, the speed of decision-making, the speed of processing, failures, failures, consequences.
And on what it will be implemented - it doesn’t matter: at least put Martyn behind the wheel!

N
Nazar Mokrinsky, 2017-05-27
@nazarpc

There is no ideal option, and therefore the question in general does not make sense. They write on what they know, what there are suitable libraries for and what is suitable for a specific specific project. There is no such thing as choosing the "right" language and everything worked out.
Rust may well be one of the options.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question