Its pretty obvious “awesome” is meant literally, as in “inspiring an overwhelming feeling of reverence, admiration, or fear”
@MaceUA
3 жыл бұрын
Reminded me of one anti-pattern that I've seen in at least two projects in their legacy code: `if (this == NULL) return;`. Obviously, the compiler has the right to throw it all away, because `this` is not allowed to be null.
@doBobro
2 жыл бұрын
It's ridiculous how much code compiler can remove but you don't notice it in any way.
@sjswitzer1
Жыл бұрын
Arguably true for code you write yourself. The problem comes from templates, which can generate a lot of code that really should be dead-code-eliminated. The back end has trouble knowing the difference.
@aliancemd
6 жыл бұрын
51:47 - was that Niko Matsakis(sounded like him) at CppCon 2017? :)
@nullplan01
5 жыл бұрын
49:00 Regarding the memory allocation thing: You know, you can just turn on strict accounting (by turning off overcommit). That has other problems, though.
@user-mv4oh8yp1y
3 жыл бұрын
Useful part: 16:17, 20:23-21:09, 29:51, 35:00-35:37, 43:34. 1. Your if statement about checking nullptr wil be considered by Compiler to check undefined behaviour. 2. Don't forget return statement at every branch. 3. Undefined Behaviour means assuming not happen, to speed up. In short: don't write smart (short) code then you will be fine.
@FalcoGer
Жыл бұрын
@ 33:00 when i compile that with clang 10, it emits an ud2 instruction, or 0F0B. "Raise invalid opcode exception". When run, this will trigger a segfault with "illegal hardware instruction (core dumped)"
@michalmarszaleck
4 жыл бұрын
25:00 if it would not be static then that means, there could be somewhere extern in another compilation unit and initialization before main and it could not do this.
@kamilziemian995
Жыл бұрын
Is "Behaviour" in the title of the video a typo or something else?
@hatemel-kharashy8856
Жыл бұрын
it is still correct. "Behaviour" is UK english and "Behavior" is US english
Пікірлер: 14