search
Log In

Recent questions tagged runtime-environments

37 votes
4 answers
1
Which of the following is NOT an advantage of using shared, dynamically linked libraries as opposed to using statistically linked libraries? Smaller sizes of executable files Lesser overall page fault rate in the system Faster program startup Existing programs need not be re-linked to take advantage of newer versions of libraries
asked Sep 17, 2014 in Compiler Design Kathleen 6.1k views
26 votes
5 answers
2
The following program fragment is written in a programming language that allows global variables and does not allow nested declarations of functions. global int i=100, j=5; void P(x) { int i=10; print(x+10); i=200; j=20; print (x); } main() {P(i+j);} If the ... and call by need parameter passing mechanism, the values printed by the above program are: $115, 220$ $25, 220$ $25, 15$ $115, 105$
asked Sep 17, 2014 in Programming Kathleen 3.3k views
24 votes
4 answers
3
Dynamic linking can cause security concerns because Security is dynamic The path for searching dynamic libraries is not known till runtime Linking is insecure Cryptographic procedures are not available for dynamic linking
asked Sep 16, 2014 in Operating System Kathleen 2.6k views
17 votes
3 answers
4
What is printed by the print statements in the program $P1$ assuming call by reference parameter passing? Program P1() { x = 10; y = 3; func1(y,x,x); print x; print y; } func1(x,y,z) { y = y + 4; z = x + y + z } $\text{10, 3}$ $\text{31, 3}$ $\text{27, 7}$ None of the above
asked Sep 15, 2014 in Programming Kathleen 3.9k views
28 votes
2 answers
5
The process of assigning load addresses to the various parts of the program and adjusting the code and the data in the program to reflect the assigned addresses is called Assembly parsing Relocation Symbol resolution
asked Sep 14, 2014 in Compiler Design Kathleen 4.2k views
28 votes
6 answers
6
Suppose a processor does not have any stack pointer registers, which of the following statements is true? It cannot have subroutine call instruction It cannot have nested subroutines call Interrupts are not possible All subroutine calls and interrupts are possible
asked Sep 14, 2014 in CO and Architecture Kathleen 6k views
22 votes
3 answers
7
Consider the following pseudo-code (all data items are of type integer): procedure P(a, b, c); a := 2; c := a + b; end {P} begin x := 1; y := 5; z := 100; P(x, x*y, z); Write ('x = ', x, 'z = ', z); end Determine its output, if the parameters are passed to the Procedure P by value reference name
asked Sep 13, 2014 in Compiler Design Kathleen 1.3k views
21 votes
1 answer
8
29 votes
7 answers
9
Which of the following are true? A programming language which does not permit global variables of any kind and has no nesting of procedures/functions, but permits recursion can be implemented with static storage allocation Multi-level access link (or display) arrangement is needed to arrange ... scheme for activation records II and V only I, III and IV only I, II and V only II, III and V only
asked Sep 12, 2014 in Compiler Design Kathleen 5.1k views
27 votes
3 answers
10
The use of multiple register windows with overlap causes a reduction in the number of memory accesses for: Function locals and parameters Register saves and restores Instruction fetches $I$ only $II$ only $III$ only $I$, $II$ and $III$
asked Sep 12, 2014 in CO and Architecture Kathleen 8k views
48 votes
1 answer
11
What is the return value of $f(p,p)$, if the value of $p$ is initialized to $5$ before the call? Note that the first parameter is passed by reference, whereas the second parameter is passed by value. int f (int &x, int c) { c = c - 1; if (c==0) return 1; x = x + 1; return f(x,c) * x; }
asked Aug 7, 2014 in Programming gatecse 7.3k views
...