http://code.google.com/p/data-race-test/wiki/ThreadSanitizer is a dynamic data
race detector that runs on top of valgrind. With this patch, the binaries at
http://code.google.com/p/data-race-test/wiki/ThreadSanitizer#Binaries pass many
but not all of the Python tests. All of regrtest still passes outside of tsan.
I've implemented part of the C1x atomic types so that we can explicitly mark
variables that are used across threads, and get defined behavior as compilers
advance.
I've added tsan's client header and implementation to the codebase in
dynamic_annotations.{h,c} (docs at
http://code.google.com/p/data-race-test/wiki/DynamicAnnotations).
Unfortunately, I haven't been able to get helgrind and drd to give sensible
error messages, even when I use their client annotations, so I'm not supporting
them.
module now takes an optional timeout argument in seconds. Timeout support
relies on the system threading library, so as to avoid a semi-busy wait
loop.
svn+ssh://pythondev@svn.python.org/python/trunk
........
r79837 | antoine.pitrou | 2010-04-06 17:38:25 +0200 (mar., 06 avril 2010) | 19 lines
14 years later, we still don't know what it's for.
Spotted by the PyPy developers.
Original commit is:
branch: trunk
user: guido
date: Mon Aug 19 21:32:04 1996 +0200
files: Python/getargs.c
description:
[svn r6499] Support for keyword arguments (PyArg_ParseTupleAndKeywords) donated by
Geoff Philbrick <philbric@delphi.hks.com> (slightly changed by me).
Also a little change to make the file acceptable to K&R C compilers
(HPUX, SunOS 4.x).
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r79642 | benjamin.peterson | 2010-04-02 20:08:34 -0500 (Fri, 02 Apr 2010) | 1 line
split out large test function
........
r79644 | benjamin.peterson | 2010-04-02 20:28:57 -0500 (Fri, 02 Apr 2010) | 1 line
give TypeError when trying to set T_STRING_INPLACE
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r79555 | antoine.pitrou | 2010-04-01 18:42:11 +0200 (jeu., 01 avril 2010) | 5 lines
Issue #8276: PyEval_CallObject() is now only available in macro form. The
function declaration, which was kept for backwards compatibility reasons,
is now removed (the macro was introduced in 1997!).
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r79205 | benjamin.peterson | 2010-03-21 12:34:54 -0500 (Sun, 21 Mar 2010) | 1 line
rewrite a bit
........
r79219 | benjamin.peterson | 2010-03-21 14:24:08 -0500 (Sun, 21 Mar 2010) | 1 line
flatten condition
........
r79228 | benjamin.peterson | 2010-03-21 14:35:39 -0500 (Sun, 21 Mar 2010) | 1 line
remove pointless condition
........
r79230 | benjamin.peterson | 2010-03-21 14:39:52 -0500 (Sun, 21 Mar 2010) | 1 line
co_varnames is certainly a tuple, so let's not waste time finding out
........
r79232 | benjamin.peterson | 2010-03-21 14:54:56 -0500 (Sun, 21 Mar 2010) | 1 line
fix import
........
r79233 | benjamin.peterson | 2010-03-21 14:56:37 -0500 (Sun, 21 Mar 2010) | 1 line
don't write duplicate tests
........
r79235 | benjamin.peterson | 2010-03-21 15:21:00 -0500 (Sun, 21 Mar 2010) | 4 lines
improve error message from passing inadequate number of keyword arguments #6474
Note this removes the "non-keyword" or "keyword" phrases from these messages.
........
r79237 | benjamin.peterson | 2010-03-21 15:30:30 -0500 (Sun, 21 Mar 2010) | 1 line
take into account keyword arguments when passing too many args
........
POSIX systems with a C extension module. This is required in order for
the subprocess module to be made thread safe.
The pure python implementation is retained so that it can continue to be
used if for some reason the _posixsubprocess extension module is not
available.
The unittest executes tests on both code paths to guarantee compatibility.
* Moves PyLong_FromPid and PyLong_AsPid from posixmodule.c into longobject.h.
Code reviewed by jeffrey.yasskin at http://codereview.appspot.com/223077/show
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78826 | victor.stinner | 2010-03-10 23:30:19 +0100 (mer., 10 mars 2010) | 5 lines
Issue #3137: Don't ignore errors at startup, especially a keyboard interrupt
(SIGINT). If an error occurs while importing the site module, the error is
printed and Python exits. Initialize the GIL before importing the site
module.
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78527 | gregory.p.smith | 2010-02-28 17:22:39 -0800 (Sun, 28 Feb 2010) | 4 lines
Issue #7242: On Solaris 9 and earlier calling os.fork() from within a
thread could raise an incorrect RuntimeError about not holding the import
lock. The import lock is now reinitialized after fork.
........
r78550 | gregory.p.smith | 2010-02-28 22:01:02 -0800 (Sun, 28 Feb 2010) | 2 lines
Fix test to be skipped on windows.
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78393 | amaury.forgeotdarc | 2010-02-24 00:19:39 +0100 (mer., 24 févr. 2010) | 2 lines
#4852: Remove dead code in every thread implementation, unused for many years.
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77763 | eric.smith | 2010-01-26 19:28:29 -0500 (Tue, 26 Jan 2010) | 1 line
Issue #7766: Change sys.getwindowsversion() return value to a named tuple and add the additional members returned in an OSVERSIONINFOEX structure. The new members are service_pack_major, service_pack_minor, suite_mask, and product_type.
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77691 | mark.dickinson | 2010-01-22 16:18:09 +0000 (Fri, 22 Jan 2010) | 1 line
Correct typo in comment.
........
r77698 | mark.dickinson | 2010-01-22 17:04:07 +0000 (Fri, 22 Jan 2010) | 3 lines
Issue #7743: Fix a potential incorrect rounding bug in dtoa.c (2nd bug
in issue 7743).
........
r77713 | mark.dickinson | 2010-01-23 20:48:56 +0000 (Sat, 23 Jan 2010) | 3 lines
Issue #7743: Add checks for zero inputs to the lshift and mult functions;
this fixes the first bug described in issue #7743.
........
r77714 | mark.dickinson | 2010-01-23 21:25:53 +0000 (Sat, 23 Jan 2010) | 1 line
dtoa.c fix from upstream that fixes incorrectly rounded results for certain subnormals that are also halfway cases.
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77589 | mark.dickinson | 2010-01-17 20:57:56 +0000 (Sun, 17 Jan 2010) | 7 lines
Issue #7632: When Py_USING_MEMORY_DEBUGGER is defined, disable the
private memory allocation scheme in dtoa.c, along with a piece of code
that caches powers of 5 for future use. This makes it easier to
detect dtoa.c memory leaks with Valgrind or similar tools.
Patch by Stefan Krah.
........
where the right hand operand is a set of constants, by turning the set into
a frozenset and pre-building it as a constant. The comparison operation
is made against the constant instead of building a new set each time it is
executed (a similar optimization already existed which turned a list of
constants into a pre-built tuple). Patch and additional tests by Dave
Malcolm.
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77519 | mark.dickinson | 2010-01-16 10:44:00 +0000 (Sat, 16 Jan 2010) | 5 lines
Issue #7632: Fix a serious wrong output bug for string -> float conversion.
Also remove some now unused variables, and add comments clarifying the
possible outputs of the parsing section of _Py_dg_strtod. Thanks
Eric Smith for reviewing.
........
r77530 | mark.dickinson | 2010-01-16 17:57:49 +0000 (Sat, 16 Jan 2010) | 3 lines
Issue #7632: Fix one more case of incorrect rounding for str -> float
conversion (see bug 5 in the issue tracker).
........
r77533 | mark.dickinson | 2010-01-16 18:06:17 +0000 (Sat, 16 Jan 2010) | 1 line
Fix multiple uses of variable 'L' in _Py_dg_strtod, where one use requires an unsigned long and the other a signed long. See also r77421.
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77477 | mark.dickinson | 2010-01-13 18:21:53 +0000 (Wed, 13 Jan 2010) | 1 line
Add comments explaining the role of the bigcomp function in dtoa.c.
........
r77478 | mark.dickinson | 2010-01-13 19:02:37 +0000 (Wed, 13 Jan 2010) | 1 line
Clarify that sulp expects a nonnegative input, but that +0.0 is fine.
........
r77481 | mark.dickinson | 2010-01-13 20:55:03 +0000 (Wed, 13 Jan 2010) | 1 line
Simplify and annotate the bigcomp function, removing unused special cases.
........
r77482 | mark.dickinson | 2010-01-13 22:15:53 +0000 (Wed, 13 Jan 2010) | 1 line
Fix buggy comparison: LHS of comparison was being treated as unsigned.
........
r77483 | mark.dickinson | 2010-01-13 22:20:10 +0000 (Wed, 13 Jan 2010) | 1 line
More dtoa.c cleanup; remove the need for bc.dplen, bc.dp0 and bc.dp1.
........
r77490 | mark.dickinson | 2010-01-14 13:02:36 +0000 (Thu, 14 Jan 2010) | 1 line
Fix off-by-one error introduced in r77483. I have a test for this, but it currently fails due to a different dtoa.c bug; I'll add the test once that bug is fixed.
........
r77491 | mark.dickinson | 2010-01-14 13:14:49 +0000 (Thu, 14 Jan 2010) | 1 line
Issue 7632: fix a dtoa.c bug (bug 6) causing incorrect rounding. Tests to follow.
........
r77492 | mark.dickinson | 2010-01-14 14:40:20 +0000 (Thu, 14 Jan 2010) | 1 line
Issue 7632: fix incorrect rounding for long input strings with values very close to a power of 2. (See Bug 4 in the tracker discussion.)
........
r77493 | mark.dickinson | 2010-01-14 15:22:33 +0000 (Thu, 14 Jan 2010) | 1 line
Issue #7632: add tests for bugs fixed so far.
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77410 | mark.dickinson | 2010-01-10 13:06:31 +0000 (Sun, 10 Jan 2010) | 1 line
Remove unused BCinfo fields and an unused macro.
........
r77421 | mark.dickinson | 2010-01-11 17:15:13 +0000 (Mon, 11 Jan 2010) | 1 line
Change a variable type to avoid signed overflow; replace repeated '19999' constant by a define.
........
r77450 | mark.dickinson | 2010-01-12 22:23:56 +0000 (Tue, 12 Jan 2010) | 4 lines
Issue #7632: Fix a problem with _Py_dg_strtod that could lead to
crashes in debug builds, for certain long numeric strings
corresponding to subnormal values.
........
r77451 | mark.dickinson | 2010-01-12 22:55:51 +0000 (Tue, 12 Jan 2010) | 2 lines
Issue #7632: Fix a bug in dtoa.c that could lead to incorrectly-rounded results.
........
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77218 | mark.dickinson | 2010-01-01 17:27:30 +0000 (Fri, 01 Jan 2010) | 5 lines
Issue #5080: turn the DeprecationWarning from float arguments passed
to integer PyArg_Parse* format codes into a TypeError. Add a
DeprecationWarning for floats passed with the 'L' format code, which
didn't previously have a warning.
........