[prev in list] [next in list] [prev in thread] [next in thread] 

List:       cfe-commits
Subject:    [PATCH] D37624: add support for -fno-instrument-functions and -finstrument-functions-exclude-{file, 
From:       Hal Finkel via Phabricator via cfe-commits <cfe-commits () lists ! llvm ! org>
Date:       2017-09-30 1:30:30
Message-ID: 72b42cb25b223d6d3103032a1d54fb05 () localhost ! localdomain
[Download RAW message or body]

hfinkel added a comment.

Please also add a C++ test to check the mangling-related features.



================
Comment at: lib/CodeGen/CodeGenFunction.cpp:419
+// Assume that __cxa_demangle is provided by libcxxabi (except for Windows).
+extern "C" char *__cxa_demangle(const char *mangled_name, char *output_buffer,
+                                size_t *length, int *status);
----------------
Using the system demangler here seems like the wrong solution. You have the current \
function declaration, `CurFuncDecl`, and from it you should be able to extract the \
full name.

I think that this will do it:

  std::string FullFuncName = PredefinedExpr::ComputeName(
          PredefinedExpr::PrettyFunctionNoVirtual, CurFuncDecl);



================
Comment at: lib/CodeGen/CodeGenModule.cpp:4601
+CodeGenModule::GetSourceLocToFileNameMap() {
+  return SourceLocToFileNameMap;
+}
----------------
Make this function inline in the class definition.


https://reviews.llvm.org/D37624



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic