Skip to content

Commit 3a0c534

Browse files
authored
[ORC] Fix -Wunused-function warning on windows (#166207)
All of the users of this function are guarded by LLVM_ON_UNIX and LLVM_ENABLE_THREADS ifdefs, so wrap the function itself in these guards as well to avoid the unused function warning.
1 parent 0a28c07 commit 3a0c534

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

llvm/tools/llvm-jitlink/llvm-jitlink.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -776,6 +776,7 @@ createSharedMemoryManager(SimpleRemoteEPC &SREPC) {
776776
SlabSize, SREPC, SAs);
777777
}
778778

779+
#if LLVM_ON_UNIX && LLVM_ENABLE_THREADS
779780
static void setupEPCRemoteMemoryManager(SimpleRemoteEPC::Setup &S) {
780781
switch (UseMemMgr) {
781782
case MemMgr::Default:
@@ -789,6 +790,7 @@ static void setupEPCRemoteMemoryManager(SimpleRemoteEPC::Setup &S) {
789790
break;
790791
}
791792
}
793+
#endif
792794

793795
static Expected<MaterializationUnit::Interface>
794796
getTestObjectFileInterface(Session &S, MemoryBufferRef O) {

0 commit comments

Comments
 (0)