[developers] Re: PET crashes ramdomly on start

Stephan Oepen oe at csli.Stanford.EDU
Tue Mar 22 02:42:57 CET 2005

dear yi,

> I recently downloaded the main branch of PET from 
> http://www.dfki.de/~kiefer/pet-0.99.7.tar.gz
> and compiled it by my self on Fedora Core 3 with g++ 3.4.2.
> However PET randomly crash on start. For example, when i call "cheap"
> without any arguments, in 5 tries I will get the following output for 2
> or 3 times.
> --------------------------------------------------------------------
> [yzhang at takeshi cheap]$ ./cheap
> alloc: no space (up = b7f35000d, down = b7f35000d)
> terminate called after throwing an instance of 'tError'
> Aborted
> --------------------------------------------------------------------
> (The up and down value might vary.) It appears to be rather ramdom.
> Then I used gdb, and it seems there might be some problem with the
> memory management on initialization.  [...]

i am copying `developers at delph-in.net', a recently established channel 
to bernd, ulrich, myself, and several others.  i suspect the problem is
somewhat specific to recent Linux (kernel) versions: PET by default is 
using knowledge about platform-specific mmap(2) properties, and it can
unfortunately happen that newer kernels violate such assumptions about
the general layout of the address space.  in the past, ulrich has been
able to find defaults that worked across most Linux installations (that
were in active use over the past few years).  it is quite possible, we
will need to re-tune these for latest changes in the kernel (or FC3 and
other recent distributions). 

if you look at `common/chunk-alloc.cpp', you will find a section like:

  #if defined(linux)
  #define _CORE_LOW  0x50000000
  #define _CORE_HIGH 0xbf429fff
  #define _MMAP_DOWN
  #define _CORE_LOW  0x30000000
  #define _CORE_HIGH 0xd0000000
  #define _MMAP_DOWN

the above is what i currently use (with FC1), and i just realized these
are different values from what you got on the `main' branch (i am on a
different branch of source code, for the time being).  thus, you should 
try changing your `common/chunk-alloc.cpp' and recompilation.  there is
a brief discussion of the two current branches at:


i expect both bernd and i would be curious to know whether changing the
mmap(2) defaults will resolve your problem.  i was planning to move to
FC3 in the near future myself ...  

                                                 all the best  -  oe

+++ Universitetet i Oslo (ILF); Boks 1102 Blindern; 0317 Oslo; (+47) 2285 7989
+++     CSLI Stanford; Ventura Hall; Stanford, CA 94305; (+1 650) 723 0515
+++       --- oe at csli.stanford.edu; oe at hf.uio.no; stephan at oepen.net ---

More information about the developers mailing list