aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-vectorizer.h
diff options
context:
space:
mode:
authorRichard Biener <rguenther@suse.de>2020-05-20 15:14:47 +0200
committerRichard Biener <rguenther@suse.de>2020-05-22 08:51:24 +0200
commitf8fb2ea2b17d38518a9ef9c8774bf4adc726e508 (patch)
tree8719d1731f942f90809c2834efd508abc4960ac4 /gcc/tree-vectorizer.h
parentdc7aee01cd59aeebe3b0a944d97a8f0d05d9d645 (diff)
downloadgcc-f8fb2ea2b17d38518a9ef9c8774bf4adc726e508.zip
gcc-f8fb2ea2b17d38518a9ef9c8774bf4adc726e508.tar.gz
gcc-f8fb2ea2b17d38518a9ef9c8774bf4adc726e508.tar.bz2
add ctor/dtor to slp_tree
This adds constructor and destructor to slp_tree factoring common code. I've not changed the wrappers to overloaded CTORs since I hope to use object_allocator<> and am not sure whether that can be done in any fancy way yet. 2020-05-22 Richard Biener <rguenther@suse.de> * tree-vectorizer.h (_slp_tree::_slp_tree): New. (_slp_tree::~_slp_tree): Likewise. * tree-vect-slp.c (_slp_tree::_slp_tree): Factor out code from allocators. (_slp_tree::~_slp_tree): Implement. (vect_free_slp_tree): Simplify. (vect_create_new_slp_node): Likewise. Add nops parameter. (vect_build_slp_tree_2): Adjust. (vect_analyze_slp_instance): Likewise.
Diffstat (limited to 'gcc/tree-vectorizer.h')
-rw-r--r--gcc/tree-vectorizer.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/tree-vectorizer.h b/gcc/tree-vectorizer.h
index 38a0a1d..4f506bd 100644
--- a/gcc/tree-vectorizer.h
+++ b/gcc/tree-vectorizer.h
@@ -118,6 +118,9 @@ typedef struct _slp_tree *slp_tree;
/* A computation tree of an SLP instance. Each node corresponds to a group of
stmts to be packed in a SIMD stmt. */
struct _slp_tree {
+ _slp_tree ();
+ ~_slp_tree ();
+
/* Nodes that contain def-stmts of this node statements operands. */
vec<slp_tree> children;