On Thu, Jan 11, 2024 at 3:45 AM Ken Matsui wrote:
>
> On Thu, 11 Jan 2024 at 11:14, Jonathan Wakely wrote:
> > On Thu, 11 Jan 2024 at 10:56, Ken Matsui wrote:
> > >
> > > On Thu, 11 Jan 2024 at 10:46, Jonathan Wakely wrote:
> > > > On Th
On Thu, Jan 11, 2024 at 4:02 AM Jonathan Wakely wrote:
>
> On Thu, 11 Jan 2024 at 10:50, Jonathan Wakely wrote:
> >
> > On Thu, 11 Jan 2024 at 10:12, Ken Matsui wrote:
> > >
> > > On Thu, 11 Jan 2024 at 09:55, Jonathan Wakely
> > > wrote:
> >
On Thu, Jan 11, 2024 at 4:01 AM Jonathan Wakely wrote:
>
> On Thu, 11 Jan 2024 at 11:28, Ken Matsui wrote:
> >
> > On Thu, 11 Jan 2024 at 10:50, Jonathan Wakely wrote:
> > > On Thu, 11 Jan 2024 at 10:12, Ken Matsui
> > > wrote:
> > > >
>
On Thu, 11 Jan 2024 at 11:14, Jonathan Wakely wrote:
> On Thu, 11 Jan 2024 at 10:56, Ken Matsui wrote:
> >
> > On Thu, 11 Jan 2024 at 10:46, Jonathan Wakely wrote:
> > > On Thu, 11 Jan 2024 at 09:43, Ken Matsui wrote:
> > > >
> > > > This patch
On Thu, 11 Jan 2024 at 10:50, Jonathan Wakely wrote:
> On Thu, 11 Jan 2024 at 10:12, Ken Matsui wrote:
> >
> > On Thu, 11 Jan 2024 at 09:55, Jonathan Wakely wrote:
> > >On Thu, 11 Jan 2024, 09:43 Ken Matsui, <[1]kmat...@gcc.gnu.org> wrote:
> >
On Thu, 11 Jan 2024 at 10:46, Jonathan Wakely wrote:
> On Thu, 11 Jan 2024 at 09:43, Ken Matsui wrote:
> >
> > This patch made std::filesystem::equivalent correctly throw an exception
> > when either path does not exist as per [fs.op.equivalent]/4.
>
> Thanks,
libstdc++-v3/ChangeLog:
* src/filesystem/ops-common.h (stat_type): Use using.
Signed-off-by: Ken Matsui
---
libstdc++-v3/src/filesystem/ops-common.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libstdc++-v3/src/filesystem/ops-common.h
b/libstdc++-v3/src
On Thu, 11 Jan 2024 at 09:55, Jonathan Wakely wrote:
>On Thu, 11 Jan 2024, 09:43 Ken Matsui, <[1]kmat...@gcc.gnu.org> wrote:
>
>
>
>>
libstdc++-v3/ChangeLog:
* src/filesystem/ops-common.h (stat_type): Use using.
Signed-off-by: Ken Matsui
---
libstdc++-v3/src/filesystem/ops-common.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libstdc++-v3/src/filesystem/ops-common.h
b/libstdc++-v3/src
Likewise.
* testsuite/27_io/filesystem/operations/equivalent.cc: Handle
error codes.
* testsuite/experimental/filesystem/operations/equivalent.cc:
Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/src/c++17/fs_ops.cc | 2 +-
libstdc+
: Handle
error codes.
Signed-off-by: Ken Matsui
---
libstdc++-v3/src/c++17/fs_ops.cc | 2 +-
.../testsuite/27_io/filesystem/operations/equivalent.cc | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/libstdc++-v3/src/c++17/fs_ops.cc b
This patch optimizes the compilation performance of std::is_compound.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_compound): Do not use __not_.
(is_compound_v): Use is_fundamental_v instead.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 4
On 01-10 (21:21), Jonathan Wakely wrote:
> On Wed, 10 Jan 2024 at 19:41, Ken Matsui wrote:
> >
> > This patch optimizes the compilation performance of std::is_compound
> > by dispatching to the new __is_arithmetic built-in trait.
>
> OK for trunk (no need to wait for a
On 01-10 (01:23), Ken Matsui wrote:
> This patch implements built-in trait for std::is_scalar.
>
> gcc/cp/ChangeLog:
>
> * cp-trait.def: Define __is_scalar.
> * constraint.cc (diagnose_trait_expr): Handle CPTK_IS_SCALAR.
> * semantics.cc (trait_
::is_compound compilation performance.
Here are the benchmark results:
std::is_integral:
https://github.com/ken-matsui/gcc-bench/blob/main/is_integral.md#wed-jan-10-112014-am-pst-2024
Time: -28.5606%, Peak Mem: -25.0022%, Total Mem: -22.4503%
std::is_integral_v:
https://github.com/ken-matsui/gcc
): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_arithmetic.
* g++.dg/ext/is_arithmetic.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp
This patch optimizes the compilation performance of std::is_signed
by dispatching to the new __is_signed built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_signed): Use __is_signed built-in
trait.
(is_signed_v): Likewise.
Signed-off-by: Ken Matsui
.
(finish_trait_expr): Likewise.
(floating_point_type_p): New function.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_floating_point.
* g++.dg/ext/is_floating_point.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
.
(integral_type_p): New function.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_integral.
* g++.dg/ext/is_integral.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def
This patch optimizes the compilation performance of std::is_integral
by dispatching to the new __is_integral built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_integral): Use __is_integral
built-in trait.
(is_integral_v): Likewise.
Signed-off-by: Ken
the original
implementation.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 20
1 file changed, 16 insertions(+), 4 deletions(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 9baf3b2aa46
This patch optimizes the compilation performance of std::is_compound
by dispatching to the new __is_arithmetic built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_compound): Do not use __not_.
(is_compound_v): Use is_fundamental_v instead.
Signed-off-by: Ken
/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_signed.
* g++.dg/ext/is_signed.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
This patch optimizes the compilation performance of std::is_scalar
by dispatching to the new __is_scalar built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_scalar): Use __is_scalar built-in
trait.
(is_scalar_v): Likewise.
Signed-off-by: Ken Matsui
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_unsigned.
* g++.dg/ext/is_unsigned.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_scalar.
* g++.dg/ext/is_scalar.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 13 +
1 file changed, 13 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 23ea70eca18..9baf3b2aa46 100644
--- a/libstdc++-v3/include/std/type_traits
+++ b/libstdc
): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 13 +
1 file changed, 13 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index afa281d9cc4..23ea70eca18 100644
--- a/libstdc++-v3/include/std
This patch optimizes the compilation performance of std::is_unsigned
by dispatching to the new __is_unsigned built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unsigned): Use __is_unsigned
built-in trait.
(is_unsigned_v): Likewise.
Signed-off-by: Ken
This patch optimizes the compilation performance of
std::is_unbounded_array by dispatching to the new
__is_unbounded_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unbounded_array_v): Use
__is_unbounded_array built-in trait.
Signed-off-by: Ken Matsui
/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_const.
* g++.dg/ext/is_const.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc | 4
/type_traits (is_pointer): Likewise.
(is_pointer_v): Likewise.
Co-authored-by: Jonathan Wakely
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/bits/cpp_type_traits.h | 31 ++-
libstdc++-v3/include/std/type_traits| 44 +
2 files changed, 66
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_pointer.
* g++.dg/ext/is_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_unbounded_array.
* g++.dg/ext/is_unbounded_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def
This patch optimizes the compilation performance of std::is_volatile
by dispatching to the new __is_volatile built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_volatile): Use __is_volatile
built-in trait.
(is_volatile_v): Likewise.
Signed-off-by: Ken
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_volatile.
* g++.dg/ext/is_volatile.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
This patch optimizes the compilation performance of std::is_const
by dispatching to the new __is_const built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_const): Use __is_const built-in
trait.
(is_const_v): Likewise.
Signed-off-by: Ken Matsui
benchmarks
and the instability of the benchmark results. Here are new benchmark
results:
is_const:
https://github.com/ken-matsui/gcc-bench/blob/main/is_const.md#sat-dec-23-090605-am-pst-2023
time: -4.36603%, peak memory: -0.300891%, total memory: -0.247934%
is_volatile_v:
https://github.com/ken-matsui
On Thu, Jan 4, 2024 at 2:13 PM Jonathan Wakely wrote:
>
> On Sat, 23 Dec 2023 at 22:07, Ken Matsui wrote:
> >
> > This patch optimizes the compilation performance of std::is_pointer
> > by dispatching to the new __is_pointer built-in trait.
> &
On Thu, Jan 4, 2024 at 2:16 PM Patrick Palka wrote:
>
> On Thu, 4 Jan 2024, Patrick Palka wrote:
>
> > On Sat, 23 Dec 2023, Ken Matsui wrote:
> >
> > > This patch optimizes the compilation performance of std::is_pointer
> > > by dispatching
On Thu, Jan 4, 2024 at 2:11 PM Jonathan Wakely wrote:
>
> On Sat, 23 Dec 2023 at 23:06, Ken Matsui wrote:
> >
> > This patch uses _GLIBCXX_USE_BUILTIN_TRAIT macro instead of __has_builtin
> > in the type_traits header for traits that have a corresponding fallback
> &g
_GLIBCXX_DO_NOT_USE_BUILTIN_TRAITS macro, without needing to modify the
source code.
libstdc++-v3/ChangeLog:
* include/std/type_traits: Use _GLIBCXX_USE_BUILTIN_TRAIT.
Signed-off-by: Ken Matsui
Reviewed-by: Patrick Palka
---
libstdc++-v3/include/std/type_traits | 10 +-
1 file changed, 5 insertions(+), 5
This patch optimizes the compilation performance of
std::is_unbounded_array by dispatching to the new
__is_unbounded_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unbounded_array_v): Use
__is_unbounded_array built-in trait.
Signed-off-by: Ken Matsui
.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_unbounded_array.
* g++.dg/ext/is_unbounded_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_pointer.
* g++.dg/ext/is_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
/type_traits (is_pointer): Likewise.
(is_pointer_v): Likewise.
Co-authored-by: Jonathan Wakely
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/bits/cpp_type_traits.h | 29 ++
libstdc++-v3/include/std/type_traits| 44 +
2 files changed, 65
This patch optimizes the compilation performance of std::is_volatile
by dispatching to the new __is_volatile built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_volatile): Use __is_volatile
built-in trait.
(is_volatile_v): Likewise.
Signed-off-by: Ken
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_volatile.
* g++.dg/ext/is_volatile.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
This patch optimizes the compilation performance of std::is_const
by dispatching to the new __is_const built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_const): Use __is_const built-in
trait.
(is_const_v): Likewise.
Signed-off-by: Ken Matsui
/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_const.
* g++.dg/ext/is_const.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc | 4
eries does not cause any performance regression. The main reason
of the performance regression were the exhaustiveness of the benchmarks
and the instability of the benchmark results. Here are new benchmark
results:
is_const:
https://github.com/ken-matsui/gcc-bench/blob/main/is_const.md#sat-dec-23
On Sat, Dec 23, 2023 at 1:36 PM Ken Matsui wrote:
>
> This patch implements built-in trait for std::is_const.
>
> gcc/cp/ChangeLog:
>
> * cp-trait.def: Define __is_const.
> * constraint.cc (diagnose_trait_expr): Handle CPTK_IS_CONST.
> * semant
This patch optimizes the compilation performance of std::is_const
by dispatching to the new __is_const built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_const): Use __is_const built-in
trait.
(is_const_v): Likewise.
Signed-off-by: Ken Matsui
/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_const.
* g++.dg/ext/is_const.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc | 4
eries does not cause any performance regression. The main reason
of the performance regression were the exhaustiveness of the benchmarks
and the instability of the benchmark results. Here are new benchmark
results:
is_const:
https://github.com/ken-matsui/gcc-bench/blob/main/is_const.md#sat-dec-23
/is_scoped_enum.C: Likewise.
Signed-off-by: Ken Matsui
Reviewed-by: Patrick Palka
Reviewed-by: Jason Merrill
---
gcc/testsuite/g++.dg/ext/is_array.C | 15 ---
gcc/testsuite/g++.dg/ext/is_bounded_array.C | 20 -
gcc/testsuite/g++.dg/ext/is_function.C| 41
On Thu, Dec 21, 2023 at 11:38 AM Jason Merrill wrote:
>
> On 12/21/23 10:52, Patrick Palka wrote:
> > On Thu, Dec 21, 2023 at 8:29 AM Patrick Palka wrote:
> >>
> >> On Wed, 20 Dec 2023, Ken Matsui wrote:
> >>
> >>> This patch removes th
: Likewise.
* g++.dg/ext/is_member_pointer.C: Likewise.
* g++.dg/ext/is_object.C: Likewise.
* g++.dg/ext/is_reference.C: Likewise.
* g++.dg/ext/is_scoped_enum.C: Likewise.
Signed-off-by: Ken Matsui
---
gcc/testsuite/g++.dg/ext/is_array.C | 15 ---
gcc
On Wed, Dec 20, 2023 at 7:56 AM Patrick Palka wrote:
>
> On Tue, 19 Dec 2023, Sandra Loosemore wrote:
>
> > On 12/6/23 22:11, Ken Matsui wrote:
> > > This patch series optimizes type traits compilation performance by
> > > implementing built-in type traits and usi
On Sat, Dec 16, 2023 at 8:40 AM Jonathan Wakely wrote:
>
> On Sun, 10 Dec 2023 at 18:19, Jason Merrill wrote:
> >
> > On 12/7/23 00:11, Ken Matsui wrote:
> > > This patch series optimizes type traits compilation performance by
> > > implementing built-in t
On Sun, Dec 10, 2023 at 10:19 AM Jason Merrill wrote:
>
> On 12/7/23 00:11, Ken Matsui wrote:
> > This patch series optimizes type traits compilation performance by
> > implementing built-in type traits and using them in libstdc++.
> >
> > Changes in v26:
> >
This patch optimizes the compilation performance of std::remove_pointer
by dispatching to the new remove_pointer built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (remove_pointer): Use __remove_pointer
built-in trait.
Signed-off-by: Ken Matsui
---
libstdc++-v3
This patch optimizes the compilation performance of std::is_object
by dispatching to the new __is_object built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_object): Use __is_object built-in
trait.
(is_object_v): Likewise.
Signed-off-by: Ken Matsui
of __remove_pointer.
* g++.dg/ext/remove_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc | 5 +++
gcc/testsuite/g++.dg/ext/has-builtin-1.C | 3 ++
gcc/testsuite/g++.dg/ext/remove_pointer.C | 51
implementation. Move
this under is_const_v as this depends on is_const_v.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 23 +--
1 file changed, 21 insertions(+), 2 deletions(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include
/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_object.
* g++.dg/ext/is_object.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_function.
* g++.dg/ext/is_function.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 14 ++
1 file changed, 14 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 1edd05acb4c..db880d87f60 100644
--- a/libstdc++-v3/include/std/type_traits
+++ b/libstdc++-v3
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_reference.
* g++.dg/ext/is_reference.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
.
(is_member_object_pointer_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 17 -
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 99ae825301c
.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_member_object_pointer.
* g++.dg/ext/is_member_object_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3
-in trait.
(is_member_function_pointer_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 16
1 file changed, 16 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 4ab1d29ff51
): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_member_function_pointer.
* g++.dg/ext/is_member_function_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 16 +++-
1 file changed, 15 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 4a5068791af..4ab1d29ff51 100644
--- a/libstdc++-v3
.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_member_pointer.
* g++.dg/ext/is_member_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def
.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 12
1 file changed, 12 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 2a1a0aa80ff..4a5068791af 100644
--- a/libstdc++-v3/include/std/type_traits
+++ b
.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_scoped_enum.
* g++.dg/ext/is_scoped_enum.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp
This patch optimizes the compilation performance of std::is_bounded_array
by dispatching to the new __is_bounded_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_bounded_array_v): Use
__is_bounded_array built-in trait.
Signed-off-by: Ken Matsui
.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_bounded_array.
* g++.dg/ext/is_bounded_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc| 3 ++
gcc/cp/cp-trait.def
This patch optimizes the compilation performance of std::is_array
by dispatching to the new __is_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_array): Use __is_array built-in
trait.
(is_array_v): Likewise.
Signed-off-by: Ken Matsui
/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_array.
* g++.dg/ext/is_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc | 4
ype.
(cp_parser_simple_type_specifier): Likewise.
(cp_parser_primary_expression): Call cp_lexer_peek_trait_expr.
Signed-off-by: Ken Matsui
---
gcc/cp/parser.cc | 53 +++-
1 file changed, 34 insertions(+), 19 deletions(-)
diff --git a/gcc/cp/parser
.
(cp_parser_simple_type_specifier): Remove all RID value cases
for built-in traits. Handle type-yielding built-in traits.
Co-authored-by: Patrick Palka
Signed-off-by: Ken Matsui
---
gcc/c-family/c-common.cc | 7 ---
gcc/c-family/c-common.h | 5 --
gcc/cp/cp-objcp-common.cc | 8
.
(finish_trait_expr): Likewise.
(finish_trait_type): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Sort built-in traits alphabetically.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 68 -
gcc/cp/cp-trait.def
anges in v11:
* Merged all patches into one patch series.
* Rebased on top of trunk.
* Unified commit message style.
* Used _GLIBCXX_USE_BUILTIN_TRAIT.
Ken Matsui (23):
c++: Sort built-in traits alphabetically
c-family, c++: Look up built-in traits via identif
all paddings affected by the enum rid change.
Changes in v11:
* Merged all patches into one patch series.
* Rebased on top of trunk.
* Unified commit message style.
* Used _GLIBCXX_USE_BUILTIN_TRAIT.
Ken Matsui (23):
c++: Sort built-in traits alphabetically
c-family,
On Tue, Oct 24, 2023 at 4:02 AM Jonathan Wakely wrote:
>
>
>
> On Tue, 24 Oct 2023 at 03:16, Ken Matsui wrote:
>>
>> This patch optimizes the compilation performance of std::is_function
>> by dispatching to the new __is_function built-in trait
.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_scoped_enum.
* g++.dg/ext/is_scoped_enum.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp
.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_member_object_pointer.
* g++.dg/ext/is_member_object_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3
This patch optimizes the compilation performance of std::is_volatile
by dispatching to the new __is_volatile built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_volatile): Use __is_volatile
built-in trait.
(is_volatile_v): Likewise.
Signed-off-by: Ken
): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_member_function_pointer.
* g++.dg/ext/is_member_function_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
of __remove_pointer.
* g++.dg/ext/remove_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc | 5 +++
gcc/testsuite/g++.dg/ext/has-builtin-1.C | 3 ++
gcc/testsuite/g++.dg/ext/remove_pointer.C | 51
This patch optimizes the compilation performance of std::remove_pointer
by dispatching to the new remove_pointer built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (remove_pointer): Use __remove_pointer
built-in trait.
Signed-off-by: Ken Matsui
---
libstdc++-v3
.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of
__is_member_pointer.
* g++.dg/ext/is_member_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_pointer.
* g++.dg/ext/is_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
.
* g++.dg/ext/is_invocable3.C: New test.
* g++.dg/ext/is_invocable4.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 6 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/method.h | 28 ++
gcc/cp/semantics.cc
This patch optimizes the compilation performance of
std::is_unbounded_array by dispatching to the new
__is_unbounded_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unbounded_array_v): Use
__is_unbounded_array built-in trait.
Signed-off-by: Ken Matsui
.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 12
1 file changed, 12 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index d306073a797..7fd29d8d9f2 100644
--- a/libstdc++-v3/include/std/type_traits
+++ b
I accidentally sent is_invocable patches as well, but those have no changes.
On Mon, Oct 23, 2023 at 7:04 PM Ken Matsui wrote:
>
> This patch series optimizes type traits compilation performance by
> implementing built-in type traits and using them in libstdc++.
>
>
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_function.
* g++.dg/ext/is_function.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 ++
gcc/cp/cp-trait.def | 1 +
gcc/cp/semantics.cc
301 - 400 of 1220 matches
Mail list logo