]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
icf: Remove unused constructors of sem_function and sem_variable
authorAndrew Pinski <quic_apinski@quicinc.com>
Tue, 25 Mar 2025 05:32:54 +0000 (22:32 -0700)
committerAndrew Pinski <quic_apinski@quicinc.com>
Fri, 25 Apr 2025 14:46:44 +0000 (07:46 -0700)
The constructors for sem_function and sem_variable that just
passes the bitmap obstack and NOT the cgraph node was unused
so let's remove it.

gcc/ChangeLog:

* ipa-icf.cc (sem_function::sem_function): Remove
the obstack argument version one.
(sem_variable::sem_variable): Likewise.
* ipa-icf.h (sem_function): Remove ctor for
obstack argument only one.
(sem_variable): Likewise.

Signed-off-by: Andrew Pinski <quic_apinski@quicinc.com>
gcc/ipa-icf.cc
gcc/ipa-icf.h

index c273032cae2dfd1f400dbc8c8162d746d2dbc539..b354fb1e704c43c63db1930864854c31141477d7 100644 (file)
@@ -233,16 +233,6 @@ void sem_item::set_hash (hashval_t hash)
 
 hash_map<const_tree, hashval_t> sem_item::m_type_hash_cache;
 
-/* Semantic function constructor that uses STACK as bitmap memory stack.  */
-
-sem_function::sem_function (bitmap_obstack *stack)
-  : sem_item (FUNC, stack), memory_access_types (), m_alias_sets_hash (0),
-    m_checker (NULL), m_compared_func (NULL)
-{
-  bb_sizes.create (0);
-  bb_sorted.create (0);
-}
-
 sem_function::sem_function (cgraph_node *node, bitmap_obstack *stack)
   : sem_item (FUNC, node, stack), memory_access_types (),
     m_alias_sets_hash (0), m_checker (NULL), m_compared_func (NULL)
@@ -1646,10 +1636,6 @@ sem_function::bb_dict_test (vec<int> *bb_dict, int source, int target)
     return (*bb_dict)[source] == target;
 }
 
-sem_variable::sem_variable (bitmap_obstack *stack): sem_item (VAR, stack)
-{
-}
-
 sem_variable::sem_variable (varpool_node *node, bitmap_obstack *stack)
 : sem_item (VAR, node, stack)
 {
index c2854ed4496063217ed60e17ef4ab5ca210c0f7b..4c9094c1950678770d92fdb451dcd777a53fda1e 100644 (file)
@@ -308,8 +308,6 @@ private:
 class sem_function: public sem_item
 {
 public:
-  /* Semantic function constructor that uses STACK as bitmap memory stack.  */
-  sem_function (bitmap_obstack *stack);
 
   /*  Constructor based on callgraph node _NODE.
       Bitmap STACK is used for memory allocation.  */
@@ -419,9 +417,6 @@ private:
 class sem_variable: public sem_item
 {
 public:
-  /* Semantic variable constructor that uses STACK as bitmap memory stack.  */
-  sem_variable (bitmap_obstack *stack);
-
   /*  Constructor based on callgraph node _NODE.
       Bitmap STACK is used for memory allocation.  */