Skip to content
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

[Testing] Update ROOT and Cling to LLVM18 #209

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
138 commits
Select commit Hold shift + click to select a range
6d19058
[ntuple] remove small clusters write option
jblomer Aug 30, 2024
657773f
[df] Allow reading std::array branches from TTree
vepadulano Aug 3, 2024
d110ff6
[ci] Disable the win x86 dbg platform
dpiparo Sep 2, 2024
26f20db
[doxygen] use jsroot v7 modules for embeding
linev Jul 12, 2024
ca9aa3e
[ntuple] prepare to make RColumnElement private
silverweed Aug 23, 2024
0a53441
[ntuple] split RColumnElement defs into a separate private header
silverweed Aug 23, 2024
5b62c7e
[ntuple] some cleanups in RColumnElement
silverweed Sep 2, 2024
90d057e
[minuit] use std::string instead of vector<char>
linev Sep 2, 2024
ba1cf53
[minuit] simplify loop over points
linev Sep 2, 2024
dc6ced7
fix copying and cloning of HypoTestResult
will-cern Sep 2, 2024
99d92be
[core] Do not provide source string length to strncpy
linev Sep 2, 2024
fb1ddc8
[gui] fix calloc usage in TGFileItem
linev Sep 2, 2024
6214a86
[rdf] fix gcc14 warning in InterfaceUtils #16360
linev Sep 2, 2024
50088e5
[RF] Remove RooRealMPFE from public interface
guitargeek Aug 30, 2024
fe59efb
[RF] Rename and improve RooStatsUtils::MakeCleanWorkspace
guitargeek Aug 30, 2024
3f9d22a
[doxygen] use relative position for JSROOT drawings
linev Sep 3, 2024
8b9947e
[ntuple] add RNTupleDescriptorBuilder::BuildStreamerInfos()
jblomer Jun 14, 2024
c2cd687
[ntuple] Add RNTupleFileWriter::UpdateStreamerInfos()
jblomer Jun 17, 2024
9fa2309
[ntuple] remove hand-coded streamer info from mini file
jblomer Jun 17, 2024
74c0837
[ntuple] store streamer info records in ROOT file
jblomer Jun 17, 2024
f97315e
[ntuple] add test for streamer info in ROOT file
jblomer Jun 17, 2024
543b738
[ntuple] store read rules in streamer info
jblomer Jun 18, 2024
dc5513b
[ntuple] minor improvements to read rules test
jblomer Jun 18, 2024
005ed6e
[ntuple] work around ROOT bug #15877
jblomer Jun 18, 2024
09c29c0
[ntuple] refine streamer info test
jblomer Jun 18, 2024
e7cfd6c
[ntuple] fix streamer list cleanup in RNTupleFileWriter
jblomer Jul 3, 2024
e868480
[ntuple] fix compilation on some MSVC versions
jblomer Jul 4, 2024
7d6d858
[ntuple] more uniform RFieldDescriptor::IsCustomClass()
jblomer Jul 22, 2024
bebc65d
[ntuple] test BuildStreamerInfos() for [unordered_]map
jblomer Jul 22, 2024
1bf2e55
[ntuple] improve BuildStreamerInfos() testing
jblomer Jul 22, 2024
23ce70a
[ntuple] improve mini file streamer info test
jblomer Jul 22, 2024
719ca8f
[ntuple] minor simplification in WriteTFileStreamerInfo()
jblomer Jul 22, 2024
6dcae9e
[ntuple] minor simplification in mini file
jblomer Jul 22, 2024
84e665e
[ntuple] don't store read rules in TFile
jblomer Jul 23, 2024
171484d
[ntuple] fix-up BuildStreamerInfos() test
jblomer Jul 23, 2024
b9a41e5
[ntuple] fix dictionaries for descriptor tests
jblomer Jul 24, 2024
f7aab70
[ntuple] remove unused ChecksumRNTupleClass()
jblomer Sep 3, 2024
4ae7c1d
[tree] Remove unused code in TTreeReaderValue
vepadulano Aug 3, 2024
6b71ee0
[tree] Clarify ownership of friend proxies in TTreeReader
vepadulano Aug 3, 2024
d78734a
[tree] Clarify ownership of branch proxy director in TTreeReader
vepadulano Aug 3, 2024
6a4f114
[tree] Remove another unused variable
vepadulano Sep 1, 2024
1f47779
[tree] Break out of loop if friend found
vepadulano Sep 1, 2024
43a8143
[tree] Remove superfluous deletion in destructor
vepadulano Sep 1, 2024
1b1ee9d
[tree] Introduce error handling for number of events
vepadulano Aug 4, 2024
26af523
[tree] Add TTreeReader tests with mismatched event count
vepadulano Aug 4, 2024
846aebf
[tree] Fix tests with new logic to detect mismatched friend entries
vepadulano Sep 1, 2024
58a96e2
[rdf] remove lambda from InterfaceUtils.hxx
linev Sep 3, 2024
efb7e2f
[NFC][ntuple] remove meta-data envelope from specs
jblomer Aug 30, 2024
0eefd59
[ntuple] remove meta-data envelope stub s11n
jblomer Aug 30, 2024
62b694c
[ntuple] Add first evolution test for removed members
hahnjo Aug 5, 2024
5fe2db0
[ntuple] Add evolution test for removed base class
hahnjo Aug 5, 2024
a0a9764
[ntuple] Add evolution test for reordered members
hahnjo Aug 5, 2024
6257ea5
[core] Do not drop constness with casts
dpiparo Sep 6, 2024
f97c2bc
[tree] Report info about missing branch from TBranchProxy
vepadulano Sep 6, 2024
21c3f92
[NFC][ntuple] fixes to code comments
jblomer Sep 6, 2024
858d6cc
[NFC][ntuple] add clarifying comment
jblomer Sep 6, 2024
2e79b87
[NFC][ntuple] update locator specification
jblomer Aug 26, 2024
54f1eb6
[ntuple] make RNTupleLocator::fBytesOnStorage 64bit wide
jblomer Aug 26, 2024
00d26d1
[ntuple] remove kTypeURI locator
jblomer Aug 27, 2024
5cbb2bd
[ntuple] remove std::string from locator's fPosition variant
jblomer Aug 27, 2024
d76f9a9
[ntuple] implement on-demand large DAOS locator
jblomer Aug 27, 2024
823b4c7
[ntuple] add s11n support for large locators
jblomer Aug 29, 2024
2bd23fc
[ntuple] fix RPage::GetNBytes() for large pages
jblomer Aug 29, 2024
3137d04
[ntuple] fix sealed page for large sizes
jblomer Aug 29, 2024
12ddb3b
[ntuple] fix writing TKeys with large object length
jblomer Aug 29, 2024
07b289b
[ntuple] bump large pages limit test to pages >4GB
jblomer Aug 29, 2024
d4746dd
[NFC][ntuple] add clarifying comment
jblomer Sep 6, 2024
d3c928b
Do not draw error bars when they are smaller than the marker.
couet Sep 4, 2024
5a23ca8
Horizontal errors bars were missing for TGraphErrors.
couet Sep 4, 2024
2f47ab8
Use flags to do the tests only once and avoid problems with reverse l…
couet Sep 4, 2024
6727c0c
The flags need to be reset at each iteration
couet Sep 6, 2024
f381672
[Math] Implement code suggestions by `clang-tidy`
guitargeek Sep 3, 2024
aede851
[ntuple] new column type: Real32Trunc
silverweed Aug 6, 2024
1b7b3a8
[ntuple] implement proper reading/writing of Real32Trunc
silverweed Aug 7, 2024
ced9666
[ntuple] ensure Pack buffer has the proper size for Real32Trunc
silverweed Aug 8, 2024
cb996b7
[ntuple] group up Pack/Unpack related fn to a bespoke namespace
silverweed Aug 8, 2024
ee91d86
[ntuple] fix improper setting of RColumn's BitsOnStorage
silverweed Aug 8, 2024
d7e722e
[ntuple] fix FloatPacking::MinBufSize calculation
silverweed Aug 8, 2024
f7eb8d8
[ntuple] make Pack/UnpackFloats generic over the packed type
silverweed Aug 14, 2024
cb9afb7
[ntuple] relax size requirements on bit packing buffer
silverweed Aug 15, 2024
4f68805
[ntuple] don't modify src in RColumnElement<Real32Trunc>
silverweed Aug 22, 2024
0e50896
[ntuple] several fixes and cleanups for Real32Trunc
silverweed Sep 3, 2024
cb2b7ac
[ntuple] add exhaustive test in ntuple_packing for Real32Trunc
silverweed Sep 3, 2024
24392c3
[ntuple] add endianness test for Real32Trunc
silverweed Sep 3, 2024
633cddb
[ntuple] some fixes for Real32Trunc
silverweed Sep 9, 2024
178fd6a
[RF] Don't share a single static fitter for all RooMinimizer instances
guitargeek Aug 31, 2024
d3f6a54
[RF] Fix copy-paste typo in RooMinimizer
guitargeek Sep 9, 2024
c43cd7f
[RF] Avoid code duplication in RooMinimizer
guitargeek Aug 31, 2024
e5bc43f
[ntuple] disable -Warray-bounds in ntuple_packing.cxx
silverweed Sep 9, 2024
16ecb6e
[hist] Implement code suggestions by clang-tidy
guitargeek Sep 9, 2024
064217a
[tree][NFC] Add docs to TTree::GetEntriesFast
vepadulano Sep 8, 2024
63636f6
[Minuit2] Use `std::span` instead of `std::vector const&` for parameters
guitargeek Mar 22, 2024
bda8514
[Minuit2] Less manual memory allocations
guitargeek Mar 23, 2024
b81f1ca
[RelNotes] Mention Minuit 2 migration to `std::span`
guitargeek Sep 9, 2024
3e03f78
[CMake] Set the minimum required version to 3.20
dpiparo Sep 10, 2024
b0907c7
Import ROOT-llvm18
devajithvs Feb 3, 2024
1b06505
[llvm-project] Bump to tag ROOT-llvm18-20240821-01
devajithvs May 31, 2024
955bc36
[cling] Rename enums to match upstream LLVM 18
devajithvs May 27, 2024
cf8248d
[cling] `clang::codegenoptions` --> `llvm::codegenoptions`
devajithvs May 27, 2024
768c114
[cling] Use `FileEntryRef` and `getFileRef` methods
devajithvs Feb 2, 2024
9a3cdbd
[cling] Register callbacks with `MAM` instead of `FAM`
devajithvs May 28, 2024
9231dba
[cling] Include missing headers
devajithvs May 28, 2024
5d5f32a
[cling] Update includes to match headers moved to `TargetParsers`
devajithvs May 27, 2024
a55f39b
[cling] Remove unused/non-existing header `PassManagerBuilder.h`
devajithvs May 27, 2024
59dcfa7
[cling] Additional parameters in `AnnotateAttr::CreateImplicit`
devajithvs May 28, 2024
58c7cf7
[cling] Use `isPureVirtual`
devajithvs Aug 28, 2024
a875d7e
[cling] Update `ReadPreprocessorOptions` parameters
devajithvs Feb 2, 2024
7f73f75
[cling] Correct the assignment of `LangOptions`
devajithvs May 27, 2024
5a0afb1
[cling] Rename `OpenMPIsDevice` to `OpenMPIsTargetDevice`
devajithvs May 27, 2024
3403b14
[cling] Adapt to changes in llvm Option
devajithvs May 27, 2024
d4c16b6
[cling] Update `OPTION()` to match rebased OptTable
devajithvs Feb 8, 2024
7cf2f6c
[cling] JITTargetAddress --> ExecutorAddr
devajithvs Feb 2, 2024
c0551b7
[core] JITTargetAddress --> ExecutorAddr
devajithvs May 28, 2024
b83614c
[core] Use `FileEntryRef` and `DirectoryEntryRef`
devajithvs Feb 3, 2024
f656008
[core] Use `isPureVirtual`
devajithvs May 28, 2024
6ff579f
[core] Additional parameters in `AnnotateAttr::CreateImplicit`
devajithvs May 28, 2024
97244c0
[core] Include missing headers
devajithvs May 28, 2024
57468c8
[core] Rename enums to match upstream LLVM 18
devajithvs May 28, 2024
bcac194
[interpreter] Bump LLVM version
devajithvs May 31, 2024
6dbb74f
[TCling] Handle enumeration value ‘StructuralValue’
devajithvs May 27, 2024
a3c84ee
[cling] Adapt tok::eof -> tok::annot_repl_input_end
hahnjo Aug 8, 2024
fb5505c
[cling] Disable line numbers in error messages and warnings
hahnjo May 29, 2024
37cb102
[metcling] Povide a transaction before using `GetDecl()`
hahnjo May 29, 2024
fc2002f
[cling] Do not report an error if the fileType is a `tapi_file`
devajithvs May 29, 2024
c28b205
[cling] Set `BuiltinHeadersInSystemModules = 1`
hahnjo May 30, 2024
8962e22
[cling] Fix C++20 builds
devajithvs Jun 13, 2024
3eb76a4
[cling] Move generators to ProcessSymbols JITDylib
hahnjo Jul 3, 2024
6ab0c92
[cling] Replace symbols in platform Dylib
hahnjo Jul 2, 2024
9d2327b
Make parallel jobs 4 for Windows
devajithvs Aug 7, 2024
7a91b7e
[cling] Clear JITDylibs manually to avoid assertion failure
devajithvs Aug 8, 2024
70a1cdb
[cling] Enable conforming preprocessor with MSVC
hahnjo Aug 8, 2024
4950e9f
[cling] Fix option parsing, again
hahnjo Aug 20, 2024
bdd8080
[cling] Update expected output of cling/test/Lookup/data.C
hahnjo Aug 20, 2024
6055bab
[runtime_cxxmodules] Fix macOS 13 modulemap for LLVM 18
hahnjo Aug 22, 2024
cdfabcb
[cling] Store enum values as data members to fix cppyy enum tests
devajithvs Jul 5, 2024
b9005fd
[cling] Fix weak hidden symbols on AArch64
hahnjo Sep 5, 2024
bc96e54
[core] Fix ASan build with LLVM 18
hahnjo Sep 7, 2024
a52d34d
[cling] Enable JITLink by default for AArch64 on Linux
hahnjo Sep 9, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
3 changes: 2 additions & 1 deletion .github/workflows/root-ci-config/build_root.py
Original file line number Diff line number Diff line change
Expand Up @@ -375,10 +375,11 @@ def dump_requested_config(options):
@github_log_group("Build")
def cmake_build(buildtype):
generator_flags = "-- '-verbosity:minimal'" if WINDOWS else ""
parallel_jobs = "4" if WINDOWS else str(os.cpu_count())

