src/sys/vm/vm_init.c v1.43 hangs amd64
    Doug White 
    dwhite at gumbysoft.com
       
    Fri Apr 30 14:04:12 PDT 2004
    
    
  
Hello,
I've been having problems with adm64 hanging under load on my dual opteron
244 machine. Its a HDAMA mainboard with 2GB RAM.  The problems started
around April 8.  I finally found some time this week to narrow down the
commit that causes the breakage; its rev 1.43 of src/sys/vm/vm_init.c.
Whats really wierd and creepy is that I can fix the hang by adding 0 to
the size argument of a kmem_suballoc() call. This leads me to think
there's a gcc bug creeping around here somewhere.
In rev 1.42, line 192 of src/sys/vm/vm_init.c looks like this:
        pager_map = kmem_suballoc(clean_map, &kmi->pager_sva, &kmi->pager_eva,
                                (nswbuf*MAXPHYS) + pager_map_size);
rev 1.43 looks like this:
        pager_map = kmem_suballoc(clean_map, &kmi->pager_sva, &kmi->pager_eva,
                                (nswbuf*MAXPHYS));
If I change this line to:
        pager_map = kmem_suballoc(clean_map, &kmi->pager_sva, &kmi->pager_eva,
                                (nswbuf*MAXPHYS) + 0 );
the hang goes away.  The last argument to kmem_suballoc is a vm_size_t;
I'm wondering if there is some odd type conversion going on, and that the
+0 causes a different conversion.
I'm compiling with the default CFLAGS, which includes -O2. I can't seem to
find the knob to change it back to -O to test for a optimization bug.
Insights appreciated :)
-- 
Doug White                    |  FreeBSD: The Power to Serve
dwhite at gumbysoft.com          |  www.FreeBSD.org
    
    
More information about the freebsd-current
mailing list