NOTES ABOUT THE BeOS PORT ========================= The BeOS port requires BeOS R4 or higher. It uses its own threading system designated "beos-native". The "unix-jthreads" system can be made to work for the most part; however, that system relies on asynchronous I/O notifications, as well as virtual timer alarms, both of which are absent on BeOS R4. beos-native was modeled upon the oskit-pthreads system, which relies on mutexes and condition variables. BeOS has the former, but not the latter, so I defined a condition variable type based upon an article I found posted on the Web [1]. To build Kaffe for BeOS, you must configure Kaffe as follows: ./configure --disable-shared --prefix= as there is a known problem with building shared libs on R4 (yes, I realize that the fix is documented in the R4 release notes, but I'll let someone else muck with the Makefiles accordingly). As of 26 March 1999, Kaffe has not been built or tested with AWT at all. Also, the following entry points in the jthread interface have yet to be implemented: jthread_suspendall jthread_unsuspendall jthread_spinon jthread_spinoff KNOWN PROBLEMS ============== The jthread interface requires that the macros GET_JTHREAD/SET_JTHREAD and GET_COOKIE/SET_COOKIE store and retrieve per-thread information. Right now, this information is maintained in a large BeOS "area" containing an array of per_thread_info_t structures. The info for a given thread with thread id 'T' is simply (T % MAX_THREADS). Naturally, since successive calls to spawn_thread (invoked by jthread_create) will not necessarily yield contiguous thread ids, the maximum number of jthreads that can be successfully created will be somewhat less than MAX_THREADS. The implementation of forkexec() in beos-native/syscalls.c makes use of fork() instead of the recommended technique that uses load_image(). The gethostbyname() and gethostbyaddr() wrappers in beos-native/syscalls.c are not thread-safe. The test 'GCTest' gets stuck when executed from within the TestScript on a machine with 32MB of memory; it passes, though, when run from the command line. The BeanBug test in the regression test suite fails because it requires AWT. The configure script might have problems related to the Makefile in the BeOS directory not being created. To do this, type: export CONFIG_FILES=libraries/clib/awt/BeOS/Makefile export CONFIG_HEADERS= /bin/sh ./config.status REFERENCES ========== [1] "Locks and Condition Variables", http://www.cs.umd.edu/~hollings/cs412/s96/synch/locks.html REV HISTORY =========== 27 Jan 99 -- Submitted for inclusion into Kaffe, alanlb@cs.vt.edu 08 Feb 99 -- Fixed various segmentation violations 18 Mar 99 -- Implemented jcondvar_wait timeout, forkexec; fixed jthread_interrupt 22 Mar 99 -- Fixed socket read/write in beos-native/syscalls.c, redid thread cancellation (i.e., stoppage) 24 Mar 99 -- Fixed forkexec; ProcessTest now passes 26 Mar 99 -- Implemented most socket timeouts; SoTimeout now passes