]> granicus.if.org Git - llvm/commitdiff
Add NetBSD support in needsRuntimeRegistrationOfSectionRange.
authorKamil Rytarowski <n54@gmx.com>
Sat, 15 Dec 2018 16:51:35 +0000 (16:51 +0000)
committerKamil Rytarowski <n54@gmx.com>
Sat, 15 Dec 2018 16:51:35 +0000 (16:51 +0000)
Use linker script magic to get data/cnts/name start/end.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@349277 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Instrumentation/InstrProfiling.cpp

index 62da93002539e45d56c12fe285ba4a286ed8415f..15b94388cbe51429b513478eaee6f1af8e251742 100644 (file)
@@ -701,6 +701,7 @@ static bool needsRuntimeRegistrationOfSectionRange(const Module &M) {
   // Use linker script magic to get data/cnts/name start/end.
   if (Triple(M.getTargetTriple()).isOSLinux() ||
       Triple(M.getTargetTriple()).isOSFreeBSD() ||
+      Triple(M.getTargetTriple()).isOSNetBSD() ||
       Triple(M.getTargetTriple()).isOSFuchsia() ||
       Triple(M.getTargetTriple()).isPS4CPU())
     return false;