I've assigned to review this patch. First of all I'd like to understand general idea of this patch.
As I get, you're placing predicate locks to both entry tree leaf pages and posting tree leaf pages. But, GIN implements so called "fast scan" technique which allows it to skip some leaf pages of posting tree when these pages are guaranteed to not contain matching item pointers. Wherein the particular order of posting list scan and skip depends of their estimated size (so it's a kind of coincidence).
But thinking about this more generally, I found that proposed locking scheme is redundant. Currently when entry has posting tree, you're locking both:
1) entry tree leaf page containing pointer to posting tree,
2) leaf pages of corresponding posting tree.
Therefore conflicting transactions accessing same entry would anyway conflict while accessing the same entry tree leaf page. So, there is no necessity to lock posting tree leaf pages at all. Alternatively, if entry has posting tree, you can skip locking entry tree leaf page and lock posting tree leaf pages instead.