[Windows][Polly] Disable LLVMPolly module for all compilers on Windows

Before this patch, the cmake disabled loadable modules when compiling
with Visual Studio. However, the reason for this is a limitation of the
Windows DLLs, thus this restriction should apply to any compiler for the
Windows platform, such as MinGW, Cygwin, icc, etc.

Differential Revision: https://reviews.llvm.org/D87524
This commit is contained in:
Mateusz Mikuła 2020-09-15 09:12:02 +03:00 committed by Martin Storsjö
parent 61e0b2b4c5
commit e71cda21d7
2 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ else()
endif()
set(POLLY_CONFIG_EXPORTED_TARGETS Polly ${ISL_TARGET})
if (NOT MSVC AND LLVM_ENABLE_PIC)
if (NOT WIN32 AND LLVM_ENABLE_PIC)
# LLVMPolly is a dummy target on Win or if PIC code is disabled.
list(APPEND POLLY_CONFIG_EXPORTED_TARGETS LLVMPolly)
endif()

View File

@ -137,7 +137,7 @@ endif ()
# Create a loadable module Polly.so that can be loaded using
# LLVM's/clang's "-load" option.
if (MSVC OR NOT LLVM_ENABLE_PIC)
if (WIN32 OR NOT LLVM_ENABLE_PIC)
# Add dummy target, either because loadable modules are not supported
# as on Windows or because PIC code has been disabled
add_custom_target(LLVMPolly)