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

--- Comment #4 from Uroš Bizjak <ubizjak at gmail dot com> ---
(In reply to Uroš Bizjak from comment #3)

> Reopened, it looks that some sections are not handled correctly.
Following patch fixes the failure:

Index: i386.c
===================================================================
--- i386.c      (revision 236182)
+++ i386.c      (working copy)
@@ -15475,7 +15475,7 @@ legitimize_pic_address (rtx orig, rtx reg)
          new_rtx = gen_rtx_UNSPEC (Pmode, gen_rtvec (1, addr), UNSPEC_PCREL);
          new_rtx = gen_rtx_CONST (Pmode, new_rtx);
        }
-      else if (TARGET_64BIT && ix86_cmodel != CM_LARGE_PIC)
+      else if (TARGET_64BIT && ix86_cmodel == CM_SMALL_PIC)
        {
          new_rtx = gen_rtx_UNSPEC (Pmode, gen_rtvec (1, addr),
                                    UNSPEC_GOTPCREL);

Reply via email to