-
Notifications
You must be signed in to change notification settings - Fork 6
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
Include headers relative to -I #675
base: main
Are you sure you want to change the base?
Conversation
tpadioleau
commented
Nov 1, 2024
•
edited
Loading
edited
- simplifies the logic: always relative to the root,
- should better avoid clashes with namings like "macro.hpp" or "config.hpp" that other projects could also define.
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.
Most of the changes are making things slightly worse. We probably should gather more documentation on how to deal with #include
before committing to a choice.
include/ddc/detail/kokkos.hpp
Outdated
#include "macros.hpp" | ||
#include "ddc/detail/macros.hpp" |
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.
Not sure this change is sound. Using "macros.hpp"
will make the compiler look for a macros.hpp file in the current directory and not to browse the whole path list of includes.
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.
"source": https://blogs.stonesteps.ca/1/p/64
include/ddc/kernels/fft.hpp
Outdated
#include <KokkosFFT.hpp> | ||
#include <Kokkos_Core.hpp> | ||
|
||
#include "ddc/ddc.hpp" |
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.
#include "ddc/ddc.hpp" | |
#include <ddc/ddc.hpp> |
Here ddc.hpp
is not in a ddc
subdirectory of the current kernels
directory.
include/ddc/kernels/splines.hpp
Outdated
#include "ddc/ddc.hpp" | ||
#include "ddc/kernels/splines/bsplines_non_uniform.hpp" | ||
#include "ddc/kernels/splines/bsplines_uniform.hpp" | ||
#include "ddc/kernels/splines/constant_extrapolation_rule.hpp" | ||
#include "ddc/kernels/splines/deriv.hpp" | ||
#include "ddc/kernels/splines/greville_interpolation_points.hpp" | ||
#include "ddc/kernels/splines/integrals.hpp" | ||
#include "ddc/kernels/splines/knot_discrete_dimension_type.hpp" | ||
#include "ddc/kernels/splines/knots_as_interpolation_points.hpp" | ||
#include "ddc/kernels/splines/math_tools.hpp" | ||
#include "ddc/kernels/splines/null_extrapolation_rule.hpp" | ||
#include "ddc/kernels/splines/periodic_extrapolation_rule.hpp" | ||
#include "ddc/kernels/splines/spline_boundary_conditions.hpp" | ||
#include "ddc/kernels/splines/spline_builder.hpp" | ||
#include "ddc/kernels/splines/spline_builder_2d.hpp" | ||
#include "ddc/kernels/splines/spline_evaluator.hpp" | ||
#include "ddc/kernels/splines/spline_evaluator_2d.hpp" | ||
#include "ddc/kernels/splines/splines_linear_problem.hpp" | ||
#include "ddc/kernels/splines/splines_linear_problem_2x2_blocks.hpp" | ||
#include "ddc/kernels/splines/splines_linear_problem_3x3_blocks.hpp" | ||
#include "ddc/kernels/splines/splines_linear_problem_band.hpp" | ||
#include "ddc/kernels/splines/splines_linear_problem_dense.hpp" | ||
#include "ddc/kernels/splines/splines_linear_problem_maker.hpp" | ||
#include "ddc/kernels/splines/splines_linear_problem_pds_band.hpp" | ||
#include "ddc/kernels/splines/splines_linear_problem_pds_tridiag.hpp" | ||
#include "ddc/kernels/splines/splines_linear_problem_sparse.hpp" | ||
#include "ddc/kernels/splines/view.hpp" |
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.
If you go this path, I think <>
is more appropriate.
#include <ddc/ddc.hpp> | ||
|
||
#include "view.hpp" | ||
#include "ddc/ddc.hpp" |
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 think this change is not necessary.
|
||
#include "math_tools.hpp" | ||
#include "view.hpp" | ||
#include "ddc/ddc.hpp" |
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.
Same here
Well a choice was made when we started the project. Of course we can change it if there is a better choice. Here is my understanding of the choice (note that I may have again misunderstood this choice):
|
Back to draft the time we get consensus |
@cedricchevalier19 What do you think if:
Regarding 1., an issue is about the
Let me know if you have better ideas. |
8d9e351
to
b62dd89
Compare
Other idea:
with components:
|
b62dd89
to
554a311
Compare
I think this approach is easy to enforce if you are ok dealing with deep file hierarchies. |
Are you aware of difficulties with deep file hierarchies ? In a such a config there would still be one file that I don't really know how to handle which is |