Discussion:
High Level Assembler for MVS & VM & VSE
(too old to reply)
Ramesh Kumar
2004-12-08 09:49:58 UTC
Permalink
1)In this assembly language(High Level Assembler for MVS & VM & VSE)
some of the commands are like this,

BM *+16
B *+14
as i am new to this assembly programmimg i found it very difficult to
understand these statements.

2)similarly the statements
CLI 0(R8),c'-'
CLI 1(R8),c'-'
what does this 0 and 1 means.
The general purpose register R8 points to the string.

3)NUMBER EQU *
MVN EXPONENT+7(1),EXPSIGN
i cant understand these statements also.What does this * means
here?What will happen if the exponent is added with 7(1).
Exponent is defined as
EXPONENT DC D'0'

Please give me the definitions for these statements.

with regards,
Ramesh
Vernooy, C.P. - SPLXM
2004-12-08 09:55:07 UTC
Permalink
Ramesh,

please try to find an assembler course, this will teach you a 1000 times
more in a couple of days, than you will learn here from questions in a year.

Kees.
Post by Ramesh Kumar
1)In this assembly language(High Level Assembler for MVS & VM & VSE)
some of the commands are like this,
BM *+16
B *+14
as i am new to this assembly programmimg i found it very difficult to
understand these statements.
2)similarly the statements
CLI 0(R8),c'-'
CLI 1(R8),c'-'
what does this 0 and 1 means.
The general purpose register R8 points to the string.
3)NUMBER EQU *
MVN EXPONENT+7(1),EXPSIGN
i cant understand these statements also.What does this * means
here?What will happen if the exponent is added with 7(1).
Exponent is defined as
EXPONENT DC D'0'
Please give me the definitions for these statements.
with regards,
Ramesh
**********************************************************************
For information, services and offers, please visit our web site: http://www.klm.com. This e-mail and any attachment may contain confidential and privileged material intended for the addressee only. If you are not the addressee, you are notified that no part of the e-mail or any attachment may be disclosed, copied or distributed, and that any other action related to this e-mail or attachment is strictly prohibited, and may be unlawful. If you have received this e-mail by error, please notify the sender immediately by return e-mail, and delete this message. Koninklijke Luchtvaart Maatschappij NV (KLM), its subsidiaries and/or its employees shall not be liable for the incorrect or incomplete transmission of this e-mail or any attachments, nor responsible for any delay in receipt.
**********************************************************************


----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
Binyamin Dissen
2004-12-08 11:08:20 UTC
Permalink
On Wed, 8 Dec 2004 10:54:57 +0100 "Vernooy, C.P. - SPLXM"
<***@KLM.COM> wrote:

:>Ramesh,
:>
:>please try to find an assembler course, this will teach you a 1000 times
:>more in a couple of days, than you will learn here from questions in a year.

Very well put.

:>"Ramesh Kumar" <***@gmail.com> wrote in message
:>news:<***@posting.google.com>...
:>> 1)In this assembly language(High Level Assembler for MVS & VM & VSE)
:>> some of the commands are like this,
:>>
:>> BM *+16
:>> B *+14
:>> as i am new to this assembly programmimg i found it very difficult to
:>> understand these statements.
:>>
:>> 2)similarly the statements
:>> CLI 0(R8),c'-'
:>> CLI 1(R8),c'-'
:>> what does this 0 and 1 means.
:>> The general purpose register R8 points to the string.
:>>
:>> 3)NUMBER EQU *
:>> MVN EXPONENT+7(1),EXPSIGN
:>> i cant understand these statements also.What does this * means
:>> here?What will happen if the exponent is added with 7(1).
:>> Exponent is defined as
:>> EXPONENT DC D'0'
:>>
:>> Please give me the definitions for these statements.

--
Binyamin Dissen <***@dissensoftware.com>
http://www.dissensoftware.com

Director, Dissen Software, Bar & Grill - Israel


Should you use the mailblocks package and expect a response from me,
you should preauthorize the dissensoftware.com domain.

