I you have code with a bunch of compares where the direction depends on an 
input parameter, it might be faster to set a register to B'11000000' or 
B'10100000' and then execute BC or BRC instructions.

Some instructions, e.g., B2**, have part of the opcode in bits 8-15. This use 
of EX definitely needs good comments.

-- 
Shmuel (Seymour J.) Metz
http://mason.gmu.edu/~smetz3
עַם יִשְׂרָאֵל חַי
נֵ֣צַח יִשְׂרָאֵ֔ל לֹ֥א יְשַׁקֵּ֖ר




________________________________________
From: IBM Mainframe Assembler List <ASSEMBLER-LIST@LISTSERV.UGA.EDU> on behalf 
of Binyamin Dissen <00001773bcccb823-dmarc-requ...@listserv.uga.edu>
Sent: Sunday, August 3, 2025 3:35 PM
To: ASSEMBLER-LIST@LISTSERV.UGA.EDU <ASSEMBLER-LIST@LISTSERV.UGA.EDU>
Subject: Re: Execute-Type Instructions


External Message: Use Caution


On Sun, 3 Aug 2025 19:12:33 +0000 Seymour J Metz <sme...@gmu.edu> wrote:

:>Of the top of my head
:>
:>    plugging in a cc mask

Can't think how EX would be easier.

:>    plugging in a register

I do use it for that, but it is really specialized code - not normal code.

:>    modifying an opcode
:
Interesting. Please elaborate.
:-
:>Shmuel (Seymour J.) Metz
:>http://mason.gmu.edu/~smetz3
:>??? ?????????? ???
:>?????? ??????????? ???? ??????????
:>
:>
:>
:>
:>________________________________________
:>From: IBM Mainframe Assembler List <ASSEMBLER-LIST@LISTSERV.UGA.EDU> on 
behalf of Binyamin Dissen <00001773bcccb823-dmarc-requ...@listserv.uga.edu>
:>Sent: Sunday, August 3, 2025 7:07 AM
:>To: ASSEMBLER-LIST@LISTSERV.UGA.EDU <ASSEMBLER-LIST@LISTSERV.UGA.EDU>
:>Subject: Re: Execute-Type Instructions
:>
:>
:>External Message: Use Caution
:>
:>
:>On Fri, 1 Aug 2025 23:38:36 -0400 Dan Greiner <dan_grei...@att.net> wrote:
:>
:>:>As is well known to subscribers of the Assembler List, the EXECUTE 
instruction (EX) - and the (relatively) new variant of EXECUTE RELATIVE LONG 
(EXRL) - provide an extremely powerful means of altering the behavior of a 
target instruction by ORing the contents of a the rightmost bits of the first 
operand of the execute-type instruction into bits 8-15 of the target 
instruction. Common uses include modifying the length(s) of an SS-format 
instruction, the register(s), mask, or immediate field of RR, RX, SI, and many 
other formats of instructions (it is also sufficiently complex that it drives 
CPU designers slightly nuts).
:>
:>:>One reason an execute-type instruction is particularly tricky is that 
certain instruction formats contain part of the operation code in bits 8-15, 
thus the actual target instruction executed may not be that which appears in 
the memory. This can occur when the target instruction format is IE, RI, RIL, 
RRD, RRE, RRF, S, SIL, SSE, and SSF.
:>
:>:>My question is (aside from IBM diagnostics) does anybody actually exploit 
this sort of chicanery/guile/subterfuge in their code?
:>
:>Out of curiosity, which instructions (that do not alter length that is being
:>altered would benefit from EX over straight forward coding?)

--
Binyamin Dissen <bdis...@dissensoftware.com>
http://secure-web.cisco.com/1Z3qGXOgZshi0ekU8AycHW0UMvb4VNAgqPyrDElaoySBYZZzVLovCfCdN2PUKIeqJLjTWx2wODS1uPnMnBMeinElxQK5--sDj67pNLnr8r6oOzBMy_5QSnz0cKh9LhT9LHW-vQEXFrxQcA2h3y4ve1sts-NwZRl8oDsVt46YYUj5VWFt3i8Ngsty6WqHc_Wu6d-I6t6o8HR5zxfaTwWXX5whN5nvNAOZ0KYV0DHbCqTHsmpBIRNmy_sH2rnLw_tmhYzbpH1daGT4wlBcKXoWJ0Wsv9DckQIkpYiA7Liv7t74LBWK-7HSdyJ-y89QGM1MKIIExzzBbwkq1nl-2gCQbCesHMfMcGzKHZfxo3FsMwnie_AHixadTdkPGx0ELRXAKQty6dOXrt-FCcc_3UjxvQBl3LGIInhg3kewar6tHx44/http%3A%2F%2Fwww.dissensoftware.com

Director, Dissen Software, Bar & Grill - Israel



Reply via email to