<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Bug Blogger &#187; Architecture</title>
	<atom:link href="http://bugblogger.com/category/architecture/feed/" rel="self" type="application/rss+xml" />
	<link>http://bugblogger.com</link>
	<description>The Bug Labs blog</description>
	<lastBuildDate>Wed, 14 Jul 2010 03:54:08 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Java VMs Compared</title>
		<link>http://bugblogger.com/java-vms-compared-160/</link>
		<comments>http://bugblogger.com/java-vms-compared-160/#comments</comments>
		<pubDate>Tue, 29 Jul 2008 18:32:56 +0000</pubDate>
		<dc:creator>Kevin Schultz</dc:creator>
				<category><![CDATA[Architecture]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Java Poky]]></category>

		<guid isPermaLink="false">http://bugblogger.com/?p=160</guid>
		<description><![CDATA[Ken announced earlier this week that the next software release for the BUG includes some big changes. Many will be immediately visible to the user, but some of the biggest changes are coming under the hood. The new system is significantly more flexible allowing us to change the packages in our Linux distribution easily.
Our current [...]]]></description>
			<content:encoded><![CDATA[<p>Ken announced earlier this week that the next software release for the BUG includes <a title="BUG Adopts Poky Linux" href="http://bugblogger.com/bug-adopts-poky-linux-155/">some big changes</a>. Many will be immediately visible to the user, but some of the biggest changes are coming under the hood. The new system is significantly more flexible allowing us to change the packages in our <a href="http://www.pokylinux.org/">Linux distribution</a> easily.</p>
<p>Our current stack is based on <a href="https://phoneme.dev.java.net/content/phoneme_advanced_r2.html">phoneME</a><a href="https://phoneme.dev.java.net/content/phoneme_advanced_r2.html"> Advanced</a>, a configuration not available in <a href="http://wiki.openembedded.net/index.php/Main_Page">Open Embedded</a>. That forced us to look at other options as we started working with Poky. The original prototype of the BUG used <a href="http://bugblogger.com/gpl-sun-java-try-before-you-buy-64/">JamVM and and GNU Classpath</a>, but we have been using phoneME for quite a while. Now was a perfect opportunity to look at other VMs. The obvious alternative is JamVM, but we also tested the <a href="http://www.cacaovm.org/">Cacao</a> virtual machine due to its support by the <a href="https://wiki.evolvis.org/jalimo/index.php/Main_Page">Jalimo</a> and <a href="http://wiki.openmoko.org/wiki/Java">OpenMoko</a> projects.</p>
<p>It seems not many people have been comparing VMs on ARM recently so some benchmarks were in order. We based our tests on <a href="http://klomp.org/mark/free-vm-benchmarks/">this article on benchmarking</a>. Our three benchmarks were <a href="http://math.nist.gov/scimark2/">Scimark2</a>, <a href="http://www.netlib.org/benchmark/linpackjava/">Linpack</a>, and startup time comparison.</p>
<p style="0in;">First up was Scimark2, the most comprehensive of the benchmarks. The suite runs various algorithms and reports these scores in <a href="http://en.wikipedia.org/wiki/FLOPS">mega-flops per second</a>. It also makes a composite score of these tests. JamVM is the clear winner. While Cacao has solid performance on the Monte Carlo prime number finding algorithm, it falls behind in all of the rest of the tests. PhoneME seems to be about 10-20% slower than JamVM in most tests.</p>
<p style="0in;"><a href="http://bugblogger.com/wp-content/uploads/2008/07/scimark2.jpeg"><img class="alignnone size-full wp-image-174" src="http://bugblogger.com/wp-content/uploads/2008/07/scimark2.jpeg" alt="" width="500" height="332" /></a></p>
<p style="0in;">
<p><a href="http://bugblogger.com/wp-content/uploads/2008/07/scimark.jpeg"> </a></p>
<p style="justify;">Next up was the Linpack benchmark. The first graph is a measure of the speed of the processor in mega flops per second. The second graph is the overall time for running the benchmark so lower is better. Again here we see the same order as the Scimark2 tests. JamVM runs on top for both tests followed by phoneME and Cacao.</p>
<p style="center;"><a href="http://bugblogger.com/wp-content/uploads/2008/07/linpack1.jpeg"> </a></p>
<p style="0in;">
<p><a href="http://bugblogger.com/wp-content/uploads/2008/07/linpack1.jpeg"><img class="alignnone size-full wp-image-172" src="http://bugblogger.com/wp-content/uploads/2008/07/linpack1.jpeg" alt="" width="364" height="291" /></a></p>
<p style="0in;"><a href="http://bugblogger.com/wp-content/uploads/2008/07/linpack2.jpeg"><img class="alignnone size-full wp-image-173" src="http://bugblogger.com/wp-content/uploads/2008/07/linpack2.jpeg" alt="" width="364" height="291" /></a></p>
<p><a href="http://bugblogger.com/wp-content/uploads/2008/07/linpack1.jpeg"> </a></p>
<p style="center;"><a href="http://bugblogger.com/wp-content/uploads/2008/07/linpack2.jpeg"><br />
</a></p>
<p style="center;"><a href="http://bugblogger.com/wp-content/uploads/2008/07/linpack2.jpeg"> </a></p>
<p style="center;">
<p style="justify;">Finally, our startup time test. Starting up the OSGi stack currently takes a few seconds, so startup time of the VM has a significant impact on the overall boot time. For this benchmark we started up the Concierge OSGi framework &#8211; though it did not load any bundles since we had not ported all of them to the new build system at the time.</p>
<p style="center;"><a href="http://bugblogger.com/wp-content/uploads/2008/07/startup.jpeg"><img class="alignnone size-full wp-image-175" src="http://bugblogger.com/wp-content/uploads/2008/07/startup.jpeg" alt="" width="364" height="291" /></a></p>
<p style="justify;">Here JamVM performed as expected with an impressive startup time. Note that this is not a constant time, these gains will increase with a larger load. When starting up our full OSGi stack you will probably gain a few seconds with JamVM.</p>
<p style="justify;">
<p style="justify;">All of this makes it look like the best choice is JamVM, but there are a lot of variables that are swept under the rug above. Most importantly, a 20% difference on a synthetic benchmark does not indicate a 20% improvement in end user experience.</p>
<p style="justify;">Second, there are some differences in the configurations. We ran these tests using GNU Classpath on JamVM and Cacao. Keep in mind that GNU Classpath is J2SE-like in size, while phoneME Advanced is significantly lighter. This will make a big difference on a benchmark that measures full system performance. These benchmarks are designed for CPU throughput so the additional overhead of Classpath does not show up. However, both Cacao and JamVM <em>can</em> run with phoneME rather than Classpath, it is just not the default behavior in OpenEmbedded.</p>
<p style="justify;">Perhaps the biggest red herring stems from us not building phoneME with JIT right now. This is due to a problem with older versions of the Linux kernel. With the new build system we will build phoneME with JIT which will gain significant performance. These benchmarks are comparing the current build of phoneME to the Cacao and JamVM default setups in OpenEmbedded, we are not comparing the maximum performance that can be squeezed out of each VM.</p>
<p style="justify;">Finally, on Thursday Matthias Klose was able to get <a href="http://gbenson.net/?p=88">OpenJDK built for ARM</a>. We will have to take a look at its performance as soon as we have it running on the BUG.</p>
<p style="justify;">We still are very excited to see the community based VMs performing so well. While there are more factors to consider when choosing a JVM implementation (such as TCK validation, branding concerns, and community support) JamVM definitely warrants a look for anyone interested in embedded Java development on ARM based systems, it certainly impressed us. Look here for a follow up post sometime in the coming months.</p>
<p style="justify;">
<p style="0in;">
]]></content:encoded>
			<wfw:commentRss>http://bugblogger.com/java-vms-compared-160/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>Object Sentences</title>
		<link>http://bugblogger.com/object-sentences-7/</link>
		<comments>http://bugblogger.com/object-sentences-7/#comments</comments>
		<pubDate>Mon, 12 Feb 2007 19:17:46 +0000</pubDate>
		<dc:creator>Peter Semmelhack</dc:creator>
				<category><![CDATA[Architecture]]></category>
		<category><![CDATA[Concepts]]></category>

		<guid isPermaLink="false">http://bugblogger.com/?p=7</guid>
		<description><![CDATA[
]]></description>
			<content:encoded><![CDATA[<p>I love language and have always been fascinated by its mechanics &#8211; how<br />
the assembly of words in a sequence can either convey meaning or sow<br />
confusion. Given my interest in the value of splitting structure<br />
(grammar/syntax) and content (words), language has been a potent<br />
catalyst. When I was younger, one of the questions I turned over in my<br />
head all the time was &#8211; why can&#8217;t there be a language in which it was<br />
impossible to speak nonsense &#8211; meaning a language where ANY combination<br />
of words made sense somehow. It&#8217;s a wacky question but points, I think,<br />
to an important strength of every successful language &#8211; it&#8217;s incredible<br />
flexibility. Without the ability to write nonsense, nothing new could<br />
be done. Our idea of nonsense is subjective. The poetry of e.e.<br />
cummings would have likely been viewed as complete garbage 200 years<br />
ago. Or how about a computer program?? But the other thing that<br />
fascinates (inspires) me is that even though the interface between<br />
words is formally defined as grammar, it is also totally open, meaning<br />
those rules are really only a guide. Poetry routinely flouts the rules<br />
to great effect. If I know the words of more than one language the<br />
options for sentence construction increase, as long as the reader<br />
understands the languages used and doesn&#8217;t mind dealing with no formal<br />
grammatical structure. Words, like atoms, seem capable of infinite<br />
types of combinations, but gain particular value when used with a<br />
logical grammar (e.g. Shakespeare or Hemingway). All of the above, by<br />
the way, is equally true of music.</p>
<p>Lately I have<br />
been puzzling over creating what in essence is a grammar for the<br />
construction of not word sentences but &quot;object sentences&quot;. Is there a<br />
formal way to define how objects should/could go together to create a<br />
useful thing or &quot;sentence&quot;? Sounds crazy because maybe it is. But<br />
consider electronics, which for the purposes of this argument I will<br />
equate to a language &#8211; meaning it is contained and its moving pieces<br />
defined. At a very high level every device, gadget and gizmo is<br />
identical &#8211; power supply, processor(s), i/o devices. Mix them up in<br />
lots of different ways and you get everything from a digital watch, to<br />
an iPod, to an IBM mainframe; like the words of a sentence. Take vehicles of any kind &#8211; the same high level analysis produces the<br />
same result &#8211; all vehicles are identical. So what? My point is that, at<br />
least in some cases, there is a starting baseline of components (words)<br />
for the construction of certain categories of product. If you could<br />
elegantly define the interfaces between these basic categories perhaps<br />
you could start to generalize and identify an interface &quot;grammar&quot;, at<br />
least for that &quot;language&quot;. Would love to see that someday.</p>
]]></content:encoded>
			<wfw:commentRss>http://bugblogger.com/object-sentences-7/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