builddir = os.path.join(WORKDIR, "build")
result = subprocess_with_log(f"""
cmake --build '{builddir}' --config '{buildtype}' --parallel '{os.cpu_count()}' {generator_flags}
cmake --build '{builddir}' --config '{buildtype}' --parallel '{parallel_jobs}' {generator_flags}
""")

if result != 0:
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/root-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,10 @@ jobs:
config: Debug
- event_name: push
config: Debug
# This is this platform is subject to timeouts when building from
# scratch.
- target_arch: x86
config: Debug

name: Windows 10 ${{ matrix.target_arch }} ${{ matrix.config }}

Expand Down
6 changes: 1 addition & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,7 @@
# For the licensing terms see $ROOTSYS/LICENSE.
# For the list of contributors see $ROOTSYS/README/CREDITS.

if(APPLE)
cmake_minimum_required(VERSION 3.19 FATAL_ERROR)
else()
cmake_minimum_required(VERSION 3.16 FATAL_ERROR)
endif()
cmake_minimum_required(VERSION 3.20 FATAL_ERROR)

if(WIN32)
# Set CMP0091 (MSVC runtime library flags are selected by an abstraction) to OLD
Expand Down
4 changes: 4 additions & 0 deletions README/ReleaseNotes/v634/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,10 @@ The [TUnfold package](https://www.desy.de/~sschmitt/tunfold.html) inside ROOT is

## Math Libraries

### Usage of `std::span<const double>` in Minuit 2 interfaces

To avoid forcing the user to do manual memory allocations via `std::vector`, the interfaces of Minuit 2 function adapter classes like `ROOT::Minuit2::FCNBase` or `ROOT::Minuit2::FCNGradientBase` were changed to accept `std::span<const double>` arguments instead of `std::vector<double> const&`.
This should have minimal impact on users, since one should usuall use Minuit 2 via the `ROOT::Math::Minimizer` interface, which is unchanged.

## RooFit Libraries

Expand Down
10 changes: 5 additions & 5 deletions core/base/inc/Bytes.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ inline void tobuf(char *&buf, UShort_t x)
# else
// To work around a stupid optimization bug in MSVC++ 6.0
const UShort_t *intermediary = &x;
char *sw = (char *) intermediary;
const char *sw = (const char *) intermediary;
buf[0] = sw[1];
buf[1] = sw[0];
# endif
Expand All @@ -89,7 +89,7 @@ inline void tobuf(char *&buf, UInt_t x)
# else
// To work around a stupid optimization bug in MSVC++ 6.0
const UInt_t *intermediary = &x;
char *sw = (char *)intermediary;
const char *sw = (const char *)intermediary;
buf[0] = sw[3];
buf[1] = sw[2];
buf[2] = sw[1];
Expand All @@ -106,7 +106,7 @@ inline void tobuf(char *&buf, ULong_t x)
#ifdef R__BYTESWAP
// To work around a stupid optimization bug in MSVC++ 6.0
const ULong_t *intermediary = &x;
char *sw = (char *)intermediary;
const char *sw = (const char *)intermediary;
if (sizeof(ULong_t) == 8) {
buf[0] = sw[7];
buf[1] = sw[6];
Expand Down Expand Up @@ -145,7 +145,7 @@ inline void tobuf(char *&buf, Long_t x)
#ifdef R__BYTESWAP
// To work around a stupid optimization bug in MSVC++ 6.0
const Long_t *intermediary = &x;
char *sw = (char *)intermediary;
const char *sw = (const char *)intermediary;
if (sizeof(Long_t) == 8) {
buf[0] = sw[7];
buf[1] = sw[6];
Expand Down Expand Up @@ -201,7 +201,7 @@ inline void tobuf(char *&buf, ULong64_t x)
# else
// To work around a stupid optimization bug in MSVC++ 6.0
const ULong64_t *intermediary = &x;
char *sw = (char *)intermediary;
const char *sw = (const char *)intermediary;
buf[0] = sw[7];
buf[1] = sw[6];
buf[2] = sw[5];
Expand Down
12 changes: 9 additions & 3 deletions core/clingutils/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,15 @@ if (runtime_cxxmodules)
set(custom_modulemaps ${custom_modulemaps} vc.modulemap)

# We need to override the default modulemap because instead of producing a
# single std.pcm, produces hundreds of pcms. This changed with sdk 15.3.
if (CMAKE_SYSTEM_NAME MATCHES Darwin AND CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 15.0.0.15000309)
set(custom_modulemaps ${custom_modulemaps} std_darwin.modulemap)
# single std.pcm, produces hundreds of pcms. This changed with MacOSX14.4.sdk
# To support macOS 13 with LLVM 18, we need to patch the modulemap from
# MacOSX14.2.sdk
if (APPLE)
if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS 15.0.0.15000309)
set(custom_modulemaps ${custom_modulemaps} std_darwin.MacOSX14.2.sdk.modulemap)
else()
set(custom_modulemaps ${custom_modulemaps} std_darwin.modulemap)
endif()
endif()

if (NOT libcxx)
Expand Down
13 changes: 7 additions & 6 deletions core/clingutils/src/TClingUtils.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -3094,7 +3094,7 @@ clang::QualType ROOT::TMetaUtils::AddDefaultParameters(clang::QualType instanceT

if (!prefix_changed && !mightHaveChanged) return originalType;
if (prefix) {
instanceType = Ctx.getElaboratedType(clang::ETK_None,prefix,instanceType);
instanceType = Ctx.getElaboratedType(clang::ElaboratedTypeKeyword::None, prefix, instanceType);
instanceType = Ctx.getQualifiedType(instanceType,prefix_qualifiers);
}
return instanceType;
Expand Down Expand Up @@ -3388,7 +3388,7 @@ std::string ROOT::TMetaUtils::GetFileName(const clang::Decl& decl,
= HdrSearch.LookupFile(llvm::sys::path::filename(headerFE->getName()),
SourceLocation(),
true /*isAngled*/, nullptr/*FromDir*/, foundDir,
ArrayRef<std::pair<const FileEntry *, const DirectoryEntry *>>(),
ArrayRef<std::pair<OptionalFileEntryRef, DirectoryEntryRef>>(),
nullptr/*Searchpath*/, nullptr/*RelPath*/,
nullptr/*SuggestedModule*/, nullptr/*RequestingModule*/,
nullptr/*IsMapped*/, nullptr /*IsFrameworkFound*/,
Expand Down Expand Up @@ -3448,7 +3448,7 @@ std::string ROOT::TMetaUtils::GetFileName(const clang::Decl& decl,
ConstSearchDirIterator* FoundDir = nullptr;
FELong = HdrSearch.LookupFile(trailingPart, SourceLocation(),
true /*isAngled*/, nullptr/*FromDir*/, FoundDir,
ArrayRef<std::pair<const FileEntry *, const DirectoryEntry *>>(),
ArrayRef<std::pair<OptionalFileEntryRef, DirectoryEntryRef>>(),
nullptr/*Searchpath*/, nullptr/*RelPath*/,
nullptr/*SuggestedModule*/, nullptr/*RequestingModule*/,
nullptr/*IsMapped*/, nullptr /*IsFrameworkFound*/);
Expand All @@ -3474,7 +3474,7 @@ std::string ROOT::TMetaUtils::GetFileName(const clang::Decl& decl,
// (or are we back to the previously found spelling, which is fine, too)
if (HdrSearch.LookupFile(trailingPart, SourceLocation(),
true /*isAngled*/, nullptr/*FromDir*/, FoundDir,
ArrayRef<std::pair<const FileEntry *, const DirectoryEntry *>>(),
ArrayRef<std::pair<OptionalFileEntryRef, DirectoryEntryRef>>(),
nullptr/*Searchpath*/, nullptr/*RelPath*/,
nullptr/*SuggestedModule*/, nullptr/*RequestingModule*/,
nullptr/*IsMapped*/, nullptr /*IsFrameworkFound*/) == FELong) {
Expand Down Expand Up @@ -4007,7 +4007,7 @@ static void KeepNParams(clang::QualType& normalizedType,
// Here we have (prefix_changed==true || mightHaveChanged), in both case
// we need to reconstruct the type.
if (prefix) {
normalizedType = astCtxt.getElaboratedType(clang::ETK_None,prefix,normalizedType);
normalizedType = astCtxt.getElaboratedType(clang::ElaboratedTypeKeyword::None, prefix, normalizedType);
normalizedType = astCtxt.getQualifiedType(normalizedType,prefix_qualifiers);
}

Expand Down Expand Up @@ -4633,7 +4633,8 @@ clang::QualType ROOT::TMetaUtils::ReSubstTemplateArg(clang::QualType input, cons
clang::NestedNameSpecifier *scope = ReSubstTemplateArgNNS(Ctxt,etype->getQualifier(),instance);
clang::QualType subTy = ReSubstTemplateArg(clang::QualType(etype->getNamedType().getTypePtr(),0),instance);

if (scope) subTy = Ctxt.getElaboratedType(clang::ETK_None,scope,subTy);
if (scope)
subTy = Ctxt.getElaboratedType(clang::ElaboratedTypeKeyword::None, scope, subTy);
subTy = Ctxt.getQualifiedType(subTy,scope_qualifiers);
return subTy;
}
Expand Down
2 changes: 1 addition & 1 deletion core/dictgen/src/DictSelectionReader.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ bool DictSelectionReader::SecondPass(const clang::RecordDecl &recordDecl)
userDefinedProperty = propNames::comment + propNames::separator + "||";
}
if (!userDefinedProperty.empty()) {
fieldPtr->addAttr(clang::AnnotateAttr::CreateImplicit(C, userDefinedProperty));
fieldPtr->addAttr(clang::AnnotateAttr::CreateImplicit(C, userDefinedProperty, nullptr, 0));
userDefinedProperty = "";
}
}
Expand Down
2 changes: 1 addition & 1 deletion core/dictgen/src/LinkdefReader.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -1082,7 +1082,7 @@ bool LinkdefReader::Parse(SelectionRules &sr, llvm::StringRef code, const std::v
clang::Token tok;
do {
PP.Lex(tok);
} while (tok.isNot(clang::tok::eof));
} while (tok.isNot(clang::tok::annot_repl_input_end));

fSelectionRules = nullptr;
return 0 == DClient.getNumErrors();
Expand Down
1 change: 1 addition & 0 deletions core/dictgen/src/Scanner.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@

#include <iostream>
#include <sstream> // class ostringstream
#include "llvm/ADT/StringExtras.h"

#include "SelectionRules.h"

Expand Down
8 changes: 4 additions & 4 deletions core/dictgen/src/TModuleGenerator.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,8 @@ TModuleGenerator::GetSourceFileKind(const char *filename) const
auto hdrFileEntry
= HdrSearch.LookupFile(filename, clang::SourceLocation(),
true /*isAngled*/, nullptr /*FromDir*/, CurDir,
clang::ArrayRef<std::pair<const clang::FileEntry*,
const clang::DirectoryEntry*>>(),
clang::ArrayRef<std::pair<clang::OptionalFileEntryRef,
clang::DirectoryEntryRef>>(),
nullptr /*SearchPath*/,/*RelativePath*/ nullptr,
nullptr /*RequestingModule*/, nullptr /*SuggestedModule*/,
nullptr /*IsMapped*/, nullptr /*IsFrameworkFound*/);
Expand Down Expand Up @@ -581,8 +581,8 @@ bool TModuleGenerator::FindHeader(const std::string &hdrName, std::string &hdrFu
if (auto hdrFileEntry
= HdrSearch.LookupFile(hdrName, clang::SourceLocation(),
true /*isAngled*/, nullptr /*FromDir*/, CurDir,
clang::ArrayRef<std::pair<const clang::FileEntry*,
const clang::DirectoryEntry*>>(),
clang::ArrayRef<std::pair<clang::OptionalFileEntryRef,
clang::DirectoryEntryRef>>(),
nullptr /*SearchPath*/, nullptr /*RelativePath*/,
nullptr /*RequestingModule*/, nullptr/*SuggestedModule*/,
nullptr /*IsMapped*/, nullptr /*IsFrameworkFound*/)) {
Expand Down
15 changes: 7 additions & 8 deletions core/dictgen/src/rootcling_impl.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ static void AnnotateFieldDecl(clang::FieldDecl &decl,
// before persisting the ProtoClasses in the root pcms.
// BEGIN ROOT PCMS
if (name == propNames::comment) {
decl.addAttr(clang::AnnotateAttr::CreateImplicit(C, value));
decl.addAttr(clang::AnnotateAttr::CreateImplicit(C, value, nullptr, 0));
}
// END ROOT PCMS

Expand All @@ -308,16 +308,15 @@ static void AnnotateFieldDecl(clang::FieldDecl &decl,
// This next line is here to use the root pcms. Indeed we need to annotate the AST
// before persisting the ProtoClasses in the root pcms.
// BEGIN ROOT PCMS
decl.addAttr(clang::AnnotateAttr::CreateImplicit(C, "!"));
decl.addAttr(clang::AnnotateAttr::CreateImplicit(C, "!", nullptr, 0));
// END ROOT PCMS
// The rest of the lines are not changed to leave in place the system which
// works with bulk header parsing on library load.
} else {
userDefinedProperty = name + propNames::separator + value;
}
ROOT::TMetaUtils::Info(nullptr, "%s %s\n", varName.c_str(), userDefinedProperty.c_str());
decl.addAttr(clang::AnnotateAttr::CreateImplicit(C, userDefinedProperty));

decl.addAttr(clang::AnnotateAttr::CreateImplicit(C, userDefinedProperty, nullptr, 0));
}
}
}
Expand Down Expand Up @@ -362,7 +361,7 @@ void AnnotateDecl(clang::CXXRecordDecl &CXXRD,
const std::string &value = attr.second;
userDefinedProperty = name + ROOT::TMetaUtils::propNames::separator + value;
if (genreflex::verbose) std::cout << " * " << userDefinedProperty << std::endl;
CXXRD.addAttr(AnnotateAttr::CreateImplicit(C, userDefinedProperty));
CXXRD.addAttr(AnnotateAttr::CreateImplicit(C, userDefinedProperty, nullptr, 0));
}
}

Expand All @@ -389,14 +388,14 @@ void AnnotateDecl(clang::CXXRecordDecl &CXXRD,
if (comment.size()) {
// The ClassDef annotation is for the class itself
if (isClassDefMacro) {
CXXRD.addAttr(AnnotateAttr::CreateImplicit(C, comment.str()));
CXXRD.addAttr(AnnotateAttr::CreateImplicit(C, comment.str(), nullptr, 0));
} else if (!isGenreflex) {
// Here we check if we are in presence of a selection file so that
// the comment does not ends up as a decoration in the AST,
// Nevertheless, w/o PCMS this has no effect, since the headers
// are parsed at runtime and the information in the AST dumped by
// rootcling is not relevant.
(*I)->addAttr(AnnotateAttr::CreateImplicit(C, comment.str()));
(*I)->addAttr(AnnotateAttr::CreateImplicit(C, comment.str(), nullptr, 0));
}
}
// Match decls with sel rules if we are in presence of a selection file
Expand Down Expand Up @@ -3909,7 +3908,7 @@ static bool ModuleContainsHeaders(TModuleGenerator &modGen, clang::HeaderSearch
header, clang::SourceLocation(),
/*isAngled*/ false,
/*FromDir*/ 0, CurDir,
clang::ArrayRef<std::pair<const clang::FileEntry *, const clang::DirectoryEntry *>>(),
clang::ArrayRef<std::pair<clang::OptionalFileEntryRef, clang::DirectoryEntryRef>>(),
/*SearchPath*/ 0,
/*RelativePath*/ 0,
/*RequestingModule*/ 0, &SuggestedModule,
Expand Down
2 changes: 1 addition & 1 deletion core/meta/src/TClass.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -698,7 +698,7 @@ void TDumpMembers::Inspect(TClass *cl, const char *pname, const char *mname, con
}
}
if (isPrintable) {
strncpy(line + kvalue, *ppointer, std::min( i, kline - kvalue));
strncpy(line + kvalue, *ppointer, kline - kvalue);
line[kvalue+i] = 0;
} else {
line[kvalue] = 0;
Expand Down
9 changes: 5 additions & 4 deletions core/metacling/src/TCling.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -3236,8 +3236,8 @@ Bool_t TCling::IsLoaded(const char* filename) const
clang::SourceLocation(),
/*isAngled*/ false,
/*FromDir*/ nullptr, CurDir,
clang::ArrayRef<std::pair<const clang::FileEntry *,
const clang::DirectoryEntry *>>(),
clang::ArrayRef<std::pair<clang::OptionalFileEntryRef,
clang::DirectoryEntryRef>>(),
/*SearchPath*/ nullptr,
/*RelativePath*/ nullptr,
/*RequestingModule*/ nullptr,
Expand Down Expand Up @@ -7034,6 +7034,7 @@ static std::string GetClassSharedLibsForModule(const char *cls, cling::LookupHel
case TemplateArgument::Integral:
case TemplateArgument::Pack:
case TemplateArgument::NullPtr:
case TemplateArgument::StructuralValue:
case TemplateArgument::Expression:
case TemplateArgument::Template:
case TemplateArgument::TemplateExpansion: return;
Expand Down Expand Up @@ -8723,7 +8724,7 @@ void TCling::SetDeclAttr(DeclId_t declId, const char* attribute)
{
Decl* decl = static_cast<Decl*>(const_cast<void*>(declId));
ASTContext &C = decl->getASTContext();
decl->addAttr(AnnotateAttr::CreateImplicit(C, attribute));
decl->addAttr(AnnotateAttr::CreateImplicit(C, attribute, nullptr, 0));
}

//______________________________________________________________________________
Expand Down Expand Up @@ -8902,7 +8903,7 @@ Long_t TCling::FuncTempInfo_Property(FuncTempInfo_t *ft_info) const
if (md->isVirtual()) {
property |= kIsVirtual;
}
if (md->isPure()) {
if (md->isPureVirtual()) {
property |= kIsPureVirtual;
}
if (const clang::CXXConstructorDecl *cd =
Expand Down
7 changes: 3 additions & 4 deletions core/metacling/src/TClingCallbacks.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,7 @@ class AutoloadLibraryMU : public llvm::orc::MaterializationUnit {
}

if (addr) {
loadedSymbols[symbol] =
llvm::JITEvaluatedSymbol(llvm::pointerToJITTargetAddress(addr), llvm::JITSymbolFlags::Exported);
loadedSymbols[symbol] = {llvm::orc::ExecutorAddr::fromPtr(addr), llvm::JITSymbolFlags::Exported};
} else {
// Collect all failing symbols, delegate their responsibility and then
// fail their materialization. R->defineNonExistent() sounds like it
Expand Down Expand Up @@ -858,7 +857,7 @@ bool TClingCallbacks::tryResolveAtRuntimeInternal(LookupResult &R, Scope *S) {
// is a gross hack, because TClingCallbacks shouldn't know about
// EvaluateTSynthesizer at all!

Wrapper->addAttr(AnnotateAttr::CreateImplicit(C, "__ResolveAtRuntime"));
Wrapper->addAttr(AnnotateAttr::CreateImplicit(C, "__ResolveAtRuntime", nullptr, 0));

// Here we have the scope but we cannot do Sema::PushDeclContext, because
// on pop it will try to go one level up, which we don't want.
Expand Down Expand Up @@ -995,7 +994,7 @@ bool TClingCallbacks::tryInjectImplicitAutoKeyword(LookupResult &R, Scope *S) {
// Annotate the decl to give a hint in cling.
// FIXME: We should move this in cling, when we implement turning it on
// and off.
Result->addAttr(AnnotateAttr::CreateImplicit(C, "__Auto"));
Result->addAttr(AnnotateAttr::CreateImplicit(C, "__Auto", nullptr, 0));

R.addDecl(Result);

Expand Down
17 changes: 9 additions & 8 deletions core/metacling/src/TClingDataMemberInfo.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -397,16 +397,17 @@ Longptr_t TClingDataMemberInfo::Offset()
// clang there is misbehaviour in MangleContext::shouldMangleDeclName.
// enum constants are essentially numbers and don't get addresses. However
// ROOT expects the address to the enum constant initializer to be returned.
else if (const EnumConstantDecl *ECD = dyn_cast<EnumConstantDecl>(D))
else if (const EnumConstantDecl *ECD = dyn_cast<EnumConstantDecl>(D)) {
// The raw data is stored as a long long, so we need to find the 'long'
// part.
#ifdef R__BYTESWAP
// In this case at the beginning.
return reinterpret_cast<Longptr_t>(ECD->getInitVal().getRawData());
#else
// In this case in the second part.
return reinterpret_cast<Longptr_t>(((char*)ECD->getInitVal().getRawData())+sizeof(Longptr_t) );
#endif

// The memory leak for `EnumConstantDecl` was fixed in:
// https://github.com/llvm/llvm-project/pull/78311
// We were relying on the leak to provide the address for EnumConstantDecl.
// Now store the data value as a member instead.
fEnumValue = ECD->getInitVal().getExtValue();
return reinterpret_cast<Longptr_t>(&fEnumValue);
}
return -1L;
}

Expand Down
1 change: 1 addition & 0 deletions core/metacling/src/TClingDataMemberInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ class TClingDataMemberInfo final : public TClingDeclInfo {
TClingDataMemberIter fIter; // Current decl.
std::string fTitle; // The meta info for the member.
bool fFirstTime = true; // We need to skip the first increment to support the cint Next() semantics.
int64_t fEnumValue; // Special case to handle enums

mutable std::string fIoType;
mutable std::string fIoName;
Expand Down
Loading