18.10.2014 Views

SIMSCRIPT II.5 Programming Language

SIMSCRIPT II.5 Programming Language

SIMSCRIPT II.5 Programming Language

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Advanced Topics<br />

Table 6-2. Intrpacking Factors for Common 32-Bit Machines<br />

Intrapacking Factor<br />

Attribute Value<br />

Placement<br />

(*/2) 2 values per word<br />

(*/4) 4 values per word<br />

Attributes are usually assigned locations within the entity structure in order of their appearance in<br />

an every statement, taking any explicit equivalencing and packing into account. It is also possible,<br />

however, to specify exactly where an attribute is to be placed within a temporary entity structure by<br />

following its declaration with the clause in word i, where is an integer constant, as in examples<br />

1. and 2. below.<br />

1. Declaration:<br />

temporary entities<br />

every PERSON owns a FAMILY, has an AGE in word 1,<br />

and has a HEIGHT<br />

Entity structure:<br />

word 1 AGE<br />

word 2<br />

HEIGHT<br />

word 3 F.FAMILY<br />

word 4 L.FAMILY<br />

word 5<br />

N.FAMILY<br />

It may be seen that AGE now occupies the first location.<br />

2. Declaration:<br />

every PERSON has an (AGE(1/4),SEX(2/4),HEIGHT(2/2))<br />

in word 1 and a DEBT in word 2<br />

Entity structure:<br />

word 1 AGE SEX HEIGHT<br />

word 2<br />

DEBT<br />

269

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!