Ilya Leoshkevich wrote: > After r265371 (S/390: Make "b" constraint match literal pool references), > satisfies_constraint_b () started accepting memory references, whose > addresses do not pass legitimate_address_p (). Specifically, literal > pool accesses past the end of the entry they are based on are explicitly > rejected by s390_decompose_address (). This leads to ICE in early_mach > pass when trying to perform UNSPEC_LTREF substitution on such addresses. > > s390_decompose_address () check does not apply to relative addresses. > The reason it is even made is that larl_operand () does not accept > literal pool references transformed into UNSPEC_LTREF. This patch > makes larl_operand () treat plain and transformed literal pool > references identically.
I don't think this change is correct. Literal pool references that match a larl_operand ("b" constraint) should not have been transformed into UNSPEC_LTREF in the first place; see this comment and code: /* Annotate every literal pool reference in INSN by an UNSPEC_LTREF expression. Fix up MEMs as required. Skip insns which support relative addressing, because they do not use a base register. */ static void annotate_constant_pool_refs (rtx_insn *insn) { if (s390_safe_relative_long_p (insn)) return; Bye, Ulrich -- Dr. Ulrich Weigand GNU/Linux compilers and toolchain ulrich.weig...@de.ibm.com