Question

In: Computer Science

Let's assume that, an application program calls a High Level Language library function to display a...

Let's assume that, an application program calls a High Level Language library function to display a string with red color in the monitor. Explain the steps executing the operation (from function call to low hardware level).

Solutions

Expert Solution

Given that,

Lets start from the high level. At this level, a program called a library function to print a string in red color. When this function call is made, it's code is loaded in the current program internally.

Then the whole code is converted into assembly language. This is kind of in the middle of high level and the low level. Here the address space is converted from names and labels in high level code to virtual addresses in assembly level code. So here the function is converted to assembly language with some processings like all the variable names and function calls replaced by their respective virtual addresses.

After that, this assembly level code is converted to machine level code or object code. Object code completely in machine readable format(binary). As we know, a peice of code is nothing but set of instructions that we tell CPU to perform in a given sequence. These instructions are now finally converted to the machine reable/ binary format.

Then these instructions are loaded in ram. The given string is also stored in this binary format. After that, CPU starts from the beginning and executes the instructions one by one. For example, here we wanted to print the given string in red color. this command would have been converted into a series of instructions. These instructions are now beign executed. When CPU knows this, It sets pixels correspinding to the string and color them red (RGB coloring). After that, CPU sends this command to the monitor and it adjust the assigned pixels accordingly. This way the whole process goes in a very abstract sense.

<<<<Please Give Me Like>>>>

Thank you:)


Related Solutions

Discussion Topic: In a program written in a high level language, if an arithmetic error occurs...
Discussion Topic: In a program written in a high level language, if an arithmetic error occurs the program aborts and produces an error message that usually has the phrase "Arithmetic Overflow Error". This can happen in different circumstances such as: an illegal calculation was performed, such as trying to divide a number by zero the result of a calculation is a number that is too large or two small for the computer to store and in other circumstances as well....
In this program you will develop an application that will display an amortization schedule.
Using Anaconda Python, program the following:OverviewIn this program you will develop an application that will display an amortization schedule. The word "amortize" means to "To write off gradually and systematically a given amount of money within a specific number of time periods." It will show, for each month of the loan, how much of your monthly loan payment is being applied towards interest costs, and how much is actually being applied to reduce the outstanding balance (principal) of your loan.The...
In MIPS assembly language, write a function that will display the max and min value in...
In MIPS assembly language, write a function that will display the max and min value in an array. Then write a function to calculate and display the average of all values in an array. This must be done in MIPS assembly language.
The program is to be called CarClub The application will display menu as below 1. load...
The program is to be called CarClub The application will display menu as below 1. load cars 2. display all cars 3. search car 4 count cars older the 30 years 5 exit Please enter your option: Load car menu should read input data from text file name (car.txt) Car class have 4 data members which are. Car make, car model, car year and car price In addition If both car year and price were not provided, year has a...
Write an 8051-assembly language program for the interfacing of ADC0804 and LM35 to display the room...
Write an 8051-assembly language program for the interfacing of ADC0804 and LM35 to display the room temperature on 16x2 LCD (10marks) please note that the program should be interfacing with ADC0804.
IN C++ LANGUAGE PLEASE::: Design and implement a program (name it Rectangle) to calculate and display...
IN C++ LANGUAGE PLEASE::: Design and implement a program (name it Rectangle) to calculate and display the area and perimeter of a rectangle with width = 4 and height = 8.
Design and write a function which will calculate and display the stock level of a product...
Design and write a function which will calculate and display the stock level of a product at the end of the day. The function will take as input the initial stock level, the amount we bought and the amount we sold. Add lines to main which get 3 values from the user, as shown below, the pass them to the function. Sample output: Enter stock at start of day: 20 Enter amount of new stock received today: 10 Enter amount...
Take the following program and include overload functions into it. Display result of function. C++ Program:...
Take the following program and include overload functions into it. Display result of function. C++ Program: #include <iostream> using namespace std; // this is the additional function string read() {     string input;     cout << "Enter input: ";     cin >> input;     return input; } int main() {     // call function here     string output = read();     cout << "You entered: " << output; }
Using c++, write a program that will display your name as a void function then will...
Using c++, write a program that will display your name as a void function then will perform the following by user-defined functions: a. to compute for the sum of two numbers (n1, n2) using function.
Create a C# program named SalesLetter whose Main() method uses several WriteLine() calls to display a...
Create a C# program named SalesLetter whose Main() method uses several WriteLine() calls to display a sales letter to prospective clients for a business of your choice. Display your contact information at least three times in the letter. The contact information should contain at least three lines with data such as land line phone number and/or cellphone number, email address, and web address.. Each time you want to display the contact information, call a method namedDisplayContactInfo().
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT