[PATCH] D91850: [compiler-rt] [profile] Silence a warning about an unused function on mingw targets
Martin Storsjö via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 20 01:39:25 PST 2020
mstorsjo created this revision.
mstorsjo added reviewers: vsk, amccarth.
Herald added subscribers: Sanitizers, phosek, dberris.
Herald added a project: Sanitizers.
mstorsjo requested review of this revision.
This function is only used within the ifdef below.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D91850
Files:
compiler-rt/lib/profile/InstrProfilingFile.c
Index: compiler-rt/lib/profile/InstrProfilingFile.c
===================================================================
--- compiler-rt/lib/profile/InstrProfilingFile.c
+++ compiler-rt/lib/profile/InstrProfilingFile.c
@@ -420,14 +420,12 @@
fclose(File);
}
-#ifndef _MSC_VER
+#if !defined(__Fuchsia__) && !defined(_WIN32)
static void assertIsZero(int *i) {
if (*i)
PROF_WARN("Expected flag to be 0, but got: %d\n", *i);
}
-#endif
-#if !defined(__Fuchsia__) && !defined(_WIN32)
/* Write a partial profile to \p Filename, which is required to be backed by
* the open file object \p File. */
static int writeProfileWithFileObject(const char *Filename, FILE *File) {
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D91850.306620.patch
Type: text/x-patch
Size: 684 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201120/dbc64a36/attachment.bin>
More information about the llvm-commits
mailing list