public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/42164]  New: mm/rmap.c:860:1: internal compiler error: in simplify_subreg, at simplify-rtx.c:5138
@ 2009-11-24 15:47 wuzhangjin at gmail dot com
  2009-11-24 16:22 ` [Bug target/42164] " pinskia at gcc dot gnu dot org
                   ` (16 more replies)
  0 siblings, 17 replies; 18+ messages in thread
From: wuzhangjin at gmail dot com @ 2009-11-24 15:47 UTC (permalink / raw)
  To: gcc-bugs

I'm using the latest gcc 4.5 to compile the latest linux kernel(rc8).

$ mips64el-unknown-linux-gnu-gcc --version
mips64el-unknown-linux-gnu-gcc (GCC) 4.5.0 20091123 (experimental)

and encountered this error:

$ make ARCH=mips CROSS_COMPILE=mips64el-unknown-linux-gnu- mm/rmap.o
  CHK     include/linux/version.h
  CHK     include/linux/utsrelease.h
  SYMLINK include/asm -> include/asm-mips
  Checking missing-syscalls for N32
  CALL    scripts/checksyscalls.sh
  Checking missing-syscalls for O32
  CALL    scripts/checksyscalls.sh
  CALL    scripts/checksyscalls.sh
  CC      mm/rmap.o
mm/rmap.c: In function 'try_to_unmap_one':
mm/rmap.c:860:1: internal compiler error: in simplify_subreg, at
simplify-rtx.c:5138
Please submit a full bug report,

I have tried to find the exact place which introduced this error and at
last found out this line of that file:

818               swp_entry_t entry = { .val = page_private(page) };

If I change that line to:

        swp_entry_t entry = { .val = 1 };

the error will go away.

and I found that page_privete(page) is something like this:

include/linux/mm.h:

228 #define page_private(page)              ((page)->private)

So, I moved that (page)->private to the above directly, and try it with:

            swp_entry_t entry = { .val = ((page)->private) };
and 

            swp_entry_t entry = { .val = (page)->private };
and

            swp_entry_t entry = { .val = page->private };

and even tried with:

             swp_entry_t entry;
            entry.val = page->private;  

All of them failed, at last, I found the line of gcc:

5130 /* Simplify SUBREG:OUTERMODE(OP:INNERMODE, BYTE)
5131    Return 0 if no simplifications are possible.  */
5132 rtx
5133 simplify_subreg (enum machine_mode outermode, rtx op, 
5134                  enum machine_mode innermode, unsigned int byte)
5135 {
5136   /* Little bit of sanity checking.  */
5137   gcc_assert (innermode != VOIDmode);

5138   gcc_assert (outermode != VOIDmode);      --> This line.....

5139   gcc_assert (innermode != BLKmode);
5140   gcc_assert (outermode != BLKmode);


-- 
           Summary: mm/rmap.c:860:1: internal compiler error: in
                    simplify_subreg, at simplify-rtx.c:5138
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: blocker
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: wuzhangjin at gmail dot com
 GCC build triplet: i486-cross-linux-gnu
  GCC host triplet: i486-cross-linux-gnu
GCC target triplet: mips64el-unknown-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42164


^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2009-12-11 23:41 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-11-24 15:47 [Bug c/42164] New: mm/rmap.c:860:1: internal compiler error: in simplify_subreg, at simplify-rtx.c:5138 wuzhangjin at gmail dot com
2009-11-24 16:22 ` [Bug target/42164] " pinskia at gcc dot gnu dot org
2009-11-24 16:23 ` pinskia at gcc dot gnu dot org
2009-11-25  1:05 ` wuzhangjin at gmail dot com
2009-11-25  1:08 ` wuzhangjin at gmail dot com
2009-11-25  1:10 ` daney at gcc dot gnu dot org
2009-11-25  1:17 ` wuzhangjin at gmail dot com
2009-11-25  1:23 ` wuzhangjin at gmail dot com
2009-12-01  7:26 ` daney at gcc dot gnu dot org
2009-12-01  7:27 ` daney at gcc dot gnu dot org
2009-12-01 21:15 ` [Bug target/42164] [4.5 Regression] " daney at gcc dot gnu dot org
2009-12-02  0:19 ` daney at gcc dot gnu dot org
2009-12-02  0:21 ` daney at gcc dot gnu dot org
2009-12-02  1:39 ` daney at gcc dot gnu dot org
2009-12-02 12:12 ` rguenth at gcc dot gnu dot org
2009-12-04 17:46 ` [Bug rtl-optimization/42164] " daney at gcc dot gnu dot org
2009-12-04 18:21 ` daney at gcc dot gnu dot org
2009-12-11 23:41 ` hjl at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).