Using OpenCL to accelerate high-performance computing in web browsers

Source: Internet
Author: User
Keywords Web browser OpenCL
Tags adobe application applications browser browsers click computer computing

Because the image processor (GPU) has a highly parallel infrastructure, it can perform some type of application faster than traditional central processing units (CPUs). The Open Computing Language (OPENCL) is one of the most popular languages to harness the power of the GPU. A typical example is Adobe®premiere®pro CS6, which accelerates the processing of images and video by performing OpenCL routines on the user's GPU.

Many companies believe that GPU acceleration is a big help for browser-based applications, and a team has been set up to promote the technology. In May 2012, the Working group published the first draft of the Web Computing Language (WEBCL). As its home page describes, the WEBCL workgroup is designed to "support Web applications that harness GPU and multi-core CPU processing in web browsers."

Two companies have released related extensions that support the call to WEBCL functionality from within the browser. Samsung has released a WebKit-oriented WEBCL extension, an engine that provides powerful functionality for Apple Safari browsers on Mac OS X. Nokia has released a Mozilla Firefox WEBCL plug-in to run on Windows® and 32-bit linux® operating systems. Because of its extensive developer base, this article will focus on the implementation of Nokia. This article will explain how to install WEBCL and also introduce the basics of WEBCL encoding. Then demonstrate how to use WEBCL to search the entire text at a high speed.

Install WEBCL

The WEBCL application requires three components: the OPENCL Software Development Kit (SDK), the Firefox browser, and the Nokia Firefox plugin.

Get OpenCL SDK

The WEBCL application invokes the OpenCL feature on the host. Therefore, you must install OpenCL before running the WEBCL application. The OpenCL Development Toolkit is device-and OS-specific, so to run the routine on a Windows computer with an Nvidia GPU, you need to install an Nvidia OpenCL SDK for Windows. Although it is not possible to provide a guide for all OpenCL SDK installations, this article can point you in the right direction:

The AMD Accelerated Parallel 處理 (APP) SDK needs to be downloaded by executing routines on the AMD CPU or GPU. Executing routines on the NVIDIA GPU requires downloading the nvidia GPU Computing SDK. Executing routines on Intel CPUs requires downloading the Intel SDK for OpenCL.

You can install multiple OpenCL SDK on a single computer without conflicts.

Install WEBCL on Firefox

After the OpenCL SDK is installed, the installation WEBCL is very simple, as shown in the following steps:

Download Firefox from the Mozilla website. In Firefox, login to Nokia's WEBCL website. Click the Nokia WEBCL expansion pack. If necessary, support the download support Firefox expansion pack (a *.xpi file). In the Software Installation dialog box, click Install Now, and then restart the browser. To test the installation, please login to Nokia's WEBCL website and choose click here to check this have WEBCL enabled (click here to see if you support WEBCL).

If it appears to be a dialog box, excellent! Your system does support WEBCL (very good!) Your system supports WEBCL), it means that WEBCL was installed successfully. If the dialog box shows that unfortunately your system does not support WEBCL (sorry that your system does not support WEBCL), you may need to reinstall the expansion pack or access WEBCL on another computer.

Writing WEBCL applications

WEBCL technology is a mystery to novices, so it's important to keep the following goals in mind:

Submit a function to the device. Executes functions on the device. Transfer output from device to host

Figure 1 shows this process.

Figure 1. WEBCL Application Operations

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.