Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
Root
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
为了安全,强烈建议开启2FA双因子认证:User Settings -> Account -> Enable two-factor authentication!!!
Show more breadcrumbs
cxwx
Root
Commits
d1cda8b4
Commit
d1cda8b4
authored
6 years ago
by
Danilo Piparo
Browse files
Options
Downloads
Patches
Plain Diff
[TTreeProcessorMT] Remove protections to cope with task interleaving
parent
26421c3c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
tree/treeplayer/inc/ROOT/TTreeProcessorMT.hxx
+0
-15
0 additions, 15 deletions
tree/treeplayer/inc/ROOT/TTreeProcessorMT.hxx
tree/treeplayer/src/TTreeProcessorMT.cxx
+0
-6
0 additions, 6 deletions
tree/treeplayer/src/TTreeProcessorMT.cxx
with
0 additions
and
21 deletions
tree/treeplayer/inc/ROOT/TTreeProcessorMT.hxx
+
0
−
15
View file @
d1cda8b4
...
@@ -71,7 +71,6 @@ namespace ROOT {
...
@@ -71,7 +71,6 @@ namespace ROOT {
// NOTE: fFriends must come before fChain to be deleted after it, see ROOT-9281 for more details
// NOTE: fFriends must come before fChain to be deleted after it, see ROOT-9281 for more details
std
::
vector
<
std
::
unique_ptr
<
TChain
>>
fFriends
;
///< Friends of the tree/chain
std
::
vector
<
std
::
unique_ptr
<
TChain
>>
fFriends
;
///< Friends of the tree/chain
std
::
unique_ptr
<
TChain
>
fChain
;
///< Chain on which to operate
std
::
unique_ptr
<
TChain
>
fChain
;
///< Chain on which to operate
std
::
vector
<
Long64_t
>
fLoadedEntries
;
///<! Per-task loaded entries (for task interleaving)
////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////
/// Construct fChain, also adding friends if needed and injecting knowledge of offsets if available.
/// Construct fChain, also adding friends if needed and injecting knowledge of offsets if available.
...
@@ -161,20 +160,6 @@ namespace ROOT {
...
@@ -161,20 +160,6 @@ namespace ROOT {
// we need to return the entry list too, as it needs to be in scope as long as the reader is
// we need to return the entry list too, as it needs to be in scope as long as the reader is
return
std
::
make_pair
(
std
::
move
(
reader
),
std
::
move
(
localList
));
return
std
::
make_pair
(
std
::
move
(
reader
),
std
::
move
(
localList
));
}
}
//////////////////////////////////////////////////////////////////////////
/// Push a new loaded entry to the stack.
void
PushTaskFirstEntry
(
Long64_t
entry
)
{
fLoadedEntries
.
push_back
(
entry
);
}
//////////////////////////////////////////////////////////////////////////
/// Restore the tree of the previous loaded entry, if any.
void
PopTaskFirstEntry
()
{
fLoadedEntries
.
pop_back
();
if
(
fLoadedEntries
.
size
()
>
0
)
{
fChain
->
LoadTree
(
fLoadedEntries
.
back
());
}
}
};
};
}
// End of namespace Internal
}
// End of namespace Internal
...
...
This diff is collapsed.
Click to expand it.
tree/treeplayer/src/TTreeProcessorMT.cxx
+
0
−
6
View file @
d1cda8b4
...
@@ -335,17 +335,11 @@ void TTreeProcessorMT::Process(std::function<void(TTreeReader &)> func)
...
@@ -335,17 +335,11 @@ void TTreeProcessorMT::Process(std::function<void(TTreeReader &)> func)
shouldUseGlobalEntries
?
entries
:
std
::
vector
<
Long64_t
>
({
theseClustersAndEntries
.
second
[
0
]});
shouldUseGlobalEntries
?
entries
:
std
::
vector
<
Long64_t
>
({
theseClustersAndEntries
.
second
[
0
]});
auto
processCluster
=
[
&
](
const
Internal
::
EntryCluster
&
c
)
{
auto
processCluster
=
[
&
](
const
Internal
::
EntryCluster
&
c
)
{
// This task will operate with the tree that contains start
treeView
->
PushTaskFirstEntry
(
c
.
start
);
std
::
unique_ptr
<
TTreeReader
>
reader
;
std
::
unique_ptr
<
TTreeReader
>
reader
;
std
::
unique_ptr
<
TEntryList
>
elist
;
std
::
unique_ptr
<
TEntryList
>
elist
;
std
::
tie
(
reader
,
elist
)
=
treeView
->
GetTreeReader
(
c
.
start
,
c
.
end
,
fTreeName
,
theseFiles
,
fFriendInfo
,
std
::
tie
(
reader
,
elist
)
=
treeView
->
GetTreeReader
(
c
.
start
,
c
.
end
,
fTreeName
,
theseFiles
,
fFriendInfo
,
fEntryList
,
theseEntries
,
friendEntries
);
fEntryList
,
theseEntries
,
friendEntries
);
func
(
*
reader
);
func
(
*
reader
);
// In case of task interleaving, we need to load here the tree of the parent task
treeView
->
PopTaskFirstEntry
();
};
};
pool
.
Foreach
(
processCluster
,
thisFileClusters
);
pool
.
Foreach
(
processCluster
,
thisFileClusters
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment