[cxx-mem-model] testing infrastructure
Aldy Hernandez
aldyh@redhat.com
Thu Mar 10 19:58:00 GMT 2011
Hi folks.
The following is a test harness for testing atomicity problems and data
races in multi-threaded environments. Please see the README file in the
patch below, which describes the use of GDB to test in-between states in
a possibly threaded execution.
I would like to use this branch as the repository for tests of data
races introduced by the compiler (atomics, illegal memory hoists of
global variables in a multi-threaded environment, etc etc).
Eventually, as part of this project, I will be adding flags to the
compiler (-fno-allow-load-data-races, etc), which we can use to safe
guard against these illegal data race injections by the compiler. Until
then, I expect all (or most) of the tests below to fail.
A few tidbits...
1. I stole the GDB checks in the guality harness to check the presence
of GDB. If there is a more canonical way of checking the presence of a
working gdb, let me know.
2. There is a README explaining the infrastructure, and the anatomy of a
test.
3. Most of this work is actually Andrew Macleod's, who is off in a
tropical island somewhere. I have stolen most of his tests, implemented
the harness, and cleaned up things for submission. All errors, are
obviously mine.
I would appreciate comments, and/or new relevant tests/problems you have
encountered and would like fixed in the future. I know there are a few
Linux kernel problems that fall into this category.
Fire away, I don't mind being crucified.
Aldy
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: curr
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20110310/7dd47709/attachment.ksh>
More information about the Gcc-patches
mailing list