q what is segment directivesegment directive


Q. What is SEGMENT Directive?

Segment directive defines logical segment to which following instructions or data allocations statement belong.  It also provides a segment name to base of that segment.  

Address of each element in a 8086 assembly program should be represented in segment - relative format.  Which means that each address should be expressed in terms of a segment register and an offset from base of segmented addressed by that register. By defining the base of a logical segment, a segment directive makes it potential to set a segment register to address that base and also makes it likely to compute the offset of every element in that segment from a common base.

An 8086 assembly language program comprises logical segments which can be a code segment, stack segment, data segment and an additional segment.

A segment directive denotes to assemble all statements following it in a single source file till an ENDS directive.

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: q what is segment directivesegment directive
Reference No:- TGS0327924

Expected delivery within 24 Hours