1 2007-07-18 Miguel de Icaza <miguel@novell.com>
3 * WaitHandle.cs (Handle): in the 2.0 profile, explicitly dispose
4 the old SafeWaitHandle, do not wait for the finalizer to run;
6 Take ownership of the handle; The docs did not say that
7 assigning to this value would lead to a leak, the docs said that
8 in the 1.0 and 1.1 profiles assigning to this property might lead
13 2007-07-09 Atsushi Enomoto <atsushi@ximian.com>
15 * LockCookie.cs, AsyncFlowControl.cs :
16 added missing operator == and !=.
18 2007-05-22 Jonathan Chambers <joncham@gmail.com>
20 * Thread.cs: Use & to check ThreadState rather than ==.
21 Fixes AlbumSurfer regression.
23 2007-05-09 Jonathan Chambers <joncham@gmail.com>
25 * Thread.cs: Implement ApartmentState related items.
27 2007-05-02 Dick Porter <dick@ximian.com>
29 * ReaderWriterLock.cs: ReaderWriterLock derives from
30 CriticalFinalizerObject in the 2.0 profile
32 2007-05-01 Dick Porter <dick@ximian.com>
35 * AsyncFlowControl.cs:
37 * RegisteredWaitHandle.cs:
39 * ThreadStateException.cs:
42 * WaitOrTimerCallback.cs:
46 * ThreadAbortException.cs:
48 * ReaderWriterLock.cs:
49 * NativeOverlapped.cs:
55 * SynchronizationLockException.cs:
56 * ManualResetEvent.cs:
58 * IOCompletionCallback.cs:
60 * AbandonedMutexException.cs:
61 * SendOrPostCallback.cs:
62 * ThreadInterruptedException.cs: Update to 2.0 profile
64 Thu Apr 19 16:47:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
66 * ThreadPool.cs: patch from Robert Jordan to implement
67 ThreadPool.SetMaxThreads.
69 2007-04-03 Alp Toker <alp@atoker.com>
71 * Monitor.cs: Class is static in 2.0.
73 2007-03-27 Dick Porter <dick@ximian.com>
75 * Mutex.cs: Throw ApplicationException if ReleaseMutex() fails.
78 Tue Jan 23 17:43:50 CET 2007 Paolo Molaro <lupus@ximian.com>
80 * Thread.cs: mark the GC-tracked field with UIntPtr.
82 2006-12-31 Miguel de Icaza <miguel@novell.com>
84 * ThreadPool.cs: Stub a method.
86 2006-12-11 Miguel de Icaza <miguel@novell.com>
88 * WaitHandle.cs: In 2.0 use SafeWaitHandles and the SafeWaitHandle
89 patterns instead of using directly the IntPtr Handle.
91 Refactor the code to reuse as much as possible, and follow the new
92 conventions where appropriate.
94 2006-11-07 Robert Jordan <robertj@gmx.net>
96 * WaitHandle.cs: Don't assume Assembly.GetEntryAssembly () !=
97 null. Fixes bug #79859.
99 2006-11-02 Dick Porter <dick@ximian.com>
101 * Thread.cs: Use the new Interrupt and SpinWait icalls.
103 2006-07-04 Atsushi Enomoto <atsushi@ximian.com>
105 * WaitHandle.cs : CheckArray() is also used in WaitAny(), so added
106 extra argument to skip STAThread check.
108 2006-06-30 Duncan Mak <duncan@novell.com>
110 * WaitHandle.cs (CheckArray): Avoid using reflection unless we
113 2006-06-29 Duncan Mak <duncan@novell.com>
115 * WaitHandle.cs (CheckArray): Throw NotSupportedException if the
116 current thread is marked with the STAThreadAttribute. Fixes bug
119 2006-05-05 Sebastien Pouliot <sebastien@ximian.com>
121 * ExecutionContext.cs: Don't capture the compressed stack unless the
122 security manager is active (this wasn't ready to be called in
125 2004-04-29 Atsushi Enomoto <atsushi@ximian.com>
127 * Timer.cs : avoid NullReferenceException when it is already disposed.
128 Patch by pawel.sakowski@mind-breeze.com. Fixed bug #78208.
130 2004-04-28 Atsushi Enomoto <atsushi@ximian.com>
132 * SynchronizationContext.cs : use ThreadPool in Post(), as suggested
135 2004-04-04 Atsushi Enomoto <atsushi@ximian.com>
137 * Thread.cs : base class is CriticalFinalizerObject.
138 * ThreadStartException.cs : no public constructors.
140 Wed Mar 29 18:29:55 CEST 2006 Paolo Molaro <lupus@ximian.com>
142 * Thread.cs: update for the runtime changes to culture caching.
144 Wed Mar 15 16:35:49 CET 2006 Paolo Molaro <lupus@ximian.com>
146 * Thread.cs: updates for LocalDataStoreSlot: we use an array as
147 storage for the slots now so that LocalDataStoreSlot objects an be
148 garbage collected if the user doesn't keep a reference to them.
150 2006-02-09 Miguel de Icaza <miguel@novell.com>
152 * Monitor.cs: Patch from Thong Nguyen, Wait (.., Timeout) method
153 should allow a -1 (Timeout.Infinite) to mean indefinite wait (the
154 code already supported this.
156 Removed also a LAMESPEC for missing argument checking in Wait with
159 Fixed the use of exceptions.
161 2005-12-23 Dick Porter <dick@ximian.com>
163 * EventWaitHandle.cs:
164 * Mutex.cs: Implement OpenExisting
166 * NativeEventCalls.cs: Add OpenEvent icall for OpenExisting in
167 2.0. Add a "created" boolean out parameter to CreateEvent icall.
169 * ManualResetEvent.cs:
170 * AutoResetEvent.cs: Update CreateEvent icall signature (now has
171 "created" boolean out parameter.)
173 2005-12-17 Dick Porter <dick@ximian.com>
175 * ThreadStartException.cs:
176 * EventWaitHandle.cs:
178 * AbandonedMutexException.cs: New for 2.0 profile
182 * RegisteredWaitHandle.cs:
186 * ManualResetEvent.cs:
187 * AutoResetEvent.cs: Updated for 2.0 profile
189 2005-11-23 Zoltan Varga <vargaz@gmail.com>
191 * Interlocked.cs: Add T:class constraint to the generic
192 CompareExchange and Exchange methods.
194 2005-11-17 Zoltan Varga <vargaz@gmail.com>
196 * Interlocked.cs: Add generic CompareExchange and Exchange methods.
198 2005-11-17 Sebastien Pouliot <sebastien@ximian.com>
200 * WaitHandleCannotBeOpenedException.cs: New (2.0). Is required to
201 compile the Semaphore tests (in System.dll).
203 2005-10-23 Marek Safar <marek.safar@seznam.cz>
205 * SynchronizationContext.cs: A few simple fixes.
207 2005-10-06 Sebastien Pouliot <sebastien@ximian.com>
209 * Thread.cs: Copy an existing IPrincipal to new threads. Fix bug
212 2005-10-06 Sebastien Pouliot <sebastien@ximian.com>
214 * Thread.cs: Added new attributes, [ReliabilityContract] for
215 destructor and [Obsolete] for [Get|Set]CompressedStack, that were
218 2005-09-11 Zoltan Varga <vargaz@gmail.com>
220 * Thread.cs (MemoryBarrier): Make this an icall.
222 2005-09-10 Zoltan Varga <vargaz@gmail.com>
224 * Thread.cs (Interrupt): Make this throw a NotImplementedException.
226 2005-09-09 Martin Baulig <martin@ximian.com>
228 * Timer.cs (Timer.Runner.Start): Silently catch
229 ObjectDisposedException and return; works around some race
230 condition on thread abort.
232 2005-08-19 Dick Porter <dick@ximian.com>
234 * Thread.cs: Reserve 64 bits for the thread ID.
236 2005-07-19 Martin Baulig <martin@ximian.com>
238 * Timer.cs (Timer.Runner.Start): Fix a race condition which was
239 causing a hang on exit int he debugger: check `!disposed' before
240 `start_event.WaitOne ()' and again after it.
242 2005-06-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
244 * Thread.cs: check that the culture is valid for formatting
245 (ie, (!neutral || invariant)).
247 2005-06-07 Sebastien Pouliot <sebastien@ximian.com>
249 * Thread.cs: Added _Thread interface (and members) and a few missing
250 attributes (for both 1.1 and 2.0).
252 2005-06-06 Zoltan Varga <vargaz@freemail.hu>
254 * Thread.cs Mutex.cs Monitor.cs: Add some missing 2.0 attributes.
256 2005-05-29 Sebastien Pouliot <sebastien@ximian.com>
258 * Timer.cs: Added new constructor for 2.0 and ComVisible attribute.
259 * Timeout.cs: This is a static class in 2.0 and ComVisible attribute.
261 2005-05-26 Ben Maurer <bmaurer@ximian.com>
263 * Thread.cs: Use a static object for a lock rather than
266 2005-05-26 Sebastien Pouliot <sebastien@ximian.com>
268 * SynchronizationContext.cs: Re-introduced SendOrPost method as it's
269 being used in System.Web.Services.
271 2005-05-26 Sebastien Pouliot <sebastien@ximian.com>
273 * SynchronizationContext.cs: Updated to beta2 API so it doesn't depend
274 on the switcher structure anymore (which will be removed from the
277 2005-05-24 Sebastien Pouliot <sebastien@ximian.com>
279 * Thread.cs: Removed #pragma which aren't supported by CSC 7.x.
281 2005-05-20 Sebastien Pouliot <sebastien@ximian.com>
283 * AsyncFlowControl.cs: Now available, as internal, in NET_1_1. This is
284 required to get some methods from SecurityContext and ExecutionContext
286 * CompressedStack.cs: Now includes the current CompressedStack in a new
288 * ExecutionContext.cs: Includes more methods in NET_1_1 to enable
289 ThreadPool.UnsafeQueueUserWorkItem to work properly (i.e. without
291 * Thread.cs: Made ExecutionContext field accessible from the runtime.
292 Added stack propagation when Thread.Start is called.
293 * ThreadPool.cs: QueueUserWorkItem now does stack propagation (done in
294 the runtime), so I "fixed" UnsafeQueueUserWorkItem not to do so.
296 2005-05-19 Miguel de Icaza <miguel@novell.com>
298 * Thread.cs: REmove warnings.
300 2005-05-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
302 * Thread.cs: first check for null, then set in_currentculture.
304 2005-05-12 Lluis Sanchez Gual <lluis@novell.com>
306 * Thread.cs: Moved all checks done inside sync_lock to unmanaged code.
307 Merged Thread_internal and Start_internal into a single icall, which
310 2005-05-11 Sebastien Pouliot <sebastien@ximian.com>
312 * CompressedStack.cs: Allow merging of an existing CompressedStack
313 with the actual stack of the current Thread.
314 * Thread.cs: GetCompressedStack and SetCompressedStack are public
315 before 2.0 but couldn't be seen with mono-api-info because of it's
316 LinkDemand for the ECMA public key. Removed unused CompressedStack
317 private field (now part of the ExecutionContext).
319 2005-05-09 Sebastien Pouliot <sebastien@ximian.com>
321 * CompressedStack.cs: GetCompressedStack is public before 2.0 but
322 couldn't be seen with mono-api-info because of it's LinkDemand for
323 the ECMA public key. Stack capture occurs here if none exists on the
326 2005-04-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
328 * ReaderWriterLock.cs: fix random ApplicationException errors. Tested
329 with the System.Web.Cache stress program. Patch by Eyal Alayuf
330 (Mainsoft). Fixes 74598.
332 2005-04-28 Sebastien Pouliot <sebastien@ximian.com>
334 * Thread.cs: Added property to get the ExecutionContext in 2.0. Fixed
335 GetCompressedStack and made SetCompressedStack available (as internal)
338 2005-04-28 Sebastien Pouliot <sebastien@ximian.com>
340 * AsyncFlowControl.cs: Updated wrt beta2.
341 * ExecutionContext.cs: Updated wrt beta2. Class is now internal in
342 NET_1_1 to allow the compressed stack propagation to other threads.
343 * CompressedStack.cs: Updated wrt beta2. Class is internal in NET_1_1
344 to allow the compressed stack propagation to other threads.
345 * ContextCallback.cs: Updated wrt beta2.
346 * HostExecutionContext.cs: Updated wrt beta2.
347 * HostExecutionContextManager.cs: Updated wrt beta2.
348 * Thread.cs: Added internal property to get the ExecutionContext.
350 2005-04-19 Zoltan Varga <vargaz@freemail.hu>
352 * Thread.cs: Add some unused fields.
354 2005-04-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
356 * ThreadPool.cs: BindHandle does nothing now.
358 2005-04-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
360 * Thread.cs: clear the Unstarted bit before calling Start_internal.
363 2005-04-04 Ben Maurer <bmaurer@ximian.com>
365 * Thread.cs: Do argument checking for Current[UI]Culture to make
366 the exception more clear for a null value being set.
368 2005-03-24 Sebastien Pouliot <sebastien@ximian.com>
370 * CompressedStack.cs: Added LinkDemand for UnmanagedCode and ECMA
371 public key on GetCompressedStack method.
372 * Mutex: Added LinkDemand for UnmanagedCode to create named (system
374 * Thread.cs: Added LinkDemand for ECMA public key on [Get|Set]
375 CompressedStack methods.
376 * WaitHandle.cs: Added LinkDemand and InheritanceDemand for
377 UnmanagedCode on set Handle property.
379 2005-03-10 Zoltan Varga <vargaz@freemail.hu>
381 * Thread.cs: Make slothash a ThreadStatic field. Fixes #65414.
383 2005-02-21 Zoltan Varga <vargaz@freemail.hu>
385 * Monitor.cs Interlocked.cs: Add net 2.0 ReliabilityContractAttributes.
387 2005-02-20 Zoltan Varga <vargaz@freemail.hu>
389 * Interlocked.cs: Applied patch from Luca Barbieri (luca.barbieri@gmail.com). Add NET 2.0 methods.
391 Tue Feb 15 18:19:11 CET 2005 Paolo Molaro <lupus@ximian.com>
393 * Thread.cs: make the slothash a field in MonoThread.
395 2005-01-27 Sebastien Pouliot <sebastien@ximian.com>
397 * Overlapped.cs: Added check for ControlPolicy and ControlEvidence for
398 Unsafe pack. Added MonoTODO for missing security stack propagation.
399 * Thread.cs: Add security checks for ControlThread.
400 * ThreadPool.cs: Added declarative security checks.
402 Thu Jan 13 18:15:32 CET 2005 Paolo Molaro <lupus@ximian.com>
404 * Thread.cs: implement stacksize and parameterized
405 start functionality (requires matching runtime).
407 2005-01-12 Gonzalo Paniagua Javier <gonzalo@ximian.com>
409 * ThreadAbortException.cs: added private serialization .ctor.
411 2004-12-20 Sebastien Pouliot <sebastien@ximian.com>
413 * CompressedStack.cs: Implemented most todo so it's usable for CAS.
414 * CompressedStackSwitcher.cs: Implemented most todo.
415 * Thread.cs: Implement support for getting/setting CompressedStack.
417 2004-12-15 Zoltan Varga <vargaz@freemail.hu>
419 * Thread.cs: Change type of culture_info and ui_culture_info to
420 IntPtr. Implement correct culture handling for the UI culture as
423 2004-12-14 Zoltan Varga <vargaz@freemail.hu>
425 * Thread.cs: Optimize CurrentCulture to avoid initializing the
426 serialization infrastructure in the common case when the culture is
429 2004-12-06 Zoltan Varga <vargaz@freemail.hu>
431 * Thread.cs: Add new fields 'serialized_culture_info{_len}'.
433 * Thread.cs (CurrentCulture): Fix leaking of culture info objects
434 across appdomains. Partially fixes #50049.
436 2004-12-05 Miguel de Icaza <miguel@ximian.com>
438 * AutoResetEvent.cs (Set, Reset): If we are disposed, throw a
439 ObjectDisposedEvent, helped track the WebConnection destructor
442 2004-09-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
444 * Timer.cs: don't invoke the callback twice when the timer changes.
447 2004-09-08 Marek Safar <marek.safar@seznam.cz>
449 * Interlocked.cs: Class is static in NET_2_0.
451 2004-09-04 Sebastien Pouliot <sebastien@ximian.com>
453 * Thread.cs: Changed an imperative security demand to declarative
454 (unsupported) so it doesn't (for now) call the security runtime.
456 2004-08-20 Sebastien Pouliot <sebastien@ximian.com>
458 * Thread.cs: Added Fx 2.0 properties/methods/attributes.
460 2004-08-12 Sebastien Pouliot <sebastien@ximian.com>
462 * CompressedStackSwitcher.cs: Added missing [ComVisible] and
463 [ReliabilityContract] attributes.
464 * ExecutionContext.cs: Added missing [ComVisible] and
465 [Serializable] attributes.
466 * HostExecutionContext.cs: Added missing [ComVisible] attribute.
467 * HostExecutionContextManager.cs: Added missing [ComVisible] and
468 [ReliabilityContract] attributes.
469 * HostExecutionContextSwitcher.cs: Added missing Equals and
470 GetHashCode methods and [ComVisible] and [ReliabilityContract] attrs.
471 * ParameterizedThreadStart.cs: New delegate in NET_2_0.
472 * SendOrPostCallback.cs: Added missing [ComVisible] attribute.
473 * SynchronizationContext.cs: Added new (2.0 beta1) methods Copy and
474 WaitHelper. Added missing [ComVisible] and [ReliabilityContract] attrs.
475 * SynchronizationContextSwitcher.cs: Added missing [ComVisible] and
476 [ReliabilityContract] attributes.
478 2004-08-08 Sebastien Pouliot <sebastien@ximian.com>
480 * HostExecutionContext.cs: Fx 2.0 stub required for AppDomain.
481 * HostExecutionContextManager.cs: Fx 2.0 stub required for AppDomain.
482 * HostExecutionContextSwitcher.cs: Fx 2.0 stub required for AppDomain.
484 2004-08-04 Gonzalo Paniagua Javier <gonzalo@ximian.com>
486 * Timer.cs: don't invoke the callback if the period changes before the
487 due time. Fixes bug #62421.
489 2004-07-27 Lluis Sanchez Gual <lluis@novell.com>
491 * ExecutionContext.cs, ExecutionContextSwitcher.cs,
492 SynchronizationContext.cs, SynchronizationContextSwitcher.cs: Added
495 2004-07-15 Dick Porter <dick@ximian.com>
497 * Thread.cs: Hold a lock in GetNamedDataSlot. Fixes bug 61582,
498 based on patch by Sbastien Robitaille
499 (sebastien.robitaille@croesus.com). Also fix instances of
500 lock(typeof(Thread)) to lock a private object instead.
502 2004-07-14 Sebastien Pouliot <sebastien@ximian.com>
504 * AsyncFlowControl.cs: New structure in Fx 2.0 required in
505 System.Security namespace.
506 * CompressedStackSwitcher.cs: New structure in Fx 2.0 required in
507 System.Security namespace.
508 * ContextCallback.cs: New delegate in Fx 2.0 required in
509 System.Security namespace.
510 * CompressedStack.cs: Updated API for NET_2_0 profile.
512 2004-07-10 Lluis Sanchez Gual <lluis@ximian.com>
514 * SendOrPostCallback.cs: New delegate.
516 2004-06-24 Dick Porter <dick@ximian.com>
518 * Mutex.cs: Implement the createdNew parameter
520 2004-06-15 Gert Driesen <drieseng@users.sourceforge.net>
522 * Thread.cs: changed return type of VolatileRead to UIntPtr
523 * ThreadPool.cs: set return type of SetMinThreads to bool
525 2004-06-15 Lluis Sanchez Gual <lluis@ximian.com>
527 * Thread.cs: Added new fields to keep sync with MonoThread.
528 Removed state changes in Sleep and Join. The state change is now done
529 in the icall. For accessing to internal fields lock with synch_lock
530 instead of this, which can be a source of deadlocks.
532 2004-06-15 Lluis Sanchez Gual <lluis@ximian.com>
534 * Timer.cs: Don't abort the thread if Dispose() is called from the runner
537 2004-06-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
540 (CurrentPrincipal): lock on CurrentThread, not typeof (Thread) and set
541 the thread IPrincipal if we get it from the AppDomain.
543 2004-06-09 Gert Driesen <drieseng@users.sourceforge.net>
545 * CompressedStack.cs: Added finalizer to match public API of
548 2004-05-19 Lluis Sanchez Gual <lluis@ximian.com>
550 * Thread.cs: Some fixes in Abort. Implemented Suspend and Resume.
551 Added internal interruption_requested field.
553 2004-05-13 Sebastien Pouliot <sebastien@ximian.com>
555 * CompressedStack.cs: Added an internal constructor so a default one
556 doesn't appear with corcompare.
557 * Thread.cs: Added missing MemoryBarrier (only for 1.1) and SpinWait to please
558 corcompare. Both throw a NotImplementedException.
559 * ThreadPool.cs: Added missing UnsafeRegisterWaitForSingleObject methods (4
560 overloads) to please corcompare. All throw a NotImplementedException.
562 2004-05-12 Zoltan Varga <vargaz@freemail.hu>
564 * CompressedStack.cs: New file.
566 2004-04-15 Lluis Sanchez Gual <lluis@ximian.com>
568 * ThreadPool.cs: Added GetMinThreads and SetMinThreads.
569 * Timer.cs: In Change, return false if the timer has been disposed.
570 In Dispose, notify the WaitHandle.
572 2004-04-11 Lluis Sanchez Gual <lluis@ximian.com>
574 * ReaderWriterLock.cs: More fixes: never wait where acquiring a reader lock
575 if the thread already has the lock. Added readyWaitingReaders variable to
576 keep track of threads ready to get the reader lock.
578 2004-04-11 Lluis Sanchez Gual <lluis@ximian.com>
580 * LockQueue.cs: Moved lockCount change inside the rwlock lock. Removed
581 lock(this) when entering the rwlock to avoid a deadlock.
582 * ReaderWriterLock.cs: In AcquireWriterLock, queue the thread if the queue
583 is not empty (even if state==0).
585 2004-04-09 Zoltan Varga <vargaz@freemail.hu>
587 * Timer.cs: Call the callback immediately if dueTime is 0. Fixes
590 2004-04-08 Jackson Harper <jackson@ximian.com>
592 * ReaderWriterLock.cs: Fix tyop
594 2004-04-08 Lluis Sanchez Gual <lluis@ximian.com>
596 * ReaderWriterLock.cs: Changed some methods to private.
597 * WaitHandle.cs: In Wait methods, release the synchronization context when
600 2004-04-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
602 * Timer.cs: call Abort on the Runner instance too.
604 2004-04-07 Jackson Harper <jackson@ximian.com>
606 * Thread.cs: Use new culture info method for constructing the
609 2004-04-07 Lluis Sanchez Gual <lluis@ximian.com>
611 * ReaderWriterLock.cs: When a thread holds a writer lock, a call to
612 AcquireReaderLock works like a call to AcquireWriterLock.
614 2004-04-06 Lluis Sanchez Gual <lluis@ximian.com>
616 * Monitor.cs: In Wait(), release the synchronization context when
619 2004-04-06 Lluis Sanchez Gual <lluis@ximian.com>
621 * LockCookie.cs: Keep in this class the count of reader or writer locks
622 for a thread, not only whether it has locks or not.
623 * LockQueue.cs: Added property for checking if a thread is waiting in
624 the queue. Wait now returns a boolean that set to false on timeout
626 * ReaderWriterLock.cs: Started fixing bugs but I had to rewrite a lot of it.
627 The main change is that now it keeps a reader lock count for each
628 thread. This is needed since methods like ReleaseLock or
629 UpgradeToWriterLock need to return a per-thread status in LockCookie.
630 Also added support for recursive writer-lock requests.
632 2004-03-21 Gonzalo Paniagua Javier <gonzalo@ximian.com>
634 * ThreadAbortException.cs: use same HResult as MS.
635 * Timer.cs: abort the running thread when disposing the Timer. This
636 fixes NullRefs when finishing xsp.
638 2004-03-15 Gonzalo Paniagua Javier <gonzalo@ximian.com>
640 * NativeOverlapped.cs: added 2 new internal fields.
641 * Overlapped.cs: implemented, but it's not used.
643 * ThreadPool.cs: implemented BindHandle.
645 2004-03-08 Zoltan Varga <vargaz@freemail.hu>
647 * Timer.cs (Dispose): Applied patch from Jaroslaw Kowalski
648 (jaak@zd.com.pl). Fix finalization problems during appdomain unload.
650 2004-02-23 Jackson Harper <jackson@ximian.com>
652 * LockCookie.cs: Add some fields for restoring locks.
653 * ReaderWriterLock.cs: Implement
654 * LockQueue.cs: New File - used for queueing thread locks in
657 2004-02-19 Jackson Harper <jackson@ximian.com>
659 * Monitor.cs: Fix spelleng.
661 2004-02-09 Zoltan Varga <vargaz@freemail.hu>
663 * Thread.cs: Add fields added to unmanaged MonoThread here as well.
664 Fixes random errors caused by memory corruption.
666 2004-02-06 Zoltan Varga <vargaz@freemail.hu>
668 * Thread.cs: Store the thread name in unmanaged memory, since the
669 thread object is shared between appdomains.
671 2004-02-05 Sebastien Pouliot <sebastien@ximian.com>
673 * Thread.cs: Implemented CurrentPrincipal.
675 2004-01-22 Gonzalo Paniagua Javier <gonzalo@ximian.com>
677 * Thread.cs: delayed thread creation until Start is called. If we
678 don't do that and Start() is not called, the thread is leaked. First
679 step towards fixing bug #53078.
681 2003-12-02 Dick Porter <dick@ximian.com>
683 * Thread.cs: Throw InvalidOperationException if Thread.Name is
686 2003-12-01 Dick Porter <dick@ximian.com>
688 * Thread.cs: Implement CurrentCulture and CurrentUICulture
690 2003-11-12 Miguel de Icaza <miguel@ximian.com>
692 * Thread.cs: Add new VolatileRead/VolatileWrite methods from 1.1
694 2003-10-23 Lluis Sanchez Gual <lluis@ximian.com>
696 * Thread.cs: Added ResetDataStoreStatus and RestoreDataStoreStatus
697 methods. They are used in CrossAppDomainChannel to save and restore
698 thread's local data when switching between domains.
700 2003-10-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
702 * ManualResetEvent.cs: added check for disposed.
703 * Thread.cs: no need to init this field.
705 2003-10-01 Zoltan Varga <vargaz@freemail.hu>
707 * Thread.cs: Add locking to AllocateNamedDataSlot and
710 Wed Aug 20 12:01:36 CEST 2003 Paolo Molaro <lupus@ximian.com>
712 * Thread.cs: put all the fields at the start and add
713 more fields needed by the runtime.
715 2003-08-14 Lluis Sanchez Gual <lluis@ximian.com>
717 * Thread.cs: SetData() method: use Hashtable.Contains to check
718 if a dataslot has been allocated (value could be null).
720 2003-07-23 Duncan Mak <duncan@ximian.com>
722 * WaitHandle.cs (CheckDisposed): This method is not in the public
723 API, mark it as 'internal'.
725 2003-07-01 Dick Porter <dick@ximian.com>
727 * Thread.cs: Throw an exception if thread creation failed.
728 (Better than just blowing up later.)
730 2003-06-27 Dietmar Maurer <dietmar@ximian.com>
732 * ThreadPool.cs: use async delegate invoke.
734 2003-06-25 Dick Porter <dick@ximian.com>
736 * WaitHandle.cs: Default handle value should be InvalidHandle, not
739 2003-06-21 Gonzalo Paniagua Javier <gonzalo@ximian.com>
741 * ThreadPool.cs: correctly create a TimeSpan with provided the number of
744 * WaitHandle.cs: fixes for WaitAny/All and TimeSpan.
746 2003-06-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
748 * WaitHandle.cs: checks and exceptions.
750 2003-06-02 Gonzalo Paniagua Javier <gonzalo@ximian.com>
752 * NativeEventCalls.cs: added CloseEvent_intenal.
753 * WaitHandle.cs: call CloseEvent_internal when disposing.
755 2003-05-31 Gonzalo Paniagua Javier <gonzalo@ximian.com>
757 * RegisteredWaitHandle.cs: check that the callback is not null before
760 * ThreadPool.cs: fixed timeout -> TimeSpan conversions (closes bug
761 #43963). Queue the item before setting the handle. If there's a timeout,
762 avoid trying to Dequeue, getting the exception et al, just continue the
765 Mon May 19 09:07:45 CEST 2003 Paolo Molaro <lupus@ximian.com>
767 * Monitor.cs: removed test_owner, the check is already done in the
770 Tue May 13 15:34:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
772 * Thread.cs: added missing field used by the runtime and
773 a new field to support thread-static data.
775 2003-04-17 Pedro Mart?ez Juli? <yoros@wanadoo.es>
777 * Timer.cs: Change the position of two lines because they were
778 before the "if" that ensures the integrity. After this, the first of
779 that two lines was producing a NullReferenceException.
781 2003-04-09 Dick Porter <dick@ximian.com>
783 * Thread.cs: Make sure a reference to the ThreadStart delegate is
784 held. There's no telling how long it will be before
785 Thread.Start() is called, and GC might destroy the delegate.
786 Thread() and Start() need to be rewritten so that the runtime
787 creates the new thread when Start() is called, which will simplify
788 the code a great deal.
790 2003-03-20 Miguel de Icaza <miguel@ximian.com>
792 * Thread.cs (CurrentCuluture): use the invaraint culture instead
793 of "" for the current_culture setting.
795 2003-03-25 Zoltan Varga <vargaz@freemail.hu>
797 * Thread.cs: Fix visibility of ResetAbort().
799 2003-03-18 Dick Porter <dick@ximian.com>
801 * Thread.cs: Keep the thread state updated in all the places that
802 require it. (Suspend, Resume and Interrupt not handled yet)
804 2003-03-03 Lluis Sanchez Gual <lluis@ideary.com>
806 * Thread.cs: Changed implementation of CurrentContext, adapted to the changes
809 2003-02-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
811 * Thread.cs: implemented CurrentContext.
813 2003-02-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
815 * Thread.cs: made the thread_id for the current thread accesible through
816 an internal property.
818 2003-02-17 Dick Porter <dick@ximian.com>
820 * Thread.cs: Added the Start semaphore field to the class. Update
821 the thread state after Start() has returned, not before.
823 2003-02-13 Zoltan Varga <vargaz@freemail.hu>
825 * Thread.cs (Sleep): Timeout.Infinite is a value argument.
827 2003-02-11 Dick Porter <dick@ximian.com>
829 * Monitor.cs: Infinite wait is Infinite, not 0 ms
831 2003-02-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
833 * Thread.cs: fixed bug #37759.
835 2003-02-07 Patrik Torstensson
837 * Timer.cs: Set the Background thread flag for the timer thread
839 2003-02-05 Patrik Torstensson
841 * ThreadPool.cs: Reformated and fixed issue that made all thread exit the pool.
843 2003-02-04 Lluis Sanchez Gual <lluis@ideary.com>
845 * ThreadPool.cs: Implemented RegisterWaitForSingleObject methods.
847 Tue Jan 28 17:55:59 CET 2003 Paolo Molaro <lupus@ximian.com>
849 * Thread.cs: delay-init datastorehash.
851 2003-01-10 Patrik Torstensson <totte@race-x-change.com>
853 * ThreadPool.cs: Temporary removed the usage of monitor thread, implemented a
854 model more equal to the MS one.
856 2002-12-10 Dick Porter <dick@ximian.com>
862 * WaitHandle.cs: Use TotalMilliseconds to convert a TimeSpan to
863 ms, not Milliseconds.
865 2002-12-07 Martin Baulig <martin@ximian.com>
867 * Timer.cs: Make it actually work; now it no longer sets your
868 application on fire if you use a zero periode and Timer.Change()
871 2002-11-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
873 * Timer.cs: implemented more stuff. It works now.
875 2002-10-25 Zoltan Varga <vargaz@freemail.hu>
877 * Thread.cs: Implement GetDomain() and GetDomainID().
879 2002-10-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>
881 * ThreadPool.cs: now the monitor thread is not sleeping and checking if
882 more worker threads needed. It waits on _DataInQueue. If (and only if)
883 there's data in the queue it checks if more worker threads needed and
884 then sleeps 0.5s before waiting for queued data again.
886 2002-09-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
888 * ThreadPool.cs: set IsThreadPoolThread before starting the worker.
890 2002-09-11 Dick Porter <dick@ximian.com>
893 * ManualResetEvent.cs:
894 * AutoResetEvent.cs: Use the WaitHandle.Handle property instead of
897 * WaitHandle.cs: Hide the os_handle field and the WaitOne_internal
900 2002-09-03 Dick Porter <dick@ximian.com>
902 * Thread.cs: Added thread ID field
904 2002-08-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
906 * WaitHandle.cs: IDisposable fixes.
908 2002-08-14 Dick Porter <dick@ximian.com>
910 * Thread.cs: Make CurrentUICulture act the same as CurrentCulture
913 2002-08-12 Dietmar Maurer <dietmar@ximian.com>
915 * ThreadAbortException.cs: impl. ExceptionState property.
917 * Thread.cs: moved all instance variables to the start of the
918 class. added support for Thread::Abort()
920 2002-04-30 Dick Porter <dick@ximian.com>
922 * Thread.cs: If LocalDataStoreSlot already has data set, remove it
923 before adding a new one.
925 Use the Thread object destructor to tell the runtime to close the
928 2002-04-14 Patrik Torstensson <patrik.torstensson@labs2.com>
930 * Interlocked.cs: made all methods icalls.
932 2002-04-14 Gonzalo Paniagua Javier <gonzalo@ximian.com>
934 * IOCompletionCallback.cs: added attributes to the delegate
935 (CLSCompliant(false) and Serializable).
937 2002-04-14 Patrik Torstensson <patrik.torstensson@labs2.com>
938 * Thread.cs: Fixed IsThreadPoolThread to use a internal property instead of extending
939 the threadstate enum.
940 * ThreadPool.cs: Now using the internal Isthreadpoolthread property
941 * ThreadState.cs: removed non-standard enum (ThreadPoolThread)
943 2002-04-14 Patrik Torstensson <patrik.torstensson@labs2.com>
945 * ThreadState.cs: Added enum for threadpool thread
946 * Thread.cs: changed the set/clr_state to be internal (used from threadpool)
947 * Thread.cs: Added IsThreadPoolThread
948 * ThreadPool.cs: Implementation of QueueUserWorkItem
950 Wed Feb 13 21:51:30 CET 2002 Paolo Molaro <lupus@ximian.com>
952 * Thread.cs: implement CurrentCulture property needed by
953 Convert.ChangeType() (used when compiling enums).
955 2002-01-23 Dick Porter <dick@ximian.com>
957 * ManualResetEvent.cs:
958 * AutoResetEvent.cs: Fixed DOS line endings
960 2002-01-22 Veronica De Santis <veron78@interfree.it>
962 * NativeEventCalls : Class that contains internal calls shared by Auto
963 and Manual Reset Events
964 * AutoResetEvents.cs : Added class AutoResetEvents and its implementation
965 * ManualResetEvents.cs : Added class ManualResetEvents and its implementation
967 2002-01-16 Veronica De Santis <veron78@interfree.it>
969 * WaitHandle.cs : Renamed handle to os_handle and make it protected
971 * Mutex.cs : Write the System.Threading.Mutex methods ( constructors
972 and the ReleaseMutex)
974 2002-01-15 Dick Porter <dick@ximian.com>
977 * Thread.cs: Make the runtime's idea of infinite timeouts coincide
978 with the class library's
980 2002-01-10 Dick Porter <dick@ximian.com>
982 * WaitHandle.cs: Added checks for too many handles and null
983 handles in WaitAll() and WaitAny
986 2002-01-05 Ravi Pratap <ravi@ximian.com>
988 * AutoResetEvent.cs, ManualResetEvent.cs, Monitor.cs : MonoTODO
991 * Mutex.cs, Overlapped.cs, ReaderWriterLock.cs, RegisteredWaitHandle.cs,
992 Thread.cs, ThreadAbortException.cs, ThreadPool.cs, Timer.cs, WaitHandler.cs : Ditto.
994 2001-12-11 Dick Porter <dick@ximian.com>
996 * WaitHandle.cs: Implemented WaitAll(), WaitAny() and WaitOne() as
999 2001-11-26 Dick Porter <dick@ximian.com>
1001 * Thread.cs: DataSlot uses a single system TLS slot, and a
1002 hashtable per thread. Some minor changes to reflect the new
1003 internal calls using the new IO library, and the newly-supported
1004 bool returns from internal calls.
1006 * Monitor.cs: Use bool returns from internal calls now they are
1007 supported by the runtime. Coalesce enter with the try_enter
1010 Wed Nov 14 17:06:18 CET 2001 Paolo Molaro <lupus@ximian.com>
1012 * Overlapped.cs, ThreadPool.cs, Timer.cs: CLSCompliant updates.
1014 2001-10-03 Dick Porter <dick@ximian.com>
1016 * Monitor.cs: Implemented all methods except the two Wait()
1017 methods that take boolean parameters
1019 2001-09-28 Dick Porter <dick@ximian.com>
1021 * Thread.cs: Implemented AllocateDataSlot(),
1022 AllocateNamedDataSlot(), FreeNamedDataSlot(), GetData(),
1023 GetNamedDataSlot(), SetData(), IsBackground. Reworked Thread()
1024 and Start() to avoid a race condition. Added thread-safe state
1025 changing private operations.
1027 * Monitor.cs: Comment out the GetType() calls because it isn't implemented yet
1029 2001-09-25 Dick Porter <dick@ximian.com>
1031 * Thread.cs: Implement Join and timed Join, set correct state
1032 around Start, Join and Sleep calls, implement IsAlive and
1033 ThreadState properties.
1035 * ThreadState.cs (Threading): Added StopRequested,
1036 SuspendRequested, Suspended values
1038 2001-09-23 Dick Porter <dick@ximian.com>
1040 * Thread.cs: Implemented CurrentThread and Sleep (both versions)
1041 with internal calls, and Name.
1043 2001-09-21 Dick Porter <dick@ximian.com>
1045 * Thread.cs: Implement Thread(ThreadStart) constructor and Start()
1046 with an internal call
1048 * WaitHandle.cs: Close calls Dispose(false)
1050 2001-09-13 Dick Porter <dick@ximian.com>
1052 * ApartmentState.cs (Threading): Set the correct enum values
1054 2001-09-13 Dick Porter <dick@ximian.com>
1056 * ApartmentState.cs, AutoResetEvent.cs, IOCompletionCallback.cs,
1057 Interlocked.cs, LockCookie.cs, ManualResetEvent.cs, Monitor.cs,
1058 Mutex.cs, NativeOverlapped.cs, Overlapped.cs, ReaderWriterLock.cs,
1059 RegisteredWaitHandle.cs, SynchronizationLockException.cs,
1060 Thread.cs, ThreadAbortException.cs, ThreadInterruptedException.cs,
1061 ThreadPool.cs, ThreadStart.cs, ThreadStateException.cs,
1062 Timeout.cs, Timer.cs, TimerCallback.cs, WaitCallback.cs,
1063 WaitHandle.cs, WaitOrTimerCallback.cs: System.Threading class
1066 2001-07-18 Michael Lambert <michaellambert@email.com>
1068 * ThreadPriority.cs, ThreadState.cs: Add.