Lecture 16. Volatile Variables

preview_player
Показать описание
This short video introduces the volatile qualifier in C.
Рекомендации по теме
Комментарии
Автор

Very nice explaination of volatile keyword !

neutrino
Автор

It is so clear!! By the way, i want to buy your book but i want epub because i have an e-reader. Do you consider to deploy as epub on amazon?

coderhex
Автор

Great explanation of an important topic. 4:30 Would it be sufficient to use a GetFunction such as int GetFlag(void){return flag} which is called by main while(Getflag() == 0) instead of using volatile int flag? I'm not sure if the compiler could remove even a function call for optimization.

Pappag
Автор

good explanation but volatile keyword is such a BS that its meaning is ambiguity itself. In this demo, we should assume that it's compiler bug! Why optimize out a memory access when
a) systick handler accesses the memory area
b) they are advertising their product is a compiler for embedded system development. The compiler should know!

hawkkim
join shbcf.ru