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

How to declare & access array in assembler?


IBM Mainframe Forums -> PL/I & Assembler
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
afroz alam

New User


Joined: 02 Jul 2007
Posts: 13
Location: India

PostPosted: Mon Jul 16, 2007 12:15 pm
Reply with quote

Hi all...

Suppose i have declared a array variable in assembler like

aaa dc F'111,222,333,444,555,666'

now i want to access it.....can any one plz tell me what are instructions requred to access it by using BCT instruction...?

afroz
Back to top
View user's profile Send private message
afroz alam

New User


Joined: 02 Jul 2007
Posts: 13
Location: India

PostPosted: Tue Jul 17, 2007 3:17 pm
Reply with quote

Can anyon plz send the reply its urgent?




afroz
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Tue Jul 17, 2007 3:36 pm
Reply with quote

Learning assembler on an urgent basis is going to be difficult...
Try the PoP:
BRANCH ON COUNT (BCT, BCTR)
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: Wed Jul 18, 2007 12:32 am
Reply with quote

Hello,

Hopefully, you realize that BCT does not reference the array. . . BCT is a way to control the iterations thru the loop.

More often (in code i've written or supported), the BCT is not used. After incrementing the address in the array, it is usually checked to see if the end of the array has been reached. BCT means that you have to have to count entries each time there are adds or deletes to the table. If you use the end-of-table address (next byte after the table), the code controlling the loop does not need to be changed. I was once asked to look into a program problem that was caused by entries being modified in a similar array, but the count was not properly changed. It had been running wrong for a long time before the error was discovered. . .
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 -> PL/I & Assembler

 


Similar Topics
Topic Forum Replies
No new posts Access to non cataloged VSAM file JCL & VSAM 18
No new posts How to access web services/website? Mainframe Interview Questions 4
No new posts access the last host command CLIST & REXX 2
No new posts Build dataset list with properties us... PL/I & Assembler 4
No new posts Finding Assembler programs PL/I & Assembler 5
Search our Forums:

Back to Top