LTO: expose LTO_SYMBOL_ALIAS, which indicates that the symbol is an alias.
[oota-llvm.git] / lib / LTO / LTOModule.cpp
index 6131c3180249ded2331ad3e122cef53cd896bf21..53ed4175f8e35463e9826858ff84efdf5046a6d8 100644 (file)
@@ -473,6 +473,9 @@ void LTOModule::addDefinedSymbol(const char *Name, const GlobalValue *def,
   if (def->hasComdat())
     attr |= LTO_SYMBOL_COMDAT;
 
+  if (isa<GlobalAlias>(def))
+    attr |= LTO_SYMBOL_ALIAS;
+
   auto Iter = _defines.insert(Name).first;
 
   // fill information structure