IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

compare two load modules


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Rahul Mekkunnath

New User


Joined: 05 Nov 2008
Posts: 3
Location: Mumbai, India

PostPosted: Thu Nov 06, 2008 12:07 am
Reply with quote

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
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Thu Nov 06, 2008 12:27 am
Reply with quote

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
View user's profile Send private message
Pedro

Global Moderator


Joined: 01 Sep 2006
Posts: 2547
Location: Silicon Valley

PostPosted: Thu Nov 06, 2008 1:48 am
Reply with quote

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
View user's profile Send private message
Terry Heinze

JCL Moderator


Joined: 14 Jul 2008
Posts: 1249
Location: Richfield, MN, USA

PostPosted: Thu Nov 06, 2008 10:06 am
Reply with quote

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
View user's profile Send private message
Rahul Mekkunnath

New User


Joined: 05 Nov 2008
Posts: 3
Location: Mumbai, India

PostPosted: Fri Nov 07, 2008 12:08 am
Reply with quote

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
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Fri Nov 07, 2008 4:57 am
Reply with quote

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
View user's profile Send private message
Rahul Mekkunnath

New User


Joined: 05 Nov 2008
Posts: 3
Location: Mumbai, India

PostPosted: Sat Nov 08, 2008 12:29 am
Reply with quote

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
View user's profile Send private message
Terry Heinze

JCL Moderator


Joined: 14 Jul 2008
Posts: 1249
Location: Richfield, MN, USA

PostPosted: Sat Nov 08, 2008 2:24 am
Reply with quote

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
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Sat Nov 08, 2008 3:19 am
Reply with quote

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.. icon_smile.gif & I hope you already know what is required as an output from the program.
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2481
Location: @my desk

PostPosted: Sat Nov 08, 2008 7:04 am
Reply with quote

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.icon_rolleyes.gif Extensive testing required icon_biggrin.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts Compare 2 files(F1 & F2) and writ... JCL & VSAM 8
No new posts Load new table with Old unload - DB2 DB2 6
No new posts Compare only first records of the fil... SYNCSORT 7
No new posts How to load to DB2 with column level ... DB2 6
Search our Forums:

Back to Top