Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-17 Thread Gregory Shimansky
Evgueni Brevnov wrote: In other words we will observe the crash as we do now if sem_wait completes unsuccessfully for whatever reason... Well it shouldn't return an error except for signal, shouldn't it? Two possible other errors are EINVAL and EDEADLK which should never happen. Maybe we

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-16 Thread Evgueni Brevnov
the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody comment on that? It might be that semantic is different on different platforms which

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-16 Thread Gregory Shimansky
Evgueni Brevnov wrote: You can look at the change here http://issues.apache.org/jira/browse/HARMONY-2203 Could someone who knowns classlib native code internals better than me comment on this JIRA? I've added my comment from the general POV. I would change the loop to detect only signal

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-16 Thread Geir Magnusson Jr.
Yes - that's why I was poking him to see the patch. I was going to suggest something very similar. geir Gregory Shimansky wrote: Evgueni Brevnov wrote: You can look at the change here http://issues.apache.org/jira/browse/HARMONY-2203 Could someone who knowns classlib native code

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-16 Thread Evgueni Brevnov
Gregory, The code which goes after sem_wait doesn't work properly if sem_wait returns with an error code. So we need to either loop until sem_wait returns successfully or adjust the code after sem_wait to handle irregular cases. Thanks Evgueni On 11/16/06, Geir Magnusson Jr. [EMAIL PROTECTED]

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-16 Thread Evgueni Brevnov
In other words we will observe the crash as we do now if sem_wait completes unsuccessfully for whatever reason... On 11/17/06, Evgueni Brevnov [EMAIL PROTECTED] wrote: Gregory, The code which goes after sem_wait doesn't work properly if sem_wait returns with an error code. So we need to either

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-15 Thread Evgueni Brevnov
the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody comment on that? It might be that semantic is different on different platforms which is probably even worse. Your

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-15 Thread Geir Magnusson Jr.
and acquires a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody comment

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-15 Thread Geir Magnusson Jr.
out one interesting thing. It turned out that DRL implementation of hythread_monitor_init / hythread_monitor_init_with_name initializes and acquires a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-15 Thread Evgueni Brevnov
and acquires a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-14 Thread Geir Magnusson Jr.
/ hythread_monitor_init_with_name initializes and acquires a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-13 Thread Artem Aliev
. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody comment on that? Thanks Evgueni

[drlvm][threading] Which group to choose for new thread?

2006-11-13 Thread Evgueni Brevnov
Hi community, I'd like to discuss one particular feature of DRL threading library with you. TM provides four interface functions that can be used to create a new native thread or attach existing one to TM. Here they are: 1. hythread_create(hythread_t *handle, UDATA stacksize, UDATA priority

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-13 Thread Evgueni Brevnov
is described in HARMONY-2006 I found out one interesting thing. It turned out that DRL implementation of hythread_monitor_init / hythread_monitor_init_with_name initializes and acquires a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-13 Thread Evgueni Brevnov
/ hythread_monitor_init_with_name initializes and acquires a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-13 Thread Artem Aliev
and acquires a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody comment

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-13 Thread Gregory Shimansky
/ hythread_monitor_init_with_name initializes and acquires a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody comment

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-13 Thread Alexei Fedotov
Evgueni, That was great. Artem, It's nice to see you online. Could you please check the last comments to http://issues.apache.org/jira/browse/HARMONY-1904 and decide what should we do about this issue?

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-13 Thread Evgueni Brevnov
Gregory, I can't reproduce the problem described by you on my local Ubuntu machine. So I can only guess. And my guess is that mapPortLibSignalToUnix can't find corresponding signal in the map. That's why you have undefined sig (-1215196204) in jsig_handler. I can think of two reasons why

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-11 Thread Evgueni Brevnov
and acquires a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody comment on that? It might

[drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-10 Thread Evgueni Brevnov
monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody comment on that? Thanks Evgueni

[drlvm][threading module] a question about jthread_raw_monitor_create()

2006-11-10 Thread Weldon Washburn
I might be misunderstanding the code but the local variable, hythread_monitor_t monitor; is used as a parameter to a call to array_add(jvmti_monitor_table, monitor);. It seems that once jthread_raw_monitor_create() returns, the jvmti_monitor_table will end up with an invalid pointer. Is this

Re: [drlvm][threading module] a question about jthread_raw_monitor_create()

2006-11-10 Thread Gregory Shimansky
On Saturday 11 November 2006 01:36 Weldon Washburn wrote: I might be misunderstanding the code but the local variable, hythread_monitor_t monitor; is used as a parameter to a call to array_add(jvmti_monitor_table, monitor);. It seems that once jthread_raw_monitor_create() returns, the

Re: [drlvm][threading] Should hythread_monitor_init() aquire the monitor?

2006-11-10 Thread Gregory Shimansky
a monitor. Original spec reads: Acquire and initialize a new monitor from the threading library AFAIU that doesn't mean to lock the monitor but get it from the threading library. So the hythread_monitor_init should not lock the monitor. Could somebody comment on that? It might

[drlvm][threading][build] HARMONY-1907 commit (r472524) breaks the build on SUSE9

2006-11-09 Thread Egor Pasko
done:[JET_DPGO n=788: OK] java/lang/Object::notifyAll()V most likely, threading library failed to load, because: (gdb) bt 20 #0 0x40007de5 in do_lookup_x () from /lib/ld-linux.so.2 #1 0x400080dc in _dl_lookup_symbol_x () from /lib/ld-linux.so.2 #2 0x40558f16 in do_sym () from /lib/tls/libc.so.6 #3

Re: [drlvm][threading][build] HARMONY-1907 commit (r472524) breaks the build on SUSE9

2006-11-09 Thread Gregory Shimansky
] java/lang/Thread::runImpl()V EM: compile done:[JET_DPGO n=787: OK] java/lang/Thread::runImpl()V EM: compile start:[JET_DPGO n=788] java/lang/Object::notifyAll()V EM: compile done:[JET_DPGO n=788: OK] java/lang/Object::notifyAll()V most likely, threading library failed to load, because: (gdb) bt 20

Re: [drlvm][threading][build] HARMONY-1907 commit (r472524) breaks the build on SUSE9

2006-11-09 Thread Geir Magnusson Jr.
::notifyAll()V most likely, threading library failed to load, because: (gdb) bt 20 #0 0x40007de5 in do_lookup_x () from /lib/ld-linux.so.2 #1 0x400080dc in _dl_lookup_symbol_x () from /lib/ld-linux.so.2 #2 0x40558f16 in do_sym () from /lib/tls/libc.so.6 #3 0x4055904a in _dl_sym () from /lib/tls

Re: [drlvm][threading] Possible race condition in implementation of conditional variables?

