Image

CS401 Final term Solved MCQs and Subjective With References by Moaaz

cs401 Final Term Paper Shared by Student

cs401 current paper 12-Sep-2020
Q) Format of DOS input buffer:
Answer:-
Offset Size Description
00 1 maximum characters buffer can hold
01 1 number of chars from last input which may be recalled OR number of characters actually read, excluding CR
02 n actual characters read, including the final carriage return
Q) Describe MOVS instructions
Answer:- (Page 92) MOVS MOVS transfers a byte or word from the source location DS:SI to the destination ES:DI and updates SI and DI to point to the next locations. MOVS is used to move a block of memory. The DF is important in the case of overlapping blocks.
Q) How interrupts are handled in protected mode & IDTR.
Answer:- (Page 182)
Handling interrupts in protected mode is also different. Instead of the IVT at physical address 0 there is the IDT
(interrupt descriptor table) located at physical address stored in IDTR, a special purpose register. The IDTR is
also a 48bit register similar in structure to the GDTR and loaded with another special instruction LGDT.
Q) VESA service "INT 10 – VESA – Get SuperVGA Information" uses which registers to return the result?
Answer:- (Page 180) To return the result,
"INT 10 – VESA – Get SuperVGA Information” uses: Return: AL = 4Fh if function supported AH = status
INT 10 – VESA – Get SuperVGA Infromation
AX = 4F00h
ES:DI -> buffer for SuperVGA information
Return:
AL = 4Fh if function supported
AH = status
Q) define interrupt INT 0*80
Answer:-
int 0x80 ; multitasking kernel interrupt
Q)Define HOOKING And Unhooking
HOOKING AN INTERRUPT
To hook an interrupt we change the vector corresponding to that interrupt. As soon as the interrupt vector changes, that interrupt will be routed to the new handler. By hooking this interrupt a debugger can get control after every instruction and display the registers etc
Unhooking Interrupt
We now add the interrupt restoring part to our program. This code resets the interrupt vector to the value it had before the start of our program.
Q) How interrupts are handled in protected mode.
Answer:-
Handling interrupts in protected mode is also different. Instead of the IVT at physical address 0 there is the IDT (interrupt descriptor table) located at physical address stored in IDTR, a special purpose register. The IDTR is also a 48bit register similar in structure to the GDTR and loaded with another special instruction LGDT.
Q) INT 14 READ OPERATION from SERIAL PORT
Answer:-
The BIOS INT 14 provides serial port services. We will use a mix of BIOS services and direct port access for our example. A major limitation in using BIOS is that it does not allows interrupt driven data transfer, i.e. we are interrupted whenever a byte is ready to be read or a byte can be transferred since the previous transmission has completed. To achieve this we have to resort to direct port access. Important BIOS services regarding the serial port
INT 14 - SERIAL - READ CHARACTER FROM PORT
AH = 02h
DX = port number (00h-03h)
Return:
AH = line status
AL = received character if AH bit 7 clear
Q) What is EAX
AX register is extended 32 bit register is renamed as EAX
Q) Define multitasking, its environment and conditions
Answer:-
Multitasking:
*A multitasking environment allows applications to be constructed as a set of independent tasks, each with a separate thread of execution and its own set of system resources. The inter-task communication facilities allow these tasks to synchronize and coordinate their activity.
*Multitasking provides the fundamental mechanism for an application to control and react to multiple, discrete real-world events and is therefore essential for many real-time applications.
*Multitasking creates the appearance of many threads of execution running concurrently when, in fact, the kernel interleaves their execution on the basis of a scheduling algorithm. This also leads to efficient utilization of the CPU time and is essential for many embedded applications where processors are limited in computing speed due to cost, power, silicon area and other constraints.
To realize such a system, the following major functional conditions are to be carried out.
A.Process Management
• interrupt handling
• Task scheduling and dispatch
• create/delete, suspend/resume task
• manage scheduling information – priority, scheduling policy, etc
B.Inter-process Communication and Synchronization
• Code, data and device sharing
• Synchronization, coordination and data exchange mechanisms
• Deadlock and Live-lock detection
C.Memory Management
• Dynamic memory allocation
• Memory locking
• Services for file creation, deletion, reposition and protection
D.Input/Output Management
• Handles request and release functions and read, write functions for a variety of peripherals
Q) write a program add 10 numbers using register + offset addressing mode in assembly language

CS401 past papers



cs401 Final Term Paper Shared by Student

Date: 05-01-2020

Cs401 important topics
Interrupts, INT 1,INT 3, INT 10,INT 13, INT 14,INT 21/service 04
Programmable Interrupt Controller (PIC) and IRQ
Interrupt hooking , Unhooking Interrupt
Terminate and Stay Resident (TSR)
BIOS video services
DOS VIDEO SERVICES
Multitasking complete concept
Chapter 13 (secondary storage)
Serial communication
IDT (interrupt descriptor table)
Lecture 17

