<?xml version="1.0" encoding="UTF-8"?>
<!-- Generated on Sat, 26 May 2012 05:35:35 -0700 -->
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <atom:link href="http://software.intel.com/en-us/articles/whatif/type/code/feed/" rel="self" type="application/rss+xml" />
    <title>Intel Software Network articles Feed</title>
    <link>http://software.intel.com/en-us/articles/whatif/type/code/</link>
    <description></description>
    <language>en-us</language>
    <item>
      <title>Ultrabook™ and the Intel® Energy Checker SDK</title>
      <description><![CDATA[ <h2 class="sectionHeading">Abstract</h2>
With the advent of the Ultrabook™<sup>1</sup>, the demand for applications that are power misers continues to rise. The Intel® Energy Checker SDK can be used to instrument an application and collect data to help a developer pinpoint power hungry features that can be optimized for power. This article gives an overview of the Intel Energy Checker SDK and discusses how it can be used to advantage when improving energy usage on an Ultrabook.<br /><br />
<h2 class="sectionHeading">More Work, Less Power</h2>
An Ultrabook™ needs to budget its power consumption very carefully to extend usefulness while running on battery. Therefore, applications that use less energy are preferred. Often, application developers create their program on a desktop system where power/energy consumption is less important than raw performance. Not only should applications be developed to conserve power when active, they should also be developed to minimize energy usage during program idle periods, this is often overlooked and can greatly extend battery life. If power issues are ignored, running a program on an Ultrabook will result in unpleasant surprises for the user. If developers test their application on an Ultrabook system during development, they will gain insight into how well the program runs in a power limited environment. An analysis tool such as the <a href="http://software.intel.com/en-us/articles/intel-energy-checker-sdk/">Intel® Energy Checker SDK</a> can be a powerful companion during the optimization phase for software designed for an Ultrabook.<br /><br />
<h2 class="sectionHeading">Energy Efficency</h2>
Before explaining what Intel Energy Checker SDK contains, a discussion on Energy Efficiency (EE) is in order. This is a term that is used extensively in the Intel Energy Checker SDK. There is no universally accepted definition of EE, so for the purposes of this tool it is defined as:<br />
<p ><em>EE=Work/Energy</em></p>
<em>Work</em> is defined as the amount of “<em>useful work</em>” done by a software application. There is no concise, easy definition of the term <em>useful work</em> either, as what is considered <em>useful work</em> in one program may be quite different in another application. The developer is required to make that determination. For example, one might consider the areas of a movie player program where it provides the customer value (such as decoding the movie) as useful work whereas areas of the program that are accessing resources, waiting on input, or performing synchronization would not.<br /><br />
<h2 class="sectionHeading">Code Instrumentation</h2>
The first step in using Intel Energy Checker SDK to help determine an application’s EE is to create and use “counters” in the software to determine quantities of “useful work”. A counter is defined as a 64-bit (8 byte) variable that keeps a running total of how many times a particular event occurs. In the “C” language, this becomes an unsigned long long data type. A developer can create one or more counters during the initialization portion of the software. Next, a container for the counters can be created, called a “Productivity Link” (PL)<sup>2</sup>. Each PL holds up to 512 counters, and up to 10 different PL’s can be open at one time, but most software will require far smaller numbers of counters and PL’s.<br /><br />During the application runtime, values can be written to any counter in the PL, based on the developer’s requirements. Intel Energy Checker SDK can collect the information from the PL’s in order to determine how much work was done.<br /><br />
<h2 class="sectionHeading">Energy Consumed</h2>
The second part of finding the EE of a software application is to measure how much energy was consumed while the program was running. To do this, Intel Energy Checker SDK uses two tools which are included in the SDK download: Energy Server (ESRV) and Temperature Server (TSRV). ESRV is used to monitor energy and power consumption as reported by external power tools while TSRV monitors temperature related information as reported by environmental probes. ESRV and TSRV counters can be accessed by any program using the Intel Energy Checker API. In addition to the counters created by the developer to determine quantities of work, the developer will want to add counters to collect information from ESRV and possibly TSRV. There are three different ways to set up ESRV:<br /><br /><ol>
<li>Use a power meter to collect actual “platform energy and power” information.<br /><br />There are several different power meters that work with the Intel Energy Checker SDK. Please consult the <em>Intel® Energy Checker SDK User Guide</em> included in the download or found on the <a href="http://software.intel.com/en-us/articles/intel-energy-checker-sdk/">Intel® Energy Checker SDK page</a> to determine which power meters will work and how they should be attached to the test system.<br /></li>
<li>Use <a href="http://software.intel.com/en-us/articles/intel-power-gadget/">Intel® Power Gadget</a> to collect “processor energy and power” usage information on 2nd Generation Intel Core™ processor family. External power meters can also be used which report platform power together with Intel Power Gadget that provides processor power.The blog Accessing Intel® Power Gadget From Intel® Energy Checker SDK by Intel engineer Jun De Vega discusses how to enable Intel® Power Gadget with Intel® Energy Checker.<br /></li>
<li>Choose to use the simulation method which will use the CPU utilization percentage returned from the OS. This method does not require a hardware probe. The Intel Energy Checker SDK offers this method as an option for all processors (rather than just the 2nd Generation Intel Core processor family as with the Intel Power Gadget) in order for enable the user who does not have a power meter. Included in the SDK is a support library for accessing this metric.</li>
</ol>
<p ><img src="http://software.intel.com/file/41168" /><br /><br /><strong>Figure 1:</strong> Conceptualized drawing of Intel Energy Checker setup with Instrumented Application, Power Meter and Environmental probes attached</p>
<h2 class="sectionHeading">Intel Energy Checker Extras</h2>
There are two companion tools that are bundled with the Intel Energy Checker SDK in addition to those already mentioned. The PL GUI Monitor is a user interface that displays Productivity Link (PL) counters in a running program that has already been instrumented with the Intel Energy Checker API. The PL CSV Logger<sup>3</sup> is an application that can collect and write PL counters to a CSV file for later analysis in a variety of spreadsheet applications.<br /><br />Included with the Intel Energy Checker SDK is the <em>Intel® Energy Checker SDK Companion Application User Guide</em> that discusses the features and capabilities of both of these tools.<br /><br />
<p ><img src="http://software.intel.com/file/41169" /><br /><br /><strong>Figure 2:</strong> PL GUI Monitor running while a picture is being rendered</p>
The entire Intel Energy Checker SDK includes other build, scripting, interoperability, and monitoring tools to help developers instrument code and collect energy metrics.<br /><br />A white paper entitled “<em>How Green Is Your Software?</em>” is available for download from the SDK site. This paper discusses approaches for making software power efficient. Look for it in the “Code, Resources and Documentation” section of the <a href="http://software.intel.com/en-us/articles/intel-energy-checker-sdk/">Intel Energy Checker SDK page</a>. Several blogs about Intel Energy Checker that were written by Intel Engineer Jamel Tayeb will also be helpful:<br /><br /><a href="http://software.intel.com/en-us/blogs/2010/04/15/using-the-intel-energy-checker-sdk-at-home/?wapkw=(Energy+Checker)">Using the Intel® Energy Checker SDK at Home</a><br /><br /><a href="http://software.intel.com/en-us/blogs/2010/02/19/creating-a-simple-device-library-for-intel-energy-checker-sdk/?wapkw=(Energy+Checker)">Creating a Simple Device Library for Intel® Energy Checker SDK</a><br /><br /><a href="http://software.intel.com/en-us/blogs/2010/03/30/measuring-the-energy-consumed-by-a-command-using-the-intel-energy-checker-sdk/?wapkw=(Energy+Checker)">Measuring the energy consumed by a command using the Intel® Energy Checker SDK</a><br /><br />All of these resources allow a developer to get started in gathering helpful information.<br /><br />
<h2 class="sectionHeading">Optimizing Applications for Ultrabooks</h2>
Once a program has been instrumented to collect counter information and an energy collection plan is in place (either simulation or power meter), the setup is complete. The developer will then be able to gather information about the application’s energy usage profile and to incorporate optimizations to improve results.<br /><br />There are several areas of optimization the Ultrabook developer can select for improvements:<br /><br />
<div >Consider modifying the application to be aware of the power status and changing usage to reduce energy consumption when the system is on battery.<br /><br />Check the hardware and software system power management possibilities to choose a balanced power setting. This could be a recommended setting suggested in application documentation.<br /><br />Reduce power usage while the application is actively running or doing work. Compute intensive parts of the program will likely benefit from multi-threading and vectorization techniques.<br /><br />Reduce power usage while the application is idle. Being able to minimize the timer tick rate or setting up periodic actions to happen within the same wakeup period are examples of how to reduce idle application power usage.</div>
<br /><br />
<h2 class="sectionHeading">Summary</h2>
With the growth of Ultrabook devices, it will benefit program designers and developers to take a look at ways to save energy while providing a great user experience on an Ultrabook. Intel Energy Checker SDK can provide the means to identify the key areas of focus and confirm the positive results achieved after optimization. Long live Ultrabook!<br /><br />
<h2 class="sectionHeading">About the Author</h2>
<img src="http://software.intel.com/file/41170"  /> Judy Hartley is a Software Applications Engineer who has been working in the Software and Services Group since 2005. She has contributed to many software products and written about her experiences through blogs and whitepapers. Recently Judy has been working on Graphics and Power tools and training for future Intel processors.<br /><br  />
<hr />
<br /><sup>1</sup> Ultrabook is a trademark of Intel Corporation in the U.S. and/or other countries.<br /><br /><sup>2</sup> A Productivity Link is a term used by Intel Energy Checker to represent an arbitrary or logical collection of counters.<br /><br /><sup>3</sup> CSV is the acronym for Comma Separated Values.<br /><br /> ]]></description>
      <link>http://software.intel.com/en-us/articles/ultrabook-and-the-intel-energy-checker-sdk/</link>
      <pubDate>Tue, 24 Jan 2012 00:00:00 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/ultrabook-and-the-intel-energy-checker-sdk/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/ultrabook-and-the-intel-energy-checker-sdk/</guid>
      <category>Mobility</category>
      <category>What If Experimental Software</category>
      <category>Tools</category>
      <category>Intel Software Network communities</category>
      <category>Intel SW Partner program</category>
      <category>Code &amp; Downloads</category>
      <category>Power Efficiency</category>
      <category>Resources For Software Developers</category>
      <category>Ultrabook</category>
    </item>
    <item>
      <title>Intel® Cilk™ Plus Software Development Kit</title>
      <description><![CDATA[ <a href="http://software.intel.comjavascript:void(0)" onclick="ndownload('http://software.intel.com/file/43660')">cilkutil-linux-build%7E002516-eng.tgz</a>
<table width="100%" cellpadding="1" cellspacing="1" border="0">
<tbody>
<tr>
<td align="center"><a target="_top" href="http://software.intel.com/en-us/articles/download-intel-cilk-plus-software-development-kit/ "><img src="http://software.intel.com/file/15820" /></a></td>
<td ><span class="sectionBody"><a href="http://software.intel.com/en-us/articles/welcome-to-whatifintelcom">What If Home</a> | <a href="http://software.intel.com#Product Overview">Product Overview</a> | <a href="http://software.intel.com#Support">Support &amp; Feedback</a> | <a href="http://software.intel.com#Technical Requirements">Technical Requirements</a> | <a href="http://software.intel.com#FAQ">FAQ</a></span></td>
</tr>
</tbody>
</table>
<p><br />The Intel® Cilk™ Plus SDK (Software Development Kit) supplies additional tools for Intel® Cilk™ Plus developers working on the Microsoft Windows* and Linux* operating systems. These tools are especially helpful for users converting from the previous Intel® Cilk++ WhatIf kit to the Intel Cilk Plus implementation provided with the Intel® Parallel Composer 2011 and Intel® C++ Composer XE 2011 products.</p>
<div class="sectionHeading"><a name="Product Overview"></a>Product Overview</div>
<br />
<p>The Intel Cilk Plus SDK provides the following tools:</p>
<ul>
<li>Intel® Cilk screen race detector (Cilk screen) – Monitors the actual operation of an Intel Cilk Plus program as run with your test input. Cilk screen reports all data races introduced by the Intel Cilk Plus scheduler encountered during execution. By monitoring program execution, Cilk screen can detect races in your production binary, and can even detect races produced by third-party libraries for which you may not have source code. </li>
<li>Intel® Cilk view scalability analyzer (Cilk view) – Helps you understand the parallel performance of your Intel Cilk Plus program.  Cilk view reports parallel statistics about an Intel Cilk Plus program and predicts how the performance will scale on multiple processor systems.  In addition, Cilk view can automatically benchmark an Intel Cilk Plus program running on one or more processors.</li>
<li>Integration of Cilk screen and Cilk view into Microsoft Visual Studio* 2005, 2008 and 2010 on Microsoft Windows* operating systems.  Integration into the user’s development environment allows users to view error locations at the click of a mouse.</li>
</ul>
<p>For more information, see the Intel® Cilk™ Plus SDK User’s Guide.</p>
<div class="sectionHeading"><a name="Features"></a>Support &amp; Feedback</div>
<p>The primary support model for the Intel Cilk Plus SDK is through the <a href="http://software.intel.com/en-us/forums/intel-cilk-plus/">Intel® Cilk™ Plus support forum</a> . Use this Support Forum to ask questions about the product, share your experiences with other developers, and ask for assistance if you encounter issues with these tools.</p>
<p>You are encouraged to use this forum for submitting suggestions on new features you would like to see supported and to comment on features currently in the product.  Your feedback is valuable to Intel.</p>
<div class="sectionHeading"><a name="Technical Requirements"></a>Technical Requirements</div>
<p>This release of the Intel Cilk Plus SDK supports the following operating systems:</p>
<ul>
<li>Microsoft Windows XP* or later for the IA-32 or Intel® 64 architectures</li>
<li>Linux* for the IA-32 or Intel 64 architectures</li>
</ul>
<p>In addition, the user must have installed the Intel® C++ Compiler included with one of the following product suites:</p>
<ul>
<li>Intel® Parallel Composer 2011 Update 1</li>
<li>Intel® C++ Composer XE 2011 Update 1</li>
</ul>
<p>Failure to install the compiler update will result in an error claiming that no Intel Cilk Plus code was found.</p>
<div class="sectionHeading"><a name="FAQ"></a>FAQ</div>
<p><b>Q – What is the status of the Intel Cilk Plus SDK on the WhatIf site?</b><br />A<b> –</b> The Intel Cilk Plus SDK is provided free of charge as a technology preview.  We are interested in your feedback.  Since it is only a technology preview, the support level for this version is limited.</p>
<p><b>Q – How do I get started?</b><br />A<b> –</b> Before installation, you must set up your environment as described in the Technical Requirements (above).  After downloading the Intel Cilk Plus SDK:</p>
<ul>
<li>On Windows* unzip the zipfile and run setup.exe</li>
<li>On Linux* untar the tarball into your home directory or your /usr/local directory</li>
</ul>
<p>The Intel Cilk Plus SDK User’s Guide is installed as part of the installation.</p>
<p><b>Q – How do I report problems or send feedback?</b><br />A<b> – </b>You are welcome to join the Intel® Cilk™ Plus Forum to post your questions and issues.  The support team monitors the discussion to address questions.</p>
<p><b>Q – Where can I learn more about Intel Cilk Plus?</b><br />A – Visit the <a href="http://software.intel.com/en-us/articles/intel-cilk-plus/">Intel® Cilk™ Plus product page</a> for technical documents, presentations and tech-talks on Intel Cilk Plus.</p>
<div class="sectionHeading"><a name="PreviousVersion"></a>Previous Version</div>
<p>The Intel Cilk++ WhatIf kit is still available at <a href="http://software.intel.com/en-us/articles/download-intel-cilk-sdk/">http://software.intel.com/en-us/articles/download-intel-cilk-sdk/</a><a>.</a></p> ]]></description>
      <link>http://software.intel.com/en-us/articles/intel-cilk-plus-software-development-kit/</link>
      <pubDate>Wed, 22 Dec 2010 21:00:00 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/intel-cilk-plus-software-development-kit/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/intel-cilk-plus-software-development-kit/</guid>
      <category>What If Experimental Software</category>
    </item>
    <item>
      <title>Intel Software Autotuning Tool</title>
      <description><![CDATA[ <table border="0" cellpadding="1" cellspacing="1" width="100%">
<tbody>
<tr>
<td align="center"><a href="http://software.intel.com/en-us/articles/download-intel-software-autotuning-tool/" target="_top"><img src="http://software.intel.com/file/15820" /></a></td>
<td ><span class="sectionBody"><a href="http://software.intel.com/en-us/articles/welcome-to-whatifintelcom">What If Home</a> | <a href="http://software.intel.com#Product Overview">Product Overview</a> | <a href="http://software.intel.com#Features">Features</a> | <a href="http://software.intel.com#Technical Requirements">Technical Requirements</a> | <a href="http://software.intel.com#Documentation">Documentation</a><br /><a href="http://software.intel.com#FAQ">FAQ</a> | <a href="http://software.intel.com#Bio">Primary Technology Contacts<br /></a></span></td>
</tr>
</tbody>
</table>
<div class="sectionHeading"><a name="Product Overview"></a><br /><br />Product Overview</div>
<br /><b>Intel Software Autotuning Tool</b>
<p>The Intel Software Autotuning Tool (ISAT) is a new performance tuning tool that supports automatic searching  for the near-optimal values of program parameters that have significant performance impact.  Examples are the cache-blocking factors in matrix computations, the task granularity in TBB,  and the scheduling policy of OpenMP parallel constructs. The output of ISAT is a tuned version of the program based on the searching results.  In addition, it supports visualization of the tuning results (e.g., Figure 1) so that the developer can have a better understanding  of his program performance. ISAT can be used on top of any C/C++ compilers on Linux.</p>
<img src="http://software.intel.com/file/32921/" alt="isat-graph" width="600" /> <br />Figure 1: Visualization of ISAT results.  <br /> <br />
<div class="sectionHeading"><a name="Features"></a>Features</div>
<ul>
<li>Automatic searching of the near-optimal values of program parameters</li>
<li>Easy to use with no compiler dependency</li>
<li>Programmer-controlled searching strategies</li>
<li>Threading-library specific tuning for OpenMP and TBB</li>
<li>Visualization of tuning results</li>
<li>The autotuner is open-sourced</li>
</ul>
<div class="sectionHeading"><a name="Technical Requirements"></a>Technical Requirements</div>
<ul>
<li> 32 or 64-bit Linux; Python version between 2.4 and 2.9; any C/C++ compiler.</li>
</ul>
<div class="sectionHeading"><a name="Downloads"></a>Downloads</div>
<ul>
<li> <a href="http://software.intel.com/file/32922/">Kit for 32/64-bit Linux</a> </li>
</ul>
<div class="sectionHeading"><a name="Documentation"></a>Documentation</div>
<ul>
<li> <a href="http://software.intel.com/file/32918/"> User manual </a> </li>
<li> <a href="http://software.intel.com/file/32919/"> A Synergetic Approach to Throughput Computing on x86- Based Multicore Desktops</a> </li>
<li> <a href="http://software.intel.com/file/32920/"> Presentation: A Synergetic Approach to Throughput Computing on Intel® Architecture</a> </li>
</ul>
<div class="sectionHeading"><a name="Bio"></a>Primary Technology Contacts</div>
<a href="http://www.ckluk.org/ck">Chi-Keung (CK) Luk</a> is a Senior Staff Engineer in a Software Pathfinding Group at Intel,  where he conducts research and advanced development in parallel programming, compiler,  and program-analysis tools. Previously, he worked on the Pin dynamic instrumentation system.  CK obtained his Ph.D. from the University of Toronto and was a visiting scholar at Carnegie Mellon University.  He has 30 publications and two issued patents with a few others pending.  He received an Intel Achievement Award and a nomination for the ACM Doctoral Dissertation Award. ]]></description>
      <link>http://software.intel.com/en-us/articles/intel-software-autotuning-tool/</link>
      <pubDate>Wed, 15 Dec 2010 21:00:00 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/intel-software-autotuning-tool/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/intel-software-autotuning-tool/</guid>
      <category>What If Experimental Software</category>
    </item>
    <item>
      <title>Download Intel Software Autotuning Tool</title>
      <description><![CDATA[ <b>Technical Documentation</b>
<p><a href="http://software.intel.com/file/32918/">User manual</a></p>
<b>Download Files</b> <br />Click to accepting the end user license agreement and download the Intel Software Autotuning Tool. <br /><br /><a href="http://software.intel.com/file/32922/" onclick="show_file_download(3,false,'http://software.intel.com/file/32922/')" title="download_3" class="filedownload" id="free_download_3">Kit for 32/64-bit Linux</a> 6.76MB
<p> </p>
<p>Please take a moment to <a href="https://login-software.intel.com/isn/registration/isnRegpage.aspx?TARGET=http://softwarecommunity.intel.com/isn/home/default.aspx?xclear=1">register with ISN </a>to participate in forum discussions.</p>
<p>Back to the <a href="http://software.intel.com/en-us/articles/intel-software-autotuning-tool/">Intel Software Autotuning Tool</a>page.</p> ]]></description>
      <link>http://software.intel.com/en-us/articles/download-intel-software-autotuning-tool/</link>
      <pubDate>Wed, 15 Dec 2010 21:00:00 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/download-intel-software-autotuning-tool/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/download-intel-software-autotuning-tool/</guid>
      <category>What If Experimental Software</category>
    </item>
    <item>
      <title>Download Intel® Cilk™ Plus Software Development Kit</title>
      <description><![CDATA[ <a onclick="ndownload('http://software.intel.com/file/43279')" href="http://software.intel.comjavascript:void(0)"></a>
<p><b>Description</b><br />This SDK is compatible with Cilk-style parallelized binaries compiled with the Intel® Parallel Composer 2011 and Intel® C++ Composer XE products. Support for the Intel Cilk Plus SDK is through the <a href="http://software.intel.com/en-us/forums/intel-cilk-plus/">Intel® Cilk™ Plus support forum</a>.</p>
<p><b>Download Files<br /></b>Select your operating system and accepting the end user license agreement.</p>
<ul>
<!--
<li>Compatible with Intel C++ V13.0: <br /> <a class="filedownload" id="free_download_9" title="download_9" onclick="show_file_download(9,false,'http://software.intel.com/file/43280')" href="http://software.intel.comjavascript:void(0);" mce_href="javascript:void(0);" file_path="http://software.intel.com/file/43280">Download Intel® Cilk™ Plus SDK installer for Windows*</a> (cilktools_windows_2449-v13.0.zip) 13.2MB <br /> <a class="filedownload" id="free_download_9" title="download_9" onclick="show_file_download(9,false,'http://software.intel.com/file/43279')" href="http://software.intel.comjavascript:void(0);" mce_href="javascript:void(0);" file_path="http://software.intel.com/file/43280">Download Intel® Cilk™ Plus SDK package for Linux*</a> (cilkutil-linux-2449-v13.0.tgz) 11.5MB <br /> <a href="http://software.intel.com/file/43279" mce_href="http://software.intel.com/file/43279">Download source for libelf and libdwarf used by Intel® Cilk™ Plus SDK for Linux*</a> (extsrc.tgz) 1.2MB </li>
-->
<li> Compatible with Intel C++ V12.1: <br /> <a class="filedownload" id="free_download_9" title="download_9" onclick="show_file_download(9,false,'http://software.intel.com/file/43658')" href="http://software.intel.comjavascript:void(0);" file_path="http://software.intel.com/file/43658">Download Intel® Cilk™ Plus SDK installer for Windows*</a> (cilktools_windows_2516-v12.1.zip) 13.2MB <br /> <a class="filedownload" id="free_download_9" title="download_9" onclick="show_file_download(9,false,'http://software.intel.com/file/43660')" href="http://software.intel.comjavascript:void(0);" file_path="http://software.intel.com/file/43660">Download Intel® Cilk™ Plus SDK package for Linux*</a> (cilkutil-linux-2516-v12.1.tgz) 11.5MB <br /> <a href="http://software.intel.com/file/39866">Download source for libelf and libdwarf used by Intel® Cilk™ Plus SDK for Linux*</a> (extsrc.tgz) 1.2MB <br /><a class="filedownload" id="free_download_9" title="download_9" onclick="show_file_download(9,false,'http://software.intel.com/file/43281')" href="http://software.intel.comjavascript:void(0);" file_path="http://software.intel.com/file/43281">Download libzca source to provide access to Cilk metadata</a> (libzca-src-151.tgz) 34KB </li>
<a class="filedownload" id="free_download_9" title="download_9" onclick="show_file_download(9,false,'http://software.intel.com/file/43282')" href="http://software.intel.comjavascript:void(0);" file_path="http://software.intel.com/file/43282">Download cilkprof source example of using Cilk metadata</a> (cilkprof-src-151.tgz) 16KB
<li>Compatible with Intel C++ V12.0:<br /> <a class="filedownload" id="free_download_9" title="download_9" onclick="show_file_download(9,false,'http://software.intel.com/file/33254/')" href="http://software.intel.comjavascript:void(0);" file_path="http://software.intel.com/file/33254/">Download Intel® Cilk™ Plus SDK installer for Windows*</a> (cilktools_1113.zip) 12.5MB<br /> <a class="filedownload" id="free_download_9" title="download_9" onclick="show_file_download(9,false,'http://software.intel.com/file/33225/')" href="http://software.intel.comjavascript:void(0);" file_path="http://software.intel.com/file/33225/">Download Intel® Cilk™ Plus SDK package for Linux* </a>(cilkutil-linux-build~001113.tgz) 10.8MB </li>
</ul>
<p>Please take a moment to <a href="https://login-software.intel.com/isn/registration/isnRegpage.aspx?TARGET=http://softwarecommunity.intel.com/isn/home/default.aspx?xclear=1">register with ISN </a>to participate in forum discussions.</p>
<p>Back to the <a href="http://software.intel.com/en-us/articles/intel-cilk-plus-software-development-kit/">Intel® Cilk Plus SDK</a> page.</p> ]]></description>
      <link>http://software.intel.com/en-us/articles/download-intel-cilk-plus-software-development-kit/</link>
      <pubDate>Fri, 03 Dec 2010 21:00:00 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/download-intel-cilk-plus-software-development-kit/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/download-intel-cilk-plus-software-development-kit/</guid>
      <category>What If Experimental Software</category>
    </item>
    <item>
      <title>Pre-Release License Agreement for Intel® C++ STM Compiler, Prototype Edition</title>
      <description><![CDATA[ <p>Note - Please make sure that you have an active license of the Intel(R) C++ Compiler for Windows* or the Intel(R) C++ Compiler for Linux* on your system. If you don't, you can easily acquire a <a href="http://www3.intel.com/cd/software/products/asmo-na/eng/compilers/284132.htm">commercial product or try an evaluation copy</a>.</p>
<p>Attention – the include/itm.h file shipped with the C++ STM compiler version 11.0.606 has been corrupted and needs to be corrected manually to be usable. The solution is to remove all lines after and including line 389 in the include/itm.h file. Please accept our apologies for the inconvenience.</p>
<p><b>Intel® C++ STM Compiler Prototype Edition 4.0</b></p>
<ul>
<li><a href="http://software.intel.com/file/29788/" onclick="show_file_download(3,false,'http://software.intel.com/file/29788/')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD WINDOWS* IA-32</a> (w_cstmc_p_11.0.509_ia32.exe, 337MB)</li>
<li><a href="http://software.intel.com/file/29787/" onclick="show_file_download(3,false,'http://software.intel.com/file/29787/')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD WINDOWS* Intel® 64</a> (w_cstmc_p_11.0.509_intel64.exe, 412MB)</li>
<li><a href="http://software.intel.com/file/29784/" onclick="show_file_download(3,false,'http://software.intel.com/file/29784/')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD LINUX* IA-32 and Intel® 64</a> (l_cproc_p_11.0.610.tgz, 1.1GB)</li>
<li><a href="http://software.intel.com/file/29786/" onclick="show_file_download(3,false,'http://software.intel.com/file/29786/')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD LINUX* IA-32</a> (l_cproc_p_11.0.610_ia32.tgz, 592MB)</li>
<li><a href="http://software.intel.com/file/29785/" onclick="show_file_download(3,false,'http://software.intel.com/file/29785/')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD LINUX* Intel® 64</a> (l_cproc_p_11.0.610_intel64.tgz, 611MB)</li>
</ul>
<p><b>Intel® C++ STM Compiler Prototype Edition 3.0</b></p>
<p><a href="http://software.intel.com/en-us/articles/intel-c-stm-compiler-prototype-edition-20-release-notes ">Release Notes</a> | <a href="http://softwarecommunity.intel.com/isn/Downloads/whatif/stm/Intel-C-STM-Language-Extensions-Users-Guide-V2_0.pdf"></a><a href="http://software.intel.comjavascript:void(0)" onclick="ndownload('http://software.intel.com/file/8263')">Intel® C++ STM Compiler Prototype Edition 3.0 Language Extensions and User’s Guide</a></p>
<ul>
<li><a href="http://software.intel.com/file/8260" onclick="show_file_download(3,false,'http://software.intel.com/file/8260')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD WINDOWS* IA-32</a> (w_cstmc_p_11.0.507_ia32.exe, 326.9MB)</li>
<li><a href="http://software.intel.com/file/8262" onclick="show_file_download(3,false,'http://software.intel.com/file/8262')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD WINDOWS* Intel® 64</a> (w_cstmc_p_11.0.507_intel64.exe, 401.6MB)</li>
<li><a href="http://software.intel.com/file/8259" onclick="show_file_download(3,false,'http://software.intel.com/file/8259')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD LINUX* IA-32 and Intel® 64</a> (l_cproc_p_11.0.606.tgz, 1.09GB)</li>
<li><a href="http://software.intel.com/file/8258" onclick="show_file_download(3,false,'http://software.intel.com/file/8258')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD LINUX* IA-32</a> (l_cproc_p_11.0.606_ia32.tgz, 507.5MB)</li>
<li><a href="http://software.intel.com/file/8261" onclick="show_file_download(3,false,'http://software.intel.com/file/8261')" title="download_3" class="filedownload" id="free_download_3">DOWNLOAD LINUX* Intel® 64</a> (l_cproc_p_11.0.606_intel64.tgz, 594.2MB)</li>
</ul>
<p> </p>
<p>Please take a moment to <a href="https://login-software.intel.com/isn/registration/isnRegpage.aspx?TARGET=http://softwarecommunity.intel.com/isn/home/default.aspx?xclear=1">register with ISN</a> to participate in forum discussions.</p>
<p>Back to the <a href="http://software.intel.com/en-us/articles/intel-c-stm-compiler-prototype-edition-20">Intel® C++ STM Compiler Prototype Edition</a> page.</p> ]]></description>
      <link>http://software.intel.com/en-us/articles/pre-release-license-agreement-for-intel-c-stm-compiler-prototype-edition/</link>
      <pubDate>Sun, 22 Aug 2010 21:00:00 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/pre-release-license-agreement-for-intel-c-stm-compiler-prototype-edition/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/pre-release-license-agreement-for-intel-c-stm-compiler-prototype-edition/</guid>
      <category>What If Experimental Software</category>
    </item>
    <item>
      <title>Intel® AVX C/C++ Intrinsics Emulation</title>
      <description><![CDATA[ <p>Intel® AVX instruction set extension <a target="_blank" href="http://software.intel.com/en-us/avx/">[1]</a> will appear in the next generation Intel microarchitecture codename ‘Sandy Bridge'. We chose to announce AVX early to get as much support from software vendors as possible by the hardware launch time. Now, most software development platforms are supporting Intel AVX, examples are compilers and assemblers from Intel, Microsoft and GCC as well as UNIX binutils.</p>
<p>For early adopters we introduced support of AVX in Intel® Software Development Emulator <a target="_blank" href="http://software.intel.com/en-us/articles/intel-software-development-emulator/">[2]</a>, it allows you to run and check functional correctness of the code with the actual AVX instructions before hardware is available.</p>
<p>Today we are adding another useful piece to help those who may not be able to use new tools supporting AVX in their current development environment but plan to migrate in the future or are using a software platform which is not supported by Intel SDE. These software developers can still start programming with Intel AVX using intrinsics.</p>
<p>Here we are providing the C and C++ header file which emulates Intel AVX intrinsics. The AVX emulation header file uses intrinsics for the prior Intel instruction set extensions up to Intel SSE4.2. SSE4.2 support in your development environment as well as hardware is required in order to use the AVX emulation header file. <br /><br />To use simply have this file included:</p>
<p>#include "avxintrin_emu.h"</p>
<p>Instead of usual:</p>
<p>#include &lt;immintrin.h&gt;</p>
<p><br />One can also create alternative immintrin.h file (which in turn includes avxintrin_emu.h) to avoid an intrusive change to the source base and then simply switch between real AVX code generation and emulation via alternating the path to include directories.</p>
<p>Emulation header is primarily targeting UNIX type of environments, and was tested on such with GCC and Intel C/C++ compilers. We have a strong support with other tools (compilers, assemblers and SDE) on Microsoft Windows platform, but this header file can still be used on Windows, if desired, with Intel Compiler.</p>
<p>Note that the AVX emulation header file is designed to allow functional correctness of an AVX implementation and not recommended for long-term usage or release in a final product. Once your development environment and hardware supports AVX, we recommend that you switch to the real AVX intrinsic header file.<br /><br />Although we did our best to debug it, this file must <em>not</em> be considered a reference functional implementation of AVX instructions or even bug-free. Please see the current version's limitations and caveats in the beginning of the file. Please let us know about the issues you faced using it.</p>
<p><b><br />Example</b></p>
<pre name="code" class="cpp:nogutter:nocontrols">#include "avxintrin_emu.h"  // #include &lt;immintrin.h&gt;

void saxpy( float a, const float* x, const float* y, float* __restrict z, size_t len )
{
    size_t i = 0;
    __m256 a_ = _mm256_set1_ps( a );

    for ( size_t len16_ = len &amp; -16; i + 16 &lt;= len16_; i += 16 )
    {
        __m256 x1_ = _mm256_loadu_ps( x + i );
        __m256 x2_ = _mm256_loadu_ps( x + i + 8 );

        __m256 y1_ = _mm256_loadu_ps( y + i );
        __m256 y2_ = _mm256_loadu_ps( y + i + 8 );

        x1_ = _mm256_mul_ps( x1_, a_ );
        x2_ = _mm256_mul_ps( x2_, a_ );

        x1_ = _mm256_add_ps( x1_, y1_ );
        x2_ = _mm256_add_ps( x2_, y2_ );

        _mm256_storeu_ps( z + i     , x1_ );
        _mm256_storeu_ps( z + i + 8 , x2_ );
    }

    for ( ; i &lt; len; ++i )
        z[i] = x[i] * a + y[i];
}</pre>
<p><br /><strong><br />References </strong></p>
<p>[1] Intel AVX - <a target="_blank" href="http://software.intel.com/en-us/avx/">http://software.intel.com/en-us/avx/</a></p>
<p>[2] Intel Software Development Emulator - <a target="_blank" href="http://software.intel.com/en-us/articles/intel-software-development-emulator/">http://software.intel.com/en-us/articles/intel-software-development-emulator/</a></p> ]]></description>
      <link>http://software.intel.com/en-us/articles/avx-emulation-header-file/</link>
      <pubDate>Wed, 23 Jun 2010 00:00:00 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/avx-emulation-header-file/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/avx-emulation-header-file/</guid>
      <category>Parallel Programming</category>
      <category>Open Source</category>
      <category>What If Experimental Software</category>
      <category>Tools</category>
      <category>Intel® AVX</category>
      <category>Software News</category>
      <category>Code &amp; Downloads</category>
    </item>
    <item>
      <title>Intel Web API Connector Documentation and Examples</title>
      <description><![CDATA[ <p>
The Intel Web API Connector manages the installation of other Intel Web APIs.
Once the Connector is installed, other Intel Web APIs can be downloaded and
installed without a browser restart.
</p>

<div >
<a name="Contents">Contents</a>
</div>
<div >
  <ul>
    <li>
      <a href="http://software.intel.com#Overview">Overview</a>
    </li>
    <li>
      <a href="http://software.intel.com#Browser and Device Compatibility">Browser and Device Compatibility</a>
    </li>
    <li>
      <a href="http://software.intel.com#A code sample to get you started">A code sample to get you started</a>
    </li>
    <li>
      <a href="http://software.intel.com#JavaScript API Details">JavaScript API Details</a>
    </li>
    <li>
      <a href="http://software.intel.com#Attributions">Attributions</a>
    </li>
    <li>
      <a href="http://software.intel.com#See it working">See it working in this page!</a>
    </li>
  </ul>
</div>

<br/>
<div >
  <a name="Overview">Overview</a>
</div>
<div >
    <p>
    The Intel Web APIs are implemented as browser plugins.  In order to 
    avoid requiring the viewers of web pages with these plugins to individually
    download and install the plugins, the Connector simplifies this chore
    without compromising the viewer's control and security.
    </p>
    <p>
    When first visting a site using Intel Web APIs, the viewer of the page
    will be directed to install the Connector.  This installation is like any
    other plugin installation - download the installer, run it, and restart
    the browser.  After this, however, the viewer experiences much different
    behavior with Intel Web API web pages.  Upon subsequent visits to a page
    with Intel Web APIs, the web page will request that the Connector download
    and install any required Intel Web APIs.  This occurs without the viewer
    performing the steps manually - so no longer does the viewer need to
    download, run, and restart. 
    </p>
    <p>
    Instead, after the Connector is installed, the viewer will be prompted to
    allow or deny each web site requesting other Intel Web APIs.  This ensures the viewer
    remains in control of which web sites can and cannot use Intel Web APIs
    on his or her machine. The Connector allows the viewer to establish both
    per-session and permenant whitelists and blacklists.  In otherwords, known
    good and known bad sites.
    </p>
    <p>
    In addition to viewer-controlled white and black lists, the Connector also
    refuses to download and install plugins that are not digitally signed by
    the folks here at Intel working on Intel Web APIs - we don't want a rouge
    web site to instruct the Connector to download any random plugin!
    </p>
</div>

<br/>
<div >
<a name="Browser and Device Compatibility">Browser and Device Compatibility</a>
</div>
<div >
  <p>
  The table below lists some compatability notes for browser and operating system combinations.
  </p>
  <p>
  If you are interested in seeing these APIs available on other device types and operating systems 
  please let us know by <a href="http://software.intel.com/en-us/articles/intel-web-api-connector-documentation-and-examples">leaving comments</a>.
  </p>
  <table >
    <tr>
      <th >Browser</th><th >Operating System</th><th >Notes</th>
    </tr>
    <tr>
      <td>Firefox 3.5.x, 3.6.x</td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Seems to be working well.</td>
    </tr>
    <tr>
      <td>Chrome 4.0.x.y</td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Seems to be working well.</td>
    </tr>
    <tr>
      <td>Safari 4.0.x</td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Seems to be working well.</td>
    </tr>
    <tr>
      <td>Opera v 10.x </td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Not currently working. It's on the debug todo list.</td>
    </tr>
    <tr>
      <td>Internet Explorer 8.x</td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Not supported yet. Its on the todo list though.</td>
    </tr>
    <tr>
      <td>Firefox, Chrome, Safari</td>
      <td>Linux, MacOS</td>
      <td>Not supported yet. Linux and Mac OS porting is underway :)</td>
    </tr>
  </table>
</div>

<br/>
<div >
  <a name="A code sample to get you started">A code sample to get you started</a>
</div>
<div >
<p>
  This HTML & JavaScript shows you how to embed the Intel Connector Web API
  into your app.
</p>
<pre >
  &lt;div id="IntelWebAPIs_sample_code_status_div" 
    &gt;&lt;/div&gt;
  &lt;script 
    type="text/javascript" 
    src="http://software.intel.com/sites/whatif/webapis/intelwebapis.js"&gt;
  &lt;/script&gt;
  
  &lt;script type="text/javascript"&gt;
  
    // this outer closure just to keep the sample code from cluttering up
    // the namespace with the function names etc being used
    (function() {
      
      //kick off IntelWebAPIs.init() and IntelWebAPIs.require() when
      //the page is loaded
      add_onload_handler( function() {
  
        IntelWebAPIs.init(init_result_func);
        
        //called by IntelWebAPIs.init()
        function init_result_func(result) {
          if(result.success) {
            // now bring in Intel Web APIs required by your app...
            output_status("IntelWebAPIs Connector init success: version " +
                          IntelWebAPIs.connector.version);
          }
          else {
            output_status("IntelWebAPIs Connector init error: " + result.error.msg);
            //handle error condition
            //result.error.msg contains an error message
            //result.connectorInstUrl contains the url to the Intel Web API connector installer
            output_status("you may need to download the Intel Web API connector from here: " + 
              result.connectorInstUrl);
          }
        }
      });     
      
      /* Its recommended that you wait until the document is loaded 
         before calling IntelWebAPIs.init() and IntelWebAPIs.require() 
         This utility helps with that...*/
      function add_onload_handler(addfunc, altwindow) {
        var targwindow = window;
        if(typeof(altwindow) != 'undefined'){
          targwindow = altwindow;
        }
        
        /* chain the onload functions together */
        var prevf = targwindow.onload;
        var newf  = addfunc;
        targwindow.onload = function(){
            newf();
            if(typeof(prevf) == 'function'){
              prevf();
            }
          };
      }
      
      /* utility that outputs status messages to a div*/
      function output_status(str) {
        var divout = document.getElementById("IntelWebAPIs_sample_code_status_div");
        divout.innerHTML += str + "&lt;br/&gt;";
        divout.scrollTop = divout.scrollHeight;
      }
    })(); // end of outer closure
  &lt;/script&gt;
</pre>
<br/>
<p>
  Th Object that is passed into callback for the init() function is formatted
  as follows:<br/>
</p>

<pre >
  result = { 
    success           : boolean,
    
    // these fields are valid if success != true
    connectorInstUrl  : string 
    error             : {
      msg             : string 
    } 
  }
</pre>
  If the Intel Web API Connector is not yet installed on a user's device you can
  use the result.connectorInstUrl to prompt the user, in the context of your
  app, to install it.<br/> 
  Once the Intel Web API Connector is installed other apis are installed by the
  connector, with minimal user interruption, when your app calls IntelWebAPIs.require().

<br/>
</div>

<br/>
<div >
<a name="JavaScript API Details">JavaScript API Details</a>
</div>
<div >
These are the properties and methods exposed by the connector Web API:<br/><br/>
<pre >
  IntelWebAPIs.connector = {
    'version'     : string
  };
</pre>
<br/>
<div >
<a name="IntelWebAPIs.connector.version">IntelWebAPIs.connector.version</a>
</div>
<div>
This is the API's version string. It is formatted as "major.minor.patch" where major
and minor are numbers and patch is a string.  The connector will auto-update
itself during each require() call.
</div>
<br/>
</div>
<div >
  <a name="Attributions">Attributions</a>
</div>
<div >
    <p>
    Intel Connector Web API uses the following software components:
    </p>
    <ul>
      <li>
        OpenSSL:
        
        This product includes software developed by the OpenSSL Project for use 
        in the OpenSSL Toolkit (http://www.openssl.org/).
        
        Copyright (c) 1998-2008 The OpenSSL Project.  All rights reserved. 
      </li>
      <li>
        JSONXX:
        
        Copyright (c) 2010 Hong Jiang

        Permission is hereby granted, free of charge, to any person
        obtaining a copy of this software and associated documentation
        files (the "Software"), to deal in the Software without
        restriction, including without limitation the rights to use,
        copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the
        Software is furnished to do so, subject to the following
        conditions:

        The above copyright notice and this permission notice shall be
        included in all copies or substantial portions of the Software.
      </li>
    </p>
</div>
<br/>
<div >
<a name="See it working" href="http://software.intel.com/sites/whatif/webapis/api/connector">See it working in this page!</a>
</div>
 ]]></description>
      <link>http://software.intel.com/en-us/articles/intel-web-api-connector-documentation-and-examples/</link>
      <pubDate>Wed, 07 Apr 2010 00:00:00 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/intel-web-api-connector-documentation-and-examples/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/intel-web-api-connector-documentation-and-examples/</guid>
      <category>What If Experimental Software</category>
      <category>Code &amp; Downloads</category>
    </item>
    <item>
      <title>Intel Connection Web API Documentation and Examples</title>
      <description><![CDATA[ <p>
The Intel Connection Web API provides web developers with JavaScript access to 
information about the device's connection state.
</p>

<div >
<a name="Contents">Contents</a>
</div>
<div >
  <ul>
    <li>
      <a href="http://software.intel.com#Overview">Overview</a>
    </li>
    <li>
      <a href="http://software.intel.com#Browser and Device Compatibility">Browser and Device Compatibility</a>
    </li>
    <li>
      <a href="http://software.intel.com#A code sample to get you started">A code sample to get you started</a>
    </li>
    <li>
      <a href="http://software.intel.com#JavaScript API Details">JavaScript API Details</a>
    </li>
    <li>
      <a href="http://software.intel.com#See it working">See it working in this page!</a>
    </li>
  </ul>
</div>

<br/>
<div >
  <a name="Overview">Overview</a>
</div>
<div >
    <p>
    When web apps have the ability to learn about the characteristics of the device's 
    network connection they are be able to make use of that information to 
    create a better experience for the user.
    </p>
    <p>
    For instance, in combination with other information about the device, a web 
    app might use connection information to request a video stream which is approprate
    for the device's current bandwidth capability. A web app may determine that
    current signal strength is not sufficient for the app to function appropriatly
    for the desired user experience - and may prompt the user re-orient the device
    or move closer to a wireless access point. 
    </p>
</div>

<br/>
<div >
<a name="Browser and Device Compatibility">Browser and Device Compatibility</a>
</div>
<div >
  <p>
  The table below lists some compatability notes for browser and operating system combinations.
  </p>
  <p>
  If you are interested in seeing these APIs available on other device types and operating systems 
  please let us know by <a href="http://software.intel.com/en-us/articles/intel-connection-web-api-documentation-and-examples">leaving comments</a>.
  </p>
  <table >
    <tr>
      <th >Browser</th><th >Operating System</th><th >Notes</th>
    </tr>
    <tr>
      <td>Firefox 3.5.x, 3.6.x</td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Seems to be working well.</td>
    </tr>
    <tr>
      <td>Chrome 4.0.x.y</td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Seems to be working well.</td>
    </tr>
    <tr>
      <td>Safari 4.0.x</td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Seems to be working well.</td>
    </tr>
    <tr>
      <td>Opera v 10.x </td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Not currently working. It's on the debug todo list.</td>
    </tr>
    <tr>
      <td>Internet Explorer 8.x</td>
      <td>Windows (XP, Vista, Win 7)</td>
      <td>Not supported yet. Its on the todo list though.</td>
    </tr>
    <tr>
      <td>Firefox, Chrome, Safari</td>
      <td>Linux, MacOS</td>
      <td>Not supported yet. Linux and Mac OS porting is underway :)</td>
    </tr>
  </table>
</div>

<br/>
<div >
  <a name="A code sample to get you started">A code sample to get you started</a>
</div>
<div >
<p>
  This HTML & JavaScript shows you how to embed the Intel Connection Web API
  into your app.
</p>
<pre >
  &lt;div id="IntelWebAPIs_sample_code_status_div" 
    &gt;&lt;/div&gt;
  &lt;script 
    type="text/javascript" 
    src="http://software.intel.com/sites/whatif/webapis/intelwebapis.js"&gt;
  &lt;/script&gt;
  &lt;script type="text/javascript"&gt;

    // this outer closure just to keep the sample code from cluttering up
    // the namespace with the function names etc being used
    (function() {
      
      //kick off IntelWebAPIs.init() and IntelWebAPIs.require() when
      //the page is loaded
      add_onload_handler( function() {

        IntelWebAPIs.init(init_result_func);
        
        //called by IntelWebAPIs.init()
        function init_result_func(result) {
          if(result.success) {
            // now bring in Intel Web APIs required by your app...
            output_status("IntelWebAPIs Connector init success");
            IntelWebAPIs.require(["connection"], require_completion_func, require_progress_func);
          }
          else {
            output_status("IntelWebAPIs Connector init error: " + result.error.msg);
            //handle error condition
            //result.error.msg contains an error message
            //result.connectorInstUrl contains the url to the Intel Web API connector installer
            output_status("you may need to download the Intel Web API connector from here: " + 
              result.connectorInstUrl);
          }
        }
    
        //called by IntelWebAPIs.require()
        function require_completion_func(result) {
          if(result.success){
            //you can now use IntelWebAPIs.connection properties and functions
            output_status("IntelWebAPIs." + result.installInfo.plugins[0].name + " ready for use!");
            setInterval(function(){
              // send a status message to our div every second
              var connInfo = IntelWebAPIs.connection.getConnectionInfo();
              output_status("Wifi connected=" + connInfo.wifi.connected);
              output_status("Wifi signal strength=" + connInfo.wifi.signalStrength);
            },1000);
          }
          else {
            //check other result properties and handle error condition
            output_status("IntelWebAPIs error: " + result.installInfo.msg);
          }
        }
        
        //called by IntelWebAPIs.require()
        function require_progress_func(statusMsg){
          //statusMsg is a string - send this wherever
          output_status("IntelWebAPIs connector status: " + statusMsg);
        }
      
      });
      
      /* Its recommended that you wait until the document is loaded 
         before calling IntelWebAPIs.init() and IntelWebAPIs.require() 
         This utility helps with that...*/
      function add_onload_handler(addfunc, altwindow) {
        var targwindow = window;
        if(typeof(altwindow) != 'undefined'){
          targwindow = altwindow;
        }
        
        /* chain the onload functions together */
        var prevf = targwindow.onload;
        var newf  = addfunc;
        targwindow.onload = function(){
            newf();
            if(typeof(prevf) == 'function'){
              prevf();
            }
          };
      }
      
      /* utility that outputs status messages to a div*/
      function output_status(str) {
        var divout = document.getElementById("IntelWebAPIs_sample_code_status_div");
        divout.innerHTML += str + "&lt;br/&gt;";
        divout.scrollTop = divout.scrollHeight;
      }
    })(); // end of outer closure
  &lt;/script&gt;
</pre>
<br/>
<p>
  This is the result Object that is passed into init_result_func(result).<br/>
  If the Intel Web API Connector is not yet installed on a user's device you can
  use the result.connectorInstUrl to prompt the user, in the context of your
  app, to install it.<br/> 
  Once the Intel Web API Connector is installed other apis are installed by the
  connector, with minimal user interruption, when your app calls IntelWebAPIs.require().
</p>

<pre >
  result = { 
    success           : boolean,
    
    // these fields are valid if success != true
    connectorInstUrl  : string 
    error             : {
      msg             : string 
    } 
  }
</pre>
<br/>
This is the result Object that is passed into require_completion_func(result).<br/><br/>
<pre >
  result = { 
    success       : boolean,
    
    installInfo   : {
      msg         : string,
      
      plugins     : [ { 
        name      : string,
        installed : boolean,
        details   : string
        }, 
        //...
      ], 
    }
  }  
</pre>
</div>

<br/>
<div >
<a name="JavaScript API Details">JavaScript API Details</a>
</div>
<div >
These are the properties and functions exposed by the Connection Web API:<br/><br/>
<pre >
  IntelWebAPIs.connection = {
    'version'             : string,
    'connected'           : boolean,
    'getConnectionInfo'   : function
  };
</pre>
<br/>
<div >
<a name="IntelWebAPIs.connection.version">IntelWebAPIs.connection.version</a>
</div>
<div>
This is the API's version string. It is formatted as "major.minor.patch" where major
and minor are numbers and patch is a string.
</div>
<br/>
<div >
<a name="IntelWebAPIs.connection.connected">IntelWebAPIs.connection.connected</a>
</div>
<div>
The IntelWebAPIs.connection.connected property indicates if the device is connected
to a network or not. true for connected, false otherwise.
</div>
<br/>
<div >
<a name=IntelWebAPIs.connection.getConnectionInfo">IntelWebAPIs.connection.getConnectionInfo()</a>
</div>
<div>
The IntelWebAPIs.connection.getConnectionInfo() function returns an Object with information about
the current connection.<br/>
<pre >
  connectionInfo =  {
    'lan'         : {
      'connected'       : boolean,
      'signalStrength'  : number,     //will be 100 if connected, 0 if not connected
      'linkSpeed'       : number      //kbps in 100bps or 0 if unknown or disconnected
    },
    'wifi'        : {
      'connected'       : boolean
      'signalStrength'  : number,     //RSSI signal strength as a percent or -1 if unknown. 
                                      // signal strength is 0 when disconnected.
      'linkSpeed'       : number      //kbps in 100bps or 0 if unknown or disconnected
    }
  }
</pre>
</div>
<br/><br/>
These JavaScript functions demonstrate accessing the connection information:
<br/><br/>
<pre >
  function output_connected(){
    alert("connected = " + IntelWebAPIs.connection.connected);      
  }
  
  function output_connection_info() {
    var conninfo = IntelWebAPIs.connection.getConnectionInfo();
    alert("lan.connected="        + conninfo['lan']['connected']);  
    alert("lan.signalStrength="   + conninfo['lan']['signalStrength']);
    alert("lan.linkSpeed="        + conninfo['lan']['linkSpeed']);

    alert("wifi.connected="       + conninfo['wifi']['connected']);  
    alert("wifi.signalStrength="  + conninfo['wifi']['signalStrength']);
    alert("wifi.linkSpeed="       + conninfo['wifi']['linkSpeed']);
  }
</pre>
</div>
<br/><br/>
<div >
<a name="See it working" href="http://software.intel.com/sites/whatif/webapis/api/connection">See it working in this page!</a>
</div>
 ]]></description>
      <link>http://software.intel.com/en-us/articles/intel-connection-web-api-documentation-and-examples/</link>
      <pubDate>Wed, 10 Feb 2010 00:00:00 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/intel-connection-web-api-documentation-and-examples/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/intel-connection-web-api-documentation-and-examples/</guid>
      <category>What If Experimental Software</category>
      <category>Code &amp; Downloads</category>
    </item>
    <item>
      <title>CPU / Power / Connection Video Mashup</title>
      <description><![CDATA[ <div >
<a name="Contents">Contents</a>
</div>
<div >
  <ul>
    <li>
      <a href="http://software.intel.com#Overview">Overview</a>
    </li>
    <li>
      <a href="http://software.intel.com/sites/whatif/webapis/mashup/cpcvideo/mashup.html">
        Check out the mashup!</a>
    </li>
  </ul>
</div>
<br/>
<div >
  <a name="Overview">Overview</a>
</div>
<div >
  <p>
    This mashup demonstrates using the Intel CPU/Power/Connection Indicator Widget 
    in a page that includes a video player.
  </p>
  <p>
    The goal of the mashup is to help the user avoid a choppy and/or interrupted viewing
    experience - due to CPU load being too high, too little battery time remaining
    or poor network signal strength.
  </p>
</div>

<br/>
<div >
  <a name="Check out the mashup">Check out the mashup!</a>
</div>
<div >
  <p>
  We put the mashup in its own page to give it a more "realistic" look and feel :)<br/>
  When you go to the page be sure to look at the page source to see how we embedded
  the widget and player. To see other examples of how to embed the CPU Power Connection Indicator
  widget go to the widget's page 
  <a href="http://software.intel.com/sites/whatif/webapis/widget/cpc">here</a>.
  </p>
  <a href="http://software.intel.com/sites/whatif/webapis/mashup/cpcvideo/mashup.html">
    Click here to go to the mashup page</a>
</div>
 ]]></description>
      <link>http://software.intel.com/en-us/articles/cpupowerconnection-video-mashup/</link>
      <pubDate>Wed, 10 Feb 2010 00:00:00 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/cpupowerconnection-video-mashup/#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/cpupowerconnection-video-mashup/</guid>
      <category>What If Experimental Software</category>
    </item>
  </channel></rss>
