hokein added inline comments.

================
Comment at: clang-tools-extra/pseudo/lib/GLR.cpp:621
     // Consume the token.
     glrShift(Heads, Terminals[I], Params, Lang, NextHeads);
 
----------------
hokein wrote:
> I think we can move the Line634 `Heads.resize(HeadsPartition)` before the 
> `glrShift()` as we only do shift on the nearly-created heads, we might gain 
> some performance back.
oops, my previous comment is incorrect, here we want the second part of the 
partition; while on recovery, we want the first part of partition.

we can pass `llvm::ArrayRef<const GSS::Node 
*>(Heads).drop_front(HeadsPartition);` as the Heads to `glrShift`.




Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D130523/new/

https://reviews.llvm.org/D130523

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to