29 Commits

Author SHA1 Message Date
Julian Seward
2bdcd29d63 Implement pause().
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@442
2002-06-19 10:17:40 +00:00
Julian Seward
b05ceff761 Do pthread_rwlockattr_init.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@440
2002-06-18 09:24:34 +00:00
Julian Seward
7351752815 Do siglongjmp, although without running cleanup handlers in the section
of stack which it skips over.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@438
2002-06-18 09:07:54 +00:00
Julian Seward
f34cee7b2f Add pthread_attr_setschedpolicy / pthread_attr_getschedpolicy.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@431
2002-06-17 12:19:44 +00:00
Julian Seward
e6f8b8949a Cancellation wrapper for recvmsg.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@392
2002-06-06 08:33:54 +00:00
Julian Seward
c5b0a61b28 Inch towards JVM (Sun, 1.4.0) working.
- Thread stack size = 1 Meg
- Alias for __pthread_kill_other_threads_np
Now at least valgrind doesn't crash/assert.  Still doesn't work tho.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@373
2002-06-04 08:38:04 +00:00
Julian Seward
30b7d97214 More RH 7.3 fixes
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@369
2002-06-03 23:12:58 +00:00
Julian Seward
a75be28f6f Failed attempt to make JDK 1.4.0 work.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@361
2002-06-03 00:58:18 +00:00
Julian Seward
501f08d781 Do pthread_atter_{set,get}scope.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@360
2002-06-02 09:29:31 +00:00
Julian Seward
dbd505a061 Support for POSIX reader-writer locks (preliminary).
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@325
2002-05-27 13:00:05 +00:00
Julian Seward
09846794fc More minor fixes to make OpenOffice 1.0 work.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@321
2002-05-24 02:11:32 +00:00
Julian Seward
cce8a3ebd3 Implement pthread_yield.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@308
2002-05-22 13:17:31 +00:00
Julian Seward
8d2d128371 Don't mask libc's vfork / __vfork:
$ nm /lib/libc-2.2.4.so | grep vfork
   000b4220 T __vfork
   000b4220 W vfork

There's no __libc_vfork, so there's nothing we can do here.
Just don't supply our own version.

Not at all sure if this is correct.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@303
2002-05-21 00:51:21 +00:00
Julian Seward
2560fc9e47 Cancellation wrappers for pread/pwrite (Philip Martin).
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@287
2002-05-18 10:56:27 +00:00
Julian Seward
a57b808f60 Cancellation wrapper for __pwrite64 (Adam Zell(?))
Be more paranoid in pthread_attr_setstacksize


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@285
2002-05-18 10:43:22 +00:00
Julian Seward
a1b75f8383 Cancellation wrapper for pread64.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@283
2002-05-16 23:39:10 +00:00
Julian Seward
f3067ffa5d Minimal impl of pthread_attr_setstacksize.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@279
2002-05-16 20:51:15 +00:00
Julian Seward
9360e0621c Cancellation wrapper for sendmsg(), wierd wrapper for raise().
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@278
2002-05-16 16:57:25 +00:00
Julian Seward
30199fec47 In accordance with "build one to throw away, you will anyway (tm)",
throw away the old signals simulation and more or less start again
from scratch.  vg_signals.c is nearly a complete rewrite.  In fact
this is now the third generation of the signals simulation.

The purpose of this is to properly support signals in threads -- a
nightmare combination.  pthread_sigmask, pthread_kill and sigwait
are now alledged to work as POSIX requires.

In the process, throw away confusing and conceptually muddled old
implementation and replace with something which is more verbose but
conceptually cleaner, simpler and easier to argue is correct.

* When the client does sigaction/sigprocmask et al, the resulting
  changes are stored verbatim in SCSS -- the Static Client Signal State.
  So SCSS is the state the client believes the kernel is in.

* Every time SCSS changes, we recalculate the state the kernel
  *should* be in so that our signal simulation works.  This is the
  SKSS -- Static Kernel Signal State.  The kernel state is then
  updated accordingly.  By diffing the new and old SKSSs, the
  number of real system calls made is minimised.

* The dynamic state of the client's signals is stored in DCSS
  -- Dynamic Client Signal State.  This just records which signals
  are pending for which threads.

The big advantage of this scheme over the previous is that the SCSS ->
SKSS mapping is made explicit and gathered all in one place, rather
than spread out in a confusing way and done implicitly.  That makes it
all lot easier to decide if the mapping, which is really the heart of
the signals simulation, is correct or not.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@271
2002-05-15 21:13:39 +00:00
Julian Seward
0ba6f33e4f Add support for pthread_sigmask() and sigwait(). All absolutely
horrible, especially the latter.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@266
2002-05-13 00:16:03 +00:00
Julian Seward
8b15df18c2 Change _pthread_cleanup_push and _pthread_cleanup_pop into no-ops
rather than aborts.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@237
2002-05-08 14:08:22 +00:00
Julian Seward
9518212384 Do __pthread_initialize.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@236
2002-05-08 02:01:14 +00:00
Julian Seward
be21872520 Various cleanups following earlier exit fixes. Also add boilerplate
copyright notices.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@204
2002-05-03 20:43:10 +00:00
Julian Seward
c082a81f8f Fix more stuff broken by recent exported-symbol hackery.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@156
2002-04-26 21:01:13 +00:00
Julian Seward
205ec6efd2 Finish first pass of the symbols cleanup. Only versioned symbols remain
to do.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@155
2002-04-26 14:31:40 +00:00
Julian Seward
66b4d0b7ca Mess around with aliases to make the exported T/D/W syms look like those
of the real libpthread.so.  This is a Good Thing, despite the fact it
temporarily breaks some threaded programs.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@153
2002-04-26 13:25:00 +00:00
Julian Seward
edf9ed279b Fix many holes and bugs in an attempt to get my libpthread.so to export
the same set of symbols as the real one, which I now realise is crucial
for it to work at all.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@151
2002-04-26 03:28:18 +00:00
Julian Seward
a70e548ee7 Fix various bugs getting in the way of licq starting up.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@150
2002-04-26 00:27:53 +00:00
Julian Seward
c107508a0f Try and give at least some minimal binding for all functions exported
by the real libpthread.so.  In the process fix a bunch of stuff, including
adding thread-specific h_errno and resolver state storage.  This fixes
licq crashing at startup.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@149
2002-04-25 20:17:29 +00:00