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

[DO NOT MERGE] Comparison between our main and the forked main #12

Open
wants to merge 28 commits into
base: main-legacy
Choose a base branch
from

Conversation

lefessan
Copy link
Member

@lefessan lefessan commented Feb 4, 2025

No description provided.

emilienlemaire and others added 28 commits June 6, 2024 14:58
This commit adds a Nix flakes to create automatically a dev environment
with `nix develop`.

I also removed the flag `-libstdc++fs` as this library is a part of
`libstdc++` since GCC 9.
Now the `run_test` script uses environment variables from the flake.
Add a shell script to run tests
`std::iterator` have been deprecated in stdc++-17. It seems that the
recommended usage to build custom iterators in modern C++ consists in
defining type aliases with the directive `using` (see for instance the
tutorial https://www.internalpointers.com/post/writing-custom-iterators-modern-cpp).
Remove `std::iterator`

`std::iterator` have been deprecated in stdc++-17. It seems that the
recommended usage to build custom iterators in modern C++ consists in
defining type aliases with the directive `using` (see for instance the
tutorial https://www.internalpointers.com/post/writing-custom-iterators-modern-cpp).
This PR reduces the huge compile time by a factor of two. I caught the
guilty template using the profiler features of `clang++`. Basically,
configure the project with

```
CXX=/usr/bin/clang++ CXXFLAGS="-ftime-trace" ./configure
```
will activate the profiler and `clang++` produces a json file per
compilation unit. The compiler instantiates massively the template `spdlog::pattern_formatter::handle_flag_` from the spdlog library. It is a well known issue (see for instance the issue gabime/spdlog#1708). The solution consists in using the compiled version of the library with the flag `-DSPDLOG_COMPILED_LIB`.

Before this commit, the compile time for the complete project was around
3m30s on my laptop. After this commit, it is 1m50s.

The size of the runtime is 69M.

This PR reduces the huge compile time by a factor of two. I caught the
guilty template using the profiler features of clang++. Basically,
configure the project with

CXX=/usr/bin/clang++ CXXFLAGS="-ftime-trace" ./configure

will activate the profiler and clang++ produces a json file per
compilation unit. The compiler instantiates massively the template spdlog::pattern_formatter::handle_flag_ from the spdlog library. It is a well known issue (see for instance the issue gabime/spdlog#1708). The solution consists in using the compiled version of the library with the flag -DSPDLOG_COMPILED_LIB.

Before this commit, the compile time for the complete project was around
3m30s on my laptop. After this commit, it is 1m50s.

The size of the runtime is now 69M.
Change test preprocessor to Superbol sql preproc
As we plan to test the legacy preprocessor and new one with gixsql
runtime, this commit modifies both the test runner and the bash script
to allow this usage.
These files are generated by `autoreconf` and we should put them in
the repository.
Add a flag to choose the preprocessor
This commit prepares the script `run_test.sh` to be run in the CI of
Superbol. Now the script configures a complete PostgreSQL database in
`_output/pg` directory.

To run the script with the legacy preprocessor:
```sh
nix develop
LEGACY_PP= ./run_test.sh
```

With the new preprocessor, you need to specify the location of Superbol:
```sh
nix develop
SUPERBOL_DIR=... ./run_test.sh
```
This commit prepares the script `run_test.sh` to be run in the CI of
Superbol. Now the script configures a complete PostgreSQL database in
`_output/pg` directory.

To run the script with the legacy preprocessor:
```sh
nix develop
LEGACY_PP= ./run_test.sh
```

With the new preprocessor, you need to specify the location of Superbol:
```sh
nix develop
SUPERBOL_DIR=... ./run_test.sh
```
It is important to stop the server after running tests.
Run spellcheck and add finalizer

It is important to stop the server after running tests.
The tests #000 and mridoni#91 always fail. This commit disables them
temporary.
Disable two tests

The tests #000 and mridoni#91 always fail. This commit disables them
temporary.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants