To remind folks what I was proposing...
   1) More flexibility in defining 2 and 4-byte immediate values
   2) Arithmetic values reported as out-of-range, but seemed ok
   3) HLASM output shows some immediates but not others

Since my last posting which got favourable support I have been
exchanging Emails with Jonathan Scott

This has proved useful as I now have a better understanding of how
HLASM actually works

I don't entirely agree that it should work that way, but I would like
to throw both opinions back to the community to see what the general
view is

Jonathan has allowed me to quote from our private Emails provided I
don't misrepresent his views, and I will be vigilant not to do so

The symbols >>JS<< and >>MM<< are used to differentiate opinions

>>JS<<
Every assembler expression is evaluated in a way which is completely
unrelated to its context, currently as a 31-bit signed expression

For an immediate operand, the expression value is then assigned to the
instruction field, preserving the numerical interpretation of that
value according to whether the field is signed or unsigned

>>MM<<
This does explain the curiosity of LH 1,=X'FFFF' being valid and LHI
1,X'FFFF' being invalid. The LHI immediate will generate a binary
value of 65535 which is outside the range for the operand. If the
immediate were valid it would still comply with the PoOP "The second
operand is sign extended..."

Similarly, LHI 1,2X'FF isn't valid because strictly speaking the
immediate operand is not a single binary value

>>JS<<
And 2X'FF' would still be an invalid value for LHI regardless of
notation

There might be a partial solution...
>>JS<<
All I can say for now is that we are hoping to make checking more
consistent in the future by introducing a truncation check option
while at the same time providing an option to tolerate use of unsigned
values in signed fields and vice versa

>>MM<<
I guess we aren't going to get a true DC-type expression for 2 or
4-byte immediates unless the feeling is strong enough

One last point, as I don't work for an IBM customer I have no access
to the formal method of submitting an RFE. If the general feeling here
is that one should be submitted may I ask for someone to do this on my
behalf

Melvyn Maltz.

Reply via email to