Skip to content

Commit def408c

Browse files
authored
Merge pull request #10294 from vgvassilev/llvm13
Update ROOT's llvm to llvm13.
2 parents 6041136 + 20ee9be commit def408c

File tree

8,428 files changed

+1320959
-525584
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

8,428 files changed

+1320959
-525584
lines changed

CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ project(ROOT)
4141
set(ENV{LANG} C)
4242

4343
#---Set paths where to put the libraries, executables and headers------------------------------
44+
file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/lib) # prevent mkdir races
4445
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
4546
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
4647
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)

bindings/pyroot/cppyy/CPyCppyy/src/ProxyWrappers.cxx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -364,9 +364,9 @@ static int BuildScopeProxyDict(Cppyy::TCppScope_t scope, PyObject* pyclass)
364364

365365
PyErr_Clear();
366366

367-
// it could still be that this is an anonymous enum, which is not in the list
367+
// it could still be that this is an unnamed enum, which is not in the list
368368
// provided by the class
369-
if (strstr(Cppyy::GetDatamemberType(scope, idata).c_str(), "(anonymous)") != 0) {
369+
if (strstr(Cppyy::GetDatamemberType(scope, idata).c_str(), "(unnamed)") != 0) {
370370
AddPropertyToClass(pyclass, scope, idata);
371371
continue;
372372
}

bindings/pyroot/cppyy/cppyy-backend/clingwrapper/src/clingwrapper.cxx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,7 @@ std::string Cppyy::ResolveEnum(const std::string& enum_type)
448448

449449
// desugar the type before resolving
450450
std::string et_short = TClassEdit::ShortType(enum_type.c_str(), 1);
451-
if (et_short.find("(anonymous") == std::string::npos) {
451+
if (et_short.find("(unnamed") == std::string::npos) {
452452
std::ostringstream decl;
453453
// TODO: now presumed fixed with https://sft.its.cern.ch/jira/browse/ROOT-6988
454454
for (auto& itype : {"unsigned int"}) {
@@ -2123,7 +2123,7 @@ bool Cppyy::IsEnumData(TCppScope_t scope, TCppIndex_t idata)
21232123
std::string ti = m->GetTypeName();
21242124

21252125
// can't check anonymous enums by type name, so just accept them as enums
2126-
if (ti.rfind("(anonymous)") != std::string::npos)
2126+
if (ti.rfind("(unnamed)") != std::string::npos)
21272127
return m->Property() & kIsEnum;
21282128

21292129
// since there seems to be no distinction between data of enum type and enum values,

bindings/pyroot/pythonizations/test/CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,9 @@ if (dataframe)
113113
ROOT_ADD_PYUNITTEST(pyroot_pyz_rdataframe_makenumpy rdataframe_makenumpy.py PYTHON_DEPS numpy)
114114
endif()
115115
if(NOT MSVC OR win_broken_tests OR CMAKE_CXX_STANDARD GREATER 14)
116-
ROOT_ADD_PYUNITTEST(pyroot_pyz_rdataframe_asnumpy rdataframe_asnumpy.py PYTHON_DEPS numpy)
116+
if(NOT MSVC OR ${LLVM_VERSION} VERSION_LESS 13.0.0 OR llvm13_broken_tests)
117+
ROOT_ADD_PYUNITTEST(pyroot_pyz_rdataframe_asnumpy rdataframe_asnumpy.py PYTHON_DEPS numpy)
118+
endif()
117119
ROOT_ADD_PYUNITTEST(pyroot_pyz_rdataframe_histo_profile rdataframe_histo_profile.py)
118120
endif()
119121
endif()

bindings/pyroot_legacy/src/RootWrapper.cxx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -398,9 +398,9 @@ static int BuildScopeProxyDict( Cppyy::TCppScope_t scope, PyObject* pyclass ) {
398398

399399
PyErr_Clear();
400400

401-
// it could still be that this is an anonymous enum, which is not in the list
401+
// it could still be that this is an unnamed enum, which is not in the list
402402
// provided by the class
403-
if ( strstr( Cppyy::GetDatamemberType( scope, idata ).c_str(), "(anonymous)" ) != 0 ) {
403+
if ( strstr( Cppyy::GetDatamemberType( scope, idata ).c_str(), "(unnamed)" ) != 0 ) {
404404
AddPropertyToClass( pyclass, scope, idata );
405405
continue;
406406
}

builtins/zlib/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ endif()
126126

127127
add_library(ZLIB::ZLIB ALIAS ZLIB)
128128

129-
set(ZLIB_LIBRARY $<TARGET_FILE:ZLIB> CACHE INTERNAL "")
129+
set(ZLIB_LIBRARY $<TARGET_FILE:ZLIB::ZLIB> CACHE INTERNAL FORCE "")
130130
set(ZLIB_LIBRARIES ZLIB::ZLIB CACHE INTERNAL "")
131131

132132
if(DEFINED ZLIB_LIBRARY_DEBUG)

cmake/modules/RootBuildOptions.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,7 @@ ROOT_BUILD_OPTION(vdt ON "Enable support for VDT (fast and vectorisable mathemat
191191
ROOT_BUILD_OPTION(veccore OFF "Enable support for VecCore SIMD abstraction library")
192192
ROOT_BUILD_OPTION(vecgeom OFF "Enable support for VecGeom vectorized geometry library")
193193
ROOT_BUILD_OPTION(win_broken_tests OFF "Enable broken tests on Windows")
194+
ROOT_BUILD_OPTION(llvm13_broken_tests OFF "Enable broken tests with LLVM 13 on Windows")
194195
ROOT_BUILD_OPTION(winrtdebug OFF "Link against the Windows debug runtime library")
195196
ROOT_BUILD_OPTION(x11 ON "Enable support for X11/Xft")
196197
ROOT_BUILD_OPTION(xml ON "Enable support for XML (requires libxml2)")

cmake/modules/SetUpWindows.cmake

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,9 @@ elseif(MSVC)
4545
if(win_broken_tests)
4646
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DR__ENABLE_BROKEN_WIN_TESTS")
4747
endif()
48+
if(llvm13_broken_tests)
49+
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DR__ENABLE_LLVM13_BROKEN_TESTS")
50+
endif()
4851
else()
4952
set(CMAKE_CXX_FLAGS "-nologo -FIw32pragma.h -FIsehmap.h ${BLDCXXFLAGS} -EHsc- -W3 -wd4244 -D_WIN32 ${ARCH}")
5053
set(CMAKE_C_FLAGS "-nologo -FIw32pragma.h -FIsehmap.h ${BLDCFLAGS} -EHsc- -W3 -D_WIN32 ${ARCH}")

core/base/src/TApplication.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -823,7 +823,7 @@ GetUrlForDataMember(const TString &scopeName, const TString &dataMemberName, TDa
823823
// We create a TString with the name of the scope and the enumeration from which the enumerator is.
824824
TString scopeEnumeration = dataMember->GetTrueTypeName();
825825
TString md5EnumClass;
826-
if (scopeEnumeration.Contains("(anonymous)")) {
826+
if (scopeEnumeration.Contains("(unnamed)")) {
827827
// FIXME: need to investigate the numbering scheme.
828828
md5EnumClass.Append(scopeName);
829829
md5EnumClass.Append("::@1@1");

core/clingutils/res/TClingUtils.h

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -569,6 +569,24 @@ std::string GetModuleFileName(const char* moduleName);
569569
// that can be used in C++ as a variable name.
570570
void GetCppName(std::string &output, const char *input);
571571

572+
//______________________________________________________________________________
573+
// Demangle the input symbol name for dlsym.
574+
static inline std::string DemangleNameForDlsym(const std::string& name)
575+
{
576+
std::string nameForDlsym = name;
577+
578+
#ifdef R__MACOSX
579+
// The JIT gives us a mangled name which has an additional leading underscore
580+
// macOS, for instance __ZN8TRandom34RndmEv. However, dlsym requires us to
581+
// remove it.
582+
// FIXME: get this information from the DataLayout via getGlobalPrefix()!
583+
if (nameForDlsym[0] == '_')
584+
nameForDlsym.erase(0, 1);
585+
#endif //R__MACOSX
586+
587+
return nameForDlsym;
588+
}
589+
572590
//______________________________________________________________________________
573591
// Return the type with all parts fully qualified (most typedefs),
574592
// including template arguments, appended to name.

0 commit comments

Comments
 (0)