<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/atom10full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" gd:etag="W/&quot;CUIHQ3o7fip7ImA9WhRbEE0.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771</id><updated>2012-01-31T01:52:12.406-08:00</updated><category term="BayFP" /><category term="WBRU" /><category term="computer science" /><category term="concolic testing" /><category term="cs164" /><category term="functional reactive programming" /><category term="lambda calculus" /><category term="Parallel FRP" /><category term="web frameworks" /><category term="security" /><category term="compilers" /><category term="programming" /><category term="ECMAScript" /><category term="CFL-Reachability" /><category term="parallel browser" /><category term="Points-To Analysis" /><category term="bay area" /><category term="TA" /><category term="cognitive science" /><category term="ErlyWeb" /><category term="Java" /><category term="Prolog" /><category term="optimistic replication" /><category term="flapjax" /><category term="windows sucks" /><category term="CouchDB" /><category term="autotuning" /><category term="firefox" /><category term="programming language theory" /><category term="Rhino" /><category term="mobile computing" /><category term="software engineering" /><category term="garbage collection" /><category term="e-cash" /><category term="sk combinators" /><category term="Berkeley" /><category term="refinement types" /><category term="machine learning" /><category term="programming languages" /><category term="JavaScript" /><category term="usability" /><category term="Erlang" /><title>The Good Soldier LMeyerov</title><subtitle type="html">a grad student's tale of survival in the face of absurd web programming models, systems insecure almost by design, disconnected language theories, and the berkeley meat grinder</subtitle><link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/posts/default" /><link rel="alternate" type="text/html" href="http://lmeyerov.blogspot.com/" /><link rel="next" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default?start-index=26&amp;max-results=25&amp;redirect=false&amp;v=2" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><generator version="7.00" uri="http://www.blogger.com">Blogger</generator><openSearch:totalResults>158</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/atom+xml" href="http://feeds.feedburner.com/lmeyerov" /><feedburner:info uri="lmeyerov" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><entry gd:etag="W/&quot;CUIHQ3oycCp7ImA9WhRbEE0.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-8360239699012335055</id><published>2012-01-31T01:12:00.001-08:00</published><updated>2012-01-31T01:52:12.498-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-01-31T01:52:12.498-08:00</app:edited><title>The fallacy of race to halt: power measurements from vectorizing webpage layout and binary search</title><content type="html">&lt;a href="http://3.bp.blogspot.com/-gtrv6G4stSI/TyewrwZOwjI/AAAAAAAAAfo/ZsqAmHj3C6w/s1600/power2.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 211px;" src="http://3.bp.blogspot.com/-gtrv6G4stSI/TyewrwZOwjI/AAAAAAAAAfo/ZsqAmHj3C6w/s400/power2.png" border="0" alt="" id="BLOGGER_PHOTO_ID_5703721718859612722" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://1.bp.blogspot.com/-q_q8CNIWKBE/Tyewr0g0c2I/AAAAAAAAAfc/DHlE48kB1Ys/s1600/power1.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 255px;" src="http://1.bp.blogspot.com/-q_q8CNIWKBE/Tyewr0g0c2I/AAAAAAAAAfc/DHlE48kB1Ys/s400/power1.png" border="0" alt="" id="BLOGGER_PHOTO_ID_5703721719965184866" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div&gt;An important rule of optimization is that you don't know if it worked until you've measured it. Parallel algorithms research, until recently, has violated this rule. Researchers typically report speedup (old time / new time) or scaling (sequential time / parallel time), but that is wrong. The main reason we even care about parallel algorithms is that parallel hardware &lt;i&gt;might&lt;/i&gt; provide more performance per Watt (PPW) &lt;i&gt;if we use it properly&lt;/i&gt;. Otherwise, we should just turn up the clock rate and forget about it. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;One of the most efficient forms of parallelism is SIMD, so I finally had a good opportunity to measure PPW vs. speedup for an algorithms paper we're finishing. For example, for our SIMD webpage layout algorithm performance (top picture),  our 5x of speedup comes with an 8.5x PPW increase.  Likewise, we sped up the binary search algorithm you learn in school by 15.8x and with a corresponding improvement on PPW of 13.1x. The biggest PPW wins were consistently from SIMD evaluation. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The surprise is that not all speedups improve PPW. We often assume work-efficient algorithms (parallel asymptotics do not dominate sequential ones) will, at worst, not impact PPW. Such "race to halt" reasoning is a good intuition, but even "intuitive" cases can break it. For example, take a closer look at our binary search results. Cache line blocking, a common high performance computing trick for better data prefetching, gives speedups for our binary search algorithm (both eager and optimistic speculative variants), but decreases PPW for the optimistic case.  Measuring cache line blocking energy consumption clearly shows it hurts  performance -- but based on speedup numbers and conventional wisdom, I wouldn't have bet that way.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-8360239699012335055?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/A3mMpVKtJzU" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/8360239699012335055/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=8360239699012335055" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/8360239699012335055?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/8360239699012335055?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/A3mMpVKtJzU/fallacy-of-race-to-halt-power.html" title="The fallacy of race to halt: power measurements from vectorizing webpage layout and binary search" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/-gtrv6G4stSI/TyewrwZOwjI/AAAAAAAAAfo/ZsqAmHj3C6w/s72-c/power2.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2012/01/fallacy-of-race-to-halt-power.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkQGQH0zfSp7ImA9WhRUFEo.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-2343945608945847117</id><published>2012-01-24T22:51:00.001-08:00</published><updated>2012-01-24T22:52:01.385-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-01-24T22:52:01.385-08:00</app:edited><title>Note to self</title><content type="html">Note to self: remember to include the phrase "We are 4.9x faster than FAST, the recent binary search algorithm ..." into the paper rewrite.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-2343945608945847117?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/soMST7Fp1fk" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/2343945608945847117/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=2343945608945847117" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/2343945608945847117?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/2343945608945847117?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/soMST7Fp1fk/note-to-self.html" title="Note to self" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2012/01/note-to-self.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0AHRX46fSp7ImA9WhRWEkU.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-6883585647744659591</id><published>2011-12-30T13:44:00.000-08:00</published><updated>2011-12-30T13:48:54.015-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-12-30T13:48:54.015-08:00</app:edited><title>Natbib for LNCS / splncs.bst</title><content type="html">It took me awhile to find this, but if you want to use \citeauthor, \citet macros from natbib, etc. for Springer / LNCS papers, use &lt;a href="http://phaseportrait.blogspot.com/2011/02/natbib-compatible-bibtex-style-bst-file.html"&gt;this package&lt;/a&gt;. If you aren't using these macros, you should: it will avoid heartache from misspelling author names. If you are not mentioning author names, this may also help put you into the habit.&lt;br /&gt;&lt;br /&gt;&lt;div class="code"&gt;&lt;br /&gt;\documentclass{llncs}&lt;br /&gt;\usepackage[numbers]{natbib}&lt;br /&gt;\bibliographystyle{splncsnat}&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;Springer, please fix this!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-6883585647744659591?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/Hv0PQaQxhCc" height="1" width="1"/&gt;</content><link rel="related" href="http://phaseportrait.blogspot.com/2011/02/natbib-compatible-bibtex-style-bst-file.html" title="Natbib for LNCS / splncs.bst" /><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/6883585647744659591/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=6883585647744659591" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/6883585647744659591?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/6883585647744659591?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/Hv0PQaQxhCc/natbib-for-lncs-splncsbst.html" title="Natbib for LNCS / splncs.bst" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2011/12/natbib-for-lncs-splncsbst.html</feedburner:origLink></entry><entry gd:etag="W/&quot;Ck4GQnk8cSp7ImA9WhRXGU4.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-324712449523146221</id><published>2011-12-25T14:59:00.000-08:00</published><updated>2011-12-26T12:22:03.779-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-12-26T12:22:03.779-08:00</app:edited><title>FTL: Fast Tree Language for synthesizing a parallel layout engine</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.eecs.berkeley.edu/~lmeyerov/projects/pbrowser/pubfiles/spiraldemo2/364.html"&gt;&lt;img style="display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 382px; height: 400px;" src="http://1.bp.blogspot.com/-1FnhUDcReBE/Tve0yT3KuWI/AAAAAAAAAWk/Qb9Qql-eKgQ/s400/files3.tiff" alt="" id="BLOGGER_PHOTO_ID_5690215430624033122" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;A radial layout widget declaratively specified in FTL being used to visualize file directory structure. Achieves 22fps through quadcore layout and GPU rendering. Check out the &lt;a href="http://www.eecs.berkeley.edu/~lmeyerov/projects/pbrowser/pubfiles/spiraldemo2/364.html"&gt;HTML5 version and source code&lt;/a&gt;.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;We finally submitted &lt;a href="http://eecs.berkeley.edu/~lmeyerov/projects/pbrowser/pubfiles/ftl.pdf"&gt;a paper about FTL&lt;/a&gt;, our language for specifying layout languages and synthesizing a parallel evaluator. The paper is dense, so we'd appreciate feedback on what to cut and what to expand :)&lt;br /&gt;&lt;br /&gt;Our systems goes all the way from a high-level language specification to an optimized browser layout engine. We had to solve two basic problems:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Strongly scaling the parallel tree traversals.&lt;/span&gt; Our specification analysis will take a language specification, such as for CSS, and find a sequence of parallel tree traversals that will lay out any document (the tree) in that language. However, we couldn't find any existing algorithms that would give you a 2x speedup on 2 cores, 4x speedup on 4 cores, etc. We ended up A) finding a mix of existing data layout optimizations (pointer compression, blocking, etc.) and B) inventing our own runtime task scheduler (semi-static scheduling that &lt;span style="font-style: italic;"&gt;simulates&lt;/span&gt; work stealing to precompute a partitioning). Scaling plummets if you drop either. More fun, due to the locality benefits of data layout optimizations, we achieve superlinear speedups -- 9.2.x on 8 cores!&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Generating the &lt;span style="font-style: italic;"&gt;right&lt;/span&gt; sequence of tree traversals.&lt;/span&gt; While our system will automatically find parallelism in a declarative specification, it won't find all. For example, specifying how a box lays out its children by using absolute coordinates creates a global dependency, but specifying them as coordinates relative to the box and then stitching them together to get the absolute ones will break the dependency enough for our analysis. Programmers can write queries about the set of schedules inferable from a specification to help debug this sort of problem. &lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;We found reasoning about schedules to be such a helpful programming tool that we incorporated it into our specification language. For example, it's very convenient to make rendering calls within a specification, e.g., "box(self.x,self.y,self.w,self.h,self.color)". The specification must take care to say what order to render boxes, such as the foreground text being above the background. Z indices are ambiguous due to overlap and monadically passing around the dependency is really painful. We can take a lesson from the current informal CSS standard, which specifies the document traversal order and then locally defines order within each node. Our solution is to allow functional specifications (the grammar) to be refined with traversal order constraints ("do rendering in an inorder traversal"). We can also catch specification changes that violate such a constraint!&lt;br /&gt;&lt;br /&gt;Synthesizing schedules yields extra benefits. When synthesizing an implementation that talks to legacy code, this has the added benefit of making it easy to avoid parallel calls into non-reentrant libraries. Furthermore, many different traversals will implement the same specification: our synthesizer can generate them and autotune over them.&lt;br /&gt;&lt;br /&gt;I'm working with some great undergrads to move forward on several fronts. At MSR, I wrote a proof-of-concept manual implementation that uses SIMD instructions for further speedups within a core: we're now automating it as a new FTL backend. Next, Thibaud Hottelier is writing a visualization language based on bidirectional constraints that compiles to FTL, which our undergrads are using to write some stunning demos. I already wrote one to animate inspecting file sizes on your hard drive (see picture above): we get 22fps for animating 20,000 files, and we should handle bigger data sets once I fix some segfaults. [For reference -- the HTML5 version is 8fps and, on my phone, 1fps]. Finally, we're pushing FTL's expressive limits by formalizing the CSS standard in it. Fun times ahead!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-324712449523146221?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/oJ1DedgrDwU" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/324712449523146221/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=324712449523146221" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/324712449523146221?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/324712449523146221?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/oJ1DedgrDwU/ftl-fast-tree-language-for-synthesizing.html" title="FTL: Fast Tree Language for synthesizing a parallel layout engine" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/-1FnhUDcReBE/Tve0yT3KuWI/AAAAAAAAAWk/Qb9Qql-eKgQ/s72-c/files3.tiff" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2011/12/ftl-fast-tree-language-for-synthesizing.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DUAASHY4eCp7ImA9WhdWGEg.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-6266688877065559265</id><published>2011-09-12T12:40:00.000-07:00</published><updated>2011-09-12T13:02:29.830-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-09-12T13:02:29.830-07:00</app:edited><title>What to Implement</title><content type="html">&lt;div style="text-align: center;"&gt;&lt;span class="Apple-style-span"&gt;&lt;u&gt;&lt;br /&gt;&lt;/u&gt;&lt;/span&gt;&lt;/div&gt;&lt;a href="http://4.bp.blogspot.com/-_VdG3Fz1vqY/Tm5j9Mg3YSI/AAAAAAAAARE/rsL7erljXJ8/s1600/propertydistribution.png" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 284px; height: 400px;" src="http://4.bp.blogspot.com/-_VdG3Fz1vqY/Tm5j9Mg3YSI/AAAAAAAAARE/rsL7erljXJ8/s400/propertydistribution.png" border="0" alt="" id="BLOGGER_PHOTO_ID_5651564485378793762" /&gt;&lt;/a&gt;&lt;br /&gt;A big chunk of the coding side of my thesis is writing a declarative spec of CSS and then  automatically generating a fast/correct/instrumentable/etc. implementation from it. However, how much do I really need to implement? More generally, if you're making a tool to compute over webpage style, how much do you really care about? E.g., if you make a proxy-based layout optimizer, which features are important? Full compliance, ACID tests, etc. are often an overkill.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;To help pick a subset to focus on, I ran a bunch of popular pages through my parallel browser skeleton and counted dynamic occurrences of CSS attributes. For example, if a browser or user defined style property is that images inside paragraphs get a blue border ("p img { border: blue; }"), and a gallery has 2 such pictures, that counts as 2 hits on feature "border". &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;For many features, the options -- e.g., blue vs. red, 10" vs. 20% -- are easy to handle. For others, the cases are a big deal: e.g., a table ("display: table") vs. word-wrapping box ("display: block"). So, for some of the more common features, I also broke down the cases. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The diagrams below show first the features and then, for a couple, the cases. It might be interesting to also do a log plot (power law, anyone?). Basically, you can get legible (but wonky) looking sites without much. To get pixel perfect... not so much.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;a href="http://3.bp.blogspot.com/-ZrJMgQ2sLG4/Tm5kXv28mPI/AAAAAAAAARc/sSP7NF6eL5Q/s1600/position.png" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"&gt;&lt;img src="http://3.bp.blogspot.com/-ZrJMgQ2sLG4/Tm5kXv28mPI/AAAAAAAAARc/sSP7NF6eL5Q/s400/position.png" border="0" alt="" id="BLOGGER_PHOTO_ID_5651564941543250162" style="display: block; margin-top: 0px; margin-right: auto; margin-bottom: 10px; margin-left: auto; text-align: center; cursor: pointer; width: 400px; height: 241px; " /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://3.bp.blogspot.com/-_CyEblMl3UY/Tm5kUDy2h1I/AAAAAAAAARU/IIEl2fUjgUc/s1600/float.png" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"&gt;&lt;img src="http://3.bp.blogspot.com/-_CyEblMl3UY/Tm5kUDy2h1I/AAAAAAAAARU/IIEl2fUjgUc/s400/float.png" border="0" alt="" id="BLOGGER_PHOTO_ID_5651564878175307602" style="display: block; margin-top: 0px; margin-right: auto; margin-bottom: 10px; margin-left: auto; text-align: center; cursor: pointer; width: 400px; height: 241px; " /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://2.bp.blogspot.com/-pzTZYgCO0jE/Tm5kPO19InI/AAAAAAAAARM/AmatCgH411Q/s1600/display.png" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"&gt;&lt;img src="http://2.bp.blogspot.com/-pzTZYgCO0jE/Tm5kPO19InI/AAAAAAAAARM/AmatCgH411Q/s400/display.png" border="0" alt="" id="BLOGGER_PHOTO_ID_5651564795241767538" style="display: block; margin-top: 0px; margin-right: auto; margin-bottom: 10px; margin-left: auto; text-align: center; cursor: pointer; width: 400px; height: 397px; " /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;**Note: this isn't terribly scientific. The sample size is small and on popular, professionally engineered sites. Likewise, many of the features are 'default' features set by the browser, and may even correspond to doing nothing. For a bigger scale, also check out Opera's &lt;a href="http://dev.opera.com/articles/view/mama/"&gt;MAMA&lt;/a&gt; analysis.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-6266688877065559265?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/zJglB-hboqI" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/6266688877065559265/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=6266688877065559265" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/6266688877065559265?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/6266688877065559265?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/zJglB-hboqI/what-to-implement.html" title="What to Implement" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://4.bp.blogspot.com/-_VdG3Fz1vqY/Tm5j9Mg3YSI/AAAAAAAAARE/rsL7erljXJ8/s72-c/propertydistribution.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2011/09/what-to-implement.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CE8CRXcyeSp7ImA9WhdSFUU.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-4429028021545946709</id><published>2011-07-25T01:25:00.000-07:00</published><updated>2011-07-25T01:34:24.991-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-07-25T01:34:24.991-07:00</app:edited><title>Advanced, Submitted... Time for new things!</title><content type="html">I passed my quals, and Todd Mytkowicz and I just submitted a fun paper on using SIMD instructions where you shouldn't. Maybe now I can start doing research again..&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Particularly fun in our submission is a 4x speedup on a canonically sequential algorithm as well as some more browser hardware acceleration tricks. Weirdest yet, in our approach, the clustering ratio of how well you can relate objects in a data parallel computation is inversely proportional to our expected vector etc. speedup! Somehow, it all makes sense. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Sadly, we couldn't do our 2 coolest algorithms: one for legal reasons, the other because the vector hardware I have is missing a permute instruction. So goes.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-4429028021545946709?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/kd0rscfNxUw" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/4429028021545946709/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=4429028021545946709" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/4429028021545946709?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/4429028021545946709?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/kd0rscfNxUw/advanced-submitted-time-for-new-things.html" title="Advanced, Submitted... Time for new things!" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2011/07/advanced-submitted-time-for-new-things.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DEcHQHk4fip7ImA9WhZQF0Q.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-6337691895120981803</id><published>2011-04-25T22:21:00.001-07:00</published><updated>2011-04-25T22:33:51.736-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-04-25T22:33:51.736-07:00</app:edited><title>New Berkeley Prelim Syllabus</title><content type="html">I volunteered to help rethink the language design portion of the Berkeley prelim syllabus this week.  Increasing the challenge is that we're cutting down from 60+ articles from before to only 36. We're shooting for about 6 core technical papers, and hoping there will be overlap with other areas (e.g., semantics, type theory, verification, optimization).&lt;br /&gt;&lt;br /&gt;For my first pass, I've been thinking:&lt;div&gt;&lt;ol&gt;&lt;li&gt;macros&lt;/li&gt;&lt;li&gt;continuations: &lt;span class="Apple-style-span" style="font-family: Arial; font-size: 15px; "&gt;&lt;span style="font-size: 11pt; font-family: Arial; color: rgb(0, 0, 153); background-color: transparent; font-weight: normal; font-style: normal; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap; "&gt;&lt;a href="http://www.springerlink.com/content/d50g530707771gu1/"&gt;on implementing prolog in functional programming&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span"&gt;&lt;span class="Apple-style-span" style="font-size: 15px;"&gt;meta object protocol + messages: &lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Arial; font-size: 15px; "&gt;&lt;span style="font-size: 11pt; font-family: Arial; color: rgb(0, 0, 153); background-color: transparent; font-weight: normal; font-style: normal; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap; "&gt;&lt;a href="http://www.bracha.org/mirrors.pdf"&gt;mirrors&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="font-family: Arial; font-size: 15px; "&gt;type-directed programming: &lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Arial; font-size: 15px; "&gt;&lt;span style="font-size: 11pt; font-family: Arial; color: rgb(0, 0, 153); background-color: transparent; font-weight: normal; font-style: normal; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap; "&gt;&lt;a href="http://citeseerx.ist.psu.edu/viewdoc/download;jsessionid=D05232418D233CD64342933C9EAB76D5?doi=10.1.1.33.7930&amp;amp;rep=rep1&amp;amp;type=pdf"&gt;more types for nested data parallel programming&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Arial; font-size: 15px; white-space: pre-wrap; "&gt; &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;Any ideas for particulars or topic areas? For macros, I had been considering Shriram's &lt;span class="Apple-style-span" style="font-family: Arial; font-size: 15px; "&gt;&lt;span style="font-size: 11pt; font-family: Arial; color: rgb(0, 0, 153); background-color: transparent; font-weight: normal; font-style: normal; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap; "&gt;&lt;a href="http://www.cs.brown.edu/~sk/Publications/Papers/Published/sk-automata-macros/"&gt;swine before per&lt;/a&gt;l&lt;/span&gt;&lt;/span&gt; or &lt;span class="Apple-style-span" style="font-family: Arial; font-size: 15px; "&gt;&lt;span style="font-size: 11pt; font-family: Arial; color: rgb(0, 0, 153); background-color: transparent; font-weight: normal; font-style: normal; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap; "&gt;&lt;a href="http://www.cs.brown.edu/people/sk/Publications/Papers/Published/ick-adapt-oo-fwk-frp/paper.pdf"&gt;Adapting Object-Oriented Frameworks to FRP&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;. There are also some lightweight but useful papers, such as Hoare's &lt;span class="Apple-style-span" style="font-family: Arial; font-size: 15px; "&gt;&lt;span style="font-size: 11pt; font-family: Arial; color: rgb(0, 0, 153); background-color: transparent; font-weight: normal; font-style: italic; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap; "&gt;&lt;a href="http://portal.acm.org/book_gateway.cfm?id=63445&amp;amp;type=pdf&amp;amp;bookpath=%2F70000%2F63445%2Fcb-p193-hoare.pdf&amp;amp;coll=&amp;amp;dl=GUIDE&amp;amp;CFID=15151515&amp;amp;CFTOKEN=6184618&amp;amp;ei=xPFZSp7eOoaHtgel67XdCg&amp;amp;usg=AFQjCNFRgx0Pyq3NsScwyv2IKKIFm7SpGA&amp;amp;sig2=d1AfYhaeL8jMxLLO_M-5dA"&gt;Hints on Programming-Language Design&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;. I couldn't think of anything sufficiently motivated for laziness (e.g., stream processing is pretty weak and equational reasoning is iffy). &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Fun exercise :) &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I'll try to post soon about some of the fun PL design / analysis / optimization work I've been doing. We just finished a camera ready for a workshop but I won't be writing up any of my bigger papers (SIMD tree layouts, multicore scheduling, CSS semantics / layout engine synthesis, and adoption-oriented languages) until later this year. Need to kickstart the writing process :)&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-6337691895120981803?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/P3B41xq4v1Q" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/6337691895120981803/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=6337691895120981803" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/6337691895120981803?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/6337691895120981803?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/P3B41xq4v1Q/new-berkeley-prelim-syllabus.html" title="New Berkeley Prelim Syllabus" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>2</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2011/04/new-berkeley-prelim-syllabus.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D0QBQHg5eip7ImA9WhZSF0Q.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-5194863903443066581</id><published>2011-04-02T18:38:00.000-07:00</published><updated>2011-04-02T18:49:11.622-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-04-02T18:49:11.622-07:00</app:edited><title>Topological Sort in Datalog</title><content type="html">As a neat trick, I've been spending the weekend rewriting our hundrends (thousands?) of lines of attribute grammar visit scheduling from Java to maybe 100 lines of Datalog. This isn't so much of a surprise: there's been a bunch of work showing how to declaratively describe program analyses with datalog (and optimally optimize it with BDDs, though those results are, unfortunately, more contentious).&lt;br /&gt;&lt;br /&gt;Anyways, the core of an attribute grammar scheduler is a topological sort of dependencies. I found this difficult to write. Originally, I tried using a successor relation, where each step was the set of edges (or nodes) that are reachable from the previous. No go, and searching on the web, I didn't see anything else. So, here's another tact:&lt;br /&gt;&lt;br /&gt;Given the data:&lt;br /&gt;&lt;div class="code"&gt;&lt;br /&gt;&lt;br /&gt;edge('aa', 'b').&lt;br /&gt;&lt;br /&gt;edge('a', 'b').&lt;br /&gt;edge('b', 'c').&lt;br /&gt;edge('c', 'd').&lt;br /&gt;&lt;br /&gt;edge('d', 'y').&lt;br /&gt;edge('d', 'z').&lt;br /&gt;&lt;br /&gt;edge('a', 'm').&lt;br /&gt;edge('m', 'n').&lt;br /&gt;edge('n', 'o').&lt;br /&gt;&lt;br /&gt;edge('o', 'y').&lt;br /&gt;edge('o', 'z').&lt;br /&gt;&lt;br /&gt;node(?n) :- edge(?n, ?m).&lt;br /&gt;node(?n) :- edge(?m, ?n).&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;We calculate the flows-to relation, and then, for each edge, propagate 1 + the label of the previous edge. Finally, we take the maximal incoming label for each node, and voila!&lt;br /&gt;&lt;br /&gt;&lt;div class="code"&gt;&lt;br /&gt;&lt;br /&gt;flows(?n, ?m) :- edge(?n, ?m).&lt;br /&gt;flows(?n, ?m) :- flows(?n, ?x), flows(?x, ?m).&lt;br /&gt;whenAll(?n, 0) :- node(?n), !edge(?m, ?n).&lt;br /&gt;whenAll(?n, ?c) :- whenAll(?m, ?d), flows(?m, ?n), ?d + 1 = ?c. &lt;br /&gt;when(?n, ?c) :- whenAll(?n, ?c), ?c + 1 = ?d, !whenAll(?n, ?d). &lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;Testing the result:&lt;br /&gt;&lt;br /&gt;&lt;div class="code"&gt;&lt;br /&gt;?- when(?n, ?c).  &lt;br /&gt;Query:      ?- when(?n, ?c). ==&gt;&gt; 10 rows in 0ms&lt;br /&gt;Variables:  ?n, ?c&lt;br /&gt;('aa', 0)&lt;br /&gt;('a', 0)&lt;br /&gt;('b', 1)&lt;br /&gt;('m', 1)&lt;br /&gt;('c', 2)&lt;br /&gt;('n', 2)&lt;br /&gt;('d', 3)&lt;br /&gt;('o', 3)&lt;br /&gt;('y', 4)&lt;br /&gt;('z', 4)&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-5194863903443066581?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/uecmDX1lJCk" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/5194863903443066581/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=5194863903443066581" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/5194863903443066581?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/5194863903443066581?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/uecmDX1lJCk/topological-sort-in-datalog.html" title="Topological Sort in Datalog" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2011/04/topological-sort-in-datalog.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DUANRH89eyp7ImA9Wx9VEUQ.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-5156228049482257042</id><published>2011-01-27T22:10:00.000-08:00</published><updated>2011-01-27T22:56:35.163-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-01-27T22:56:35.163-08:00</app:edited><title>SIMTask parallelism and ConLangs</title><content type="html">Thought I'd post about two interesting things I've been looking at recently: running task parallel code using SIMD instructions and artificial human languages.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;SIMTask Parallelism&lt;/span&gt;&lt;br /&gt;First, while trying to make CSS layout engines ridiculously fast through hardware-oriented optimizations, I had the basic question: well, if it has multicore-friendly parallelism, why not SIMD-friendly parallelism? I wasn't sure how practical the question was, but as an academic experiment, it's a very interesting one about the nature of parallelism in 'real' hard-to-parallelize software (as opposed to, say, rendering and dense matrices).  Looking at our task parallel formulation of CSS layout, we can say it's a combination of two patterns: a task-parallel decomposition roughly following the HTML tree, and a visitor pattern for dispatching different tasks based on the type of each tree node (paragraph, link, etc.). How do we use SIMD instructions for that?&lt;br /&gt;&lt;br /&gt;Often, for SIMD instructions, we want something like basic reductions (e.g., scan operations): taking the sum of a list, max of a list. We don't see that a lot in webpages: you'll sum up the children in a node, but then do a lot of computation within the node (margin, padding, border, etc.). Even better for SIMD instructions are maps: add 10 to each width, divide every height by 3, etc. That sounds more close to what we want... except the visitor pattern thing: the data being computed on with the same instructions needs to be adjacent, but, unfortunately, if we look at the tree, different functions are being run on adjacent nodes!&lt;br /&gt;&lt;br /&gt;Enter SIMTask parallelism. We can do some data mining on the tree to rearrange it in memory so that the same type of node is next to others of the same type. For example, we can collapse the webpage into a &lt;a href="http://en.wikipedia.org/wiki/Trie"&gt;prefix tree&lt;/a&gt; and use that to have a different layout in memory: now the same types of nodes are next to each other physically. Because of the task parallelism (with some minor compiler trickery), we can actually run the code in this same rearranged order! For example, in a shopping cart, where each shopping cart item is a complicated subtree, but the subtrees are the same across items (just changing what picture, what text, etc.), all of the link nodes will be next to each other in memory, as will text, as will paragraph formatting, etc. SIMD instructions can be then used!&lt;br /&gt;&lt;br /&gt;Anyways, we just submitted a fun vision paper about this. If you take a step back, what we're really saying is that task parallel code often isn't just good for multicores: with smarter frameworks and compilers, we can hope for exploiting some regularity in the task structure to get better memory effects (e.g., from &lt;a href="http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.33.7930"&gt;flattening&lt;/a&gt;) and even potentially scale down the parallelism to use SIMD evaluation (including better branch prediction)! This is a big departure from current lightweight task parallel frameworks like Cilk/TBB, that, outside of some stack representation trickery, are really about lightweight runtimes and not heavy yet powerful code transformations. &lt;br /&gt;&lt;br /&gt;Finally, if you're familiar with modern GPU architecture, this may sound familiar. Modern GPUs use something called a SIMThread model, which is somewhere between vector and threaded ones. Threads get bundled, and for the convergent threads in a bundle (i.e., branching the same way), you get parallel/vector execution. SIMThread = Same Instruction, Multiple Threads. SIMTasks are like that, but more software managed: SIMTasks are to SIMThreads as threads are to SIMThreads. Likewise, vectors &lt; SIMThreads &lt; threads, and reductions/scans &lt; SIMTasks &lt; tasks. Doing SIMTasks introduces a pretty interesting world of optimization; I did some neat tricks with memory layouts and even found opportunities for memoization across SIMTasks that you wouldn't get in normal tasks (in CSS, at least). If you haven't picked up on it now, SIMTask = Same Instruction, Multiple Tasks.&lt;br /&gt;&lt;br /&gt;Should be able to put the paper out in a couple months either way. I'd like to report on the full results of the CSS side of things, but we didn't really fit that into this writeup and am not sure when we can (a bit more work to do, can use more automation, and deserves its own writeup -- maybe if we fit it into the Berkeley browser we'll be able to). Story of my life :)&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;ConLangs: Constructed Languages&lt;/span&gt;&lt;br /&gt;A little more fun, I was browsing a bookstore and found a book about the rise of inventing languages: &lt;a href="http://inthelandofinventedlanguages.com/"&gt;In the Land of Invented Languages&lt;/a&gt;. However, with maybe one exception, these weren't about languages for instructing computers: these are about languages for communicating between humans. We all know Esparanto and Klingon, and maybe even Hildegard's and Tolkein's (Tolkein made the elves' language, including their derivation, before the books!), but there have been symbol languages adopted for the deaf, and, even earlier, language invention was almost a gentleman's pursuit. &lt;br /&gt;&lt;br /&gt;One was particularly fun: &lt;a href="http://www.laadanlanguage.org/pages/node/43"&gt;Laadan&lt;/a&gt;, a language from a woman's perspective. It stole a bit from Navajo, but apparently also has some novelties predicting some modern security and HCI research: for the grammar, terms are affixed both with emotion and source of authority! &lt;br /&gt;&lt;br /&gt;I was really interested in the book as part of my "socio-PLT" kick (sociological approach to programming language theory): how is adopting Klingon or Logjam different from adopting brainfuck or Haskell?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-5156228049482257042?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/V76F9NAQqaY" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/5156228049482257042/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=5156228049482257042" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/5156228049482257042?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/5156228049482257042?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/V76F9NAQqaY/simtask-parallelism-and-conlangs.html" title="SIMTask parallelism and ConLangs" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2011/01/simtask-parallelism-and-conlangs.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkIERXkyeip7ImA9Wx9SEko.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-7598967452926131277</id><published>2010-12-01T22:09:00.000-08:00</published><updated>2010-12-01T22:15:04.792-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-12-01T22:15:04.792-08:00</app:edited><title>Last class!</title><content type="html">I believe this will be my last class at Berkeley: &lt;a href="http://www.ischool.berkeley.edu/courses/203"&gt;Social and Organizational Issues of Information&lt;/a&gt;. Should be fun -- the main impetus being my questions about programming language adoption, but even that has been broadening recently.&lt;br /&gt;&lt;br /&gt;In that spirit, a fun NY Times book review on &lt;a href="http://www.nytimes.com/2010/11/14/books/review/Greif-t.html"&gt;70's French sociology explaining hipsters, tastes, and, I posit, programming language popularity&lt;/a&gt;. It's on my To-Read list for as soon as I can track it down.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-7598967452926131277?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/foLghfEcZBU" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/7598967452926131277/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=7598967452926131277" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/7598967452926131277?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/7598967452926131277?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/foLghfEcZBU/last-class.html" title="Last class!" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>2</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/12/last-class.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CEEAQXk4eyp7ImA9Wx9SEE8.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-5355527429259132812</id><published>2010-11-29T00:29:00.001-08:00</published><updated>2010-11-29T01:24:00.733-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-11-29T01:24:00.733-08:00</app:edited><title>Proxies gaining traction... objects considered harmful?</title><content type="html">I saw that Brendan has started &lt;a href="http://brendaneich.com/2010/11/proxy-inception/"&gt;promoting proxies&lt;/a&gt; in his talks. Now that Mozilla's JS engine has a proxy primitive (essentially objects that support full overriding of meta object protocol interactions), Brendan stated that Firefox 4 code is apparently shifting to use them for &lt;a href="https://developer.mozilla.org/en/XPConnect_security_membranes"&gt;securely connecting browser JS code&lt;/a&gt; In a security context, you need (1) a recursive pattern ("membranes") with double-sided protection but also (2) some way of securely injecting your policies into the wrappers (e.g.,for a whitelist, to prevent the whitelist object from leaking out and being hijacked). While Adrienne and I mostly focused on the web application scenario in our Object Views paper about extending a library that does (1) to also do (2),  it equally applies to a browser security kernel employing the pattern. Indeed, one of our ultimate goals was for browser extensions!&lt;br /&gt;&lt;br /&gt;There's also a fun implementation tidbit that popped out. Andreas implemented proxies using an indirection table similar to that for the 'becomes' operator in Smalltalk. For our approach to incorporating policies into wrappers in both a succinct and safe way, we used aspects as the interface. I &lt;a href="http://lmeyerov.blogspot.com/2010/01/become-operator-advice-and-javascript.html"&gt;previously  showed&lt;/a&gt; 'becomes' and (ocap-style) aspects are the same thing. While not much is known in popular communities about 'becomes', aspects are fairly close to the ability to &lt;a href="http://xkcd.com/353/"&gt;import antigravity&lt;/a&gt;. As noted on Brendan's blog, a world of known language abstractions are now possible for these objects: perhaps using regular objects should be considered harmful?&lt;br /&gt;&lt;br /&gt;Finally, as I'm now apparently a performance person  -- it would be interesting to compare the efficiency of Ben Lerner's JS aspect implementation for Spur (a tracing JS VM from MSR) to Gal's proxys. I'm still curious, especially once one takes tracing optimizations into account and typical boundary crossing rates, which is more efficient. As promoted in Joel's 2010 Usenix paper, objects should be closely associated with origins (i.e., taint field), and, as suggested in our W2SP paper, I'm particularly curious about creating origin-indexed views: putting 1 + 1 together, can we get dynamic security primitives for multiprincipal programming at no runtime overhead (modulo policy logic)?&lt;br /&gt;&lt;br /&gt;Anyways, I've been mostly quiet about my work recently: I've stumbled upon a couple of big algorithm and related programming model results at MSR this fall so, once able, I'm looking forward to describing them. I'm starting again with the socio-PLT stuff so we'll see where that goes as well. Back in Berkeley in January; the next couple of months will be busy!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-5355527429259132812?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/CMIp1rqV3M8" height="1" width="1"/&gt;</content><link rel="related" href="http://brendaneich.com/2010/11/proxy-inception/" title="Proxies gaining traction... objects considered harmful?" /><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/5355527429259132812/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=5355527429259132812" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/5355527429259132812?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/5355527429259132812?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/CMIp1rqV3M8/proxies-gaining-traction-objects.html" title="Proxies gaining traction... objects considered harmful?" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/11/proxies-gaining-traction-objects.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkQERn84cSp7ImA9Wx5WF0k.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-1503326196023672446</id><published>2010-09-28T22:54:00.000-07:00</published><updated>2010-09-28T23:05:07.139-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-09-28T23:05:07.139-07:00</app:edited><title>1/3rd solved</title><content type="html">The theory behind an LL(k) version of worst-case expressive typical-case efficient parsing is easy... almost a restatement of how to do LL(k):&lt;br /&gt;&lt;br /&gt;&lt;a href="http://2.bp.blogspot.com/_4m57DDHVrBA/TKLWCNMZblI/AAAAAAAAAPU/_sgWkTe_QR4/s1600/parser.png"&gt;&lt;img style="display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 400px; height: 159px;" src="http://2.bp.blogspot.com/_4m57DDHVrBA/TKLWCNMZblI/AAAAAAAAAPU/_sgWkTe_QR4/s400/parser.png" alt="" id="BLOGGER_PHOTO_ID_5522211426499391058" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The proper way to state this might be an interesting form of abstract interpretation, but, in that case, my arrows are upside down.&lt;br /&gt;&lt;br /&gt;Now to earn the bacon by replacing the LLker boxes with LRker ones. Way better than proposal writing and apartment hunting. Tomorrow will be my last Philz coffee for a long time -- hello Seattle!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-1503326196023672446?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/C-cHA4P2Mx4" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/1503326196023672446/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=1503326196023672446" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/1503326196023672446?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/1503326196023672446?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/C-cHA4P2Mx4/13rd-solved.html" title="1/3rd solved" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/_4m57DDHVrBA/TKLWCNMZblI/AAAAAAAAAPU/_sgWkTe_QR4/s72-c/parser.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/09/13rd-solved.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A0YMR3YzcCp7ImA9Wx5WE0w.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-3888472491910326338</id><published>2010-09-23T14:45:00.000-07:00</published><updated>2010-09-24T02:06:26.888-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-09-24T02:06:26.888-07:00</app:edited><title>Affinity Matters</title><content type="html">Took me awhile to find this, but to pin the current thread to some core on Linux 2.6+ kernels:&lt;br /&gt;&lt;br /&gt;&lt;div class="code"&gt;&lt;br /&gt;  cpu_set_t mask;&lt;br /&gt;  CPU_ZERO(&amp;mask);&lt;br /&gt;  CPU_SET( SOME_CORE_INT, &amp;mask);&lt;br /&gt;  int error = sched_setaffinity(0, sizeof mask, &amp;mask);&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;Using this significantly improved the scaling of my multicore tree visitors. I still haven't found a good way to do it on OS X systems, which only seems to support affinity across units with distinct L2 caches.&lt;br /&gt;&lt;br /&gt;I believe it's more general than pinning in that it could be used for affinity by setting multiple potential cores. Tuning for hyperthreads is iffy in that I believe the hardware context -&gt; logical cpu mapping is unreliable (e.g., no guarantee the HTs are contiguously named).&lt;br /&gt;&lt;br /&gt;Edit: also, all you need to do is link in -lpthread and include "pthread.h" ; no more funny business.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-3888472491910326338?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/wQmTqkYIkX4" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/3888472491910326338/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=3888472491910326338" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/3888472491910326338?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/3888472491910326338?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/wQmTqkYIkX4/affinity-matters.html" title="Affinity Matters" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/09/affinity-matters.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CUEARng-fSp7ImA9Wx5XEE0.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-12339830434543597</id><published>2010-09-08T20:40:00.001-07:00</published><updated>2010-09-08T20:40:47.655-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-09-08T20:40:47.655-07:00</app:edited><title>Back from San Diego</title><content type="html">Seth and I invented an awesome new multicore+simd parsing algorithm on the flight back. Sweet.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-12339830434543597?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/rtLeC-_K-i8" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/12339830434543597/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=12339830434543597" title="3 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/12339830434543597?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/12339830434543597?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/rtLeC-_K-i8/back-from-san-diego.html" title="Back from San Diego" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>3</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/09/back-from-san-diego.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkMEQng4fyp7ImA9Wx5QF0s.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-3107964421745988890</id><published>2010-09-06T01:38:00.000-07:00</published><updated>2010-09-06T02:13:23.637-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-09-06T02:13:23.637-07:00</app:edited><title>One scalable memory allocator later...</title><content type="html">... and we now have great utilization on a quadcore. Colors represent sequential workload times in milliseconds: we're trying to speed up a bunch of tiny passes.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_4m57DDHVrBA/TISsvnOeY1I/AAAAAAAAAPA/utfCrS8xkU0/s1600/graph2.png"&gt;&lt;img style="display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 400px; height: 279px;" src="http://3.bp.blogspot.com/_4m57DDHVrBA/TISsvnOeY1I/AAAAAAAAAPA/utfCrS8xkU0/s400/graph2.png" alt="" id="BLOGGER_PHOTO_ID_5513721777791853394" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The first two dips occur at socket jumps, the second dip worsens due to Amdahl's law (a buggy work partitioner), and from there the performance soon peaks before burning out.&lt;br /&gt;&lt;br /&gt;An interesting challenge I don't see often discussed is that I'm benchmarking the solving time and I needed to pull quite a few tricks to warm up before then (time isn't included here). Some time before a pass actually starts, e.g., near the end of the previous pass, the final implementation should actually start warming it up. That's a tuning nightmare! However, more fun, I want to first experiment with tree SIMDization.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-3107964421745988890?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/m1eo4lOTPc0" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/3107964421745988890/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=3107964421745988890" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/3107964421745988890?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/3107964421745988890?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/m1eo4lOTPc0/one-scalable-memory-allocator-later.html" title="One scalable memory allocator later..." /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/_4m57DDHVrBA/TISsvnOeY1I/AAAAAAAAAPA/utfCrS8xkU0/s72-c/graph2.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/09/one-scalable-memory-allocator-later.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DEEMQHs4eCp7ImA9Wx5RGEQ.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-1534387326224257564</id><published>2010-08-27T00:59:00.000-07:00</published><updated>2010-08-27T01:11:21.530-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-08-27T01:11:21.530-07:00</app:edited><title>Parallel Attribute Grammars / Tree Stencil / Visitors</title><content type="html">Got my first parallelism results for the tree solving part of my work. When computing on a (task parallel) tree, if the tree is big or the the computations per node is large, parallelization is easy: just traverse and work steal (e.g, Intel's TBB or Cilk).  However, we often have small calculations, such as computing a (tree) sum. Furthermore, we also want to do many macroscopic (tree-wide) optimizations like changing its layout for better memory access patterns. I spent most of the summer doing macroscopic sequential optimizations for my tree language but now also have finally achieved parallel speedups for a minimal CSS-like layout language (vertical boxes, horizontal boxes, and colors). It is a *very* minimal language, meaning a lightweight computation (4 tree traversals, each less than 1ms), so speedups are non-trivial. However, by having very lightweight traversals, adding additional passes now has less of a sting (giving leeway to both the flexibility of CSS and the quality of our attribute grammar -&gt; tree stencil compiler).&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_4m57DDHVrBA/THdyeXTLr4I/AAAAAAAAAOk/-rIPdqy6nHQ/s1600/tuning.png"&gt;&lt;img style="display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 400px; height: 324px;" src="http://2.bp.blogspot.com/_4m57DDHVrBA/THdyeXTLr4I/AAAAAAAAAOk/-rIPdqy6nHQ/s400/tuning.png" alt="" id="BLOGGER_PHOTO_ID_5509998535087206274" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;4-pass grammar speedup (where one of the passes is followed by parallel  font handling code, but not counted). Overheads of creating and  destroying pthreads are not counted (later step will be to do standard pooling and warmup tricks).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-1534387326224257564?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/XPAKIC9sgcw" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/1534387326224257564/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=1534387326224257564" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/1534387326224257564?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/1534387326224257564?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/XPAKIC9sgcw/parallel-attribute-grammars-tree.html" title="Parallel Attribute Grammars / Tree Stencil / Visitors" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/_4m57DDHVrBA/THdyeXTLr4I/AAAAAAAAAOk/-rIPdqy6nHQ/s72-c/tuning.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/08/parallel-attribute-grammars-tree.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0AMQn49fCp7ImA9Wx5QF0s.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-3552097632843707337</id><published>2010-08-02T17:16:00.000-07:00</published><updated>2010-09-06T01:29:43.064-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-09-06T01:29:43.064-07:00</app:edited><title>An Undercited Paper</title><content type="html">Note: this is a rewrite of the original posting as the blogger interface confused me into thinking the edit an article button was just a comment button.&lt;br /&gt;&lt;br /&gt;"&lt;a href="http://scholar.google.com/scholar?q=related:KxGIRVSvzfIJ:scholar.google.com/&amp;amp;hl=en&amp;amp;as_sdt=2000"&gt;NESL&lt;/a&gt;": Seminal work on data parallelism that handles regular structures like matrices very well. However, super common structures like trees, graphs, etc. are supported only in hard-to-read encoding or overly restricted (e.g., fixed depth) legible ones. Front page of google scholar: ~600 citations.&lt;br /&gt;&lt;br /&gt;"&lt;a href="http://scholar.google.com/scholar?q=related:irJQxU3VngQJ:scholar.google.com/&amp;amp;hl=en&amp;amp;as_sdt=2000"&gt;Flattening Trees&lt;/a&gt;": shows that recursive types -- such as trees -- are no big deal to add at the interface level and that the flattening transformation can be modified to support them. ~22 citations and what seems like the real first step towards making flattening acceptable for general purpose languages. "&lt;a href="http://scholar.google.com/scholar?q=related:N7eVlRrxfBUJ:scholar.google.com/&amp;amp;hl=en&amp;amp;as_sdt=2000"&gt;More types for nested data parallel programming&lt;/a&gt;" finishes the job. (Nit: conflating nested data parallel with flattening is bad; these papers are really about the latter which is just *one* approach to the former).&lt;br /&gt;&lt;br /&gt;Bonus read: "&lt;a href="http://web.engr.oregonstate.edu/%7Eerwig/papers/abstracts.html#JFP01"&gt;Inductive Graphs and Functional Graph Algorithms&lt;/a&gt;" shows how to (sequentially) support graphs. It's interesting in that 1) graph specialization is restricted to an ADT that could be optimized external to the language  and 2) similarly, I suspect nested data parallelism can be reasonably achieved as library with it. At least for the near future, having the work be at the library level is a big deal: API changes are more forgiving.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-3552097632843707337?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/bAmNIFD9UxM" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/3552097632843707337/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=3552097632843707337" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/3552097632843707337?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/3552097632843707337?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/bAmNIFD9UxM/undercited-paper.html" title="An Undercited Paper" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>2</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/08/undercited-paper.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D0EESH49eip7ImA9WxFaFkw.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-9214452547345976238</id><published>2010-07-20T01:37:00.000-07:00</published><updated>2010-07-20T01:46:49.062-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-07-20T01:46:49.062-07:00</app:edited><title>Towards taming the web</title><content type="html">Happy to see &lt;a href="http://code.google.com/p/chromium/issues/detail?id=35897#c63"&gt;resource blocking&lt;/a&gt; got slashdotted. Still far away from our default-deny vision @ W2SP, let alone what Ben wrote about with mutation event transforms and followed up on in our Oakland paper, but having the spotlight there helps force the issue.&lt;br /&gt;&lt;br /&gt;Been in heads-down mode all summer experimenting on a new high-performance computing inspired language runtime; hopefully be able to say something interesting about that soon. Next few weeks should be fun: ~2 weeks in RI (+MA/NY?), a few days in the Maryland/DC area, a few more in Seattle+Redmond, and finally either Vancouver (CA) or Costa Rica. Assuming some experiments turn out well this week, that means I should have some downtime to hack on the language prediction stuff again!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-9214452547345976238?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/NQwI6UhczBE" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/9214452547345976238/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=9214452547345976238" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/9214452547345976238?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/9214452547345976238?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/NQwI6UhczBE/towards-taming-web.html" title="Towards taming the web" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/07/towards-taming-web.html</feedburner:origLink></entry><entry gd:etag="W/&quot;Ck4EQHs_eip7ImA9WxFUE0g.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-6061387417235636797</id><published>2010-06-23T18:31:00.001-07:00</published><updated>2010-06-23T20:41:41.542-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-06-23T20:41:41.542-07:00</app:edited><title>Insprirational paper</title><content type="html">Sometimes (often?), I feel like there's a doubling distance on inspirational papers: the more you read, the less you get surprised. I've been increasingly disappointed in PL papers: while this is often due to a topic I'm not personally interested in (e.g., shape analysis), it is more often due to an incremental area (symbolic execution, dependent types, etc.) where the leaps are for  practitioners in the field and don't open new doors or general perspectives for those not in the area.&lt;br /&gt;&lt;br /&gt;So... I was very happy to stumble upon '&lt;a href="cseweb.ucsd.edu/users/tullsen/hpca07.pdf"&gt;Accelerating and Adapting Precomputation Threads for Efficient Prefetching&lt;/a&gt;', which seems to be the current extent of a fascinating line of work.&lt;br /&gt;&lt;br /&gt;Most general software has rampant L1/L2 cache misses. For example, while profiling WebKit (Google Chrome, Safari), 10% of the instructions in layout missed the L1 and required an L2 fetch: such occurrences have a ~10x penalty, meaning about 50% of the time would be spent doing nothing but waiting for data to transfer from L2 to L1/registers. Similarly, despite a large L2 cache on the test machine, 0.2% instructions missed the L2 cache, meaning 15% of the time was spent getting that data. That's a problem: most of webpage layout time, therefore, is spent moving data around and not actually computing anything.&lt;br /&gt;&lt;br /&gt;Enter prefetching. It is a form of memory parallelism that mixes communication with computation: tell the computer to fetch data before you need it, so by the time you're ready to compute on it, it's there. Hardware prefetching does this automatically. When the computer is told to fetch one chunk of data, it'll also start grabbing ones that are next to it: so, if you're traversing an array linearly laid out in memory, when you finish with the first chunk and ask for the next, it'll already be there so you can start working on it immediately, and meanwhile the next chunk will be fetched for you, etc. Unfortunately, most general programs don't have regularly laid out data (e.g., they use trees instead of just arrays). One fix is software prefetching -- special commands to asynchronously load data at a specified  location -- but that's often hard to use. For example, if you're traversing a tree, you'll want to prefetch a few nodes ahead -- but you'll only know the direct children! Prefetching is often too much of a pain for serious consideration, especially once you factor in software engineering concerns like code legibility and robustness.&lt;br /&gt;&lt;br /&gt;This paper makes an interesting proposition: what if, on a concurrent hardware context, we simply start traversing the tree ahead of time, but don't do any actual work? Let's assume a fetch of a node takes the same time as the amount of work (arithmetic instructions etc.) on the node: &lt;br /&gt;&lt;br /&gt;Time 0: computer does nothing, prefetcher requests node A, worker does nothing &lt;br /&gt;Time 1: computer brings A, prefetcher requests node B, worker computes on A&lt;br /&gt;Time 2: computer brings B, prefetcher requests node C, worker computes on B&lt;br /&gt;...&lt;br /&gt;&lt;br /&gt;Unfortunately, there are a lot of little details like what to do if the prefetcher gets ahead of the worker -- the cache is only so big, so this might actually cause problems! Similarly, if there isn't much work per fetch, the prefetcher will get behind schedule: software prefetching, if possible, is still useful as it generally supports multiple prefetches around the same time. The described paper focuses on automatic dynamic optimizations on hot traces with a prefetcher on a SMT core: they use a framework that records code that runs, and when it realizes a bunch repeats but with different data, takes action. This is really good for sequential loops over regular structures, such as iterating over a list with two alternating types of nodes), where they perform compiler analyses to achieve software prefetching, and, as long as computation time &gt;= fetch time per datum, their worst case still eliminates fetch time.&lt;br /&gt;&lt;br /&gt;There's a lot more to do: the idea is general (touch what you need ahead of time in a general concurrent thread) but their actual algorithm is very specialized. Browsers are beyond their obvious worst case. First, the worst case: the data structure is an unpredictable tree with computation time close to fetch time, so their compiler optimizations won't really work and their prefetcher will likely get behind schedule. The less obvious and really concerning part is that they assume you have a free SMT hardware context (waiting for a prefetch blocks the SMT hardware context from other use): we can perform our traversal in parallel and thus, in their approach, forced to choose between task parallelism (parallel traversal) and memory parallelism (concurrent prefetching)! &lt;br /&gt;&lt;br /&gt;Like I wrote in the beginning: this paper is not just useful for a particular examined case but also inspirational. It opens doors. E.g., while I can't use their prefetching optimizations to keep the prefetcher from getting behind, I can likely use 'jump pointers' to point further ahead in a tree for a given node and then sleep, preventing blocking on the SMT thread. Similarly, task parallelism, typically using work-stealing, tries to use disjoint memory to prevent interference between tasks, but this suggests I might be better off interleaving traversals. &lt;br /&gt;&lt;br /&gt;Anyways, fun stuff.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-6061387417235636797?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/k5QlLueJZK4" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/6061387417235636797/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=6061387417235636797" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/6061387417235636797?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/6061387417235636797?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/k5QlLueJZK4/insprirational-paper.html" title="Insprirational paper" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/06/insprirational-paper.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkcER309cSp7ImA9WxFVFEQ.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-893762986634336778</id><published>2010-06-13T21:28:00.000-07:00</published><updated>2010-06-13T21:33:26.369-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-06-13T21:33:26.369-07:00</app:edited><title>valgrind, kcachegrind for os 10.6</title><content type="html">In case any mac devs haven't noticed:&lt;br /&gt;&lt;br /&gt;&lt;div class="code"&gt;&lt;br /&gt;#use valgrind once 10.6 support is in the main branch&lt;br /&gt;sudo port install valgrind-devel &lt;br /&gt;sudo port install kcachegrind&lt;br /&gt;sudo port install graphviz&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;The kcachegrind port seems a bit wonky -- I've had to run it with elevated privileges ('sudo kcachegrind &lt;myfile&gt;').&lt;br /&gt;&lt;br /&gt;Life just got better. Still waiting for a VTune etc. port for OS X;  multicore (esp. TBB) profiling is still too hard.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-893762986634336778?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/3Zl5TwrnBfU" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/893762986634336778/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=893762986634336778" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/893762986634336778?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/893762986634336778?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/3Zl5TwrnBfU/valgrind-kcachegrind-for-os-106.html" title="valgrind, kcachegrind for os 10.6" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/06/valgrind-kcachegrind-for-os-106.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DUQBQHY_fyp7ImA9WxFWEE8.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-250095088203090826</id><published>2010-05-27T22:47:00.000-07:00</published><updated>2010-05-27T23:15:51.847-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-05-27T23:15:51.847-07:00</app:edited><title>p(category | language)</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_4m57DDHVrBA/S_9fQKcSjiI/AAAAAAAAAOM/maj62wrulrY/s1600/time.png"&gt;&lt;br /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_4m57DDHVrBA/S_9antVe9PI/AAAAAAAAAOE/VTE0742Ev0Y/s1600/projsize.png"&gt;&lt;br /&gt;&lt;/a&gt;I've been data mining ~10 years of projects from sourceforge for awhile now to try to understand how languages spread and factors in people adopting them... It's been tricky, but I found the following charts pretty interesting:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_4m57DDHVrBA/S_9ZpJV4_oI/AAAAAAAAAN0/M7KvxUMzlbE/s1600/pcl.png"&gt;&lt;img style="display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 400px; height: 335px;" src="http://2.bp.blogspot.com/_4m57DDHVrBA/S_9ZpJV4_oI/AAAAAAAAAN0/M7KvxUMzlbE/s400/pcl.png" alt="" id="BLOGGER_PHOTO_ID_5476194235323055746" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;(probability of the category for a project given the language)&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_4m57DDHVrBA/S_9aPJQzYmI/AAAAAAAAAN8/u5vVKjPyIak/s1600/numdevs.png"&gt;&lt;img style="display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 400px; height: 171px;" src="http://1.bp.blogspot.com/_4m57DDHVrBA/S_9aPJQzYmI/AAAAAAAAAN8/u5vVKjPyIak/s400/numdevs.png" alt="" id="BLOGGER_PHOTO_ID_5476194888136745570" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;(1: given a project with N developers, likelihood of being in a particular language, 2: likelihood of a project having N developers in language L)&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_4m57DDHVrBA/S_9antVe9PI/AAAAAAAAAOE/VTE0742Ev0Y/s1600/projsize.png"&gt;&lt;img style="display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 400px; height: 349px;" src="http://2.bp.blogspot.com/_4m57DDHVrBA/S_9antVe9PI/AAAAAAAAAOE/VTE0742Ev0Y/s400/projsize.png" alt="" id="BLOGGER_PHOTO_ID_5476195310136915186" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div style="text-align: center;"&gt;(log number of developers with N projects)&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_4m57DDHVrBA/S_9fQKcSjiI/AAAAAAAAAOM/maj62wrulrY/s1600/time.png"&gt;&lt;img style="display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 400px; height: 150px;" src="http://4.bp.blogspot.com/_4m57DDHVrBA/S_9fQKcSjiI/AAAAAAAAAOM/maj62wrulrY/s400/time.png" alt="" id="BLOGGER_PHOTO_ID_5476200403191369250" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;(increasing use of a language for different tasks over 10 years -- 1: Java, 2: Python)&lt;br /&gt;&lt;br /&gt;&lt;div style="text-align: left;"&gt;Next step: correlating factors to explain this stuff.&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-250095088203090826?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/3vFPTNvgNT4" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/250095088203090826/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=250095088203090826" title="4 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/250095088203090826?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/250095088203090826?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/3vFPTNvgNT4/pcategory-language.html" title="p(category | language)" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/_4m57DDHVrBA/S_9ZpJV4_oI/AAAAAAAAAN0/M7KvxUMzlbE/s72-c/pcl.png" height="72" width="72" /><thr:total>4</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/05/pcategory-language.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkMFQX4yeCp7ImA9WxFXFE8.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-7215517705596662719</id><published>2010-05-20T22:04:00.000-07:00</published><updated>2010-05-20T22:40:10.090-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-05-20T22:40:10.090-07:00</app:edited><title>... and Oakland/W2SP are over</title><content type="html">Feel like I've been reading security papers long enough now that mind-blowing work is more rare. However, "Towards Static Flow-Based Declassification for Legacy and Untrusted Programs" felt like a good step forward and "Side-Channel Leaks in Web Applications: a Reality Today, a Challenge Tomorrow" seemed like it should have gotten some sort of award.  New to me were the handling malicious hardware design (e.g., backdoor) talks, for which I still don't understand the threat model. I liked the solutions, but, for example, I wasn't sure why some couldn't have been recast as static verification problems pre-fab  (at least one seemed well-suited for static verification instead of making new hardware to help check the hardware).&lt;br /&gt;&lt;br /&gt;Our ConScript talk went smoothly (never spoke to such a large audience before, pretty intimidating, especially when it's the finger-jabbing security crowd!). Not much to report there -- some press, some emails after, and some people describing the talk to me later but not realizing I was the one who gave it ;-)&lt;br /&gt;&lt;br /&gt;Today was W2SP and probably my favorite part of the whole thing. Gustav Rydstedt gave a  hilarious (but scary) account of framebusting: not enough people do it and those that attempt it do it wrong. I didn't entirely buy the solution (e.g., it depends upon CSS-conformant browsers, which is questionable in mobile), but, then again, I'm a first principles guy, and that doesn't really work on the deployed web, while Gustav's solution does the important thing of taking care of most desktop users. Steve Hanna gave a cool account of attacks on postMessage usage (not sure I'm ready to call JS stored in a DB a problem, which accounted for the 2nd half of his talk). I wish his talk was a little longer because in his paper he started to talk about the principles behind his API fix suggestions. Brendan Meeder's talk was also interesting, particularly in how it exposed the basic problem that we don't know how important privacy attacks against basic social interactions despite them being fairly pervasive. Probably annoying for Brendan's otherwise intersting talk, this came up through tearing apart his evaluation criteria, but I don't think people appreciate the difficulty of this step.&lt;br /&gt;&lt;br /&gt;Perhaps the most interesting talk was the keynote where Jermiah Grossman  essentially provided empirical evidence that the web security model is  broken on a mass scale. On the plus side, this means that all the  automatic web bug finding guys should have great results for the next  few years.&lt;br /&gt;&lt;br /&gt;Our talk seemed to be amiably received. It and a CSP-like plea were the only concrete let's-do-it-right-from-the-bottom proposals and Terri Oda had something pretty in sync with Adobe's approach to languages (don't assume the developer is a coder). Unfortunately, modulo the above exceptions and a few others, I felt the overall week was woefully short on correct-by-constructions solutions and instead focused on band aids (though this is understandable for a security as opposed to SE or languages conference). This wasn't lost on others either -- the discussion at the end of W2SP essentially asked the same thing, should we have more of a focus on finding the 'right' solution or keep on keeping on?&lt;br /&gt;&lt;br /&gt;Still piled under for the next ~5 days. Have a backlog of fascinating emails I still can't get to replying to and some code that I still don't have time to write :( May, you're such a strange beast.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-7215517705596662719?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/F2xOCwUyqLE" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/7215517705596662719/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=7215517705596662719" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/7215517705596662719?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/7215517705596662719?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/F2xOCwUyqLE/and-oaklandw2sp-are-over.html" title="... and Oakland/W2SP are over" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/05/and-oaklandw2sp-are-over.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DU4GQ3gyeCp7ImA9WxFXEE8.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-2693601747593893170</id><published>2010-05-16T08:41:00.000-07:00</published><updated>2010-05-16T09:38:42.690-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-05-16T09:38:42.690-07:00</app:edited><title>Great OSQ</title><content type="html">Back from OSQ (Santa Cruz is a Good Thing) so now crunching on a term project, Oakland/W2SP talks, the parlab demo, and finding a place to live. Odd how not sleeping outside is fairly low on the list of priorities.&lt;br /&gt;&lt;br /&gt;Perhaps the most interesting talks were Neil's and Peter's on the BOOM project where they've been experimenting with modal extensions to Datalog (time and/or location) as means to compiling declarative programs into distributed ones. A big motivation has been their work on declarative networking, applied to tasks like synthesizing CHORD, and their current work seems to be in a similar vein -- they can synthesize and potentially verify tricky protocols.  It'll be interesting to see how this transitions from framework/protocol building to their goal of general application building.  Another project briefly presented was Thorn (OOPSLA09, POPL2010) which takes a similar scripting position but trades in the declarative core for actors and gradual typing -- I've been more on this side for awhile (dealing with stratification etc. at a low-level is  odd), but as observed in BOOM, I think we need a bit more abstraction help in handling modality. An interesting example of such an extension is Swarm's ability to move a thread of control to a particular location (e.g., the data's).&lt;br /&gt;&lt;br /&gt;Much of the rest of the retreat was the usual symbolic execution for concurrency and security checking stuff (where are the correct-by-design people??). It was interesting to see Prateek et al take what Raluca and I had been hacking on a couple of years ago and take it to the next level, they seem to be getting a lot of traction! They were hit by the same event explosion problem so might be worth integrating our solution in, and the problem I've been most worried about -- server interactions -- still seems to be open. Prateek avoided it by scaling down the problem (client interactions) and assuming cooperation with the server (known login, stateless server or known reset, ...).&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;There was a lot of grumbling about impact and fundamental process from the verification crowd so I gave a short talk on sociology. It was about using insights from 'diffusion of innovation'  studies to examine the social process of applying verification (my particular interest is in doing this for PLs, but that's for another day). Unfortunately, it was partially misunderstood by some: making our research tools popularly used is nice, but not what I was advocating, and I even agree with the seemingly contrarian position that research adoption shouldn't be an academic's focus. However, the sociology community has essentially given us criteria for what it means to be a socially acceptable innovation: I'm not advocating focusing research effort on &lt;span style="font-style: italic;"&gt;deployment&lt;/span&gt; but &lt;span style="font-style: italic;"&gt;deployability&lt;/span&gt;. What is an appropriate verification process? We might be making bad assumptions about what people can and cannot do and thus not only running the verification race one-legged but potentially may even be in the wrong race.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-2693601747593893170?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/XwKItzie6zM" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/2693601747593893170/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=2693601747593893170" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/2693601747593893170?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/2693601747593893170?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/XwKItzie6zM/great-osq.html" title="Great OSQ" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>2</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/05/great-osq.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DEcMR388fyp7ImA9WxFRGEw.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-5709920376737229453</id><published>2010-05-01T23:53:00.000-07:00</published><updated>2010-05-02T09:01:26.177-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-05-02T09:01:26.177-07:00</app:edited><title>Back from WWW and the significance of social network research</title><content type="html">Came back from my first WWW conference. Given its broad scope, I wasn't  sure of what to expect. Below are some notes on the good, the bad, and a  bit of an insight I've had about all the social network research going  on.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;First, the good&lt;/span&gt;. As a  researcher, often better than seeing a new solution is a new problem.&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Gregory Conti talked about "Malicious Interface Design: Exploiting  the User" -- how advertisers and complicit content providers work  against users. Is there a social, economic, or technical defense against  marketing? I don't even know where to begin, but at least awareness is &lt;a href="http://www.eff.org/deeplinks/2010/04/facebooks-evil-interfaces"&gt;rising&lt;/a&gt;.&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt;&lt;li&gt;Azarias Reda presented his work on "Distributing Private Data in  Challenged Network Environments". Privacy seemed to be more about emphasizing the problem -- his talk was really about deploying an  SMS-based interface for prefetching in (African) internet kiosks that  have very limited bandwidth and thus can't handle synchronous (same browsing session) content requests.&lt;br /&gt;&lt;br /&gt;I've been talking to people about poor connectivity for a couple of years now (... my housemate actively works in asynchronous long-range wireless etc.). My  basic thought is that it's a multi-tiered problem. E.g., the poor bandwidth kiosk model doesn't  seem architecturally challenged for most content: aggressive caching should eliminate most transfer (and  most common threat models), and new data isn't that heavy. A bigger  issue is how to do so given developers don't really follow pedagogy (don't separate or label cacheable content) and,  in many regions, there is no or only occasional connectivity (think  cell phones). I'd love to work on making an asynchronous and  occasionally connected web -- imagine having a village-local cache of the entire web that  gets updated whenever somebody drives through the town yet still  supports AJAX through optimistic/predicative interfaces. So little time :(&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Second, the bad&lt;/span&gt;. Given the shift  to the web from desktops for modern applications, WWW is a sensible  focal point for  research in browser and web app software. Browser security was fairly  well represented and of good quality (... and I generally found these talks to be the more rigorous ones in their sessions) -- WWW seems to be a strong home for them. Given  the optimization challenges in browsers and the ubiquity of  mobile but  slow hardware, I wish there was a bigger emphasis on performance issues (Zhu Bin  gave a good talk about incremental/cached computation across pages, was good to  see someone do it -- looking forward to reading about the details). Finally,  language and framework driven approaches were barely on the radar:  OOPSLA, ICSE, CHI, OSDI etc. seem to suck in much of the talent in this  space.&lt;br /&gt;&lt;br /&gt;Overall, while search, semantic web and now social nets  seem to be  strong points for WWW,  basic client &amp;amp; application systems are on a slippery  slope. Security seems to be teetering on -- NDSS is becoming more  webby, so it'll be interesting to see how that plays out for the non-Oakland/CCS/Usenix papers. There were a  few points when there just weren't any technical papers about improving  general web apps, whether in the application, protocol, or browser  layer, which was surprising and should be easy to fix. There's also a new Usenix Web Apps conference.. becoming less and less clear what the appropriate venues are.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Finally, what's the deal with social  network research?&lt;/span&gt; One data mining researcher I talked to simply  dubbed it the next trendy thing (the previous being search). I disagree.  At face value, I'm not particularly interested in extracting particular  facts from the Facebook or Flickr social graph. That is almost just  recasting the idea of "WebDB".&lt;br /&gt;&lt;br /&gt;An insight comes from the reason we're seeing a lot of incremental papers, namely, that social  network data is available (we can redub most of the research as "social  network research of online communities"). I've been reading "Diffusion of Innovation", a  high-level book surveying research in field named in the title, and its historical descriptions make the significance of this proliferation clear. The studies outlined in the book were hard to do as  they required researchers to do arduous tasks like interview hundreds of  farmers about they did or did not adopt some new strain of miracle  crop, find out their circle of acquaintances, and only then begin  statistical analysis.  Now, you can just download it all. For example,   my spider just finished downloading records about 250,000 users and  their interactions on some website over a span of 10 years -- for a  course project!  The iterative scientific process has just been accelerated in a big way.&lt;br /&gt;&lt;br /&gt;The point is that I think the field of sociology itself is undergoing a  revolution. The 20th century provided a mathematical foundation  (information theory, bayesian statistics, etc.) and the 21st century is  bringing the data. It's already obvious with cognitive science -- the  availability of statistical models and now data samples means 'soft'  science is becoming a misnomer.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-5709920376737229453?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/3PpNTB4jvhc" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/5709920376737229453/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=5709920376737229453" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/5709920376737229453?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/5709920376737229453?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/3PpNTB4jvhc/back-from-www-and-significance-of.html" title="Back from WWW and the significance of social network research" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/05/back-from-www-and-significance-of.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0IAQHozeyp7ImA9WxFRE0g.&quot;"><id>tag:blogger.com,1999:blog-1440405560330732771.post-2743764690925089711</id><published>2010-04-26T23:50:00.000-07:00</published><updated>2010-04-26T23:59:01.483-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-04-26T23:59:01.483-07:00</app:edited><title>Off to North Carolina (WWW2010) and Boston/Providence</title><content type="html">Ras and I mostly ironed out our talk on mechanizing and parallelizing/optimizing CSS engines for browsers and our other talk on secure mashup abstractions and mechanisms is settling. Not sure who else will be at WWW2010, but worst-case scenario I foresee excessive sweet tea, historical linguistics analysis, and layout engine hacking as a reprieve from all this powerpoint and latex nonsense.&lt;br /&gt;&lt;br /&gt;No significantly cool new results lately due to all this slide making. Working with Adam, who we're doing automatic incrementalization of CSS with, I realized that I can encode tables and floats in a fairly restricted attribute grammar language, so that was quite a relief. Quals proposal, here I come!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1440405560330732771-2743764690925089711?l=lmeyerov.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/lmeyerov/~4/sQLAgHIygOA" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://lmeyerov.blogspot.com/feeds/2743764690925089711/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1440405560330732771&amp;postID=2743764690925089711" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/2743764690925089711?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1440405560330732771/posts/default/2743764690925089711?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/lmeyerov/~3/sQLAgHIygOA/off-to-north-carolina-www2010-and.html" title="Off to North Carolina (WWW2010) and Boston/Providence" /><author><name>Leo Meyerovich</name><uri>http://www.blogger.com/profile/05895714526572076172</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://lmeyerov.blogspot.com/2010/04/off-to-north-carolina-www2010-and.html</feedburner:origLink></entry></feed>

