mcq 队列
Question 1:
问题1:
Which of the following assembler directives are used to define a Procedure in the 8086 microprocessor?
以下哪个汇编程序伪指令用于在8086微处理器中定义过程?
PROCEDURE and ENDP
程序和结束
STARTP and ENDP
STARTP和ENDP
PROC and ENDPROC
PROC和ENDPROC
None of the above
以上都不是
Answer: d. None of the above
答案:d。 以上都不是
Explanation:
说明:
The assembler directive that are used for defining a procedure in the 8086 microprocessor are: PROC and ENDP.
用于在8086微处理器中定义过程的汇编程序伪指令为:PROC和ENDP。
Question 2:
问题2:
Which of the following features is not offered by Macros?
宏不提供以下哪些功能?
Code reusability
代码可重用性
Less memory space
更少的存储空间
Fast execution
快速执行
None of the above
以上都不是
Answer: b. Less Memory Space
答案:b。 更少的内存空间
Explanation:
说明:
Every time a Macro is invoked, the entire set of instructions is loaded into the main memory due to which the execution of macros takes large memory space.
每次调用宏时,整个指令集都会加载到主存储器中,因此,宏的执行会占用较大的存储空间。
Question 3:
问题3:
Which of the following is the correct syntax for calling a Macro?
以下哪项是调用宏的正确语法?
MACRO macro_name
宏macro_name
MACRO macro_name [ parameter's list]
MACRO macro_name [参数列表]
macro_name [parameter's list ]
macro_name [参数列表]
None of the above
以上都不是
Answer: c. macro_name [parameter's list ]
答:c。 macro_name [参数列表]
Explanation:
说明:
While calling a Macro, we need not mention the assembler directive: MACRO. Also, the parameter's list is optional to pass. It is passed only if the definition of the Macro contains parameters.
在调用宏时,我们不需要提及汇编程序指令:MACRO。 同样,参数的列表是可选的。 仅当宏的定义包含参数时,才传递它。
Question 4:
问题4:
Which of the following characteristics of Procedures makes it unfit for being used for short instruction sets with less number of instructions?
该过程的以下哪些特征使其不适合用于较少指令数的简短指令集?
Extra code requirement for integrating procedures
集成过程的额外代码要求
Linking of procedures with the mainline program takes too much time
将程序与主线程序链接需要花费太多时间
Extra work load on processor for shifting controls
处理器上的额外工作量用于切换控件
All of the Above
上述所有的
Answer: d. All of the above
答案:d。 上述所有的
Explanation:
说明:
All the mentioned reasons are responsible for a procedure not being a suitable option for handling short instruction sets with less number of instructions.
所有上述原因均导致该过程不适用于处理指令数量少的简短指令集。
Question 5:
问题5:
In a program, a Macro is being called 'n' times. Then how many times is the machine code generated for the same?
在程序中,宏被称为“ n”次。 那么相同的机器代码生成了多少次?
1 time
1次
'n' times
'n'倍
'n-1' times
“ n-1”次
None of the above
以上都不是
Answer: b. 'n' times
答案:b。 'n'倍
Explanation:
说明:
The machine code (containing the instructions within the Macros) is generated every time the macro is called. So, if a Macro is being called 'n' times, then the number of times the machine code is generated is also 'n'?
每次调用宏时都会生成机器代码(包含宏中的指令)。 那么,如果宏被称为“ n”次,那么生成机器码的次数也为“ n”吗?
翻译自: https://www.includehelp.com/embedded-system/mcq-procedures-and-macros-in-8086-microprocessor.aspx
mcq 队列