How are virtual functions and vtable implemented?
问题 We all know what virtual functions are in C++, but how are they implemented at a deep level? Can the vtable be modified or even directly accessed at runtime? Does the vtable exist for all classes, or only those that have at least one virtual function? Do abstract classes simply have a NULL for the function pointer of at least one entry? Does having a single virtual function slow down the whole class? Or only the call to the function that is virtual? And does the speed get affected if the