On Sun, 17 Oct 2010 20:48:21 -0700, Edward Jaffe wrote:
>Long displacements are supported on every machine that implements
>z/Architecture. The capability was retrofitted back to the z900 millicode
>when z990 came out.
Mostly true. Not all z900s were upgraded. And it took awhile for FLEX-ES to
support long-displacement. So for a period of time at least, it was
possible for z/Architecture machines to not support long-displacement.
DB2 V8 was released during this time. The minimum hardware support was
advertised to be simply z/Architecture, but that wasn't true. DB2 V8
required an upgraded z900 and it would not run at all on FLEX-ES. But there
was no way to know that from the documentation. This was a real problem for
ISVs using FLEX-ES.
Unlike other changes before and since, the attempt to use this new feature
on a machine that didn't support it did not result in a program check or
some other obvious sign. The long displacement byte was simply ignored in
the original z/Architecture so the wrong location was accessed with typical
unpredictable results.
The assembler does not have an OPTABLE to describe an upgraded z900. It
only has ZOP (original z900) and YOP (z990). So if you want your code to be
able to take advantage of long displacement but still run on an (upgraded)
z900, there isn't an OPTABLE for you. The best you can do is use
OPTABLE(YOP) and then delete the z990-only instructions with OPSYN.
I do like the ACONTROL OPTABLE feature of HLASM. This makes it easy to
employ HLASM to check that parts of a module use only the instructions that
are known to be available in that part. zIIP support is a good example
since it is only offered on z9 and later. A zIIP interface module can start
off with OPTABLE(ESA), ZOP or YOP to ensure that it works on older systems.
Once the module detects that a zIIP is available, issue ACONTROL OPTABLE(ZS3).
Likewise with MIDAW, zHPF and other features. If a module builds either
channel programs or zHPF transport commands depending on the available
hardware, enclose the zHPF part with:
PUSH ACONTROL
ACONTROL OPTABLE(ZS4)
end with:
POP ACONTROL
and use any of the pre-z196 instructions in the middle.
David