Tree [b1ddcb] 3.1 / Misc /
History



File Date Author Commit
RPM 2012-04-06 Benjamin Peterson Benjamin Peterson [739533] bump to 3.1.5 final
TextMate 2008-05-16 Alexandre Vassalotti Alexandre Vassalotti [b63072] Merged revisions 63208-63209,63211-63212,63214-...
Vim 2010-07-03 Brett Cannon Brett Cannon [fa7151] Trailing whitespace is bad for .rst files.
ACKS 2011-06-10 Benjamin Peterson Benjamin Peterson [8625ce] fix regression in netrc comment handling (close...
HISTORY 2010-10-06 Georg Brandl Georg Brandl [a4c974] Merged revisions 78959,79170,79175,79177,79180,...
NEWS 2013-10-30 Benjamin Peterson Benjamin Peterson [b1ddcb] use the collapsed path in the run_cgi method (c...
Porting 2009-11-13 Benjamin Peterson Benjamin Peterson [a0951f] Merged revisions 76235 via svnmerge from
README 2010-08-14 Florent Xicluna Florent Xicluna [656fe6] Merged revisions 83212,83829,83833,83838-83839,...
README.AIX 2011-02-25 Georg Brandl Georg Brandl [5b35bb] Merged revisions 88438,88440 via svnmerge from
README.Emacs 2010-10-29 Barry Warsaw Barry Warsaw [8fa132] Fix issue 10214 by removing the out of date pyt...
README.OpenBSD 2012-03-14 Matthias Klose Matthias Klose [55ab7a] - rename configure.in to configure.ac
README.coverity 2006-08-11 Thomas Wouters Thomas Wouters [654c38] Merged revisions 46753-51188 via svnmerge from
README.klocwork 2006-08-21 Thomas Wouters Thomas Wouters [3674f2] Merge current trunk into p3yk. This includes th...
README.valgrind 2006-04-21 Thomas Wouters Thomas Wouters [f73185] Merge p3yk branch with the trunk up to revision...
RFD 1994-01-26 Guido van Rossum Guido van Rossum [c9b3f7] Initial revision
SpecialBuilds.txt 2011-02-25 Georg Brandl Georg Brandl [c79665] Merged revisions 87101,87146,87156,87172,87175,...
build.sh 2010-03-12 Georg Brandl Georg Brandl [6ae090] Merged revisions 78882 via svnmerge from
cheatsheet 2010-09-01 Antoine Pitrou Antoine Pitrou [944232] Issue #9549: sys.setdefaultencoding() and PyUni...
developers.txt 2010-11-26 Georg Brandl Georg Brandl [9bead9] Merged revisions 85820,85823,85825,85840,85843-...
gdbinit 2010-11-26 Georg Brandl Georg Brandl [728193] Merged revisions 86134,86315-86316,86390,86424-...
indent.pro 2010-11-26 Georg Brandl Georg Brandl [728193] Merged revisions 86134,86315-86316,86390,86424-...
maintainers.rst 2011-02-26 Éric Araujo Éric Araujo [31d4b0] Typos
pymemcompat.h 2010-09-06 Florent Xicluna Florent Xicluna [6a8b5a] typo
python-config.in 2010-10-18 Barry Warsaw Barry Warsaw [82b083] One more change for issue 9807, by Matthias Klose.
python-wing.wpr 2010-07-25 Michael Foord Michael Foord [9ecbde] Issue #4686 - add .args to exceptions in the co...
python.man 2012-02-21 Georg Brandl Georg Brandl [358aee] Remove reST markup from --help output. Also: O...
python.pc.in 2010-11-24 Barry Warsaw Barry Warsaw [a763ed] Final patch for issue 9807.
setuid-prog.c 2010-05-09 Antoine Pitrou Antoine Pitrou [f19740] Recorded merge of revisions 81032 via svnmerge ...
valgrind-python.supp 2009-06-04 Georg Brandl Georg Brandl [3f6211] #3791: remove last traces of bsddb.
vgrindefs 2006-09-06 Georg Brandl Georg Brandl [c94f37] Patch #1550800: make exec a function.

Read Me

This documentation tries to help people who intend to use Python on
AIX.

There used to be many issues with Python on AIX, but the major ones
have been corrected for version 3.2, so that Python should now work
rather well on this platform. The remaining known issues are listed in
this document.


======================================================================
			   Compiling Python
----------------------------------------------------------------------

You can compile Python with gcc or the native AIX compiler. The native
compiler used to give better performances on this system with older
versions of Python.  With Python 3.2 it may not be the case anymore,
as this compiler does not allow compiling Python with computed gotos.
Some benchmarks need to be done.

Compiling with gcc:

cd Python-3.2
CC=gcc OPT="-O2" ./configure --enable-shared
make

There are various aliases for the native compiler.  The recommended
alias for compiling Python is 'xlc_r', which provides a better level of
compatibility and handles thread initialization properly.

It is a good idea to add the '-qmaxmem=70000' option, otherwise the
compiler considers various files too complex to optimize.

Compiling with xlc:

cd Python-3.2
CC=xlc_r OPT="-O2 -qmaxmem=70000" ./configure --without-computed-gotos --enable-shared
make

Note:
On AIX 5.3 and earlier, you will also need to specify the
"--disable-ipv6" flag to configure. This has been corrected in AIX
6.1.


======================================================================
			  Memory Limitations
----------------------------------------------------------------------

Note: this section may not apply when compiling Python as a 64 bit
application.

By default on AIX each program gets one segment register for its data
segment. As each segment register covers 256 MB, a Python program that
would use more than 256MB will raise a MemoryError.  The standard
Python test suite is one such application.

To allocate more segment registers to Python, you must use the linker
option -bmaxdata or the ldedit tool to specify the number of bytes you
need in the data segment.

For example, if you want to allow 512MB of memory for Python (this is
enough for the test suite to run without MemoryErrors), you should run
the following command at the end of compilation:

ldedit -b maxdata:0x20000000 ./python

You can allow up to 2GB of memory for Python by using the value
0x80000000 for maxdata.

It is also possible to go beyond 2GB of memory by activating Large
Page Use. You should consult the IBM documentation if you need to use
this option. You can also follow the discussion of this problem
in issue 11212 at bugs.python.org.

http://publib.boulder.ibm.com/infocenter/aix/v6r1/index.jsp?topic=/com.ibm.aix.cmds/doc/aixcmds3/ldedit.htm


======================================================================
			     Known issues
----------------------------------------------------------------------

Those issues are currently affecting Python on AIX:

* Python has not been fully tested on AIX when compiled as a 64 bit
  application.

* issue 3526: the memory used by a Python process will never be
  released to the system. If you have a Python application on AIX that
  uses a lot of memory, you should read this issue and you may
  consider using the provided patch that implements a custom malloc
  implementation

* issue 11184: support for large files is currently broken

* issue 11185: os.wait4 does not behave correctly with option WNOHANG

* issue 1745108: there may be some problems with curses.panel

* issue 11192: test_socket fails

* issue 11190: test_locale fails

* issue 11193: test_subprocess fails

* issue 9920: minor arithmetic issues in cmath

* issue 11215: test_fileio fails

* issue 11188: test_time fails


======================================================================
		Implementation details for developers
----------------------------------------------------------------------

Python and python modules can now be built as shared libraries on AIX
as usual.

AIX shared libraries require that an "export" and "import" file be
provided at compile time to list all extern symbols which may be
shared between modules.  The "export" file (named python.exp) for the
modules and the libraries that belong to the Python core is created by
the "makexp_aix" script before performing the link of the python
binary. It lists all global symbols (exported during the link) of the
modules and the libraries that make up the python executable.

When shared library modules (.so files) are made, a second shell
script is invoked.  This script is named "ld_so_aix" and is also
provided with the distribution in the Modules subdirectory.  This
script acts as an "ld" wrapper which hides the explicit management of
"export" and "import" files; it adds the appropriate arguments (in the
appropriate order) to the link command that creates the shared module.
Among other things, it specifies that the "python.exp" file is an
"import" file for the shared module.

This mechanism should be transparent.