I very rarely bother responding to challenge/response systems,
especially those from irresponsible companies.

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
Charles Mills
2004-12-08 19:34:08 UTC
Permalink
I can't conceive of how anyone could be productive in assembler beyond
the most trivial modification to a working program without "learning
assembler." It's not like, for example, Rexx, where with an example and
a little hacking, one can become moderately good over time, working up
from the trivial to the moderately complex. It's just too non-intuitive
and there are too many gotchas. A 99% correct assembler program may
produce 0% satisfactory results, often with few clues (for the
uninitiated) as to what is wrong. It is possible to write total
assembler nonsense that assembles cleanly. Also, the necessary knowledge
is very fragmented. Knowing "assembler" is not enough, practically
speaking, one also has to understand the related concepts of machine
architecture, and system and I/O macros. A course or similar will teach
you all of those in a coordinated fashion; no one manual even alludes
significantly to the others.

There are several paths to learning:

- a class
- a tutorial book (not just the IBM manuals)
- sitting down with someone who is knowledgeable and has time

Charles



-----Original Message-----
From: IBM Mainframe Discussion List [mailto:IBM-***@ibm-main.lst
Behalf Of Vernooy, C.P. - SPLXM
Sent: Wednesday, December 08, 2004 1:55 AM
To: IBM-***@BAMA.UA.EDU
Subject: Re: High Level Assembler for MVS & VM & VSE


Ramesh,

please try to find an assembler course, this will teach you a 1000 times
more in a couple of days, than you will learn here from questions in a
year.

Kees.
Post by Ramesh Kumar
1)In this assembly language(High Level Assembler for MVS & VM & VSE)
some of the commands are like this,
BM *+16
B *+14
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
Bernd Oppolzer
2004-12-08 21:56:23 UTC
Permalink
I agree.

And even if you learn ASSEMBLER the "right" way, it will need years
of practical experience to understand all the tricks, for example how you can
write really large programs with only two or three base registers (in the
1980s, of course, today it will be much easier).

Or other ASSEMBLER "tricks":

LTORG - if you only do little exercise programs of limited size, you never get
an idea of what LTORG is needed for.

CNOP - you only understand the benefits of CNOP, if you have already
written some macros with instructions like the following:
B *+8
DC A(PARM)

XC A,B
XC B,A
XC A,B - only ASSEMBLER people normally know what these instructions do

TAB DC 256AL1(*-TAB) - identity table for TR as a one-liner

UNPK's use to produce readable hexadecimal output

and so on.

Great fun, but not easy to learn in short time ...

Kind regards

Bernd
Post by Charles Mills
I can't conceive of how anyone could be productive in assembler beyond
the most trivial modification to a working program without "learning
assembler." It's not like, for example, Rexx, where with an example and
a little hacking, one can become moderately good over time, working up
from the trivial to the moderately complex. It's just too non-intuitive
and there are too many gotchas. A 99% correct assembler program may
produce 0% satisfactory results, often with few clues (for the
uninitiated) as to what is wrong. It is possible to write total
assembler nonsense that assembles cleanly. Also, the necessary knowledge
is very fragmented. Knowing "assembler" is not enough, practically
speaking, one also has to understand the related concepts of machine
architecture, and system and I/O macros. A course or similar will teach
you all of those in a coordinated fashion; no one manual even alludes
significantly to the others.
- a class
- a tutorial book (not just the IBM manuals)
- sitting down with someone who is knowledgeable and has time
Charles
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
Rupert Reynolds
2004-12-13 19:05:36 UTC
Permalink
Post by Bernd Oppolzer
And even if you learn ASSEMBLER the "right" way, it will need years
of practical experience to understand all the tricks, for example how you can
write really large programs with only two or three base registers (in the
1980s, of course, today it will be much easier).
I was on an assembler course in around 1990 that attempted the theory as
well as the practice of relatively complex topics, including re-entrant
coding, 24/31-bit switching, being asked to exlain how XCTL works right
after we study standard savearea chaining, CNOP, DS 0H vs. EQU * and so
on. But apparently I was lucky. I was able to pass on the

TRTAB DC 256AL1(*-TRTAB)
ORG TRTAB+C'*' Translate * to space
DC C' '
ORG
from one expert to another. And back in the days of bit flags, we were
discussing defensive coding techniques and I thought that if we set a
flag by OR'ing with FLAG, the safest way of un-setting it is by AND'ing
it with 255-FLAG. I think. 10 years since I used it!

