https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64882

--- Comment #5 from Uroš Bizjak <ubizjak at gmail dot com> ---
This is target problem, address_no_seg_operand should check the mode for all
non-CONST_INT_P operands (please see the comment above the predicate).

So, we have to narrow the condition to:

--cut here--
Index: config/i386/predicates.md
===================================================================
--- config/i386/predicates.md   (revision 220302)
+++ config/i386/predicates.md   (working copy)
@@ -971,6 +971,11 @@
   struct ix86_address parts;
   int ok;

+  if (!CONST_INT_P (op)
+      && mode != VOIDmode
+      && GET_MODE (op) != mode)
+    return false;
+
   ok = ix86_decompose_address (op, &parts);
   gcc_assert (ok);
   return parts.seg == SEG_DEFAULT;
--cut here--

Reply via email to