This is an archive of the discontinued LLVM Phabricator instance.

[libc++] WIP: use no_unique_address for base in join_view
ClosedPublic

Authored by jloser on Feb 7 2022, 6:34 PM.

Details

Summary

Let's see what CI says. I think this will work fine in clang13 onward which is
all we care about soon.

Diff Detail

Event Timeline

jloser requested review of this revision.Feb 7 2022, 6:34 PM
jloser created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptFeb 7 2022, 6:34 PM
Herald added a reviewer: Restricted Project. · View Herald Transcript
philnik accepted this revision as: philnik.Feb 8 2022, 4:16 AM
Quuxplusone added inline comments.
libcxx/include/__ranges/join_view.h
71

Was a bug ever filed? If not, please do; if so, please give a link in the commit message.

FWIW, in the absence of any other information, I'd trust the old code comment that says "don't do this" over the CI results. ;) But I'm very curious to understand what the old code comment was talking about, because how on earth could the attribute be OK on __cache_ but ICE the compiler on __base_??

jloser added inline comments.
libcxx/include/__ranges/join_view.h
71

I don't understand how/why this could crash clang. I haven't seen a relevant bug report filed (nor am I convinced it is an actual bug). The closest one I could find is https://github.com/llvm/llvm-project/issues/50766.

@zoecarver @ldionne - any ideas here?

The conflicting D119430 has landed now; sorry for the disturbance!

Quuxplusone accepted this revision.Feb 11 2022, 2:43 PM

Please update to use _LIBCPP_NO_UNIQUE_ADDRESS, but then, in the absence of any further information, I think we should just land this and see what breaks. My bet is still on "nothing." :)

This revision is now accepted and ready to land.Feb 11 2022, 2:43 PM