Opened 6 years ago
#202 new defect
eis_tester documentation of -io option confused
| Reported by: | canthony | Owned by: | Eric Swenson |
|---|---|---|---|
| Priority: | minor | Milestone: | |
| Component: | Documentation | Version: | |
| Keywords: | eis_tester AR-97 | Cc: |
Description
AR97-3 System Diagnostic Aids, page 2-50:
"-io N
defines the instruction offset. It is used to position the instruction
relative to a page boundary. The default is 0. This places the
instruction at word 0 of the second page of the instruction area. X
indicates the number of words of the instruction to be placed in the
first page of the instruction are. The maximum value of X is 3."
The source code (bound_eis_test_.s$et_inst.pl1) is a bit clearer:
- h) -io X X defines the Instruction Offset. It is used to position
- the instruction on a page boundary. The default is 0. This
- will place the instruction at word 0 of the second page
- of the instruction area. X indicates the number of words of
- the instruction which will be placed in the first page of the
- instruction area. The maximum value of X is 3.
However, it is still internally inconsistent. Is X the offset or the length?
Looking at the code (bound_eis_tester.s$et.pl1), is seems to be offset:
/* Get a pointer to where we must place the instruction. Note, the instruction
- area words that are not used are left as nops. Once we have the pointer
- we will move the instruction word. Note, the instruction offset defined by
- the user is backwards as far as we are concerned. We need the offset from the
- beginning of the instruction area. We will convert it.
*/
our_offset = (instr_offset - 3)* (-1);
instr_ptr = addrel (addr (etx$instruction_area), our_offset);
instr_ptr -> eis_map.instruction = instr_word;
