<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/css" href="http://wiki.apidesign.org/skins/common/feed.css?116"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://wiki.apidesign.org/index.php?action=history&amp;feed=atom&amp;title=CacheForModularity</id>
		<title>CacheForModularity - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://wiki.apidesign.org/index.php?action=history&amp;feed=atom&amp;title=CacheForModularity"/>
		<link rel="alternate" type="text/html" href="http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;action=history"/>
		<updated>2026-04-11T06:36:18Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.12.0rc1</generator>

	<entry>
		<id>http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=4920&amp;oldid=prev</id>
		<title>JaroslavTulach: /* General Solution */</title>
		<link rel="alternate" type="text/html" href="http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=4920&amp;oldid=prev"/>
				<updated>2011-06-13T08:57:33Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;General Solution&lt;/span&gt;&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 08:57, 13 June 2011&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 101:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 101:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;=== General Solution ===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;=== General Solution ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;The [[CacheForModularity]] has been backported to [[OSGi]] to form the fastest (in terms of [[startup]] time) container on &lt;del style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;a &lt;/del&gt;planet - [[Netbinox]].&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;The [[CacheForModularity]] has been backported to [[OSGi]] to form the fastest (in terms of [[startup]] time) container on &lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;the &lt;/ins&gt;planet - [[Netbinox]].&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;I believe any [[module system]] could benefit from the same infrastructure, if there was a &lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;I believe any [[module system]] could benefit from the same infrastructure, if there was a &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>JaroslavTulach</name></author>	</entry>

	<entry>
		<id>http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=4919&amp;oldid=prev</id>
		<title>JaroslavTulach: /* General Solution */</title>
		<link rel="alternate" type="text/html" href="http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=4919&amp;oldid=prev"/>
				<updated>2011-06-13T08:56:57Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;General Solution&lt;/span&gt;&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 08:56, 13 June 2011&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 100:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 100:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;=== General Solution ===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;=== General Solution ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;The [[CacheForModularity]] has been backported to [[OSGi]] to form the fastest (in terms of [[startup]] time) container on a planet - [[Netbinox]].&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;I believe any [[module system]] could benefit from the same infrastructure, if there was a &lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;I believe any [[module system]] could benefit from the same infrastructure, if there was a &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>JaroslavTulach</name></author>	</entry>

	<entry>
		<id>http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=2649&amp;oldid=prev</id>
		<title>JaroslavTulach at 01:36, 15 July 2009</title>
		<link rel="alternate" type="text/html" href="http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=2649&amp;oldid=prev"/>
				<updated>2009-07-15T01:36:57Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 01:36, 15 July 2009&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 91:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 91:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;bad optimization.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;bad optimization.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;Please note that if you start NetBeans for the second time without cleaning &lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;Please note that if you start &lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;[[&lt;/ins&gt;NetBeans&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;]] &lt;/ins&gt;for the second time without cleaning &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;the filesystem caches, the start time is something like:&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;the filesystem caches, the start time is something like:&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;text&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;text&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 99:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 99:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;cold start matters.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;cold start matters.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;=== General Solution ===&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;I believe any [[module system]] could benefit from the same infrastructure, if there was a &lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;I believe any [[module system]] could benefit from the same infrastructure, if there was a &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>JaroslavTulach</name></author>	</entry>

	<entry>
		<id>http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=2648&amp;oldid=prev</id>
		<title>JaroslavTulach: /* Speed Up */</title>
		<link rel="alternate" type="text/html" href="http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=2648&amp;oldid=prev"/>
				<updated>2009-07-14T14:37:24Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Speed Up&lt;/span&gt;&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 14:37, 14 July 2009&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 33:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 33:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;This includes various improvements but one of the most significant is &lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;This includes various improvements but one of the most significant is &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;the '''resources cache''' - we are able to start [[NetBeans]] without opening or even &lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;the '''resources cache''' - we are able to start [[NetBeans]] without opening or even &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;touching (m)any [[JAR]] files.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;touching (m)any [[JAR]] files&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;. Btw. there is a lot of them, [[NetBeans]] 6.7 contains 600 to 1000 of [[JAR]]s&lt;/ins&gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;=== Trust but Verify ===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;=== Trust but Verify ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>JaroslavTulach</name></author>	</entry>

	<entry>
		<id>http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=2647&amp;oldid=prev</id>
		<title>JaroslavTulach at 14:36, 14 July 2009</title>
		<link rel="alternate" type="text/html" href="http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=2647&amp;oldid=prev"/>
				<updated>2009-07-14T14:36:27Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 14:36, 14 July 2009&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;Let me share with you few notes about our [[NetBeans]] experience with [[modularity]] and how it affects and relates to [[performance]]. As noted in [[Modular_Java_SE#False_Expectations|one paragraph]] written while [[Modular_Java_SE|modularizing the Java SE]], if one seeks faster execution, then more [[modularity]] is usually more harmful than helpful. Except one creates [[cache]]s. [[Cache]]s for modular execution.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;Let me share with you few notes about our [[NetBeans]] experience with [[modularity]] and how it affects and relates to [[performance]]. As noted in [[Modular_Java_SE#False_Expectations|one paragraph]] written while [[Modular_Java_SE|modularizing the Java SE]], if one seeks faster execution, then more [[modularity]] is usually more harmful than helpful. Except &lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;until &lt;/ins&gt;one creates [[cache]]s. [[Cache]]s for modular execution.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;=== Speed Up ===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;=== Speed Up ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>JaroslavTulach</name></author>	</entry>

	<entry>
		<id>http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=2644&amp;oldid=prev</id>
		<title>JaroslavTulach: New page: Let me share with you few notes about our NetBeans experience with modularity and how it affects and relates to performance. As noted in [[Modular_Java_SE#False_Expectations|on...</title>
		<link rel="alternate" type="text/html" href="http://wiki.apidesign.org/index.php?title=CacheForModularity&amp;diff=2644&amp;oldid=prev"/>
				<updated>2009-07-14T14:29:54Z</updated>
		
		<summary type="html">&lt;p&gt;New page: Let me share with you few notes about our &lt;a href=&quot;/wiki/NetBeans&quot; title=&quot;NetBeans&quot;&gt;NetBeans&lt;/a&gt; experience with &lt;a href=&quot;/wiki/Modularity&quot; title=&quot;Modularity&quot;&gt;modularity&lt;/a&gt; and how it affects and relates to &lt;a href=&quot;/wiki/Performance&quot; class=&quot;mw-redirect&quot; title=&quot;Performance&quot;&gt;performance&lt;/a&gt;. As noted in [[Modular_Java_SE#False_Expectations|on...&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Let me share with you few notes about our [[NetBeans]] experience with [[modularity]] and how it affects and relates to [[performance]]. As noted in [[Modular_Java_SE#False_Expectations|one paragraph]] written while [[Modular_Java_SE|modularizing the Java SE]], if one seeks faster execution, then more [[modularity]] is usually more harmful than helpful. Except one creates [[cache]]s. [[Cache]]s for modular execution.&lt;br /&gt;
&lt;br /&gt;
=== Speed Up ===&lt;br /&gt;
&lt;br /&gt;
The [[NetBeans]] IDE improved its cold start by 30% from '''33s''' in version 6.0 to '''19s''' &lt;br /&gt;
in version 6.7:&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|+ '''NetBeans IDE Speedup'''&lt;br /&gt;
! style=&amp;quot;width:100&amp;quot; | Release&lt;br /&gt;
! style=&amp;quot;width:100&amp;quot; | Start w/o Project &lt;br /&gt;
! style=&amp;quot;width:100&amp;quot; | Start w/ Project&lt;br /&gt;
|-&lt;br /&gt;
! 6.0  &lt;br /&gt;
! 33s&lt;br /&gt;
! 54s&lt;br /&gt;
|-&lt;br /&gt;
! 6.1  &lt;br /&gt;
! 22s&lt;br /&gt;
! 26s&lt;br /&gt;
|-&lt;br /&gt;
! 6.5  &lt;br /&gt;
! 20s&lt;br /&gt;
! 26s&lt;br /&gt;
|-&lt;br /&gt;
! 6.7  &lt;br /&gt;
! 19s&lt;br /&gt;
! 23s&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This includes various improvements but one of the most significant is &lt;br /&gt;
the '''resources cache''' - we are able to start [[NetBeans]] without opening or even &lt;br /&gt;
touching (m)any [[JAR]] files.&lt;br /&gt;
&lt;br /&gt;
=== Trust but Verify ===&lt;br /&gt;
&lt;br /&gt;
To see it on your own. Get [[NetBeans]] 6.7 full distribution, unzip and remove &lt;br /&gt;
ergonomics1 directory (to prevent other optimizations). &lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
# get NetBeans from http://www.netbeans.org/downloads/zip.html&lt;br /&gt;
$ unzip netbeans-6.7-*.zip&lt;br /&gt;
$ rm -r netbeans/ergonomics1&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
start (once is enough, few times is not going to hurt anyone) it so it creates &lt;br /&gt;
its caches:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
$ netbeans/bin/netbeans --userdir tmp/userdir.fake&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
now clean OS filesystem caches or just reboot to clean them. I use &lt;br /&gt;
&amp;lt;source lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
$ echo 3 &amp;gt; /proc/sys/vm/drop_caches&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
on my Linux to clear them.&lt;br /&gt;
&lt;br /&gt;
Start again, with logging enabled:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
$ netbeans/bin/netbeans --userdir tmp/userdir.fake -J-Dorg.netbeans.log.startup=print -J-Dnetbeans.logger.console=true&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
It prints a lot of things, but the important point is when main window is &lt;br /&gt;
shown:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;text&amp;quot;&amp;gt;&lt;br /&gt;
@40522 - Window system loaded&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now remove the NetBeans classes cache:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
$ rm tmp/userdir.fake/var/cache/all-resources.dat&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
Drop the OS filesystem caches and start once again:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
$ netbeans/bin/netbeans --userdir &lt;br /&gt;
tmp/userdir.fake -J-Dorg.netbeans.log.startup=print -J-Dnetbeans.logger.console=true&lt;br /&gt;
&lt;br /&gt;
@62673 - Window system loaded&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
I have guided you though all this exercise to show that the single trick of &lt;br /&gt;
not touching (m)any files on disk (you can verify with strace .. 2&amp;gt;&amp;amp;1 | grep &lt;br /&gt;
open for example) can greatly speed up time to start of (desktop) modular &lt;br /&gt;
application. &lt;br /&gt;
&lt;br /&gt;
More than '''30%''' of time gained just by storing the classes needed during start &lt;br /&gt;
in a single file and not touching hundreds of small module files, is not that &lt;br /&gt;
bad optimization.&lt;br /&gt;
&lt;br /&gt;
Please note that if you start NetBeans for the second time without cleaning &lt;br /&gt;
the filesystem caches, the start time is something like:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;text&amp;quot;&amp;gt;&lt;br /&gt;
@4192 - Window system shown&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
so compared to those horrible 62s, this is nothing to worry about. Only the &lt;br /&gt;
cold start matters.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
I believe any [[module system]] could benefit from the same infrastructure, if there was a &lt;br /&gt;
all-resources.dat cache for every started (desktop) application. I really &lt;br /&gt;
mean application, I don't mean [[module]] or [[JAR]]. The important point is to not &lt;br /&gt;
touch any files at all, except the all-resources.dat. &lt;br /&gt;
&lt;br /&gt;
In case of owning [[HotSpot]], this could be combined &lt;br /&gt;
with caching not .class files, but their internal [[HotSpot]] representation. Then the result might get even better.&lt;br /&gt;
&lt;br /&gt;
=== Technical Details ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here are links to [http://wiki.netbeans.org/StartupCache details of our implementation]:&lt;br /&gt;
* [http://hg.netbeans.org/main-golden/file/ae0c39ea7b80/o.n.bootstrap/src/org/netbeans/Archive.java Archive.java]&lt;br /&gt;
* [http://hg.netbeans.org/main-golden/file/ae0c39ea7b80/o.n.bootstrap/src/org/netbeans/JarClassLoader.java JarClassLoader.java]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;comments/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:APIDesignPatterns:Performance]]&lt;/div&gt;</summary>
		<author><name>JaroslavTulach</name></author>	</entry>

	</feed>