Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

"The Street finds its own uses for technology." -- William Gibson


computers / comp.os.vms / VMS Basic and quad by value

SubjectAuthor
* VMS Basic and quad by valueArne Vajhøj
+* Re: VMS Basic and quad by valueBill Gunshannon
|`* Re: VMS Basic and quad by valueArne Vajhøj
| `* Re: VMS Basic and quad by valueDave Froble
|  +- Re: VMS Basic and quad by valueDave Froble
|  `* Re: VMS Basic and quad by valueArne Vajhøj
|   `* Re: VMS Basic and quad by valueDave Froble
|    `- Re: VMS Basic and quad by valueArne Vajhøj
`* Re: VMS Basic and quad by valueNeil Rieck
 `* Re: VMS Basic and quad by valueArne Vajhøj
  `* Re: VMS Basic and quad by valueNeil Rieck
   `- Re: VMS Basic and quad by valueRichard Brodie

1
VMS Basic and quad by value

<tgl5ek$3h6$1@gioia.aioe.org>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=24998&group=comp.os.vms#24998

  copy link   Newsgroups: comp.os.vms
Path: i2pn2.org!i2pn.org!aioe.org!LeVffQP25j5GAigzc2gaQA.user.46.165.242.75.POSTED!not-for-mail
From: arn...@vajhoej.dk (Arne Vajhøj)
Newsgroups: comp.os.vms
Subject: VMS Basic and quad by value
Date: Fri, 23 Sep 2022 16:37:38 -0400
Organization: Aioe.org NNTP Server
Message-ID: <tgl5ek$3h6$1@gioia.aioe.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Info: gioia.aioe.org; logging-data="3622"; posting-host="LeVffQP25j5GAigzc2gaQA.user.gioia.aioe.org"; mail-complaints-to="abuse@aioe.org";
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:102.0) Gecko/20100101
Thunderbird/102.3.0
Content-Language: en-US
X-Notice: Filtered by postfilter v. 0.9.2
 by: Arne Vajhøj - Fri, 23 Sep 2022 20:37 UTC

I am not good at Basic so I may be missing something obvious.

As I read the manual then I should be able to pass a quad by value.

But the compiler disagrees.

Can anybody shed some light on this?

Arne

Re: VMS Basic and quad by value

<jp6k84Fi080U1@mid.individual.net>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=24999&group=comp.os.vms#24999

  copy link   Newsgroups: comp.os.vms
Path: i2pn2.org!i2pn.org!news.swapon.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
From: bill.gun...@gmail.com (Bill Gunshannon)
Newsgroups: comp.os.vms
Subject: Re: VMS Basic and quad by value
Date: Fri, 23 Sep 2022 16:45:56 -0400
Lines: 15
Message-ID: <jp6k84Fi080U1@mid.individual.net>
References: <tgl5ek$3h6$1@gioia.aioe.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: individual.net 2J33CGwtdxcSlxeCFD/yDwGGHuDRcBilnNGpZ4bjg3Gm4LfwqA
Cancel-Lock: sha1:uaHN73IXExMKjTZVmNwK6B84HCY=
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101
Thunderbird/91.11.0
Content-Language: en-US
In-Reply-To: <tgl5ek$3h6$1@gioia.aioe.org>
 by: Bill Gunshannon - Fri, 23 Sep 2022 20:45 UTC

On 9/23/22 16:37, Arne Vajhøj wrote:
> I am not good at Basic so I may be missing something obvious.
>
> As I read the manual then I should be able to pass a quad by value.
>
> But the compiler disagrees.
>
> Can anybody shed some light on this?
>

Can you show us the code?

bill

Re: VMS Basic and quad by value

<tglcuh$13h3$1@gioia.aioe.org>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25000&group=comp.os.vms#25000

  copy link   Newsgroups: comp.os.vms
Path: i2pn2.org!i2pn.org!aioe.org!LeVffQP25j5GAigzc2gaQA.user.46.165.242.75.POSTED!not-for-mail
From: arn...@vajhoej.dk (Arne Vajhøj)
Newsgroups: comp.os.vms
Subject: Re: VMS Basic and quad by value
Date: Fri, 23 Sep 2022 18:45:35 -0400
Organization: Aioe.org NNTP Server
Message-ID: <tglcuh$13h3$1@gioia.aioe.org>
References: <tgl5ek$3h6$1@gioia.aioe.org> <jp6k84Fi080U1@mid.individual.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: gioia.aioe.org; logging-data="36387"; posting-host="LeVffQP25j5GAigzc2gaQA.user.gioia.aioe.org"; mail-complaints-to="abuse@aioe.org";
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:102.0) Gecko/20100101
Thunderbird/102.3.0
X-Notice: Filtered by postfilter v. 0.9.2
Content-Language: en-US
 by: Arne Vajhøj - Fri, 23 Sep 2022 22:45 UTC

On 9/23/2022 4:45 PM, Bill Gunshannon wrote:
> On 9/23/22 16:37, Arne Vajhøj wrote:
>> I am not good at Basic so I may be missing something obvious.
>>
>> As I read the manual then I should be able to pass a quad by value.
>>
>> But the compiler disagrees.
>>
>> Can anybody shed some light on this?
>>
>
> Can you show us the code?

Sure.

$ type z1.bas
program z1

declare quad v

v = 123
call f(v)

end program
!

sub f(quad a by value)

print a

end sub
$ bas z1

sub f(quad a by value)
................^
%BASIC-E-NOTRECVBY, A may not be received BY VALUE
at line number 11 in file DISK2:[ARNE.ipc.redis]z1.bas;7
%BASIC-E-ENDNOOBJ, DISK2:[ARNE.ipc.redis]z1.bas;7 completed with 1
diagnostic - object deleted

and the manual says:

<quote>
You can pass BYTE, WORD, LONG, QUAD, DOUBLE, GFLOAT, SINGLE,
SFLOAT, and TFLOAT values by value.
</quote>

This is on Alpha. There would be an obvious problem on VAX.

Arne

Re: VMS Basic and quad by value

<tgllc0$2porl$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25002&group=comp.os.vms#25002

  copy link   Newsgroups: comp.os.vms
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: dav...@tsoft-inc.com (Dave Froble)
Newsgroups: comp.os.vms
Subject: Re: VMS Basic and quad by value
Date: Fri, 23 Sep 2022 21:09:42 -0400
Organization: A noiseless patient Spider
Lines: 97
Message-ID: <tgllc0$2porl$1@dont-email.me>
References: <tgl5ek$3h6$1@gioia.aioe.org> <jp6k84Fi080U1@mid.individual.net>
<tglcuh$13h3$1@gioia.aioe.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Sep 2022 01:09:20 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="707a14d256ec986ef1a82e3b1489e92c";
logging-data="2941813"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+RG0AExJ15QUNvzmMmBro+ThOqLNECffg="
User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:MjfFQ9D9Cc9tGU2Jg6OE8PiEEyA=
In-Reply-To: <tglcuh$13h3$1@gioia.aioe.org>
 by: Dave Froble - Sat, 24 Sep 2022 01:09 UTC

On 9/23/2022 6:45 PM, Arne Vajhøj wrote:
> On 9/23/2022 4:45 PM, Bill Gunshannon wrote:
>> On 9/23/22 16:37, Arne Vajhøj wrote:
>>> I am not good at Basic so I may be missing something obvious.
>>>
>>> As I read the manual then I should be able to pass a quad by value.
>>>
>>> But the compiler disagrees.
>>>
>>> Can anybody shed some light on this?
>>>
>>
>> Can you show us the code?
>
> Sure.
>
> $ type z1.bas
> program z1
>
> declare quad v
>
> v = 123
> call f(v)

You do realize, I hope, that you are passing the variable by reference?

> end program
> !
>
> sub f(quad a by value)

I tried this. It appears that Basic does not allow an argument to be declared
QUAD and received By Value. I'd consider this a bug.

However, to demonstrate:

AS800> t z5.bas,z6.bas
1 ! Program Z5

Declare Quad Q

Q = 123
Call Z6( Q )
Print Q

End

SYS$SYSDEVICE:[DFE]Z6.BAS;4

1 ! Program Z6

Sub Z6( Long L By Value )

Print L

End Sub
AS800> run z5
2061851336
123
AS800>

As expected, the value of the argument is the address of the quadword variable
in program Z5.

> print a
>
> end sub
> $ bas z1
>
> sub f(quad a by value)
> ...............^
> %BASIC-E-NOTRECVBY, A may not be received BY VALUE
> at line number 11 in file DISK2:[ARNE.ipc.redis]z1.bas;7
> %BASIC-E-ENDNOOBJ, DISK2:[ARNE.ipc.redis]z1.bas;7 completed with 1 diagnostic -
> object deleted
>
> and the manual says:
>
> <quote>
> You can pass BYTE, WORD, LONG, QUAD, DOUBLE, GFLOAT, SINGLE,
> SFLOAT, and TFLOAT values by value.
> </quote>
>
> This is on Alpha. There would be an obvious problem on VAX.
>
> Arne
>
>
>

--
David Froble Tel: 724-529-0450
Dave Froble Enterprises, Inc. E-Mail: davef@tsoft-inc.com
DFE Ultralights, Inc.
170 Grimplin Road
Vanderbilt, PA 15486

Re: VMS Basic and quad by value

<tgllsp$2r80e$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25003&group=comp.os.vms#25003

  copy link   Newsgroups: comp.os.vms
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: dav...@tsoft-inc.com (Dave Froble)
Newsgroups: comp.os.vms
Subject: Re: VMS Basic and quad by value
Date: Fri, 23 Sep 2022 21:18:38 -0400
Organization: A noiseless patient Spider
Lines: 82
Message-ID: <tgllsp$2r80e$1@dont-email.me>
References: <tgl5ek$3h6$1@gioia.aioe.org> <jp6k84Fi080U1@mid.individual.net>
<tglcuh$13h3$1@gioia.aioe.org> <tgllc0$2porl$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Sep 2022 01:18:17 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="707a14d256ec986ef1a82e3b1489e92c";
logging-data="2990094"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+s4GrlreFWanlY0ESuzzgQE0ybe/uqTzA="
User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:Vgj1vWq17PbQ+uy1Fa17r6v+IpA=
In-Reply-To: <tgllc0$2porl$1@dont-email.me>
 by: Dave Froble - Sat, 24 Sep 2022 01:18 UTC

On 9/23/2022 9:09 PM, Dave Froble wrote:
> On 9/23/2022 6:45 PM, Arne Vajhøj wrote:
>> On 9/23/2022 4:45 PM, Bill Gunshannon wrote:
>>> On 9/23/22 16:37, Arne Vajhøj wrote:
>>>> I am not good at Basic so I may be missing something obvious.
>>>>
>>>> As I read the manual then I should be able to pass a quad by value.
>>>>
>>>> But the compiler disagrees.
>>>>
>>>> Can anybody shed some light on this?
>>>>
>>>
>>> Can you show us the code?
>>
>> Sure.
>>
>> $ type z1.bas
>> program z1
>>
>> declare quad v
>>
>> v = 123
>> call f(v)
>
> You do realize, I hope, that you are passing the variable by reference?
>
>> end program
>> !
>>
>> sub f(quad a by value)
>
> I tried this. It appears that Basic does not allow an argument to be declared
> QUAD and received By Value. I'd consider this a bug.
>
> However, to demonstrate:
>
> AS800> t z5.bas,z6.bas
> 1 ! Program Z5
>
> Declare Quad Q
>
> Q = 123
> Call Z6( Q )
> Print Q
>
> End
>
> SYS$SYSDEVICE:[DFE]Z6.BAS;4
>
> 1 ! Program Z6
>
> Sub Z6( Long L By Value )
>
> Print L
>
> End Sub
> AS800> run z5
> 2061851336
> 123
> AS800>
>
> As expected, the value of the argument is the address of the quadword variable
> in program Z5.
>

>>
>> This is on Alpha. There would be an obvious problem on VAX.

As a follow up, my test was using Alpha BASIC V1.7-000

I believe there are later versions of Basic.

I tried the test on VAX, and the Basic on the VAX, VAX BASIC V3.8-000, didn't
seem to like Quad data types. As expected.

--
David Froble Tel: 724-529-0450
Dave Froble Enterprises, Inc. E-Mail: davef@tsoft-inc.com
DFE Ultralights, Inc.
170 Grimplin Road
Vanderbilt, PA 15486

Re: VMS Basic and quad by value

<8e21d81d-a2f3-4999-8feb-648bf72a0d04n@googlegroups.com>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25007&group=comp.os.vms#25007

  copy link   Newsgroups: comp.os.vms
X-Received: by 2002:a05:622a:174f:b0:35c:d766:ae93 with SMTP id l15-20020a05622a174f00b0035cd766ae93mr10395257qtk.579.1664015031433;
Sat, 24 Sep 2022 03:23:51 -0700 (PDT)
X-Received: by 2002:a05:620a:4918:b0:6ce:3c8:4ef6 with SMTP id
ed24-20020a05620a491800b006ce03c84ef6mr8354292qkb.634.1664015031117; Sat, 24
Sep 2022 03:23:51 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.os.vms
Date: Sat, 24 Sep 2022 03:23:50 -0700 (PDT)
In-Reply-To: <tgl5ek$3h6$1@gioia.aioe.org>
Injection-Info: google-groups.googlegroups.com; posting-host=70.31.99.203; posting-account=QqCTBgkAAACie99dBE6oFauYH8hE6sk0
NNTP-Posting-Host: 70.31.99.203
References: <tgl5ek$3h6$1@gioia.aioe.org>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <8e21d81d-a2f3-4999-8feb-648bf72a0d04n@googlegroups.com>
Subject: Re: VMS Basic and quad by value
From: n.ri...@bell.net (Neil Rieck)
Injection-Date: Sat, 24 Sep 2022 10:23:51 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 2996
 by: Neil Rieck - Sat, 24 Sep 2022 10:23 UTC

On Friday, September 23, 2022 at 4:37:44 PM UTC-4, Arne Vajhøj wrote:
> I am not good at Basic so I may be missing something obvious.
>
> As I read the manual then I should be able to pass a quad by value.
>
> But the compiler disagrees.
>
> Can anybody shed some light on this?
>
> Arne

I have written "a lot" of BASIC programs for VMS and OpenVMS systems since 1987 and published many demos here:
https://neilrieck.net/demo_vms_html/openvms_demo_index.html
and have saved some recent BASIC manuals here:
https://neilrieck.net/misc/pdf/vms-docs/

IIRC, the QUAD data type was added to BASIC for the port from VAX to Alpha and it appears that it was not implemented fully or properly tested by Compaq. To make matters worse, many broken items were not fixed by HP for the port to Itanium. Some of the problems with BASIC-1.7 (see first link) were fixed by HP then sent to me as private patches but were never put into production for other customers. As I understand it, all my problems with the compiler and BASRTL have all been fixed in the VSI branded products so customers still working in the OpenVMS ecosystem need to move to VSI ASAP.

A good argument could be made about passing "a byte or word by value" being more efficient than "by ref" and we thought a lot that way on VAX. But anything larger than an address (includes a QUAD) would be passed more efficiently by ref. More than 5 years ago I had to jump through a few hoops in order to interface VMS-BASIC with C (or C-API) in order to connect BASIC with TCP/IP and MySQL/MariaDB client. In order to do build them I wrote these passing demos but do not recall ever passing anything by value.

https://neilrieck.net/demo_vms_html/openvms_demo_index.html#hybrid-demo-1

Neil Rieck
Waterloo, Ontario, Canada.
http://neilrieck.net

Re: VMS Basic and quad by value

<tgo219$759$1@gioia.aioe.org>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25018&group=comp.os.vms#25018

  copy link   Newsgroups: comp.os.vms
Path: i2pn2.org!i2pn.org!aioe.org!LeVffQP25j5GAigzc2gaQA.user.46.165.242.75.POSTED!not-for-mail
From: arn...@vajhoej.dk (Arne Vajhøj)
Newsgroups: comp.os.vms
Subject: Re: VMS Basic and quad by value
Date: Sat, 24 Sep 2022 18:57:42 -0400
Organization: Aioe.org NNTP Server
Message-ID: <tgo219$759$1@gioia.aioe.org>
References: <tgl5ek$3h6$1@gioia.aioe.org> <jp6k84Fi080U1@mid.individual.net>
<tglcuh$13h3$1@gioia.aioe.org> <tgllc0$2porl$1@dont-email.me>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: gioia.aioe.org; logging-data="7337"; posting-host="LeVffQP25j5GAigzc2gaQA.user.gioia.aioe.org"; mail-complaints-to="abuse@aioe.org";
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:102.0) Gecko/20100101
Thunderbird/102.3.0
Content-Language: en-US
X-Notice: Filtered by postfilter v. 0.9.2
 by: Arne Vajhøj - Sat, 24 Sep 2022 22:57 UTC

On 9/23/2022 9:09 PM, Dave Froble wrote:
> On 9/23/2022 6:45 PM, Arne Vajhøj wrote:
>> On 9/23/2022 4:45 PM, Bill Gunshannon wrote:
>>> On 9/23/22 16:37, Arne Vajhøj wrote:
>>>> I am not good at Basic so I may be missing something obvious.
>>>>
>>>> As I read the manual then I should be able to pass a quad by value.
>>>>
>>>> But the compiler disagrees.
>>>>
>>>> Can anybody shed some light on this?
>>>>
>>>
>>> Can you show us the code?
>>
>> Sure.
>>
>> $ type z1.bas
>> program z1
>>
>> declare quad v
>>
>> v = 123
>> call f(v)
>
> You do realize, I hope, that you are passing the variable by reference?

No. I don't.

:-)

>> end program
>> !
>>
>> sub f(quad a by value)
>
> I tried this.  It appears that Basic does not allow an argument to be
> declared QUAD and received By Value.  I'd consider this a bug.

Given that the docs claims it should work, then it must
be a bug.

And I believe the compiler should be fixed not the documentation,
because on Alpha, Itanium and x86-64 there is no reason not to
allow it.

> However, to demonstrate:
>
> AS800> t z5.bas,z6.bas
> 1       ! Program Z5
>
>         Declare Quad Q
>
>         Q = 123
>         Call Z6( Q )
>         Print Q
>
> End
>
> SYS$SYSDEVICE:[DFE]Z6.BAS;4
>
> 1       ! Program Z6
>
>         Sub Z6( Long L By Value )
>
>         Print L
>
>         End Sub
> AS800> run z5
>  2061851336
>  123
> AS800>
>
> As expected, the value of the argument is the address of the quadword
> variable in program Z5.

Two compilation units. I only had one.

It seems to work with long.

$ typ z2.bas
program z2

declare quad v

v = 123
call f(v)

end program
!

sub f(quad a)

print a

end sub
$ bas z2
$ lin z2
$ r z2
123

Apparently the Basic compiler do look ahead in the compilation unit.

Arne

Re: VMS Basic and quad by value

<tgo2dn$b4v$1@gioia.aioe.org>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25019&group=comp.os.vms#25019

  copy link   Newsgroups: comp.os.vms
Path: i2pn2.org!i2pn.org!aioe.org!LeVffQP25j5GAigzc2gaQA.user.46.165.242.75.POSTED!not-for-mail
From: arn...@vajhoej.dk (Arne Vajhøj)
Newsgroups: comp.os.vms
Subject: Re: VMS Basic and quad by value
Date: Sat, 24 Sep 2022 19:04:20 -0400
Organization: Aioe.org NNTP Server
Message-ID: <tgo2dn$b4v$1@gioia.aioe.org>
References: <tgl5ek$3h6$1@gioia.aioe.org>
<8e21d81d-a2f3-4999-8feb-648bf72a0d04n@googlegroups.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: gioia.aioe.org; logging-data="11423"; posting-host="LeVffQP25j5GAigzc2gaQA.user.gioia.aioe.org"; mail-complaints-to="abuse@aioe.org";
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:102.0) Gecko/20100101
Thunderbird/102.3.0
X-Notice: Filtered by postfilter v. 0.9.2
Content-Language: en-US
 by: Arne Vajhøj - Sat, 24 Sep 2022 23:04 UTC

On 9/24/2022 6:23 AM, Neil Rieck wrote:
> On Friday, September 23, 2022 at 4:37:44 PM UTC-4, Arne Vajhøj
> wrote:
>> I am not good at Basic so I may be missing something obvious.
>>
>> As I read the manual then I should be able to pass a quad by
>> value.
>>
>> But the compiler disagrees.
>>
>> Can anybody shed some light on this?
>
> I have written "a lot" of BASIC programs for VMS and OpenVMS systems
> since 1987 and published many demos here:
> https://neilrieck.net/demo_vms_html/openvms_demo_index.html and have
> saved some recent BASIC manuals here:
> https://neilrieck.net/misc/pdf/vms-docs/
>
> IIRC, the QUAD data type was added to BASIC for the port from VAX to
> Alpha and it appears that it was not implemented fully or properly
> tested by Compaq. To make matters worse, many broken items were not
> fixed by HP for the port to Itanium. Some of the problems with
> BASIC-1.7 (see first link) were fixed by HP then sent to me as
> private patches but were never put into production for other
> customers. As I understand it, all my problems with the compiler and
> BASRTL have all been fixed in the VSI branded products so customers
> still working in the OpenVMS ecosystem need to move to VSI ASAP.

I am testing with VSI Basic 1.8.

I will just conclude that quad by value is not supported
for now.

Arne

Re: VMS Basic and quad by value

<tgo5ak$33ci6$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25022&group=comp.os.vms#25022

  copy link   Newsgroups: comp.os.vms
Path: i2pn2.org!i2pn.org!usenet.goja.nl.eu.org!weretis.net!feeder8.news.weretis.net!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: dav...@tsoft-inc.com (Dave Froble)
Newsgroups: comp.os.vms
Subject: Re: VMS Basic and quad by value
Date: Sat, 24 Sep 2022 19:54:15 -0400
Organization: A noiseless patient Spider
Lines: 117
Message-ID: <tgo5ak$33ci6$1@dont-email.me>
References: <tgl5ek$3h6$1@gioia.aioe.org> <jp6k84Fi080U1@mid.individual.net>
<tglcuh$13h3$1@gioia.aioe.org> <tgllc0$2porl$1@dont-email.me>
<tgo219$759$1@gioia.aioe.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Sep 2022 23:53:56 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="3801cd5228066952cc1541d3ff8187db";
logging-data="3256902"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18dOMOvCGMJvSbEVgV2h51yKBoszj07myQ="
User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:F8Bk/IAKztZSmWu5yOkzLJU485w=
In-Reply-To: <tgo219$759$1@gioia.aioe.org>
 by: Dave Froble - Sat, 24 Sep 2022 23:54 UTC

On 9/24/2022 6:57 PM, Arne Vajhøj wrote:
> On 9/23/2022 9:09 PM, Dave Froble wrote:
>> On 9/23/2022 6:45 PM, Arne Vajhøj wrote:
>>> On 9/23/2022 4:45 PM, Bill Gunshannon wrote:
>>>> On 9/23/22 16:37, Arne Vajhøj wrote:
>>>>> I am not good at Basic so I may be missing something obvious.
>>>>>
>>>>> As I read the manual then I should be able to pass a quad by value.
>>>>>
>>>>> But the compiler disagrees.
>>>>>
>>>>> Can anybody shed some light on this?
>>>>>
>>>>
>>>> Can you show us the code?
>>>
>>> Sure.
>>>
>>> $ type z1.bas
>>> program z1
>>>
>>> declare quad v
>>>
>>> v = 123
>>> call f(v)
>>
>> You do realize, I hope, that you are passing the variable by reference?
>
> No. I don't.
>
> :-)
>
>>> end program
>>> !
>>>
>>> sub f(quad a by value)
>>
>> I tried this. It appears that Basic does not allow an argument to be declared
>> QUAD and received By Value. I'd consider this a bug.
>
> Given that the docs claims it should work, then it must
> be a bug.
>
> And I believe the compiler should be fixed not the documentation,
> because on Alpha, Itanium and x86-64 there is no reason not to
> allow it.
>
>
>> However, to demonstrate:
>>
>> AS800> t z5.bas,z6.bas
>> 1 ! Program Z5
>>
>> Declare Quad Q
>>
>> Q = 123
>> Call Z6( Q )
>> Print Q
>>
>> End
>>
>> SYS$SYSDEVICE:[DFE]Z6.BAS;4
>>
>> 1 ! Program Z6
>>
>> Sub Z6( Long L By Value )
>>
>> Print L
>>
>> End Sub
>> AS800> run z5
>> 2061851336
>> 123
>> AS800>
>>
>> As expected, the value of the argument is the address of the quadword variable
>> in program Z5.
>
> Two compilation units. I only had one.

I never do that ...

> It seems to work with long.
>
> $ typ z2.bas
> program z2
>
> declare quad v
>
> v = 123
> call f(v)
>
> end program
> !
>
> sub f(quad a)
>
> print a
>
> end sub
> $ bas z2
> $ lin z2
> $ r z2
> 123
>
> Apparently the Basic compiler do look ahead in the compilation unit.

I doubt that. Note that in this last example, you did not attempt to declare
the argument in the sub statement to be declared by value.

--
David Froble Tel: 724-529-0450
Dave Froble Enterprises, Inc. E-Mail: davef@tsoft-inc.com
DFE Ultralights, Inc.
170 Grimplin Road
Vanderbilt, PA 15486

Re: VMS Basic and quad by value

<tgo6us$1n91$1@gioia.aioe.org>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25023&group=comp.os.vms#25023

  copy link   Newsgroups: comp.os.vms
Path: i2pn2.org!i2pn.org!aioe.org!LeVffQP25j5GAigzc2gaQA.user.46.165.242.75.POSTED!not-for-mail
From: arn...@vajhoej.dk (Arne Vajhøj)
Newsgroups: comp.os.vms
Subject: Re: VMS Basic and quad by value
Date: Sat, 24 Sep 2022 20:21:45 -0400
Organization: Aioe.org NNTP Server
Message-ID: <tgo6us$1n91$1@gioia.aioe.org>
References: <tgl5ek$3h6$1@gioia.aioe.org> <jp6k84Fi080U1@mid.individual.net>
<tglcuh$13h3$1@gioia.aioe.org> <tgllc0$2porl$1@dont-email.me>
<tgo219$759$1@gioia.aioe.org> <tgo5ak$33ci6$1@dont-email.me>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: gioia.aioe.org; logging-data="56609"; posting-host="LeVffQP25j5GAigzc2gaQA.user.gioia.aioe.org"; mail-complaints-to="abuse@aioe.org";
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:102.0) Gecko/20100101
Thunderbird/102.3.0
X-Notice: Filtered by postfilter v. 0.9.2
Content-Language: en-US
 by: Arne Vajhøj - Sun, 25 Sep 2022 00:21 UTC

On 9/24/2022 7:54 PM, Dave Froble wrote:
> On 9/24/2022 6:57 PM, Arne Vajhøj wrote:
>> Two compilation units. I only had one.
>
> I never do that ...

I never do Basic os ...

>> It seems to work with long.
>>
>> $ typ z2.bas
>> program z2
>>
>> declare quad v
>>
>> v = 123
>> call f(v)
>>
>> end program
>> !
>>
>> sub f(quad a)
>>
>>     print a
>>
>> end sub
>> $ bas z2
>> $ lin z2
>> $ r z2
>>  123
>>
>> Apparently the Basic compiler do look ahead in the compilation unit.
>
> I doubt that.  Note that in this last example, you did not attempt to
> declare the argument in the sub statement to be declared by value.

Ooops.

That was a quad default mechanism example not a long example.

I messed up. You are right - it needs to be declared.

Arne

Re: VMS Basic and quad by value

<b6a786b3-11a0-4f2d-838f-9da516eb4a3bn@googlegroups.com>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25070&group=comp.os.vms#25070

  copy link   Newsgroups: comp.os.vms
X-Received: by 2002:a05:6214:1bcd:b0:4af:646a:9793 with SMTP id m13-20020a0562141bcd00b004af646a9793mr16035910qvc.94.1664380033043;
Wed, 28 Sep 2022 08:47:13 -0700 (PDT)
X-Received: by 2002:a05:622a:1451:b0:35c:c676:1471 with SMTP id
v17-20020a05622a145100b0035cc6761471mr26954199qtx.634.1664380032823; Wed, 28
Sep 2022 08:47:12 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.os.vms
Date: Wed, 28 Sep 2022 08:47:12 -0700 (PDT)
In-Reply-To: <tgo2dn$b4v$1@gioia.aioe.org>
Injection-Info: google-groups.googlegroups.com; posting-host=70.31.97.35; posting-account=QqCTBgkAAACie99dBE6oFauYH8hE6sk0
NNTP-Posting-Host: 70.31.97.35
References: <tgl5ek$3h6$1@gioia.aioe.org> <8e21d81d-a2f3-4999-8feb-648bf72a0d04n@googlegroups.com>
<tgo2dn$b4v$1@gioia.aioe.org>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <b6a786b3-11a0-4f2d-838f-9da516eb4a3bn@googlegroups.com>
Subject: Re: VMS Basic and quad by value
From: n.ri...@bell.net (Neil Rieck)
Injection-Date: Wed, 28 Sep 2022 15:47:13 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 3199
 by: Neil Rieck - Wed, 28 Sep 2022 15:47 UTC

On Saturday, September 24, 2022 at 7:04:26 PM UTC-4, Arne Vajhøj wrote:
> On 9/24/2022 6:23 AM, Neil Rieck wrote:
> > On Friday, September 23, 2022 at 4:37:44 PM UTC-4, Arne Vajhøj
> > wrote:
> >> I am not good at Basic so I may be missing something obvious.
> >>
> >> As I read the manual then I should be able to pass a quad by
> >> value.
> >>
> >> But the compiler disagrees.
> >>
> >> Can anybody shed some light on this?
> >
> > I have written "a lot" of BASIC programs for VMS and OpenVMS systems
> > since 1987 and published many demos here:
> > https://neilrieck.net/demo_vms_html/openvms_demo_index.html and have
> > saved some recent BASIC manuals here:
> > https://neilrieck.net/misc/pdf/vms-docs/
> >
> > IIRC, the QUAD data type was added to BASIC for the port from VAX to
> > Alpha and it appears that it was not implemented fully or properly
> > tested by Compaq. To make matters worse, many broken items were not
> > fixed by HP for the port to Itanium. Some of the problems with
> > BASIC-1.7 (see first link) were fixed by HP then sent to me as
> > private patches but were never put into production for other
> > customers. As I understand it, all my problems with the compiler and
> > BASRTL have all been fixed in the VSI branded products so customers
> > still working in the OpenVMS ecosystem need to move to VSI ASAP.
> I am testing with VSI Basic 1.8.
>
> I will just conclude that quad by value is not supported
> for now.
>
> Arne

Quick question about VSI BASIC 1.8

Could you verify if the QUAD and DECIMAL bugs I flagged here in BASIC 1.7 are fixed?
https://neilrieck.net/demo_vms_html/openvms_demo_index.html#basic-compiler-bugs

Also, please declare an array of QUAD then attempt to zero it (or do anything else) using one of the MAT commands.

Thanks

Neil Rieck
Waterloo, Ontario, Canada.
http://neilrieck.net

Re: VMS Basic and quad by value

<afff369c-fb41-4380-a84d-6f42ab107054n@googlegroups.com>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=25071&group=comp.os.vms#25071

  copy link   Newsgroups: comp.os.vms
X-Received: by 2002:a05:6214:27e2:b0:4ac:97ba:57b5 with SMTP id jt2-20020a05621427e200b004ac97ba57b5mr26592528qvb.130.1664381466392;
Wed, 28 Sep 2022 09:11:06 -0700 (PDT)
X-Received: by 2002:a05:622a:1827:b0:35b:bb7f:6851 with SMTP id
t39-20020a05622a182700b0035bbb7f6851mr27292272qtc.457.1664381466162; Wed, 28
Sep 2022 09:11:06 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.os.vms
Date: Wed, 28 Sep 2022 09:11:05 -0700 (PDT)
In-Reply-To: <b6a786b3-11a0-4f2d-838f-9da516eb4a3bn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=130.246.91.22; posting-account=h471qwoAAADEqfDUYXQzwOy37zR5H-_L
NNTP-Posting-Host: 130.246.91.22
References: <tgl5ek$3h6$1@gioia.aioe.org> <8e21d81d-a2f3-4999-8feb-648bf72a0d04n@googlegroups.com>
<tgo2dn$b4v$1@gioia.aioe.org> <b6a786b3-11a0-4f2d-838f-9da516eb4a3bn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <afff369c-fb41-4380-a84d-6f42ab107054n@googlegroups.com>
Subject: Re: VMS Basic and quad by value
From: ergame...@gmail.com (Richard Brodie)
Injection-Date: Wed, 28 Sep 2022 16:11:06 +0000
Content-Type: text/plain; charset="UTF-8"
X-Received-Bytes: 1730
 by: Richard Brodie - Wed, 28 Sep 2022 16:11 UTC

On Wednesday, 28 September 2022 at 16:47:14 UTC+1, Neil Rieck wrote:

> Could you verify if the QUAD and DECIMAL bugs I flagged here in BASIC 1.7 are fixed?
> https://neilrieck.net/demo_vms_html/openvms_demo_index.html#basic-compiler-bugs

QUAD bug is fixed. DECIMAL warns about loss of precision but is not fixed.

> Also, please declare an array of QUAD then attempt to zero it (or do anything else) using one of the MAT commands.

Seems to work OK. Tested on Itanium.

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor