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
 

 

Address Constant declaration in assembly language

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & Assembler
View previous topic :: :: View next topic  
Author Message
mannu_gr8

New User


Joined: 02 Mar 2009
Posts: 3
Location: Hyderabad

PostPosted: Fri Sep 17, 2010 6:20 pm    Post subject: Address Constant declaration in assembly language
Reply with quote

Hello,

I have an requirement wherein i need to convert the variable declared in assembly language to its equivalent COBOL and that too of storage type A or V (Address Constant)

E.g.
CONST1 DC A(CONST)
here the address of CONST is stored in the storage area CONST1

CONST2 DC A(*)
CONST3 DC A(Home+2)

I need to find out the equivalent COBOL declaration of these address constant storage type in assembler....
Also what exactly is the difference between A-type and V-type address constant in terms of conversion to COBOL..??
I tried finding it in forum but did not get any clue....As m very new to Assembly language..it would be really helpful if some one can explain me this conversion or can provide me with some link where in i can get this conversion process understoop by self.....


Thanks in Advance...
manojG.
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Fri Sep 17, 2010 6:26 pm    Post subject: Reply to: Address Constant declaration in assembly language
Reply with quote

the approach is completely wrong!
when converting from one language to another one
the process implementation must be converted/rewritten
not the language constructs ( that might not even have an equivalent )
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: Fri Sep 17, 2010 6:28 pm    Post subject: Reply to: Address Constant declaration in assembly language
Reply with quote

Unless you're using OS/VS COBOL, constants (DC's) are a thing of the past in VS/COBOL II and greater.

WS relies upon either VALUE clauses or initialization at execution time and are effectively defined as DS's.

You need to post more of the Assembler program and perhaps you might get a better opinion (no guarantees).

Bill
Back to top
View user's profile Send private message
mannu_gr8

New User


Joined: 02 Mar 2009
Posts: 3
Location: Hyderabad

PostPosted: Mon Sep 20, 2010 1:25 pm    Post subject: Reply to: Address Constant declaration in assembly language
Reply with quote

@enrico-sorichetti

Here we are not manually converting the Assembler to Cobol so "the process implementation must be converted/rewritten " will not work....

We are developing a tool which will be doing this....
If you have some inputs on this..it would be really helpful....

@ Bill O'Boyle
I do not have exact assembler code as of now....as the tool mentione above is on it's initial phase...

If you have any idea or a link from where i can get the exact use of Address Constant in Assembler , it would be very helpful...


Cheers...
manojG
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Mon Sep 20, 2010 2:40 pm    Post subject: Reply to: Address Constant declaration in assembly language
Reply with quote

Quote:
We are developing a tool which will be doing this....

good luck

Quote:
As m very new to Assembly language..

more than just good luck You will need

spending more time on this issue is just a waste of time for everybody

telling how to <convert> an address constant declaration without having the whole picture is ... see the above sentence

and anyway it will a waste of time for also for a different reason
in assembler language the declarations are not type binding they just define address and length of a storage area
inferring anything else is just making wrong assumptions

the only way to <type> a variable is by looking at the assembler instructions using it

Quote:
if you have any idea or a link from where i can get the exact use of Address Constant in Assembler , it would be very helpful...


the assembler manual will tell all You want to know about assembler constructs

if You do not even know the basics on how to look/search for docs,
how do You expect to be able to write any tool icon_question.gif icon_evil.gif
Back to top
View user's profile Send private message
mannu_gr8

New User


Joined: 02 Mar 2009
Posts: 3
Location: Hyderabad

PostPosted: Mon Sep 20, 2010 3:01 pm    Post subject: Reply to: Address Constant declaration in assembly language
Reply with quote

Thanks a lot.... icon_exclaim.gif
Back to top
View user's profile Send private message
dick scherrer

Site Director


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

PostPosted: Mon Sep 20, 2010 7:32 pm    Post subject:
Reply with quote

Hello,

Quote:
We are developing a tool which will be doing this....
Suggest you reconsider. . .

People who know assembler very well would find this a daunting task. Because there is an infinite numer of ways people wrote assembler over the last 4 decades. . .

To make this less likely to succeed, it sounds like the people trying to implement the tool don't even have a beginner's level of knowledge of assembler. Address Constants are one of the simpler "things assembler can do". . .
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 -> PL/I & Assembler All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts INVALID FIELD OR CONSTANT IN SORTOF ?? Ron Klop DFSORT/ICETOOL 8 Wed Jan 11, 2017 3:44 pm
No new posts Need Help in understanding what is th... mainakdalal PL/I & Assembler 9 Mon Oct 03, 2016 8:03 pm
No new posts execute APP if they are not ADDRESS T... italo_pm CLIST & REXX 3 Fri Aug 12, 2016 2:15 am
This topic is locked: you cannot edit posts or make replies. Get and display content of an address... lind sh CICS 1 Mon Aug 08, 2016 9:18 am
No new posts Any body aware of CAP-COBOL language? Sachin Raghuwanshi COBOL Programming 4 Tue Aug 02, 2016 9:34 am


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