CS401 Final term Solved MCQs and Subjective With References by Moaaz,

VU Subjects Available List

Available Subjects List

Join Chat Room

Join Chat

Join our FB Group For VU help

Join VU Group

cs401 Final Term Paper Shared by Student

CS401 VU Current Final Term 2020 (10 September onward)
50 questions
40 mcqs 80% from past papers
1. In truncated file service which register read service and file attributes
2.SACS instruction works?
3.which interrupt is called scheduler.which main purpose of that.
4.which interrupt interrupt and control back to dos.write name of interrupt and service number.
5.serial port intiziltaion service number and also write attributes of it with service number those initialize them.
6.physical address btna tha
7.data movment instruction de v thi un ka btna tha k kon sy processor me use hoti hain.
8.code dia hua tha btna tha k instruction kya kam kr rhi us me.
9.code likhna tha apna name on top of screen show krny ka.
10.code likhna tha aik array ka jis me 128 elements ho har element 4 byte ka ho or har element ki value 0 ho.
Overall paper bhut easy tha..



cs401 Final Term Paper Shared by Student

cs401 current paper 2020

Mcqs past papers sa tha
3masks questions:
Diff between serial and parallel port communication.
How to speed up multitasking.
Ik program code aya tha for cant remember the condition.

cs401 Final Term Paper Shared by Student

Cs401 today paper 2020
30 se 33 tak mcqs past papers main se the muaaz k
Baki concept base the
Relationship b/w IRQ and INT
Rotate through carry right
C and pascal convention
Al,Ah .ch ki instructions lekni thi
2 progam the jab krne hi nahi the to pare nahi



cs401 Final Term Paper Shared by Student

cs401 current paper 2020

30% mcqs from moaz file
2 short and 2 long also from moaz file
2 from handout
What is Stack overflow
Answer:- (Page 187)
The strong argument in favour of callee cleared stacks is that the arguments were placed on the stack for the
subroutine, the caller did not needed them for itself, so the subroutine is responsible for removing them.
Removing the arguments is important as if the stack is not cleared or is partially cleared the stack will
eventually become full, SP will reach 0, and thereafter wraparound producing unexpected results.
Who is responsible for removing the parameter from the stack when we call a function in C and Pascal?
Answer:- (Page 187)
In C the caller removes the parameter while in Pascal the callee removes them. The C scheme has reasons
pertaining to its provision for variable number of arguments.
28. DOS allocate memory for program execution and then de-allocate , explain memory management in
DOS (5 marks)
Answer:- (Page 121)
At physical address zero is the interrupt vector table. Then are the BIOS data area, DOS data area, IO.SYS,
MSDOS.SYS and other device drivers. In the end there is COMMAND.COM command interpreter. The
remaining space is called the transient program area as programs are loaded and executed in this area and the
space reclaimed on their exit. A freemem pointer in DOS points where the free memory begins. When DOS
loads a program the freemem pointer is moved to the end of memory, all the available space is allocated to it,
and when it exits the freemem pointer comes back to its original place thereby reclaiming all space. This action
is initiated by the DOS service 4C. The second method to legally terminate a program and give control back to
DOS is using the service 31. Control is still taken back but the memory releasing part is modified. A portion of
the allocated memory can be retained. So the difference in the two methods is that the freemem pointer goes
back to the original place or a designated number of bytes ahead of that old position.

cs401 Final Term Paper Shared by Student

cs401 current paper 2019

50 questions
40 mcqs 80% from past papers
1. In truncated file service which register read service and file attributes
2.SACS instruction works?
3.which interrupt is called scheduler.which main purpose of that.
4.which interrupt interrupt and control back to dos.write name of interrupt and service number.
5.serial port intiziltaion service number and also write attributes of it with service number those initialize them.
6.physical address btna tha
7.data movment instruction de v thi un ka btna tha k kon sy processor me use hoti hain.
8.code dia hua tha btna tha k instruction kya kam kr rhi us me.
9.code likhna tha apna name on top of screen show krny ka.
10.code likhna tha aik array ka jis me 128 elements ho har element 4 byte ka ho or har element ki value 0 ho.
Overall paper bhut easy tha..

cs401 Final Term Paper Shared by Student

cs401 current paper 2019

Objective:
Out of 40 mcqs there were 35 mcqs from moaaz and waqar files.
Subjective:
1.S bit and P bit ka function (3 marks)
2. assembly code to print first 5 odd numbers and store its sum in dx
3. Threads Multitasking kay baray m tha question
4. which services is used in Dos INT21 SUPERVGA mode Information? usky attributes
Baki yad nhi

cs401 Final Term Paper Shared by Student

cs401 current paper 2019

