We ICE on this testcase, because the usage of #pragma GCC ivdep
pulls in the ANNOTATE internal functions which don't have underlying
fndecls, hence we segv on a NULL_TREE. This patch makes get_attrs_for
be prepared for such a scenario. The callers of get_attrs_for already
check for NULL_TREE. I don't think internal fns can have transaction_*
attributes anyway. While at it, I did some cleanups.
Bootstrapped/regtested on {ppc64,x86_64}-linux, ok for trunk?
2015-01-13 Marek Polacek <polacek@redhat.com>
PR middle-end/64391
* trans-mem.c (get_attrs_for): Return NULL_TREE if X is NULL_TREE.
* gcc.dg/tm/pr64391.c: New test.