K
K
Kamil2016-03-19 17:36:55
Microcontrollers
Kamil, 2016-03-19 17:36:55

Is programming MK, ASM really 30-40% more efficient than C?

Hello!
I am reading a book on programming microcontrollers, the author writes that firmware in C is 30-40% less efficient than in Assembler.
Tell me, is it really true?
Simply, C is much easier and I know it basicly, and Assembler is completely incomprehensible, you will have to strain your brains a lot to master it, if this is really the case.
That is, without options to learn Assembler if I want to become a good Embedded Engineer, or can I do with C?
Thank you!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
O
OnYourLips, 2016-03-19
@kamil86

Tell me, is it really true?
On the contrary, modern compilers make similar (without micro-optimizations) C code more efficient.
You will write in C and some other languages.
and Assembler is completely incomprehensible, you have to strain your brains a lot to master it
It will have to be mastered anyway.
For understanding how things work and for debugging or learning.
That is, without options to learn Assembler if I want to become a good Embedded Engineer, or can I do with C?
Can't do without C.

A
Alexander Skusnov, 2016-03-20
@AlexSku

Once upon a time I bought a book "writing drivers in assembler". There were examples for Windows3. As soon as I got to Windows NT, the author wrote: "further we will write drivers in C". The question is, why such a title?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question