[Mono-bugs] [Bug 471389] New: mono will fail with stack sizes less then 1MB on systems with 64KB pages

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Sun Feb 1 22:49:07 EST 2009


https://bugzilla.novell.com/show_bug.cgi?id=471389


           Summary: mono will fail with stack sizes less then 1MB on
                    systems with 64KB pages
    Classification: Mono
           Product: Mono: Runtime
           Version: 2.4.x
          Platform: PowerPC-64
        OS/Version: SLES 11
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: misc
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: munroesj at us.ibm.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---


Created an attachment (id=269123)
 --> (https://bugzilla.novell.com/attachment.cgi?id=269123)
Patch to use the MIN of 8 pages or 64K

User-Agent:       Mozilla/5.0 (X11; U; Linux ppc64; en-US; rv:1.8.1.19)
Gecko/20081213 SUSE/2.0.0.19-0.1 Firefox/2.0.0.19

mono/mini/mini-execeptions.c mono_setup_altstack() uses the following to
allocate guard pages:

    tls->stack_ovf_guard_size = mono_pagesize () * 8;

On platform like PowerPC whihc support multiple page size and OS like SLES11
which defaults to 64K pages this cause problems. As is this sets the guard_size
to 512K but an application may decide to use a smaller stack size for example
256K.

This not a problem on a system with 4K pages, but fails on a 64K pages system
because mono_mprotect will try to set protect on a larger area then was
actually allocated. The usual result it a segfault.

This was reported by the OpenSIM project.

Reproducible: Always

Steps to Reproduce:
1. Running a PPC64 SLES11 system
2. Specify a mono exec specifying a 256K stack
3.
Actual Results:  
segfault

Expected Results:  
Mono should us a reasonable guard size on 64K page systems and the application
should run.

-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the mono-bugs mailing list