-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Windows test fixes #196
Windows test fixes #196
Conversation
…fno-delayed-template-parsing
…ed without export errors
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #196 +/- ##
==========================================
- Coverage 78.83% 78.63% -0.21%
==========================================
Files 8 8
Lines 3048 3056 +8
==========================================
Hits 2403 2403
- Misses 645 653 +8
|
clang-tidy review says "All clean, LGTM! 👍" |
@@ -2463,6 +2463,10 @@ namespace Cpp { | |||
std::vector<const char *> ClingArgv = {"-resource-dir", ResourceDir.c_str(), | |||
"-std=c++14"}; | |||
ClingArgv.insert(ClingArgv.begin(), MainExecutableName.c_str()); | |||
#ifdef _WIN32 | |||
// FIXME : Workaround Sema::PushDeclContext assert on windows | |||
ClingArgv.push_back("-fno-delayed-template-parsing"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need -femulated-tls
for the TLS related issues? We do this here in cling:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried -fno-emulated-tls there and still got the same emulated TLS symbol errors. It looks like its defaulted to on from JITTargetMachineBuilder's constructor.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think we need a patch in upstream clang?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe I don't really know how it should work for windows.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, understood. Let's move forward with this PR and fix the remaining tests later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! @mcbarton, after this PR we might be able to remove from the CI the make-it-all-green for windows and disable only the failing tests.
@fsfod, forgot to say - can you apply clang-format on per-commit basis or shall I? |
…ectory iterator in Dyld::BuildBloomFilter
clang-tidy review says "All clean, LGTM! 👍" |
@vgvassilev This would not be possible if it was merged right now, as when CppInterOp uses Cling on Windows it currently aborts in the following tests in the CI
cc: @fsfod Any idea what is causing these tests to fail (and subsequently abort the test runs) in the Cling version , but not the Clang-Repl version? |
There are two tests that fail that are not export related:
MSVC defaults to int as the base type for enums ; |
Ok, so the tests need to be adjusted for windows... |
clang-tidy review says "All clean, LGTM! 👍" |
Maybe memory was double free'ed in cling::Value or it was uninitialized data being free'ed? |
Let’s move forward here and address the remaining issues in a subsequent PR. |
Not all tests pass yet, but they shouldn't crash early with a fatal assert from Clang any more. The library tests could fail in assert builds before because an Error value for a from a Coff symbol in Dyld::BuildBloomFilter was not handled, those errors were actually revealing another issue that search path to load shared libraries to find symbols should be much more restricted instead of PATH environment variable.
I also added the exporting of some MSVC runtime symbols based on the code from Clings cmake files to try and fix STL symbol errors, but tests still fail because of missing emulated TLS symbols
__emutls_get_address and __emutls_v._Init_thread_epoch
.Current failing tests are: