I was looking for "official" (documented to work and intended to stay working) helper functions to use in peephole2 patterns, for checking whether e.g. a specific hard register was free to use. It appears there are some such functions obviously intended for that use and used in various ports, but they aren't documented, for example peep2_next_insn, peep2_regno_dead_p and peep2_reg_dead_p.
I expected them to be mentioned along the documentation for define_peephole2, or at least cross-referenced from there. But, no grep hits at all in doc for peep2_! -- Summary: peephole2 helper functions not documented. Product: gcc Version: 4.4.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: rtl-optimization AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: hp at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37994