Intrinsic functions, Computer Networking

Assignment Help:

Intrinsic Functions

HPF introduces some new intrinsic functions in addition to those defined in F90. The two most regularly used in parallel programming are the system inquiry functions PROCESSORS_SHAPE and NUMBER_OF_PROCESSORS  . These functions gives the information about the number of physical processors on which the running program implements and processor configuration. General syntax of is

NUMBER_OF_PROCESSORS is

NUMBER_OF_PROCESSORS (dim)

where dim is an optional argument. It returns the number of processors in the underlying array or, if the optional argument is present, the size of this array along a shows dimension.

General syntax of  PROCESSORS_SHAPE is

PROCESSORS_SHAPE()

It returns an one-dimensional array, whose  ith element provides the size of the underlying processor array in its ith dimension.

 Example 10

Consider the call of the two intrinsic functions discussed above for a 32-Processor (4×8) Multicomputer:

The function call NUMBER_OF_PROCESORS () will return 32. The function call NUMBER_OF_PROCESORS (1) will return 4. The function call NUMBER_OF_PROCESORS (2) will return 8.

The function call PROCESSORS_SHAPE () will return an array with two elements 4 and 8.

We can use these intrinsic functions in tandem with array declarations and HPF directives, to give flexibility to the programmer to declare abstract processor arrays that match available physical resources. For example, the following statement! HPF$ PROCESSORS P(NUMBER_OF_PROCESSORS()) declares an abstract processor array P with size equivalent to the number of physical processors.


Related Discussions:- Intrinsic functions

Disadvantages of fiber optics, Disadvantages of Fiber Optics - Install...

Disadvantages of Fiber Optics - Installation/maintenance - Unidirectional - Cost

Program for two library methods with thread , #include void subdomain(...

#include void subdomain(float x[ ], int istart, int ipoints) { int i; for (i = 0; i x[istart+i] = 123.456; } void sub(float x[ 10000], int npoints) {

Parallel random access machines, PRAM is one of the models used for designi...

PRAM is one of the models used for designing the parallel algorithm as given in Figure. The PRAM models have the following components: A set of identical type of processors

Protocol will send a message to routers, Which protocol will send a message...

Which protocol will send a message to routers if a network outage or congestion happen Ans) Internet Control Message Protocol - ICMP will send a message to routers if a network

What are the security models by giving striking analogies, Security models ...

Security models by giving striking analogies to the real world A classical case study: (With due acknowledgements to the security exponent who proposed this theory.) He has c

Illustrate addressing, Addressing Complicated addressing scheme because...

Addressing Complicated addressing scheme because there may be intermediate stations (APs), identified by flags

Merits of shared memory and drawbacks, Merits of Shared Memory Programming ...

Merits of Shared Memory Programming Global address space gives a user-friendly programming perspective to memory. Data sharing among processes is both fast and uniform

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd