It's not like we would walk all the way to the location that "more far" is expensive. It's in the same cache line or it's not. I have a macro to generate the target in-line to ensure that HLASM knows the USING that applies to the target, accepting the fact that I sometimes need to branch over it. Like MOVE MVC A(0),B EX R1,MOVE Rumor was that walking over the target before executing it was so common that the CPU exploited the fact that the instruction was still in the pipeline or at least outweigh the branch over it. But I have not been able to show the difference other than in code length.On some models it was not good to have the target in the literal pool, and I did not feel like doing an extra code section for them.
Rather than dreaming of huge savings, measure before you make changes. And understand things will be different with the next model. Most likely for 90% of the code you will never gain back the time you spend on this. Rob On 23 November 2016 at 10:15, Philippe Cloarec <philippe.cloa...@gmail.com> wrote: > Hi, > > My understanding is, we should keep as closest as possible, the EXECUTE > instruction and its target instruction...EXECUTE instruction being greedy > enough in term of CPU use...to be clear dozens of Cycles needed to complete > its execution. > > Reviewing old Assembler programs, I guess I am surprised to see enough > often that all target instructions for ALL the Execute instructions coded > in the programs grouped mostly at the end... > > Sometimes I can see offset between EXECUTION and its Target instruction to > be enough BIG like below!!: > > > 001214 4490 B942 01942 1142 EX > R9,LIBCLE2 > .. > .. > 001942 D200 BC76 BD3F 01C76 01D3F 1607 LIBCLE2 MVC SCLE2(0),ZONLIB > > > > I did read many articles, and read often EX should be closed to Target > instruction but no recommendation in term of offset between both elements > ?!? From my humble understanding, more far is the Target instruction from > EX one more costly will be its execution - right ? ; So knowing dozens of > Cycles is "normally" required to complete one EX instruction, actually to > change the program to minimize the offset between EX and its Target > instruction CAN GREATLY reduce CPU use by comparaison with previous code - > right ? > > Thx in advance for input you may have. regards Philippe >