boostorg / boostorg/lockfree

alignment change in 1.77 beta breaks VS 2017 builds

Open
#71 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
160
Forks
99
PR merge metrics
No merged PRs in 30d

Description

The underlying issue with the VS2017 compiler is shown [here on godbolt](https://godbolt.org/z/Mq6TrcEGf).

The error was triggered in our code base (which works fine with boost-1.76) where we have boost::lockfree::queue in classes managed by shared_ptr. It is probably due to [this commit](https://github.com/boostorg/lockfree/commit/9144954d247024db8b21da0bca3fa7f20edd4fcc).

Note that `boost::lockfree::queue>`, [which is already pretty large](https://godbolt.org/z/dbzKoYdeb), increases by 60 bytes.

Of course, there is an easy fix by defining `_ENABLE_EXTENDED_ALIGNED_STORAGE`, but there is a reason they did not enable this by default.

This issue is obviously not a deal breaker but it will make upgrading boost from 1.76 to 1.77 troublesome for many users.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the linked Godbolt reproducer and the lockfree commit 9144954d247024db8b21da0ca3fa7f20edd4fcc, comparing Boost 1.76 and 1.77 behavior for boost::lockfree::queue under VS 2017. Done means the queue can again be used in shared_ptr-managed classes with VS 2017 without requiring _ENABLE_EXTENDED_ALIGNED_STORAGE.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.