https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82803
--- Comment #7 from Alexander Monakov <amonakov at gcc dot gnu.org> --- Sorry, should have double-checked when commenting. I see RTL LIM simply considers all calls non-invariant in check_maybe_invariant. I wonder if it would make sense to represent tls abi calls as unspecs up to some point like split_all_insns so they get cleaned up automatically like on i386?