[Mono-bugs] [Bug 65414][Nor] Changed - [PATCH] Thread Local Data Slots do not survive nested appdomain transitions
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Tue, 7 Sep 2004 12:44:04 -0400 (EDT)
Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by lupus@ximian.com.
http://bugzilla.ximian.com/show_bug.cgi?id=65414
--- shadow/65414 2004-09-07 12:05:34.000000000 -0400
+++ shadow/65414.tmp.1335 2004-09-07 12:44:04.000000000 -0400
@@ -102,6 +102,18 @@
mov ecx, [data_slot]
shr ecx, shift
mov eax, [eax+ecx*4]
mov ecx, [data_slot]
and ecx, 1 << shift - 1
mov eax, [eax+ecx*4]
+
+------- Additional Comments From lupus@ximian.com 2004-09-07 12:44 -------
+Currently the thread object is shared (though that has it's own
+issues, there is already a bug filed about that), so your first
+sentence doesn't make sense.
+There is a reason to avoid threadstatic fields, if you'd read the code
+you'd know: it causes additional overhead at thread creation and
+destruction and it uses more memory than sticking the per-thread data
+in the per-thread object that is already readily available.
+Making LocalDataStoreSlot hold an integer and use that to index an
+array instead of using an hash table is perfectly fine, but unrelated
+to the rest of the discussion.