IRC Networks
Irc Logs Stats
Start date: 2007-09-27 02:48:27
Last update: 2008-10-24 20:19:38
Channels: 41
Logged Lines: 6230436
Size: 1822.23 MB
Powered by
Channel Info
Network: freenodeChannel: #csharp |
Search in www.irclog.org
Log from #csharp at freenode 2006-06-17
[22:46]<fz1dbz>at least thats what im feeling
[22:47]<lcs>afaik no
[22:47]<fz1dbz>afaik = ?
[22:47]<fz1dbz>as far i know ?
[22:48]<lcs>yes
[22:49]<lcs>asynchronous access does not mean that program will perform multithread operations
[22:49]<fz1dbz>pks
[22:49]<fz1dbz>but if the access is too fast
[22:49]<fz1dbz>it will do perform multithread operations
[22:49]<fz1dbz>it uses IOCP
[22:49]<lcs>IOCP?
[22:49]<fz1dbz>yep
[22:49]<fz1dbz>I/O Completion Ports
[22:49]<lcs>whats that?
[22:49]<fz1dbz>it create threads
[22:49]<fz1dbz>when its needed
[22:49]<lcs>ah
[22:49]<fz1dbz>to perform the asynchronous operations
[22:50]<lcs>so it does not so dtuff asynchronicaly
[22:50]<fz1dbz>thats native from .NET
[22:50]<fz1dbz>it does stuff asynchronously
[22:50]<lcs>it just runs many threads
[22:50]<fz1dbz>no
[22:50]<fz1dbz>it dont run many threads
[22:50]<fz1dbz>when its not needed
[22:50]<lcs>*g*
[22:50]<fz1dbz>only when your server is overcharged of operations
[22:50]<fz1dbz>it creates another thread
[22:50]<lcs>WHAT FOR?!?!
[22:50]<fz1dbz>and if its not enough
[22:50]<fz1dbz>another one
[22:51]<fz1dbz>like if you are doing a operation that takes time enough to it not perform another operation
[22:51]<lcs>if stuff is done asychronical in respect to one thread, then there is no need of creating other wones
[22:51]<fz1dbz>sure you are saying
[22:51]<fz1dbz>asynchronous != concurrently
[22:51]<lcs>you do not perform any long time operations
[22:51]<fz1dbz>sure
[22:51]<lcs>you just insert new data to containers
[22:52]<fz1dbz>what about if the same thread
[22:52]<lcs>so you dont need it at all
[22:52]<fz1dbz>try to access read/write
[22:52]<fz1dbz>the same element
[22:52]<fz1dbz>what would happen?
[22:52]<lcs>if you have two threads that access critical secion without checking whetehr they are allowed to, then you are making a design error
[22:52]<lcs>and anything can happen
[22:53]<fz1dbz>sure but answer my question
[22:53]<lcs>then there is no problem
[22:53]<lcs>if you have one thread that does read/write there is no problem with synchornization
[22:54]<fz1dbz>but isnt asynchronous mode a way to perform various operations at the same time?
[22:54]<afd>hey all!
[22:54]<lcs>(as long there is no other thread that accesses part that part of memory)
[22:54]<lcs>Fr3DBr: no
[22:54]<lcs>Fr3DBr: it just does not block while writing and reading
[22:54]<afd>and there are two tutorials now http://aqdweb.sourceforge.net/AqDWebTutorials :)
[22:54]<afd>cheers everyone!
[22:55]<fz1dbz>hm
[22:55]<fz1dbz>well
[22:55]<fz1dbz>then thats the theory
[22:55]<afd>would someone read http://aqdweb.sourceforge.net/HtmlControls and tell me your comments?
[22:55]<fz1dbz>because in the pratice its different
[22:55]<lcs>Fr3DBr: the read goes into backgroun (=is performed by kernel)d, as soon as it finishes reading you will get
[22:55]<lcs>ah... you were talking about static data
[22:55]<fz1dbz>exactly
[22:55]<afd>ah bath time! :)
[22:55]<lcs>sure, you are right, then data might get corrupted
[22:55]<fz1dbz>yep
[22:55]<fz1dbz>thats what im saying
[22:56]<lcs>didnt notice that in the begining
[22:56]<fz1dbz>ah okay...
[22:56]<fz1dbz>so how can i protect my stuff properly ?
[22:56]<lcs>actualy thats depended on the implementation
[22:56]<fz1dbz>because im doing that wrong :|
[22:56]<lcs>in unix there is nos such problem
[22:56]<fz1dbz>http://pastehere.com/?hvbjml <- take a look
[22:56]<fz1dbz>what could i change to protect it better?
[22:56]<lcs>but it might be a problem in windows, where probably another lame theard is created :)
[22:56]<fz1dbz>yeh
[22:57]<lcs>Fr3DBr: does you app deadlock?
[22:57]<lcs>your*
[22:57]<fz1dbz>no
[22:58]<lcs>hm, it should
[22:58]<fz1dbz>lol
[22:58]<fz1dbz>it doesnt here
[22:58]<lcs>because you are doing lock(object) inside another lock(object)
[22:58]<fz1dbz>but
[22:58]<fz1dbz>it start saying shit
[22:58]<fz1dbz>like the object i added to the hashtable
[22:58]<fz1dbz>has already been added
[22:58]<fz1dbz>when it shouldnt even try to add
[22:58]<fz1dbz>because i check if it exists first
[22:58]<fz1dbz>lol
[23:00]<fz1dbz>oh true
[23:00]<fz1dbz>im doing a lock internally :p
[23:01]<fz1dbz>like (lock) { (lock) {} }
[23:01]<fz1dbz>:O
[23:03]<lcs>code looks fine with me
[23:03]<lcs>except that double lock of the same variable
[23:03]<fz1dbz>where?
[23:03]<lcs>maybe .net ignore s that
[23:03]<fz1dbz>on the ExpiredBanList ?







