I am testing the use of Intel C++ Compiler 19.1 with Visual Studio 2019 with my fairly large application. I am having problems with virtual functions in very specific situations that I do not have with the Microsoft compiler in VS, or with GCC on both Linux and Mac. This is a framework that I have been using for years without problems and (SFAIK) everything is fine (no compiler errors/warnings on any compiler, including Intel).
The problem arises with a virtual function from a base class which is resolved in an intermediate class, for example, ETable has virtual function Special Setup (which is an empty function), the working function is in subclass ETableEdit, which has an subclass ETableEditDocument. SpecialSetup out of an ETable function calls the correct SpecialSetup in ETableEdit, but the <<this>> in ETableEdit::SpecialSetup isn't correct: the pointer is 0x0625dda0 when it should be 0x0625ddb0, and this causes a run-time exception. I've found at least a half-dozen such problems and they all have the same issue: a virtual function from a base class is resolved in an intermediate class where the <<this>> pointer is off by a relatively small offset (typically 8 or 16). I have unsuccessfully tried creating a simple example of this, so I'm not sure what else it is about these classes that triggers the error.