IAP GITLAB
Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
corsika
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Air Shower Physics
corsika
Commits
bd9b6294
Commit
bd9b6294
authored
4 years ago
by
ralfulrich
Browse files
Options
Downloads
Patches
Plain Diff
slight cleanup of SetupStack
parent
86fc5889
No related branches found
No related tags found
1 merge request
!254
History
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
Setup/SetupStack.h
+28
-13
28 additions, 13 deletions
Setup/SetupStack.h
Stack/History/HistorySecondaryView.hpp
+1
-0
1 addition, 0 deletions
Stack/History/HistorySecondaryView.hpp
Stack/History/HistoryStackExtension.h
+0
-7
0 additions, 7 deletions
Stack/History/HistoryStackExtension.h
with
29 additions
and
20 deletions
Setup/SetupStack.h
+
28
−
13
View file @
bd9b6294
...
@@ -58,28 +58,43 @@ namespace corsika::setup {
...
@@ -58,28 +58,43 @@ namespace corsika::setup {
// ---------------------------------------
// ---------------------------------------
// this is the FINAL stack we use in C8:
// this is the FINAL stack we use in C8:
// the version without history
// using Stack = detail::StackWithGeometry;
// using Stack = detail::StackWithGeometry;
// the version with history
using
Stack
=
detail
::
StackWithHistory
;
using
Stack
=
detail
::
StackWithHistory
;
/*
namespace
detail
{
See Issue 161
/*
See Issue 161
unfortunately clang does not support this in the same way (yet) as
gcc, so we have to distinguish here. If clang cataches up, we
unfortunately clang does not support this in the same way (yet) as
could remove the clang branch here and also in
gcc, so we have to distinguish here. If clang cataches up, we
corsika::Cascade. The gcc code is much more generic and
could remove the clang branch here and also in
universal. If we could do the gcc version, we won't had to define
corsika::Cascade. The gcc code is much more generic and
StackView globally, we could do it with MakeView whereever it is
universal. If we could do the gcc version, we won't had to define
actually needed. Keep an eye on this!
StackView globally, we could do it with MakeView whereever it is
*/
actually needed. Keep an eye on this!
*/
#if defined(__clang__)
#if defined(__clang__)
using
StackView
=
corsika
::
stack
::
SecondaryView
<
using
The
StackView
=
corsika
::
stack
::
SecondaryView
<
typename
corsika
::
setup
::
Stack
::
StackImpl
,
typename
corsika
::
setup
::
Stack
::
StackImpl
,
// CHECK with CLANG: corsika::setup::Stack::PIType>;
// CHECK with CLANG: corsika::setup::Stack::PIType>;
// corsika::setup::detail::StackWithGeometryInterface>;
// corsika::setup::detail::StackWithGeometryInterface>;
corsika
::
setup
::
detail
::
StackWithHistoryInterface
>
;
corsika
::
setup
::
detail
::
StackWithHistoryInterface
>
;
#elif defined(__GNUC__) || defined(__GNUG__)
#elif defined(__GNUC__) || defined(__GNUG__)
using
StackView
=
corsika
::
history
::
HistorySecondaryView
<
corsika
::
stack
::
MakeView
<
corsika
::
setup
::
Stack
>::
type
>
;
using
The
StackView
=
corsika
::
stack
::
MakeView
<
corsika
::
setup
::
Stack
>::
type
;
#endif
#endif
}
// ---------------------------------------
// this is the FINAL stackitertor (particle type) we use in C8:
// the version without history
//using StackView = detail::StackView;
// the one with history
using
StackView
=
corsika
::
history
::
HistorySecondaryView
<
detail
::
TheStackView
>
;
}
// namespace corsika::setup
}
// namespace corsika::setup
This diff is collapsed.
Click to expand it.
Stack/History/HistorySecondaryView.hpp
+
1
−
0
View file @
bd9b6294
...
@@ -24,6 +24,7 @@ namespace corsika::history {
...
@@ -24,6 +24,7 @@ namespace corsika::history {
EventPtr
event_
;
EventPtr
event_
;
public:
using
StackIteratorValue
=
typename
TView
::
StackIteratorValue
;
using
StackIteratorValue
=
typename
TView
::
StackIteratorValue
;
using
StackIterator
=
typename
TView
::
StackIterator
;
using
StackIterator
=
typename
TView
::
StackIterator
;
...
...
This diff is collapsed.
Click to expand it.
Stack/History/HistoryStackExtension.h
+
0
−
7
View file @
bd9b6294
...
@@ -90,13 +90,6 @@ namespace corsika::history {
...
@@ -90,13 +90,6 @@ namespace corsika::history {
void
SetParticleData
(
HistoryDataInterface
&
/*parent*/
)
{
void
SetParticleData
(
HistoryDataInterface
&
/*parent*/
)
{
C8LOG_TRACE
(
"HistoyDatatInterface::SetParticleData(parnt)"
);
C8LOG_TRACE
(
"HistoyDatatInterface::SetParticleData(parnt)"
);
SetParticleData
();
SetParticleData
();
// store particles at production time in Event here
auto
const
sec_index
=
event_
->
addSecondary
(
stack_sec
.
GetEnergy
(),
stack_sec
.
GetMomentum
(),
stack_sec
.
GetPID
());
stack_sec
.
SetParentEventIndex
(
sec_index
);
stack_sec
.
SetEvent
(
event_
);
}
}
void
SetEvent
(
const
std
::
shared_ptr
<
TEvent
>&
v
)
{
void
SetEvent
(
const
std
::
shared_ptr
<
TEvent
>&
v
)
{
...
...
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