But for all I took time to learn my lessons (some of them /too/ easy,
such as BLANKS DC CL100' ' allowing every field to be blanked using MVC
FIELD,BLANKS) I have to say that some of the most useful or
thought-provoking bits of work have been done by people who appear, at a
casual glance, to have had far less experience than I have.

For this reason I don't put people off. In fact I'm thinking of putting
a running MVS 3.8 and a very basic interactive course on the web, just
to see who nibbles :-)

Roo

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
shmuel+ (Shmuel Metz , Seymour J.)
2004-12-14 03:28:24 UTC
Permalink
Post by Rupert Reynolds
And back in the days of bit flags, we were
discussing defensive coding techniques and I thought that if we set a
flag by OR'ing with FLAG, the safest way of un-setting it is by
AND'ing it with 255-FLAG.
That's the fastest way, but it is not guarantied to be MP-safe. There
are macros (NIL and OIL?) to serialize with CS.

--
Shmuel (Seymour J.) Metz, SysProg and JOAT
ISO position; see <http://patriot.net/~shmuel/resume/brief.html>
We don't care. We don't have to care, we're Congress.
(S877: The Shut up and Eat Your spam act of 2003)

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

shmuel+ (Shmuel Metz , Seymour J.)
2004-12-09 01:16:15 UTC
Permalink
Post by Charles Mills
I can't conceive of how anyone could be productive in assembler
beyond the most trivial modification to a working program without
"learning assembler." It's not like, for example, Rexx,
REXX has its own pitfalls for people who can't be bothered to read the
manuals.
Post by Charles Mills
- a class
- a tutorial book (not just the IBM manuals)
Beware; all of the assembler tutorials that I have seen had errors in
them.
Post by Charles Mills
- sitting down with someone who is knowledgeable and has time
Learning styles vary. I find it easier to learn from a reference than
from a lecture or tutorial.

--
Shmuel (Seymour J.) Metz, SysProg and JOAT
ISO position; see <http://patriot.net/~shmuel/resume/brief.html>
We don't care. We don't have to care, we're Congress.
(S877: The Shut up and Eat Your spam act of 2003)

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
shmuel+ (Shmuel Metz , Seymour J.)
2004-12-09 01:15:37 UTC
Permalink
Post by Charles Mills
I can't conceive of how anyone could be productive in assembler
beyond the most trivial modification to a working program without
"learning assembler." It's not like, for example, Rexx,
REXX has its own pitfalls for people who can't be bothered to read the
manuals.
Post by Charles Mills
- a class
- a tutorial book (not just the IBM manuals)
Beware; all of the assembler tutorials that I have seen had errors in
them.
Post by Charles Mills
- sitting down with someone who is knowledgeable and has time
Learning styles vary. I find it easier to learn from a reference than
from a lecture or tutorial.

--
Shmuel (Seymour J.) Metz, SysProg and JOAT
ISO position; see <http://patriot.net/~shmuel/resume/brief.html>
We don't care. We don't have to care, we're Congress.
(S877: The Shut up and Eat Your spam act of 2003)

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
Chase, John
2004-12-13 19:31:45 UTC
Permalink
Post by Charles Mills
-----Original Message-----
From: IBM Mainframe Discussion List On Behalf Of Rupert Reynolds
[ snip ]
.... And back in the days of bit flags, we were
discussing defensive coding techniques and I thought that if we set a
flag by OR'ing with FLAG, the safest way of un-setting it is
by AND'ing it with 255-FLAG. I think. 10 years since I used it!
IMO that's still the safest way to unset one (or more) bits.
Post by Charles Mills
But for all I took time to learn my lessons (some of them /too/ easy,
such as BLANKS DC CL100' ' allowing every field to be blanked using MVC
FIELD,BLANKS) ...
As long as FIELD <= 100 bytes. :-)

I've come to prefer two instructions back-to-back:

MVI FIELD,C' '
MVC FIELD+1(L'FIELD-1),FIELD

Works fine for 256-byte or shorter fields, and doesn't need a constant
defined.

For longer fields, if you have the length handy, MVCL works a treat.

-jc-

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
Loading...