DebugInfo: Simplify solution to avoid DW_AT_artificial on inlined parameters.
[opencl/llvm.git] / lib / CodeGen / AsmPrinter / DwarfDebug.cpp
index c0badde3685ac24e3d8aeec090b5378f8b026533..967c7b1b5964228e04983602962e33e1201eb909 100644 (file)
@@ -448,12 +448,7 @@ static std::unique_ptr<DIE> constructVariableDIE(DwarfCompileUnit &TheCU,
                                                  DbgVariable &DV,
                                                  const LexicalScope &Scope,
                                                  DIE *&ObjectPointer) {
-  AbstractOrInlined AOI = AOI_None;
-  if (Scope.isAbstractScope())
-    AOI = AOI_Abstract;
-  else if (Scope.getInlinedAt())
-    AOI = AOI_Inlined;
-  auto Var = TheCU.constructVariableDIE(DV, AOI);
+  auto Var = TheCU.constructVariableDIE(DV, Scope.isAbstractScope());
   if (DV.isObjectPointer())
     ObjectPointer = Var.get();
   return Var;