50 questions
40 mcqs 80% from past papers
1. In truncated file service which register read service and file attributes
2.SACS instruction works?
3.which interrupt is called scheduler.which main purpose of that.
4.which interrupt interrupt and control back to dos.write name of interrupt and service number.
5.serial port intiziltaion service number and also write attributes of it with service number those initialize them.
6.physical address btna tha
7.data movment instruction de v thi un ka btna tha k kon sy processor me use hoti hain.
8.code dia hua tha btna tha k instruction kya kam kr rhi us me.
9.code likhna tha apna name on top of screen show krny ka.
10.code likhna tha aik array ka jis me 128 elements ho har element 4 byte ka ho or har element ki value 0 ho.
Overall paper bhut easy tha..

cs401 Final Term Paper Shared by Student

cs401 current paper 2019

Subjective
Q1. Ah=ooh, Ah=01h, Ah=02h Uses for which services
Q2. Write services for Write disk, read disk and Disk sector Parameter
Q3. Aik program ko complete karna tha
Q4. Interrupt debuggers types in details
Q5. Terminate program to Dos likna tha
Q6. Code descriptor and data descriptor ka differences
Q7. G and S purpose in descriptor and its value
Q8. Koi interrupt 10 ka question tha
Etc...

cs401 Final Term Paper Shared by Student

cs401 current paper 2019

Q1.can we increase speed mulitasking.if yes then how
Q2. Difference push and pop
Q3.difference code and data descriptor
Q4.functaionalty CLI
Q5. Aik table tha 2column thy aik main function tha..second main register names btany thy.
Q6. What is the purpose S and G in interrupt descriptor and write names



cs401 Final Term Paper Shared by Student

cs401 current paper 2018

MCQS waqar and moazz handouts mix important INT and 9pinand DB9 waley topic sey subjective
1.What are the different hardware access levels in our computers?
2.If “BB” is the OPCODE of the instruction to move a constant value into AX register, then what will be the hexadecimal representation (Using little Endian notation) of the instruction “Mov AX,336”?
3.Write assembly instructions to enable the access to whole memory in protected mode.
4.In multitasking environment, do the processes know that the control has been taken by the debugger from them? Justify your answer with valid reasons.
5.assembly program to disable the sound card of a system using PIC port.
6.Write the attributes of INT 21 service for deallocate memeory
7.sub routine using assembly code to make a thread having one local variable.+
8.Interrupt Descriptor and what are the values

cs401 Final Term Paper Shared by Student

cs401 current paper 2018

40 Mcqs 36 from waqar and moaz files Mix Int ki value waly 10 aye thy Subjective Which systen progrme use to start the Computer
2; What the next value if Ax5 bx10 push15 Aur nixhy code diya hua tha
3; Trap flag k bary me question tha uska valid reason bhi batna tha k kyun use hota
4: Control bus data bus adress bus processer and momry likhuaa thaa nichy
5 Values likhii thii aur diagrm bana kar apas me link karna tha unko For example hum ny ager kuch read karna hooo too adreas memry ki tarh jaye gii ya process kii tarf...

cs401 Final Term Paper Shared by Student


cs401 current paper 2018


1. Difference between stack Clearance of pascal and c
2. Chargen video services k attributes thy 5 marks ka
3. Font text attributes likhmy thy 2.mcq's from moaaz file long mn 3 programs thy ak int 14 ka tha ak serial port mn read and write operation ka tha or short mn bios diff bw code segment and data segment protected program db 9 pins k names

cs401 Final Term Paper Shared by Student

cs401 current paper 2018

40 Mcqs 36 from waqar and moaz files Mix
Int ki value waly 10 aye thy
Subjective
Which systen progrme use to start the Computer
2;
What the next value if Ax5 bx10 push15
Aur nixhy code diya hua tha
3;
Trap flag k bary me question tha uska valid reason bhi batna tha k kyun use hota
4:
Control bus data bus adress bus processer and momry likhuaa thaa nichy 5 Values likhii thii aur diagrm bana kar apas me link karna tha unko
For example hum ny ager kuch read karna hooo too adreas memry ki tarh jaye gii ya process kii tarf..

cs401 Final Term Paper Shared by Student


cs401 current paper 2018


mcqs mostly moaaz file say thy
and subjective
1.program bnana tha jo second assignment ki base pay tha assignment main aap k name k characters show hony chayian jab k is program n
main kha gia tha k aap ka name top left pay show hona chayia
2.agr ak program c ya ksi aur language main likha ho to usy assembly say call karny kalyia kon sa register use karain gay
3.terminate and stay resident main service 31 ka function
3.mutitasking main threading k bary main kuch tha
4.calculation of physical address .
bus itna yad hay

MCQs Download
Subjective Download

MCQs Test Online 1

Take a Test 1

MCQs Test Online 2

Take a Test 2

MCQs Test Online 3

Take a Test 3

MCQs Test Online 4

Take a Test 4

MCQs Test Online 5

Take a Test 5
Virtual University 05-01-2021 10:11:35amView: 43344

Categories: Virtual University

Comments

Leave a comment