From 06f445d65b44e30be072d757edb8299d239eca31 Mon Sep 17 00:00:00 2001 From: Adrian Prantl Date: Thu, 28 Apr 2016 17:21:56 +0000 Subject: Debug info: Apply an artificial debug location to __cyg_profile_func.* calls. The LLVM Verifier expects all inlinable calls in debuggable functions to have a location. rdar://problem/25818489 llvm-svn: 267904 --- clang/lib/CodeGen/CodeGenFunction.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'clang/lib/CodeGen/CodeGenFunction.cpp') diff --git a/clang/lib/CodeGen/CodeGenFunction.cpp b/clang/lib/CodeGen/CodeGenFunction.cpp index 29a513f2bdf..0ed425ba46a 100644 --- a/clang/lib/CodeGen/CodeGenFunction.cpp +++ b/clang/lib/CodeGen/CodeGenFunction.cpp @@ -401,6 +401,7 @@ bool CodeGenFunction::ShouldInstrumentFunction() { /// instrumentation function with the current function and the call site, if /// function instrumentation is enabled. void CodeGenFunction::EmitFunctionInstrumentation(const char *Fn) { + auto NL = ApplyDebugLocation::CreateArtificial(*this); // void __cyg_profile_func_{enter,exit} (void *this_fn, void *call_site); llvm::PointerType *PointerTy = Int8PtrTy; llvm::Type *ProfileFuncArgs[] = { PointerTy, PointerTy }; -- cgit v1.2.3