[PATCH 2/5] Atomic __platform_wait: accept any 32-bit type, not just int
Thiago Macieira
thiago.macieira@intel.com
Wed Mar 3 17:27:02 GMT 2021
On Wednesday, 3 March 2021 08:21:51 PST Jonathan Wakely wrote:
> >>- = is_same_v<remove_cv_t<_Tp>, __platform_wait_t>;
> >>+ = is_scalar_v<remove_cv_t<_Tp>> && sizeof(_Tp) ==
> >>sizeof(__platform_wait_t)
> Oh, except that is_scalar is surprisingly expensive to instantiate
> (its defined in a really expensive way) and since we control all uses
> of this constant, I don't think we need it. It's only ever used from
> atomic waiting functions which are only defined for scalar types.
Thanks. Will update and re-submit.
--
Thiago Macieira - thiago.macieira (AT) intel.com
Software Architect - Intel DPG Cloud Engineering
More information about the Gcc-patches
mailing list