https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116537

            Bug ID: 116537
           Summary: integer_three_node looks like it can be removed
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Keywords: internal-improvement
          Severity: enhancement
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: pinskia at gcc dot gnu.org
  Target Milestone: ---

ChangeLog-2010: (integer_three_node): Add.
ChangeLog-2010: NULL_TREE in build_int_cst calls. Initialize the
integer_three_node.
builtins.cc:    arg2 = integer_three_node;
cp/ChangeLog-2010:      * decl.c (integer_three_node): Remove.
cp/ChangeLog-2010:      (cxx_init_decl_processing): Do not initialize the
integer_three_node.
cp/ChangeLog-2010:      * cp-tree.h (integer_three_node): Remove.
tree-ssa-loop-prefetch.cc:  local = nontemporal ? integer_zero_node :
integer_three_node;
tree.cc:  integer_three_node = build_int_cst (integer_type_node, 3);
tree.h:#define integer_three_node              global_trees[TI_INTEGER_THREE]


Those are the only references to integer_three_node in the whole GCC tree.

The use in builtins.cc is definitely not needed as it just calls expand_normal
right afterwards.

The use in tree-ssa-loop-prefetch.cc can just be replaced with `build_int_cst
(integer_type_node, 3);` as this is definitely not a hot loop and move over the
pass is not enabled for most of the time anyways.

Reply via email to