Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

S0C7 abend not able to locate

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
Rijit

Active User


Joined: 15 Apr 2010
Posts: 168
Location: Pune

PostPosted: Wed Apr 01, 2015 4:03 pm    Post subject: S0C7 abend not able to locate
Reply with quote

Code:
064BDA, F921 2707 34E0          CP    1799(3,2),1248(2,3)     WS-GRP-IDX


can anyone help me to understand this machiNE instruction. i am getting a S0C 7 on this instruction. I got to know about this instruction from abendaid log .I want to locate which instruction is causing the S0c7 abend.

Thanks

Code'd
Back to top
View user's profile Send private message

Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7913
Location: Bellevue, IA

PostPosted: Wed Apr 01, 2015 4:31 pm    Post subject:
Reply with quote

The instruction is an Assembler Compare Packed (CP) instruction -- it is used to compare two packed decimal numbers. COBOL generates anywhere from 1 to many Assembler instructions for a single COBOL statement. To locate the instruction causing the S0C7, you need to look at the COBOL compile listing and find which COBOL statement this instruction is generated for. The actual Assembler instruction does not matter too much -- what is important is which COBOL statement had the problem.
Back to top
View user's profile Send private message
Rijit

Active User


Joined: 15 Apr 2010
Posts: 168
Location: Pune

PostPosted: Wed Apr 01, 2015 5:38 pm    Post subject:
Reply with quote

Robert Sample wrote:
The instruction is an Assembler Compare Packed (CP) instruction -- it is used to compare two packed decimal numbers. COBOL generates anywhere from 1 to many Assembler instructions for a single COBOL statement. To locate the instruction causing the S0C7, you need to look at the COBOL compile listing and find which COBOL statement this instruction is generated for. The actual Assembler instruction does not matter too much -- what is important is which COBOL statement had the problem.


Hi Robert,

Any idea how to map this assembler instruction with the actual cobol instruction which is causing the S0C7 abend.
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7232

PostPosted: Wed Apr 01, 2015 6:25 pm    Post subject: Reply to: S0C7 abend not able to locate
Reply with quote

It looks like you have copied that line from the listing. I don't understand where you got the comma from...

Shortly above that line, you should find the compiler source line-number and the COBOL verb which generated that code.

The name WS-GRP-IDX is being compared to "somethiing", whose name you've chopped off.

Either WS-GRP-IDX (looks like a poor name, because it isn't an index) is not numeric, or "something" is not numeric.
Back to top
View user's profile Send private message
Rijit

Active User


Joined: 15 Apr 2010
Posts: 168
Location: Pune

PostPosted: Wed Apr 01, 2015 6:43 pm    Post subject:
Reply with quote

Code:

064BD2                 GN=3122  EQU   *
064BD2  5820 9268               L     2,616(0,9)              BLW=78
064BD6  5830 C058               L     3,88(0,12)              CBL=5
064BDA  F921 2707 34E0          CP    1799(3,2),1248(2,3)     WS-GRP-IDX   
064BE0  4720 B48A               BC    2,1162(0,11)            GN=1100(064C3C)
064BE4  5840 D108               L     4,264(0,13)             DOV=1
064BE8  F273 4058 2719          PACK  88(8,4),1817(4,2)       TS2=16


got the message from program sysout
Code:

t compile unit offset +00064BDA at entry offset +00064BDA


used 64BDA and searched in program listing and found the instruction
Code:

064BDA  F921 2707 34E0          CP    1799(3,2),1248(2,3)     WS-GRP-IDX      PGMLIT AT +16516
[/quote]
Back to top
View user's profile Send private message
Rijit

Active User


Joined: 15 Apr 2010
Posts: 168
Location: Pune

PostPosted: Wed Apr 01, 2015 6:55 pm    Post subject:
Reply with quote

WS-GRP-IDX is PIC S9(4) COMP-3 and used as an index to array .
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7232

PostPosted: Wed Apr 01, 2015 7:03 pm    Post subject: Reply to: S0C7 abend not able to locate
Reply with quote

See, now there's no comma :-)

Press PF7. You should see a line which has just a line-number and a COBOL verb or clause. Look at that (compiler-generated, the number at the left of the listing) line and you should see exactly what is being used.
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7232

PostPosted: Wed Apr 01, 2015 7:07 pm    Post subject:
Reply with quote

Rijit wrote:
WS-GRP-IDX is PIC S9(4) COMP-3 and used as an index to array .


Well, no it isn't.

I mean it's not being used as an index. Which is why I think -IDX is misleading. And COBOL doesn't have arrays (it has Tables, with OCCURS).

An index is defined (implicitly, the compiler does it) by INDEXED BY.

A data-item used for subscripting (what you have) is a different thing.

It is better as an unsigned BINARY PIC 9(4).
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Wed Apr 01, 2015 9:05 pm    Post subject: Reply to: S0C7 abend not able to locate
Reply with quote

Expanded instruction ===> CP 1799(3,2),1248(2,3)

1st-Operand = at 1799 off R2 for a length of 3

2nd-Operand = at 1248 off R3 for a length of 2

Find the addresses of R2 and R3 in your dump and then go to each one of these offsets.

You're going to find non packed-decimal data at these addreses in one or both.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts IMS BMP program causes 878 system abend Artemk IMS DB/DC 7 Tue Nov 22, 2016 8:26 pm
No new posts abend sort based on count records in ... anatol DFSORT/ICETOOL 5 Mon Oct 17, 2016 10:10 pm
No new posts hot to get details when "EXEC CI... Andi1982 CICS 11 Tue Sep 20, 2016 5:01 pm
No new posts S213-14 ABEND explantion Apurva Mehta JCL & VSAM 5 Thu Jul 07, 2016 10:56 pm
No new posts How to determine where is error in ab... jackzhang75 PL/I & Assembler 13 Fri Apr 15, 2016 2:01 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us