diff options
author | Andrea Corallo <andrea.corallo@arm.com> | 2019-04-08 12:59:24 +0000 |
---|---|---|
committer | Richard Earnshaw <rearnsha@gcc.gnu.org> | 2019-04-08 12:59:24 +0000 |
commit | 450dd8b3ab7c4c2a83ed891347f980913c5dde3f (patch) | |
tree | 32a2f613d61e9e7237f8d80343c5f9314c8b2138 | |
parent | 0d0f212a51c1601659483e102183a75f76a2bc72 (diff) | |
download | gcc-450dd8b3ab7c4c2a83ed891347f980913c5dde3f.zip gcc-450dd8b3ab7c4c2a83ed891347f980913c5dde3f.tar.gz gcc-450dd8b3ab7c4c2a83ed891347f980913c5dde3f.tar.bz2 |
The fma_forest, fma_root_node and func_fma_steering classes lack a copy constructor.
The fma_forest, fma_root_node and func_fma_steering classes lack a
copy constructor. However, they contain pointers to allocated memory
so this omission can be regarded as poor style. We don't need to copy
such objects, so declare the copy constructor private to inhibit
accidental copying.
2019-04-08 Andrea Corallo <andrea.corallo@arm.com>
PR target/83033
* config/aarch64/cortex-a57-fma-steering.c (fma_forest): Prohibit copy
construction.
(fma_root_node): Likewise.
(func_fma_steering): Likewise.
From-SVN: r270207
-rw-r--r-- | gcc/ChangeLog | 8 | ||||
-rw-r--r-- | gcc/config/aarch64/cortex-a57-fma-steering.c | 10 |
2 files changed, 18 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 5339017..51fc0bf 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2019-04-08 Andrea Corallo <andrea.corallo@arm.com> + + PR target/83033 + * config/aarch64/cortex-a57-fma-steering.c (fma_forest): Prohibit copy + construction. + (fma_root_node): Likewise. + (func_fma_steering): Likewise. + 2019-04-08 Jakub Jelinek <jakub@redhat.com> PR rtl-optimization/89865 diff --git a/gcc/config/aarch64/cortex-a57-fma-steering.c b/gcc/config/aarch64/cortex-a57-fma-steering.c index f2da03a..eb91662 100644 --- a/gcc/config/aarch64/cortex-a57-fma-steering.c +++ b/gcc/config/aarch64/cortex-a57-fma-steering.c @@ -114,6 +114,9 @@ public: void dispatch (); private: + /* Prohibit copy construction. */ + fma_forest (const fma_forest &); + /* The list of roots that form this forest. */ std::list<fma_root_node *> *m_roots; @@ -148,6 +151,10 @@ public: void rename (fma_forest *); void dump_info (fma_forest *); +private: + /* Prohibit copy construction. */ + fma_node (const fma_node &); + protected: /* Root node that lead to this node. */ fma_root_node *m_root; @@ -203,6 +210,9 @@ public: void execute_fma_steering (); private: + /* Prohibit copy construction. */ + func_fma_steering (const func_fma_steering &); + void dfs (void (*) (fma_forest *), void (*) (fma_forest *, fma_root_node *), void (*) (fma_forest *, fma_node *), bool); void analyze (); |