1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Leya [2.2K]
3 years ago
11

Consider an allocator on a 32-bit system that uses an implicit free list. Each memory block, either allocated or free, has a siz

e that is a multiple of four bytes. Thus, only the 30 higher order bits in the header and footer are needed to record block size, which includes the header and footer and is represented in units of bytes. The usage of the remaining 2 lower order bits is as follows: bit 0 indicates the use of the current block: 1 for allocated, 0 for free. bit 1 indicates the use of the previous adjacent block: 1 for allocated, 0 for free Below is a helper routine defined to facilitate the implementation of free (void *P). Which option, if any, will complete the routine so that it performs the function properly?\
Note: "size" in the answers indicates the size of the entire block /* given a pointer to a valid block header or footer, returns the size of the block */
int size(void *hp)
{
int result;
__________;
return result;
}
1. result=(*(int *)hp)&(-7)
2. result=((*(char *)hp)&(-5))<<2
3. result=(*(int *)hp)&(-3)
4. result=(*hp)&(-7)
5. None of these
Computers and Technology
1 answer:
AveGali [126]3 years ago
6 0

Answer:

result=(*(int *)hp)&(-3)

Explanation:

The result above would release the pointer or address of the integer data type with 3 memory blocks needed by the allocator.

You might be interested in
Frank - as the Scrum Master of a Scrum Team - is invited for a Daily Scrum meeting at 9am. The teamgets together in front of the
Bezzdna [24]

The thing that Frank should do according to the options given is to Wait until the discussion is over.

<h3>What is a Scrum Master do?</h3>

A Scrum master is known to be a person who is said to often leads a team in course of a project through the use of Agile project management techniques.

Note that in the above scenario, Frank should wait until the discussion is over and then give a note of warning to the employee at fault.

See options below

What should Frank do?

A) Wait until the discussion is over.

B) Interrupt the discussion and organize a follow-up meeting directly after the Daily Scrum meeting.

C) Stop the discussion. The team member who started working on this particular task is responsible and he decides what and how to do with this.

All of the above

None of the above

Learn more about Scrum Master from

brainly.com/question/4763588

7 0
2 years ago
In IDLE, which symbols are used for the prompt? <br>*** <br>&lt;&lt;&lt;<br> &gt;&gt;&gt;<br> ---​
Norma-Jean [14]

Answer: >>>

Explanation:

just finished the test and got this right

7 0
4 years ago
One reason to buy a home instead of rent a home is:
vazorg [7]
A is the correct Answer

7 0
4 years ago
What is the simplest way to permanently get rid of an unwanted file? A. Cancel the file. B. Go to the Start menu and then delete
Morgarella [4.7K]
Go to the Start menu and then delete the file <span>is the simplest way to permanently get rid of an unwanted file</span>
5 0
4 years ago
When saving my template, I will need to select Word Template in the _____ dialog box.
Bond [772]
You will need to select the file type to be saved as a template in the save as dialog box 
4 0
3 years ago
Other questions:
  • Write a function called "power" that takes in integers b&gt;0 and e≥0 and recursively computes b^3 and returns the result.
    5·2 answers
  • Missing slot covers on a computer can cause?
    9·1 answer
  • Given the module description:________.
    11·1 answer
  • In this lab, you open a file and read input from that file in a prewritten C program. The program should read and print the name
    5·1 answer
  • In which step of web design is storyboarding helpful?
    10·1 answer
  • How can a cell phone tower help people​
    11·2 answers
  • What allows a programmer to write code quickly and efficiently for an action that must be repeated?
    14·1 answer
  • Which of these does an operating system use to organize files?
    7·2 answers
  • Who is the traitor of UA?<br><br>1 Karishma<br><br>2 Yuga Aoyama<br><br>3 Denki <br><br>4 Mineta
    6·1 answer
  • In java complete a program that takes a weight in kilograms as input, converts the weight to pounds, and then outputs the weight
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!