[PATCH] D11441: Generating available_externally vtables for classes without inline virtual functions

Piotr Padlewski prazek at google.com
Wed Jul 22 18:17:42 PDT 2015


Prazek added inline comments.

================
Comment at: lib/CodeGen/ItaniumCXXABI.cpp:1510-1511
@@ +1509,4 @@
+  // can emit definition of the inline functions.
+  if (!CGM.getCodeGenOpts().OptimizationLevel || CGM.getLangOpts().AppleKext)
+    return false;
+
----------------
rsmith wrote:
> I think the `OptimizationLevel` check belongs in the caller, not here. (We can emit `available_externally` vtables even at -O0, we just usually don't want to do so.)
It will make code uglier(multiple check before every function call), but You are right


http://reviews.llvm.org/D11441







More information about the cfe-commits mailing list