Skip to content

Conversation

@xokdvium
Copy link
Contributor

@xokdvium xokdvium commented Aug 11, 2025

Nix 2.30 has significanltly improved memory usage and eval performance,
which would be nice to have in nixd.

Unpinning boost182 is necessary because:

  1. Now nix from nixpkgs propagates its boost build input.
  2. Linking 2 different versions of boost into the same executable is rather risky
    wrt to ABI breaks.

@xokdvium
Copy link
Contributor Author

Huh, UBSAN barfs on:

/nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-boost-1.87.0-dev/include/boost/asio/impl/thread_pool.ipp:133:7: runtime error: load of value 32, which is not a valid value for type 'bool'
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior /nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-boost-1.87.0-dev/include/boost/asio/impl/thread_pool.ipp:133:7 in

@xokdvium
Copy link
Contributor Author

Bumping boost seems to help here, but some tests start failing for unclear reasons...

Copy link
Member

@inclyc inclyc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution! It would be great if this patch could be merged, but the CI failures need to be fixed first.

@xokdvium
Copy link
Contributor Author

The failures are really weird. When I run lit with a bunch of processes the regressions/nixd test suite fails, but that works when running the test suite with -j1 (passing it to lit).
This is cursed. I suppose something in nixpkgs broke this.

@xokdvium
Copy link
Contributor Author

Ok, so the boost thing is broken because it really does have an uninitialized variable: boostorg/asio@30b5974

…2_30

Nix 2.30 has significanltly improved memory usage and eval performance,
which would be nice to have in nixd.

Unpinning boost182 is necessary because:

1. Now nix from nixpkgs propagates its boost build input.
2. Linking 2 different versions of boost into the same executable is rather risky
   wrt to ABI breaks.
This is the new componenentized packaging abstraction
for newer versions of nix. This doesn't bring in any
of the cli components, unlike the old approach.
@xokdvium
Copy link
Contributor Author

FML! This is a boost bug indeed.

@inclyc, the CI is now fixed. Here's what was causing those failures:

This caused either a) random failures b) UBSAN to spew errors (#709 (comment))

@inclyc
Copy link
Member

inclyc commented Aug 13, 2025

LGTM, thank you!

@inclyc inclyc merged commit 5232213 into nix-community:main Aug 13, 2025
19 checks passed
@xokdvium xokdvium deleted the nix-2.30 branch August 13, 2025 09:34
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.

2 participants