https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
Jakub Jelinek changed:
What|Removed |Added
Target Milestone|13.3|13.4
--- Comment #20 from Jakub
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
--- Comment #19 from Peter Dimov ---
This should work.
I still don't understand why JF so insisted on all these padding shenanigans.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
--- Comment #18 from Jonathan Wakely ---
So maybe:
diff --git a/libstdc++-v3/include/bits/atomic_base.h
b/libstdc++-v3/include/bits/atomic_base.h
index aa7374bb252..662cff39df5 100644
--- a/libstdc++-v3/include/bits/atomic_base.h
+++
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
--- Comment #17 from Jonathan Wakely ---
(In reply to Jonathan Wakely from comment #15)
> --- a/libstdc++-v3/include/std/atomic
> +++ b/libstdc++-v3/include/std/atomic
> @@ -238,8 +238,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
>
>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
--- Comment #16 from Jonathan Wakely ---
Alternatively, we could skip all the padding cope in compare_exchange for
C++11, since that was a C++20 change and not a DR.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
--- Comment #15 from Jonathan Wakely ---
--- a/libstdc++-v3/include/std/atomic
+++ b/libstdc++-v3/include/std/atomic
@@ -238,8 +238,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
constexpr atomic(_Tp __i) noexcept : _M_i(__i)
{
-#if
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
--- Comment #14 from Jonathan Wakely ---
Because a constexpr function can't have an if statement in C++11.
But maybe we should just clear padding unconditionally for C++11.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
--- Comment #13 from Peter Dimov ---
(In reply to Andrew Pinski from comment #10)
> #if __cplusplus >= 201402L && __has_builtin(__builtin_clear_padding)
> if _GLIBCXX17_CONSTEXPR (__atomic_impl::__maybe_has_padding<_Tp>())
>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
--- Comment #12 from Andrew Pinski ---
(In reply to Peter Dimov from comment #11)
> So, basically, C++14 and above initialize the padding of
>
> ```
> std::atomic state{{ 0, 0x }};
> ```
>
> in `main` to zero, which masks the problem
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
--- Comment #11 from Peter Dimov ---
So, basically, C++14 and above initialize the padding of
```
std::atomic state{{ 0, 0x }};
```
in `main` to zero, which masks the problem in `generate`. (The problem in
`generate` still exists
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865
Andrew Pinski changed:
What|Removed |Added
Summary|[13/14/15 Regression] |[13/14/15 Regression]
11 matches
Mail list logo