Coda File System

Re: pthreads / lwp

From: Jan Harkes <>
Date: Fri, 5 Nov 1999 13:17:23 -0500
On Fri, Nov 05, 1999 at 10:05:35AM -0500, Thomas Valentino Crimi wrote:
>  Jan,
>   How deep are your pthreads patches?  I'm considering getting coda to
> work on my FreeBSD Alpha machine, but my cursory attempt to get lwm to
> work failed (I also had to make numerous long -> time_t changes - is
> there any reason to go with longs?).  Would you say it's easier to keep
> working with lwm or to try to merge ptrheads (#ifdef?) :)

Hi Thomas,

First I should warn you. At the moment most of the code is not 64-bit
clean. An alpha port will therefore involve a lot of work.

The pthread patches are only agains LWP. I actually `emulate' LWP
behaviour (non-preemptive cooperative threads) by using a run_lock
mutex to only allow one thread to run at a time. Unless ofcourse a
thread voluntarily give up this mutex in which case it will run
completely preemptive.

The reason for doing it this way is that most of the code doesn't expect
to be preempted, and only a little locking is done. There are also only
about 3 threads for which it will make a big difference when they are
made preemptive. The rvm_flush thread, which commits pending
transactions back to disk, and the rpc2/sftp_SocketListener that handle
incoming requests/replies and the filetransfers.

But as the API is unmodified it probably suffers from many of the same
64-bit problems as the existing implementation.

Received on 1999-11-05 13:19:53