View previous topic :: View next topic
|
Author |
Message |
Rahul Mekkunnath
New User
Joined: 05 Nov 2008 Posts: 3 Location: Mumbai, India
|
|
|
|
What is the best method to compare two load modules. Case is like i have a load module which is created some time back and dont know whether it is the correct one. So inorder to make sure it is the right one i created a new load module but when i tried to compare the two load modules using SuperCE utility, its showing a lot of difference. Ideally, it should show only a difference in timestamp.
Pls suggest a way so that i can get to a conclusion whether the old load module is correct one or not. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello and welcome to the forum,
Quote: |
What is the best method to compare two load modules. |
Modules created some time apart may not be comparable unless there have been zero changes to anything in the environment where the load modules were created.
Quote: |
So inorder to make sure it is the right one i created a new load module but when i tried to compare the two load modules using SuperCE utility, its showing a lot of difference. |
Not surprising. . .
If what you are interested in is the date in the load module, you can use the AMBLIST utility to see information about a load module. If you use the forum SEARCH, there are multiple topics (at least one has jcl that will work as i tested it before posting it). |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2547 Location: Silicon Valley
|
|
|
|
I think a seemingly minor change may cascade throughout the load module because of the registers that are used by the compiler. That is, the code produced may be the same (except for the registers used by a particular instruction) but superc shows many changes.
I saw one scheme where the register numbers are replaced by a constant. Use AMBLIST to format load module and change registers to all be '*', for example. Then do the same for the second load module and compare. |
|
Back to top |
|
|
Terry Heinze
JCL Moderator
Joined: 14 Jul 2008 Posts: 1249 Location: Richfield, MN, USA
|
|
|
|
If all you need is the DATE-COMPILED, you can usually spot the eye-catcher by browsing the load module. It also shows the compiler version sometimes. |
|
Back to top |
|
|
Rahul Mekkunnath
New User
Joined: 05 Nov 2008 Posts: 3 Location: Mumbai, India
|
|
|
|
Hi Pedro, you told about using AMBLIST to format load module and changing registers. Can you tell me how this is done. |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
Rahul,
May be not the answer you are looking for but
1. EXECute both the programs using the same input & compare the output.
2. If there are difference in the results from above option - Why don't you compare the Source Code itself - that's rather straight forward.
Unless you've decided to go with load-module Comparison above options seems to work rather fast. |
|
Back to top |
|
|
Rahul Mekkunnath
New User
Joined: 05 Nov 2008 Posts: 3 Location: Mumbai, India
|
|
|
|
Anuj,
i have one single program for which i have a load module which was created some time earlier, but the listings is not available for that. If the listing was available we can compare the old listing with the new listing(that can be created). So only option we have is to compare the load modules. |
|
Back to top |
|
|
Terry Heinze
JCL Moderator
Joined: 14 Jul 2008 Posts: 1249 Location: Richfield, MN, USA
|
|
|
|
This suggestion won't help you retroactively, but going forward I'd consider putting a display statement in your programs showing load module name and the date and time compiled. I've been doing this for many years now and am sure it's benefited someone along the way in determining whether or not the dump they are looking at matches the source listing and load module they are looking at. |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
Hi,
Rahul Mekkunnath wrote: |
i have one single program for which i have a load module which was created some time earlier, but the listings is not available for that. |
What Version Control tool do you use at your shop to compile/link the COBOL programs ? Change Man by any chance ?
In anyway you can alwyas try this option
Quote: |
1. EXECute both the programs using the same input & compare the output. |
if there is some ambiguity in the output - you are left with only one choice - create other load-module.. & I hope you already know what is required as an output from the program. |
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
Anuj,
Quote: |
1. EXECute both the programs using the same input & compare the output. |
What if the test data which is used produced the same results but at the same time could have resulted in different outputs with a different set of test data. Extensive testing required |
|
Back to top |
|
|
|