public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/108075] New: Undefined typeinfo for _Float16 (_ZTIDF16_)
@ 2022-12-12 13:11 andrey458641387 at gmail dot com
2022-12-12 13:30 ` [Bug libstdc++/108075] " jakub at gcc dot gnu.org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: andrey458641387 at gmail dot com @ 2022-12-12 13:11 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108075
Bug ID: 108075
Summary: Undefined typeinfo for _Float16 (_ZTIDF16_)
Product: gcc
Version: 13.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: andrey458641387 at gmail dot com
Target Milestone: ---
The following program compiles but does not link:
#include <typeinfo>
const std::type_info &a = typeid(_Float16);
with the error "undefined reference to `_ZTIDF16_'".
Compiler Explorer link: https://godbolt.org/z/eo6fbWTPr.
As a result, using `std::vector<_Float16>` with `_GLIBCXX_DEBUG` fails with
(https://godbolt.org/z/5T5GbPs7f):
in function
`_ZN11__gnu_debug16_Error_formatter10_ParameterC2IDF16_EERKPT_PKcNS0_12_Is_iteratorE':
include/c++/13.0.0/debug/formatter.h:369: undefined reference to
`_ZTIPDF16_'
This issue exists in GCC >= 12, including trunk (at least as of CE gcc version
13.0.0 20221212).
Checked on Linux x86_64 and aarch64 (on CE).
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug libstdc++/108075] Undefined typeinfo for _Float16 (_ZTIDF16_)
2022-12-12 13:11 [Bug libstdc++/108075] New: Undefined typeinfo for _Float16 (_ZTIDF16_) andrey458641387 at gmail dot com
@ 2022-12-12 13:30 ` jakub at gcc dot gnu.org
2022-12-12 14:51 ` jakub at gcc dot gnu.org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-12-12 13:30 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108075
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Following shows much more types without typeinfo (only _Float128x is fine
because it isn't supported on any target).
#include <typeinfo>
#ifdef __STDCPP_FLOAT16_T__
const std::type_info &a = typeid(decltype(0.0f16));
#endif
#ifdef __STDCPP_BFLOAT16_T__
const std::type_info &b = typeid(decltype(0.0bf16));
#endif
#ifdef __STDCPP_FLOAT32_T__
const std::type_info &c = typeid(decltype(0.0f32));
#endif
#ifdef __STDCPP_FLOAT64_T__
const std::type_info &d = typeid(decltype(0.0f64));
#endif
#ifdef __STDCPP_FLOAT128_T__
const std::type_info &e = typeid(decltype(0.0f128));
#endif
#ifdef __FLT32X_MAX__
const std::type_info &f = typeid(decltype(0.0f32x));
#endif
#ifdef __FLT64X_MAX__
const std::type_info &g = typeid(decltype(0.0f64x));
#endif
#ifdef __FLT128X_MAX__
const std::type_info &h = typeid(decltype(0.0f128x));
#endif
int
main ()
{
}
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug libstdc++/108075] Undefined typeinfo for _Float16 (_ZTIDF16_)
2022-12-12 13:11 [Bug libstdc++/108075] New: Undefined typeinfo for _Float16 (_ZTIDF16_) andrey458641387 at gmail dot com
2022-12-12 13:30 ` [Bug libstdc++/108075] " jakub at gcc dot gnu.org
@ 2022-12-12 14:51 ` jakub at gcc dot gnu.org
2022-12-15 16:04 ` cvs-commit at gcc dot gnu.org
2022-12-15 16:10 ` jakub at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-12-12 14:51 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108075
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Last reconfirmed| |2022-12-12
Assignee|unassigned at gcc dot gnu.org |jakub at gcc dot gnu.org
Ever confirmed|0 |1
Status|UNCONFIRMED |ASSIGNED
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 54073
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54073&action=edit
gcc13-pr108075.patch
Untested fix. There is nothing that can be done for GCC 12 though.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug libstdc++/108075] Undefined typeinfo for _Float16 (_ZTIDF16_)
2022-12-12 13:11 [Bug libstdc++/108075] New: Undefined typeinfo for _Float16 (_ZTIDF16_) andrey458641387 at gmail dot com
2022-12-12 13:30 ` [Bug libstdc++/108075] " jakub at gcc dot gnu.org
2022-12-12 14:51 ` jakub at gcc dot gnu.org
@ 2022-12-15 16:04 ` cvs-commit at gcc dot gnu.org
2022-12-15 16:10 ` jakub at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-12-15 16:04 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108075
--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jakub Jelinek <jakub@gcc.gnu.org>:
https://gcc.gnu.org/g:3f101e32e2fb616633722fb552779f537e9a9891
commit r13-4722-g3f101e32e2fb616633722fb552779f537e9a9891
Author: Jakub Jelinek <jakub@redhat.com>
Date: Thu Dec 15 17:02:55 2022 +0100
c++, libstdc++: Add typeinfo for _Float{16,32,64,128,32x,64x} and __bf16
types [PR108075]
The following patch adds typeinfos for the extended floating point
types and _Float{32,64}x.
2022-12-15 Jakub Jelinek <jakub@redhat.com>
PR libstdc++/108075
gcc/cp/
* rtti.cc (emit_support_tinfos): Add pointers to
{bfloat16,float{16,32,64,128,32x,64x,128x}}_type_node to
fundamentals
array.
gcc/testsuite/
* g++.dg/cpp23/ext-floating13.C: New test.
libstdc++-v3/
* config/abi/pre/gnu.ver (CXXABI_1.3.14): Export
_ZTIDF[0-9]*[_bx], _ZTIPDF[0-9]*[_bx] and _ZTIPKDF[0-9]*[_bx].
* testsuite/util/testsuite_abi.cc (check_version): Handle
CXXABI_1.3.14.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug libstdc++/108075] Undefined typeinfo for _Float16 (_ZTIDF16_)
2022-12-12 13:11 [Bug libstdc++/108075] New: Undefined typeinfo for _Float16 (_ZTIDF16_) andrey458641387 at gmail dot com
` (2 preceding siblings ...)
2022-12-15 16:04 ` cvs-commit at gcc dot gnu.org
@ 2022-12-15 16:10 ` jakub at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-12-15 16:10 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108075
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed on the trunk. As I said, there is nothing that can be done for older
versions.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-12-15 16:10 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-12-12 13:11 [Bug libstdc++/108075] New: Undefined typeinfo for _Float16 (_ZTIDF16_) andrey458641387 at gmail dot com
2022-12-12 13:30 ` [Bug libstdc++/108075] " jakub at gcc dot gnu.org
2022-12-12 14:51 ` jakub at gcc dot gnu.org
2022-12-15 16:04 ` cvs-commit at gcc dot gnu.org
2022-12-15 16:10 ` jakub at gcc dot gnu.org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).