This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix PR c++/70452 (regression in C++ parsing performance)


I like this approach a lot.  One thing, though:

On 04/01/2016 03:13 PM, Patrick Palka wrote:
+struct GTY((chain_next ("%h.prev"))) bpr_entry
+{
+  tree body;
+  tree parms;
+  tree res;
+  struct bpr_entry *prev;
+};
+
  /* Representation of entries in the constexpr function definition table.  */

  struct GTY((for_user)) constexpr_fundef {
    tree decl;
    tree body;
+  /* A chain of unused copies of this function's body awaiting reuse for
+     CALL_EXPR evaluation.  */
+  struct bpr_entry *bpr_freelist;
  };

The freelist should be discarded on GC. I think the way to achieve that is to put all the freelists into a separate deletable hash table rather than hang them off the fundefs.

Jason


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]