Clear my choice Which of the following statements related to OpenCL image processing is/are TRUE? 1. Image objects can be accessed the same way as buffer objects 2. An image object can only have read or write access 3. Sampler objects can be initialised in the host and passed as a kernel argument Select one: a. 1 only b. 1 and 3 c. 2 only d. 2 and 3 e. 1 and 2 Clear my choice Given the following kernel: _kernel void s(_global uchar4* arr) { uchar8 mask = (uchar8) (2, 3, 5, 5, 7, 1, 6, 4); uchar8 vec = shuffle2(arr[1], arr[0], mask); } If arr contains ('b', 'z; 'w', 'e', 'k 'n'; 't), what will the contents of vec be? Select one: a. None of the choices are correct b. ('w', 'e', 'k', 'k; ;k; 'n'; 't) c. ('n'; 't', 'z', 'z', 'e', 'k', 'w', 'b') d. ('z, w, , , , 'b', 'k', 'e') e. ('w', 'e', 'k', 'k; 't; 'z; 'n'; ') Clear my choice

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

please answer the question 2 and 3 (prior 3)

Given the following snippet of kernel code:
int i = 0;
while(any (x>2))
{
}
X>>=1;
i++;
If x is of type int4 and originally contained (1, 3, 5, 7), what will the final value of i be?
Select one:
a. 0
b. 3
c. 4
d. 2
e. 1
Clear my choice
Which of the following statements related to OpenCL image processing is/are TRUE?
1. Image objects can be accessed the same way as buffer objects
2. An image object can only have read or write access
3. Sampler objects can be initialised in the host and passed as a kernel argument
Select one:
a. 1 only
b. 1 and 3
c. 2 only
d. 2 and 3
e. 1 and 2
Clear my choice
Given the following kernel:
}
_kernel void s(_global uchar4* arr)
{
uchar8 mask = (uchar8) (2, 3, 5, 5, 7, 1, 6, 4);
uchar8 vec = shuffle2(arr[1], arr[0], mask);
If arr contains ('b', 'z', 'w', 'e', 'i', 'k', 'n', 't'), what will the contents of vec be?
Select one:
a. None of the choices are correct
b. ('w', 'e', 'k', 'k', 'i', 'k', 'n'; 't')
c. ('n'; 't', 'z', 'z', 'e', 'k', 'w', 'b')
d. ('z; 'w, , , 'n', 'b', 'k', 'e')
e. ('w', 'e', 'k', 'k 't', 'z; 'n'; 'i')
Clear my choice
Transcribed Image Text:Given the following snippet of kernel code: int i = 0; while(any (x>2)) { } X>>=1; i++; If x is of type int4 and originally contained (1, 3, 5, 7), what will the final value of i be? Select one: a. 0 b. 3 c. 4 d. 2 e. 1 Clear my choice Which of the following statements related to OpenCL image processing is/are TRUE? 1. Image objects can be accessed the same way as buffer objects 2. An image object can only have read or write access 3. Sampler objects can be initialised in the host and passed as a kernel argument Select one: a. 1 only b. 1 and 3 c. 2 only d. 2 and 3 e. 1 and 2 Clear my choice Given the following kernel: } _kernel void s(_global uchar4* arr) { uchar8 mask = (uchar8) (2, 3, 5, 5, 7, 1, 6, 4); uchar8 vec = shuffle2(arr[1], arr[0], mask); If arr contains ('b', 'z', 'w', 'e', 'i', 'k', 'n', 't'), what will the contents of vec be? Select one: a. None of the choices are correct b. ('w', 'e', 'k', 'k', 'i', 'k', 'n'; 't') c. ('n'; 't', 'z', 'z', 'e', 'k', 'w', 'b') d. ('z; 'w, , , 'n', 'b', 'k', 'e') e. ('w', 'e', 'k', 'k 't', 'z; 'n'; 'i') Clear my choice
Expert Solution
steps

Step by step

Solved in 4 steps

Blurred answer
Knowledge Booster
Processes of 3D Graphics
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education