Landing: 8b52a53987cc

Project / Subsystem

gcc / libstdc++

Date

2026-04-29

Author

Alexandre Oliva

Commit

8b52a53987ccec7760f023468c9400459c4fdf28

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
libstdc++
patch_id
commit_hash
8b52a53987ccec7760f023468c9400459c4fdf28
source_type
github
headline
Libstdc++: Adjust SIMD functions to handle 64-bit long double on x86
tldr
The libstdc++ SIMD functions now handle 64-bit long double types on x86 architectures.
author
Alexandre Oliva
outcome
committed
performance_win
false
breaking_change
false
series_id
series_parts
[]
tags
  • libstdc++
  • simd
  • x86
  • long double
  • abi
discussion_id_link
bugzilla_pr
date
2026-04-29T00:00:00.000Z

This change updates the libstdc++ SIMD functions to correctly handle 64-bit long double types on x86 architectures, where long double may be as wide as double. The implementation introduces new type traits, __is_x86_ps<_Tp>() and __is_x86_pd<_Tp>(), to distinguish between float and double respectively, and maps long double to double when the -mlong-double-64 option is in effect. This ensures that the SIMD intrinsics work correctly with the extended precision type, avoiding potential errors or unexpected behavior when long double is used in SIMD operations.