Unit-1 & Ii GCC
Unit-1 & Ii GCC
Unit-1 & Ii GCC
Parallel Computing
Advantage:
Distributed Computing
It is collection of autonomous computes linked by a computer network and equipped with distributed
system software.
The software enables computes to coordinate their activites and share resource of system ,hardware ,software
and data.
Characteristic of Distributed System.
1.Resource sharing
2.Portable.
3.Concurrency
4.scalability
5.fault tolerance
6.Transperancy
Communication The processors The computer systems connect with one another
communicate with one via a network.
another via a bus.
Memory The system may have Each computer system in distributed computing
distributed or shared has its own memory.
memory.
Usage It helps to improve the It allows for scalability, resource sharing, and the
system performance efficient completion of computation tasks.
• Peer to Peer Systems: As nodes are an important part of a system. In this, each node performs their own
task on their local memory and share data through the supporting medium, this node can work as a server
or as a client for a system.
• Middleware: It works as a base for different interoperability applications running on different operating
systems. Data can be transferred to other between others by using this service.
• Three-tier: In this data of the client is stored in the middle tier rather than sorting into the client system
or on their server through which development can be done easily. This is mostly used in web or online
applications.
• N-tier: When interoperability sends the request to another application to perform a task or to provide a
service.
A distributed system is also known as distributed computer science and distributed databases; independent
components that interact with other different machines that exchange messages to achieve common goals. As such,
the distributed system appears to the end-user like an interface or a computer. Together the system can maximize
resources and information while preventing system failure and did not affect service availability.
This distributed system is used in performance computation which requires high computing.
• Cluster Computing: A collection of connected computers that work together as a unit to perform
operations together, functioning in a single system. Clusters are generally connected quickly via local
area networks & each node is running the same operating system.
When input comes from a client to the main computer, the master CPU divides the task into simple jobs and send it
to slaves note to do it when the jobs are done by the slave nodes, they send back to the master node, and then it
shows the result to the main computer.
Advantages:
• High Performance
• Easy to manage
• Scalable
• Expandability
• Availability
• Flexibility
Disadvantages:
• High cost
• The problem in finding fault
• More space is needed
Applications of Cluster Computing:
• In many web applications functionalities such as Security, Search Engines, Database servers, web
servers, proxy, and email.
• It is flexible to allocate works as small data tasks for processing.
• Assist and help to solve complex computational problems
• Cluster computing can be used in weather modeling
• Earthquake, Nuclear, Simulation, and tornado forecast
Grid computing: In grid computing, the subgroup consists of distributed systems, which are often set up as a
network of computer systems, each system can belong to a different administrative domain and can differ greatly in
terms of hardware, software, and implementation network technology.
The different department has a different computer with different OS to mage the control node is present which help
different computer with different OS to communicate with each other and transfer messages to work.
Advantages:
• Can solve bigger and more complex problems in a shorter time frame. Easier collaboration with other
organizations and better use of existing equipment
Disadvantages:
• Grid software and standards continue to evolve
• Getting started learning curve
• Non-interactive job submission
• You may need a fast connection between computer resources.
• Licensing on many servers can be prohibitive for some applications.
Applications of Grid Computing
• Organizations that develop grid standards and practices for the guild line.
• Works as a middleware solution for connecting different businesses.
• It is a solution-based solution that can meet computing, data, and network needs.
S.No. CLOUD COMPUTING DISTRIBUTED COMPUTING
In cloud computing, the users pay While in grid computing, the users do not
5. for the use. pay for use.
Over the past 60 years, computing technology has undergone a series of platform and environment changes. Evolutionary
changes in machine include architecture, operating system platform, network connectivity, and application workload. Instead
of using a centralized computer to solve computational problems, a parallel and distributed computing system uses multiple
computers to solve large-scale problems over the Internet. Thus, distributed computing becomes data-intensive and network-
centric.
• The development of market-oriented high-end computing systems is undergoing a strategic change from an HPC
paradigm to an HTC paradigm.
• The main application for high-flux computing is in Internet searches and web services by millions or more users
simultaneously.
• The performance goal thus shifts to measure high throughput or the number of tasks completed per unit of time.
• HTC technology needs to not only improve in terms of batch processing speed, but also address the acute problems
of cost, energy savings, security, and reliability at many data and enterprise computing centers.
Three New Computing Paradigms:
• The maturity of radio-frequency identification (RFID), Global Positioning System (GPS), and sensor technologies
has triggered the development of the Internet of Things (IoT).
Computing Paradigm Distinctions:
The following list defines these terms more clearly; their architectural and operational differences are discussed
further in subsequent chapters.
• Centralized computing: This is a computing paradigm by which all computer resources are centralized in one
physical system. All resources (processors, memory, and storage) are fully shared and tightly coupled within one
integrated OS. Many data centers and supercomputers are centralized systems, but they are used in parallel,
distributed, and cloud computing applications.
• Parallel computing: In parallel computing, all processors are either tightly coupled with centralized shared memory
or loosely coupled with distributed memory. Some authors refer to this discipline as parallel processing. Inter
processor communication is accomplished through shared memory or via message passing
• Distributed computing: A distributed system consists of multiple autonomous computers, each having its own
private memory, communicating through a computer network. Information exchange in a distributed system is
accomplished through message passing. A computer program that runs in a distributed system is known as a
distributed program. The process of writing distributed programs is referred to as distributed programming.
• Cloud computing An Internet cloud of resources can be either a centralized or a distributed computing system. The
cloud applies parallel or distributed computing, or both. Clouds can be built with physical or virtualized resources
over large data centers that are centralized or distributed. Some authors consider cloud computing to be a form of
utility computing or service computing.
• Distributed system families ---The system efficiency is decided by speed, programming, and energy factors (i.e.,
throughput per watt of energy consumed). Meeting these goals requires yielding the following design objectives:
• Efficiency
• Dependability.
• Adaptation in the programming model
• Flexibility in application deployment
2.2 Scalable computing trends and new paradigms
Degrees of Parallelism
• Bit-level parallelism (BLP) converts bit-serial processing to word-level processing gradually. Over the years, users
graduated from 4-bit microprocessors to 8-, 16-, 32-, and 64-bit CPUs.
• Instruction-level parallelism (ILP), in which the processor executes multiple instructions simultaneously rather
than only one instruction at a time. For the past 30 years, ILP practiced through pipelining, super-scalar computing,
VLIW (very long instruction word) architectures, and multithreading. ILP requires branch prediction, dynamic
scheduling, speculation, and compiler support to work efficiently.
• Data-level parallelism (DLP) was made popular through SIMD (single instruction, multiple• data) and vector
machines using vector or array types of instructions.
Innovative Applications
Both HPC and HTC systems desire transparency in many application aspects.
• For example, data access, resource allocation, process location, concurrency in execution, job replication, and failure
recovery should be made transparent to both users and system management.
• Users must deal with multiple database servers in distributed transactions. Maintaining the consistency of replicated
transaction records is crucial in real-time banking services.
• Other complications include lack of software support, network saturation, and security threats in these applications.
Multithreading Technology
The dispatch of five independent threads of instructions to four pipelined datapaths (functional units) in each
of the following five processor categories from left to right: a
➢ The superscalar processor is single-threaded with four functional units. Each of the three
multithreaded processors is four-way multithreaded over four functional data paths.
➢ In the dual-core processor, assume two processing cores, each a single-threaded two-way
superscalar processor. Instructions from different threads are distinguished by specific shading
patterns for instructions from five independent threads.
➢ Fine-grain multithreading switches the execution of instructions from different threads per
cycle.
➢ Course-grain multi-threading executes many instructions from the same thread for quite a few
cycles before switching to another thread.
➢ The multicore CMP executes instructions from different threads completely. These execution
patterns closely mimic an ordinary program.
➢ The blank squares correspond to no available instructions for an instruction data path at a
particular processor cycle.
2) GPU computing to exascale and beyond
➢ A GPU is a graphics coprocessor or accelerator mounted on a computer’s graphics card or
video card.
➢ A GPU offloads the CPU from tedious graphics tasks in video editing applications.
➢ The world’s first GPU, the GeForce 256, was marketed by NVIDIA in 1999.
➢ These GPU chips can process a minimum of 10 million polygons per second.
➢ Traditional CPUs are structured with only a few cores.
➢ For example, the Xeon X5670 CPU has six cores., a modern GPU chip can be built with
hundreds of processing cores.
➢ GPUs have a throughput architecture that exploits massive parallelism by executing many
concurrent threads slowly, instead of executing a single long thread in a conventional
microprocessor very quickly.
➢ General-purpose computing on GPUs , known as GPGPUs, have appeared in the HPC field.
NVIDIA’s CUDA model was for HPC using GPGPU.
System-Area Interconnects:
The nodes in small clusters are mostly interconnected by an Ethernet switch or a local area
network( LAN). As Figure 1(B) shows, a LAN typically is used to connect client hosts to big servers.
A storage area network (SAN) connects servers to network storage such as disk arrays. Network attached
storage(NAS) connects client hosts directly to the disk arrays. All three types of networks often appear in
a large cluster built with commercial network components. If no large distributed storage is shared, a
small cluster could be built with a multiport Gigabit Ethernet switch plus copper cables to link the end
machines.
➢ The host machine is equipped with the physical hardware.The VM can be provisioned for any hardware
system.
➢ The VM is built with virtual resources managed by a guest OS to run a specific application. Between the
VMs and the host platform, one needs to deploy a middleware layer called a virtual machine monitor
(VMM).).
➢ A native VM installed with the use of a VMM called a hypervisor in privi-leged mode. For example, the
hardware has x-86 architecture running the Windows system.
VM PRIMITIVE OPERATIONS:
With full virtualization, the VMM exports a VM abstraction identical to the physical
machine so that a standard OS such a Windows 2000 or Linux can run as it would on the physical hardware.
➢ First, the VMs can be multiplexed between hardware machines.
➢ Second, a VM can be suspended and stored in stable suspension.
➢ Third, a suspended VM can be resumed or provisioned to a new hardware platform. Finally, a
VM can be migrated from one hardware platform to another.
5) DATA CENTER VIRTUALIZATION FOR CLOUD COMPUTING
Single-System Image
An ideal cluster should merge multiple system images into a single-system image (SSI). Cluster designers
desire a cluster operating system or some middleware to support SSI at various levels, including the
sharing of CPUs, memory, and I/O across all cluster nodes. An SSI is an illusion created by software or
hardware that presents a collection of resources as one integrated, powerful resource.SSI makes the
cluster appear like a single machine to the user. A cluster with multiple system images is nothing but a
collection of independent computers.
GRID COMPUTING INFRASTRUCTURES
Part B→Describe the Infrastructure requirements for grid Computing (AU/Nov/Dec 2017)
➢ Users have experienced a natural growth path from Internet to web and grid computing services.
Internet services such as the Telnet command enables a local computer to connect to a remotecomputer.
Web service such as HTTP enables remote access of remote web pages.
➢ Grid computing is envisioned to allow close interaction among applications running on distant
computers simultaneously.
Computational Grids
➢ Like an electric utility power grid, a computing grid offers an infrastructure that couples computers,
software/middleware, special instruments, and people and sensors together.
➢ The grid is often constructed across LAN, WAN, or Internet backbone networks at a regional,
national, or global scale Enterprises or organizations present grids as integrated computing
resources.
➢ They can also be viewed as virtual platforms to support virtual organizations. The computers used
in a grid are primarily workstations, servers, clusters, and supercomputers. Personal computers,
laptops, and PDAs can be used as access devices to a grid system
Grid Families
➢ Grid technology demands new distributed computing models, software/middleware support,
network protocols, and hardware infrastructures.
➢ National grid projects are followed by industrial grid platform development by IBM, Microsoft,
Sun, HP, Dell, Cisco, EMC, Platform Computing, and others.
➢ New grid service providers (GSPs) and new grid applications have emerged rapidly, similar to the
growth of Internet and web services in the past two decades.
The traditional systems have encountered several performance bottlenecks: constant system maintenance,
poor utilization, and increasing costs associated with hardware/software upgrades.
Cloud computing as an on-demand computing paradigm resolves or relieves us from these problems.
Grid Vs Cloud
➢ In general, a grid system applies static resources, while a cloud emphasizes elastic resources.
➢ For some researchers, the differences between grids and clouds are limited only in dynamic
resource allocation based on virtualization and autonomic computing. One can build a grid out of
multiple clouds.
➢ This type of grid can do a better job than a pure cloud, because it can explicitly supportnegotiated
resource allocation.
➢ Thus one may end up building with a system of systems: such as a cloud of clouds, a grid of clouds,
or a cloud of grids, or inter-clouds as a basic SOA architecture.
ELEMENTS OF GRID:
Grid computing combines elements such as distributed computing, high-performance computing and disposable
computing depending on the application of the technology and the scale of operation. Grids can create a virtual
supercomputer out of the existing servers, workstations and personal computers.
Present-day grids encompass the following types
• Computational grids, in which machines will set aside resources to “number crunch” data or providecoverage
for other intensive workloads
• Scavenging grids, commonly used to find and harvest machine cycles from idle servers and desktopcomputers
for use in resource-intensive tasks (scavenging is usually implemented in a way that isunobtrusive to the
owner/user of the processor)
• Data grids, which provide a unified interface for all data repositories in an organization, and through which
data can be queried, managed and secured.
• Market-oriented grids, which deal with price setting and negotiation, grid economy management and utility
driven scheduling and resource allocation.
The architecture of a grid system is often described in terms of “layers”, each providing a specific function as
shown in the following figure. Higher layers are user centric, whereas the lower layers are hardware-centric. In
Figure 1 a generic grid architecture showing the functionality of each layer.
NETWORK LAYER: It is the bottom layer
which assures the connectivity for the
resources in the grid.
RESOURCE LAYER: It is made up of
actual resources that are part of the grid, such
as computers, storage systems, electronic data
catalogues, and even sensors such as
telescopes or other instruments, which can be
connected directly to the network.
MIDDLEWARE LAYER: It provides the
tools that enable various elements (servers,
storage, networks, etc.) to participate in a
unified grid environment.
APPLICATION LAYER: In which includes
different user applications (science,
engineering, business, financial), portal and
development toolkits-supporting applications.
➢ Storage virtualization
➢ Server virtualization
➢ Operating system-level virtualization
➢ Network virtualization:
➢ Application virtualization
Server virtualization - Server virtualization is the partitioning of a physical server into smaller virtual
servers to help maximize your server resources. In server virtualization the resources of the server
itself are hidden, or masked, from users, and software is used to divide the physical server into
multiple virtual environments, called virtual or private servers.
LEVELS OF VIRTUALIZATION
➢ A traditional computer runs with a host operating system specially tailored for its hardware
architecture, as shown in Figure 1(a).
➢ After virtualization, different user applications managed by their own operating systems
(guest OS) can run on the same hardware, independent of the host OS. This is often done by
adding additional software, called a virtualization layer as shown in Figure 1(b).
➢ This virtualization layer is known as hypervisor or virtual machine monitor (VMM). The
VMs are shown in the upper boxes, where applications run with their own guest OS over
the virtualized CPU, memory, and I/O resources.
➢ The main function of the software layer for virtualization is to virtualize the physical
hardware of a host machine into virtual resources to be used by the VMs, exclusively.
➢ This can be implemented at various operational levels, as we will discuss shortly.
➢ The virtualization software creates the abstraction of VMs by interposing a virtualization
layer at various levels of a computer system. Common virtualization layers include the
instruction set architecture (ISA) level, hardware level, operating system level, library support
level, and application level.
Figure 2: Virtualization ranging from hardware to applications in five abstraction levels.
User-Application Level
➢ Virtualization at the application level virtualizes an application as a VM. On a traditionalOS, an
application often runs as a process. Therefore, application-level virtualization isalso known as
process-level virtualization. The most popular approach is to deploy highlevel language (HLL)
VMs.
➢ In this scenario, the virtualization layer sits as an application program on top of the operating
system, and the layer exports an abstraction of a VMthat can run programs written and compiled to
a particular abstract machine definition.
➢ Any program written in the HLL and compiled for this VM will be able to run on it.
➢ The result is an application that is much easier to distribute and remove from user workstations.
➢ An example is the LANDesk application virtualization platform which deploys software
applications as self-contained, executable files in an isolated environment without requiring
installation, system modifications, or elevated security privileges.
Relative Merits of Virtualization at Various Levels (More “X”’s Means Higher Merit,
With a Maximum of 5 X’s)
Advantages of OS Extensions
➢ Compared to hardware-level virtualization, the benefits of OS extensions are twofold:
➢ These benefits can be achieved via two mechanisms of OS-level virtualization:
➢ All OS-level VMs on the same physical machine share a single operating system kernel; and (2)
the virtualization layer can be designed in a way that allows processes in VMs to access as many
resources of the host machine as possible, but never to modify them.
Disadvantages of OS Extensions
➢ The main disadvantage of OS extensions is that all the VMs at operating system level on a single
container must have the same kind of guest operating system.
➢ For example, a Windows distribution such as Windows XP cannot run on a Linux-based
container.
➢ Some prefer Windows and others prefer Linux or other operating systems.
Part –B 1. Discuss how virtualization is implemented in CPU, Memory and I/O Devices.
➢ To support virtualization, processors such as the x86 employ a special running mode and
instructions, known as hardware-assisted virtualization.
➢ In this way, the VMM and guest OS run in different modes and all sensitive instructions of the
guest OS and its applications are trapped in the VMM.
➢ To save processor states, mode switching is completed by hardware. For the x86 architecture,
Intel and AMD have proprietary technologies for hardware-assisted virtualization.
SOFTWARE:
➢ The VMware Workstation is a VM suite for x86 and x86-64 computers.
➢ This software suite allows users to set up multiple x86 and x86-64 virtual computers and to use
one or more of these VMs simultaneously with the host operating system.
➢ The VMware Workstation assumes the host-based virtualization.
➢ Xen is a hypervisor for use in IA-32,x86-64, Itanium, and PowerPC 970 hosts.
➢ Actually, Xen modifies Linux as the lowest and most privileged layer, or a hypervisor.
➢ One or more guest OS can run on top of the hypervisor.
➢ KVM (Kernel-based Virtual Machine) is a Linux kernel virtualization infrastructure. KVM can
support hardware assisted virtualization and para virtualization by using the Intel VT-x or AMD-
v and Virtual IO framework, respectively.
➢ The Virtual IO framework includes a para virtual Ethernet card, a disk I/O controller, a balloon
device for adjusting guest memory usage, and a VGA graphics interface using VMware drivers.
➢ This technique attempts to simplify virtualization because full or para virtualization is complicated.
➢ Intel and AMD add an additional mode called privilege mode level to x86 processors.
➢ Therefore, operating systems can still run at Ring0 and the hypervisor can run at Ring -1. All the
privileged and sensitive instructions are trapped in the hypervisor automatically. This technique
removes the difficulty of implementing binary translation of full virtualization. It also lets the
operating system run in VMs without modification.
➢ Virtual memory virtualization is similar to the virtual memory support provided by modern
operating systems.
➢ In a traditional execution environment, the operating system maintains mappings of virtualmemory
to machine memory using page tables, which is a one-stage mapping from virtual memory to
machine memory.
➢ All modern x86 CPUs include a memory management unit (MMU) and a translation look aside
buffer (TLB) to optimize virtual memory performance.
➢ However, in a virtual execution environment, virtual memory virtualization involves sharing the
physical system memory in RAM and dynamically allocating it to the physical memory of the VMs.
➢ That means a two-stage mapping process should be maintained by the guest OS and the VMM,
respectively: virtual memory to physical memory and physical memory to machine memory.
➢ MMU virtualization should be supported, which is transparent to the guest OS. The guest OS
continues to control the mapping of virtual addresses to the physical memory addresses of VMs.
➢ But the guest OS cannot directly access the actual machine memory. The VMM is responsible for
mapping the guest physical memory to the actual machine memory.
➢ Since each page table of the guest OSes has a separate page table in the VMM corresponding to
it, the VMM page table is called the shadow page table.
➢ Nested page tables add another layer of indirection to virtual memory. The MMU already handles
virtual-to-physical translations as defined by the OS.
➢ Then the physical memory addresses are translated to machine addresses using another set of
page tables defined by the hypervisor.
➢ VMware uses shadow page tables to perform virtual-memory-to-machine-memory address
translation. Processors use TLB hardware to map the virtual memory directly to the machine
memory to avoid the two levels of translation on every access.
➢ When the guest OS changes the virtual memory to a physical memory mapping, the VMM updates
the shadow page tables to enable a direct lookup.
➢ The AMD Barcelona processor has featured hardware-assisted memory virtualization since 2007.
➢ It provides hardware assistance to the two-stage address translation in a virtual execution
environment by using a technology called nested paging.