2006-10-31 Thread Weldon Washburn
I did some digging. It looks like what's in today's svn HEAD does the following: thread_native_semaphore.c::hysem_wait() calls thread_native_semaphore.c::sem_wait_impl() calls thread_native_condvar.c::condvar_wait_impl() which does the following: { disable_count =

Re: [drlvm][threading] Infinite loop in atomic16_inc/atomic16_dec?

2006-10-20 Thread Evgueni Brevnov
On 10/19/06, Artem Aliev [EMAIL PROTECTED] wrote: Eugeny, The problem can be easily fixed by changing int16 to unit16 in atomic16_dec. Do you think this is accaptable way to fix the problem. BTW, could somebody explain why 16-bit atomic operation is used for 32-bit value? The

Re: [drlvm][threading] Infinite loop in atomic16_inc/atomic16_dec?

2006-10-20 Thread Evgueni Brevnov
The patch for the problem was created http://issues.apache.org/jira/browse/HARMONY-1929 Evgueni On 10/20/06, Evgueni Brevnov [EMAIL PROTECTED] wrote: On 10/19/06, Artem Aliev [EMAIL PROTECTED] wrote: Eugeny, The problem can be easily fixed by changing int16 to unit16 in atomic16_dec. Do

Re: [drlvm][threading] Infinite loop in atomic16_inc/atomic16_dec?

2006-10-20 Thread Weldon Washburn
Evgueni, Please also test on Linux. This looks like a reasonable patch to me. Regarding the 16-bit CAS. A long time ago, there was a 16-bit, byte-aligned field for thread ID. monenter() would do a 16-bit CAS. Maybe this is left over from old monenter()?? On 10/19/06, Artem Aliev [EMAIL

Re: [drlvm][threading] Infinite loop in atomic16_inc/atomic16_dec?

2006-10-20 Thread Evgueni Brevnov
On 10/20/06, Weldon Washburn [EMAIL PROTECTED] wrote: Evgueni, Please also test on Linux. This looks like a reasonable patch to me. Unfortunately, I don't have access to Linux today (work from home). Regarding the 16-bit CAS. A long time ago, there was a 16-bit, byte-aligned field for

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-19 Thread Artem Aliev
Weldon, If the current scheme is the same that we had 1 or 2 years ago, the answer is no This is just the same scheme! I am really hoping that all of this is simply an implementation bug. There are no open issues on this scheme, there is no examples that fail right now because of the

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-19 Thread Weldon Washburn
On 10/18/06, Nikolay Kuznetsov [EMAIL PROTECTED] wrote: I agree it is required to have a solid model in mind. I also believe it is required to have such design/implementation which doesn't allow to break that model. No, that's the point if functionality is so safe that it's impossible to

[drlvm][threading] Infinite loop in atomic16_inc/atomic16_dec?

2006-10-19 Thread Evgueni Brevnov
Hi, Today, I had several hangs of cunit tests. It turned out to be infinite cycling in while loop of atomic16_inc/atomic16_dec (see vm/thread/src/thread_native_suspend.c) Here is a snip of assembler code produced by msvc for atomic16_dec: callport_atomic_cas16 (10004A90h) add

Re: [drlvm][threading] Infinite loop in atomic16_inc/atomic16_dec?

2006-10-19 Thread Artem Aliev
Eugeny, The problem can be easily fixed by changing int16 to unit16 in atomic16_dec. Do you think this is accaptable way to fix the problem. BTW, could somebody explain why 16-bit atomic operation is used for 32-bit value? The suspend_request could be 16bit value some time ago. Could you

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Evgueni Brevnov
with the one discussed in [drlvm][threading] Possible race condition in implementation of conditional variables? Your thoughts? The code of suspend_all method is dedicated to the cyclic suspension problem. The fact that this method is being called from suspend_disable region and have safe_point

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Evgueni Brevnov
seems to be very similar with the one discussed in [drlvm][threading] Possible race condition in implementation of conditional variables? Your thoughts? The code of suspend_all method is dedicated to the cyclic suspension problem. The fact that this method is being called from

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Evgueni Brevnov
in [drlvm][threading] Possible race condition in implementation of conditional variables? Your thoughts? The code you see is there to prevent following deadlock scenario: Thread A Thread B | | | suspend(A); | A-suspend_request = 1

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Nikolay Kuznetsov
Evgueni, first of all I'd like to emphasize that suspend/resume_all functions are potentially unsafe and should be used with care. secondly, those methods were designed mainly to support stop_the_world_enumeration and thus usually being used under certain conditions. hmmm... it is

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Nikolay Kuznetsov
hmm I never thought of it that way. My initial reaction is no. Suspend enable/disable and global thread lock are seperate, distinct concepts. The thread lock should protect the VM internal thread structs when they are being modified. For example, the thread lock should allow only one

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Evgueni Brevnov
Hi Nikolay! On 10/18/06, Nikolay Kuznetsov [EMAIL PROTECTED] wrote: Evgueni, first of all I'd like to emphasize that suspend/resume_all functions are potentially unsafe and should be used with care. secondly, those methods were designed mainly to support stop_the_world_enumeration

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Nikolay Kuznetsov
I agree it is required to have a solid model in mind. I also believe it is required to have such design/implementation which doesn't allow to break that model. No, that's the point if functionality is so safe that it's impossible to break the model, it's not so highly important(as in our case)

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Evgueni Brevnov
It seems we are not in sync I don't suggest changing current suspention scheme...I like it I'm talking about one particular case.and still can't see any disadvantages in what I propose... On 10/18/06, Nikolay Kuznetsov [EMAIL PROTECTED] wrote: I agree it is required to have a solid

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Weldon Washburn
hythread_suspend_all. The problem seems to be very similar with the one discussed in [drlvm][threading] Possible race condition in implementation of conditional variables? Your thoughts? The code you see is there to prevent following deadlock scenario: Thread A Thread B

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Weldon Washburn
On 10/18/06, Nikolay Kuznetsov [EMAIL PROTECTED] wrote: hmm I never thought of it that way. My initial reaction is no. Suspend enable/disable and global thread lock are seperate, distinct concepts. The thread lock should protect the VM internal thread structs when they are being

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-18 Thread Evgueni Brevnov
(at least me) expects to have a safe point during hythread_suspend_all. The problem seems to be very similar with the one discussed in [drlvm][threading] Possible race condition in implementation of conditional variables? Your thoughts? The code you see is there to prevent following

[drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-17 Thread Evgueni Brevnov
entering hythread_suspend_all. So it can be called in suspend disabled state and nobody (at least me) expects to have a safe point during hythread_suspend_all. The problem seems to be very similar with the one discussed in [drlvm][threading] Possible race condition in implementation of conditional

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-17 Thread Nikolay Kuznetsov
with the one discussed in [drlvm][threading] Possible race condition in implementation of conditional variables? Your thoughts? The code of suspend_all method is dedicated to the cyclic suspension problem. The fact that this method is being called from suspend_disable region and have safe_point

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-17 Thread Weldon Washburn
be deadlock or latency problems. Did you try the above approach? ARe there deadlocks? The problem seems to be very similar with the one discussed in [drlvm][threading] Possible race condition in implementation of conditional variables? Your thoughts? The code of suspend_all method is dedicated

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-17 Thread Salikh Zakirov
regarding thread's state upon entering hythread_suspend_all. So it can be called in suspend disabled state and nobody (at least me) expects to have a safe point during hythread_suspend_all. The problem seems to be very similar with the one discussed in [drlvm][threading] Possible race condition

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-17 Thread Nikolay Kuznetsov
The simplest model is to grab the thread lock whenever thread A wants to suspend thread B at a safepoint. While this serializes thread suspension and can potentially be a bottleneck, let's wait until its a proven performance problem to change this model. For thread A to be ready to grab the

Re: [drlvm][threading] Is it safe to use hythread_suspend_all and hythread_resume_all?

2006-10-17 Thread Weldon Washburn
On 10/17/06, Nikolay Kuznetsov [EMAIL PROTECTED] wrote: The simplest model is to grab the thread lock whenever thread A wants to suspend thread B at a safepoint. While this serializes thread suspension and can potentially be a bottleneck, let's wait until its a proven performance problem

Re: [drlvm][threading] Possible race condition in implementation of conditional variables?

2006-10-16 Thread Artem Aliev
it. It looks like someone changed the behavior of semaphores to be compatible with the monitors. I agree with Xiao-Feng: the sleeping thread should be in suspend_enable mode. So I vote for leaving the current threading code as is but checking DRLVM for a code that not ready for the new behavior

Re: [drlvm][threading] Possible race condition in implementation of conditional variables?

2006-10-16 Thread Rana Dasgupta
Hi, Is there any known bug related to this issue? Rana On 10/15/06, Weldon Washburn [EMAIL PROTECTED] wrote: After thinking about it a while, how about the following course of action: 1) First phase is to modify hysem_wait() and any other hy blocking functions to test if, in

Re: [drlvm][threading] Possible race condition in implementation of conditional variables?

2006-10-16 Thread Weldon Washburn
Its a design rule kind of thing. Breaking the design rule leads to undefined behavior. My experience is that the kind of problem described here leads to very hard to diagnose system instability. If anything, a known bug of general, intermittant instability could be associated with this issue.

Re: [drlvm][threading] Possible race condition in implementation of conditional variables?

2006-10-13 Thread Artem Aliev
about it. It looks like someone changed the behavior of semaphores to be compatible with the monitors. I agree with Xiao-Feng: the sleeping thread should be in suspend_enable mode. So I vote for leaving the current threading code as is but checking DRLVM for a code that not ready for the new behavior

[drlvm][threading] Possible race condition in implementation of conditional variables?

2006-10-12 Thread Evgueni Brevnov
Hi, I do the following: hythread_suspend_disable(); do unsafe actions hysem_wait(semaphore); do unsafe actions hythread_suspend_enable(); By saying hythread_suspend_disable(); I expect the thread can't be suspended until hythread_suspend_enable() is called. But hysem_wait() resets disabled

Re: [drlvm][threading] Possible race condition in implementation of conditional variables?

2006-10-12 Thread Weldon Washburn
On 10/12/06, Evgueni Brevnov [EMAIL PROTECTED] wrote: Hi, I do the following: hythread_suspend_disable(); do unsafe actions hysem_wait(semaphore); do unsafe actions hythread_suspend_enable(); By saying hythread_suspend_disable(); I expect the thread can't be suspended until

Re: [drlvm][threading] Possible race condition in implementation of conditional variables?

2006-10-12 Thread Xiao-Feng Li
GC should be enabled in waiting state. In case that a GC can happen, the code should do bookkeeping to guarantee the correctness. Thanks, xiaofeng On 10/13/06, Evgueni Brevnov [EMAIL PROTECTED] wrote: Hi, I do the following: hythread_suspend_disable(); do unsafe actions

[DRLVM][Threading/GC] thread info initialization problem

2006-10-10 Thread Xiao-Feng Li
Hi, when I tested with GCv5 in DRLVM, I found there is design issue in threading part. That is, after gc is initiated (gc_init) in runtime, the main thread can't allocate object based on its allocation context (thread local gc info), because the allocation context is not initialized

Re: [DRLVM][Threading/GC] thread info initialization problem

2006-10-10 Thread Xiao-Feng Li
Before this bug is fixed in threading part, for any people who are interested in GCv5, please use patch below for workaround, just to add two lines. GCv5 only works in Windows at the moment. Please get it in latest SVN, and patch it with http://issues.apache.org/jira/browse/HARMONY-1785

Re: [DRLVM][Threading/GC] thread info initialization problem

2006-10-10 Thread Weldon Washburn
On 10/9/06, Xiao-Feng Li [EMAIL PROTECTED] wrote: Hi, when I tested with GCv5 in DRLVM, I found there is design issue in threading part. That is, after gc is initiated (gc_init) in runtime, the main thread can't allocate object based on its allocation context (thread local gc info), because

Re: [drlvm][gc/threading] need the two lsb's from object header for MMTk port

2006-10-09 Thread Salikh Zakirov
Weldon Washburn wrote: Artem, I'd like to confirm what you said. For GC_BIT_MASK, it looks like the bottom two bits of byte number one is available for exclusive GC use. If the GC needs to alter these two bits while the mutator(s) are running, the GC needs to use CAS on the entire 32 bits

Re: [drlvm][gc/threading] need the two lsb's from object header for MMTk port

2006-10-09 Thread Weldon Washburn
On 10/9/06, Salikh Zakirov [EMAIL PROTECTED] wrote: Weldon Washburn wrote: Artem, I'd like to confirm what you said. For GC_BIT_MASK, it looks like the bottom two bits of byte number one is available for exclusive GC use. If the GC needs to alter these two bits while the mutator(s) are

Re: [drlvm][gc/threading] need the two lsb's from object header for MMTk port

2006-10-06 Thread Artem Aliev
Weldon, All Here is the updated vm/vmcore/sync_bit.h header file. That, I think, describes current state of the object header. I olso try define rules: How to update the header correctly. Welcome to discussion on them. #ifndef _sync_bits_H #define _sync_bits_H /** * These defines describe

Re: [drlvm][gc/threading] need the two lsb's from object header for MMTk port

2006-10-06 Thread Weldon Washburn
Artem, I'd like to confirm what you said. For GC_BIT_MASK, it looks like the bottom two bits of byte number one is available for exclusive GC use. If the GC needs to alter these two bits while the mutator(s) are running, the GC needs to use CAS on the entire 32 bits of obj_info. Does this sound

Re: Threading

2005-05-28 Thread André Luis Ferreira da Silva Bacci
A long, long time ago... Craig Blake wrote: Seems to me that you might want to be open to either using the platform's threading when a platform has good scalability, and punt and do it in VM when the platform doesn't offer it. If it can be done then I am all for it. Once the Harmony VM

Re: Threading

2005-05-23 Thread Geir Magnusson Jr.
examine this today - is there any way to take advantage of OS threading at all? How do you do thread management now? Most likely the merged/unified thread scheduler will be written in a type-safe language such as Java. The interesting long term question is when will the entire JVM be merge

Re: Threading

2005-05-23 Thread Weldon Washburn
, its likely to become a bottleneck on tomorrow's multicore boxes. So how do we examine this today - is there any way to take advantage of OS threading at all? How do you do thread management now? I can only speak for how ORP JVM was designed. THe short answer is, yes, the JVM takes

Re: Threading

2005-05-22 Thread Steve Blackburn
threading model, where the VM scheduled its own green threads on top of posix threads, and multiple posix threads were supported. One view of this was that it was pointless to have more than one posix thread per physical CPU (since multiple posix threads would only have to time slice anyway). Under

Re: Threading

2005-05-22 Thread Santiago Gala
El dom, 22-05-2005 a las 21:09 +1000, Steve Blackburn escribi: Incidentally, this is a good example of where James Gosling misses the point a little: MITRE got involved in Jikes RVM not because it is better than the Sun VM, but because it was OSS which meant they could fix a limitation

Re: Threading

2005-05-22 Thread Craig Blake
on posix style threads. Of course in that case your scalability will largely depend on your underlying kernel threads implementation. Whether or not it's worth it depends on your needs. The lack of a highly scalable threading model in the current popular VMs is the reason why we have to use

Re: Threading

2005-05-22 Thread Rodrigo Kumpera
of the key goals of the project was to achieve much greater levels of scalability than the commercial VMs could deliver (BTW, the project was then known as Jalapeno). The design decision was to use a multiplexed threading model, where the VM scheduled its own green threads on top of posix threads

Re: Threading

2005-05-22 Thread Geir Magnusson Jr.
as far as I know, most VMs these days just rely on posix style threads. Of course in that case your scalability will largely depend on your underlying kernel threads implementation. Whether or not it's worth it depends on your needs. The lack of a highly scalable threading model

Re: Threading

2005-05-22 Thread Craig Blake
Seems to me that you might want to be open to either using the platform's threading when a platform has good scalability, and punt and do it in VM when the platform doesn't offer it. If it can be done then I am all for it. Once the Harmony VM becomes modular it is something that can

Re: Threading

2005-05-22 Thread Geir Magnusson Jr.
On May 22, 2005, at 2:59 PM, Craig Blake wrote: Seems to me that you might want to be open to either using the platform's threading when a platform has good scalability, and punt and do it in VM when the platform doesn't offer it. If it can be done then I am all for it. Once

Re: Threading

2005-05-22 Thread Weldon Washburn
). The design decision was to use a multiplexed threading model, where the VM scheduled its own green threads on top of posix threads, and multiple posix threads were supported. One view of this was that it was pointless to have more than one posix thread per physical CPU (since multiple posix

Threading

2005-05-21 Thread Craig Blake
Just out of curiosity, can anyone familiar with the various OSS VM implementations being discussed share their insights regarding the respective threading capabilities? I have heard of some commercial specialty VMs handling upwards of 30,000 concurrent threads easily and it would