<div dir="ltr">Hi Chris, <br><br>I didn't realize that, but that's fine. If that's the case, and it's possible, conforming our concrete model to some protocols might be a nice compromise. This allows frameworks to interact more natively if they prefer while providing some convenience types for more basic implementations. Just a thought.<br><br>- Logan</div><br><div class="gmail_quote"><div dir="ltr">On Mon, Mar 27, 2017 at 5:13 PM Chris Bailey via swift-server-dev <<a href="mailto:swift-server-dev@swift.org">swift-server-dev@swift.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><font size="2" face="sans-serif" class="gmail_msg">Hi Michael:</font>
<br class="gmail_msg">
<br class="gmail_msg"><font size="2" face="sans-serif" class="gmail_msg">That's correct - the memory barrier/fence
is inserted regardless, but the impact of can be greater if multiple processors
are being used as there's additional cost is you have cache line collision
etc. </font>
<br class="gmail_msg">
<br class="gmail_msg"><font size="2" face="sans-serif" class="gmail_msg">Chris<br class="gmail_msg">
</font>
<br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg"><font size="1" color="#5f5f5f" face="sans-serif" class="gmail_msg">From:
</font><font size="1" face="sans-serif" class="gmail_msg">Michael Chiu <<a href="mailto:hatsuneyuji@icloud.com" class="gmail_msg" target="_blank">hatsuneyuji@icloud.com</a>></font>
<br class="gmail_msg"><font size="1" color="#5f5f5f" face="sans-serif" class="gmail_msg">To:
</font><font size="1" face="sans-serif" class="gmail_msg">Tanner Nelson <<a href="mailto:tanner@qutheory.io" class="gmail_msg" target="_blank">tanner@qutheory.io</a>></font>
<br class="gmail_msg"><font size="1" color="#5f5f5f" face="sans-serif" class="gmail_msg">Cc:
</font><font size="1" face="sans-serif" class="gmail_msg">Chris Bailey/UK/IBM@IBMGB,
swift-server-dev <<a href="mailto:swift-server-dev@swift.org" class="gmail_msg" target="_blank">swift-server-dev@swift.org</a>></font>
<br class="gmail_msg"><font size="1" color="#5f5f5f" face="sans-serif" class="gmail_msg">Date:
</font><font size="1" face="sans-serif" class="gmail_msg">27/03/2017 15:54</font>
<br class="gmail_msg"><font size="1" color="#5f5f5f" face="sans-serif" class="gmail_msg">Subject:
</font><font size="1" face="sans-serif" class="gmail_msg">Re: [swift-server-dev]
Next HTTP API meeting</font>
<br class="gmail_msg">
<hr noshade class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg"><tt class="gmail_msg"><font size="2" class="gmail_msg">Actually according to @hh, the compiler will add the
synchronization overhead no matter what.<br class="gmail_msg">
<br class="gmail_msg">
My guess is, despite the fact that the response will always been processed
by the same thread, but there'll be always a reference back to the main
event loop, and it is not obvious to the compiler so it will add the overhead
anyways, probably not lock but compare and swap.<br class="gmail_msg">
<br class="gmail_msg">
Michael <br class="gmail_msg">
Sent from my iPhone<br class="gmail_msg">
<br class="gmail_msg">
> On Mar 27, 2017, at 7:42 AM, Tanner Nelson <<a href="mailto:tanner@qutheory.io" class="gmail_msg" target="_blank">tanner@qutheory.io</a>>
wrote:<br class="gmail_msg">
> <br class="gmail_msg">
> @chris in my experience there's been very little passing of request/response
between threads. Usually the server accepts, spins up a new thread, and
all HTTP parsing/serializing happens on that one thread. <br class="gmail_msg">
> <br class="gmail_msg">
> Could you specify some examples where requests/responses are being
passed between threads?<br class="gmail_msg">
> <br class="gmail_msg">
> That said, it should be fairly easy to implement threading to see
what the effects would be. I will look into that. :)<br class="gmail_msg">
> <br class="gmail_msg">
> Tanner<br class="gmail_msg">
<br class="gmail_msg">
</font></tt>
<br class="gmail_msg">
<br class="gmail_msg"><font size="2" face="sans-serif" class="gmail_msg"><br class="gmail_msg">
Unless stated otherwise above:<br class="gmail_msg">
IBM United Kingdom Limited - Registered in England and Wales with number
741598. <br class="gmail_msg">
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6
3AU<br class="gmail_msg">
</font>_______________________________________________<br class="gmail_msg">
swift-server-dev mailing list<br class="gmail_msg">
<a href="mailto:swift-server-dev@swift.org" class="gmail_msg" target="_blank">swift-server-dev@swift.org</a><br class="gmail_msg">
<a href="https://lists.swift.org/mailman/listinfo/swift-server-dev" rel="noreferrer" class="gmail_msg" target="_blank">https://lists.swift.org/mailman/listinfo/swift-server-dev</a><br class="gmail_msg">
</blockquote></div>