🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: bit.listserv.asm370
Article #136

Re: Shifting memory to the right

#136
From: Blaicher, Chris
Date: Fri, 30 Sep 2005 18:25
89 lines
5153 bytes
My personal favorite is to hash a table.  It can be blazingly fast if
you have a good key to randomize on.  How long and what type of data is
the key?  How long is the whole row?

One thing that helps a lot is to use a prime number as your hashing
value.  Most of the ones I have used result in a look-up rate of a small
fraction over 1.  I only have to look at a collision chain about 1 time
in a thousand accesses.

Christopher Y. Blaicher
BMC Software, Inc.
Austin Development Labs
(512) 340-6154
BMC Software, Inc. makes no representations or promises regarding the
reliability, completeness, or accuracy of the information provided in
this discussion; all readers agree not to rely on this information or
take any action against BMC Software in response to this information.

-----Original Message-----
From: IBM Mainframe Assembler List
[mailto:ASSEMBLER-LIST@LISTSERV.UGA.EDU] On Behalf Of Don Nielsen
Sent: Friday, September 30, 2005 9:58 AM
To: ASSEMBLER-LIST@LISTSERV.UGA.EDU
Subject: Re: Shifting memory to the right

> Why not just have the table entries linked with a "next" pointer ?

Binary searching of the tables after they have been loaded.

> Have a second buffer for the table.

Good thought.  There are three tables involved, which are already very
large (75 meg between them).  I'll look into a fourth for buffer space.



-----Original Message-----
From: IBM Mainframe Assembler List
[mailto:ASSEMBLER-LIST@LISTSERV.UGA.EDU]On Behalf Of Beate Kawelke
Sent: Friday, September 30, 2005 9:14 AM
To: ASSEMBLER-LIST@LISTSERV.UGA.EDU
Subject: Re: Shifting memory to the right


Hmmmm - two thoughts:

1. Why not just have the table entries linked with a "next" pointer ? If
necessary, throw in a "previous" pointer, too. Navigation through the
table is quite easy, and you can add / delete entries simply by chaining
them in the right place.
2. Have a second buffer for the table. Move upper part to buffer, then
the new entry, then the lower part.

HTH, Beate

> -----Original Message-----
> From: IBM Mainframe Assembler List
> [mailto:ASSEMBLER-LIST@LISTSERV.UGA.EDU] On Behalf Of Don Nielsen
> Sent: Friday, September 30, 2005 3:56 PM
> To: ASSEMBLER-LIST@LISTSERV.UGA.EDU
> Subject: [ASSEMBLER-LIST] Shifting memory to the right
>
> Nothing like a dumb applications programmer question to end
> the week.  Is there an instruction like MVCL that moves
> memory starting at the end working to the beginning.  I have
> a table that is in sequence.  I want to insert a new row,
> maintaining sequence.  That requires shifting right the end
> of the table.  It would be great to just code an MVCL to do
> it, but I would be overwrite data.  But if MVCL started with
> the last byte and worked its way to the start, then the shift
> would be easy.  Does any such instruction or function exist?
>
> I guess I could do something silly and build the table
> starting at the end of the of memory block and shift it left
> as I build it.
>
> dvn
>
> Don V Nielsen
> Products & Tools
> CMS
> 3707 Corporate Drive
> Marshfield, WI 54449
> donn@cmscms.com
>
> > '715-486-8807 X434
> >
> Better Results, Faster!
>
Technical Details
Message-ID: <4C38B972143E1A4BA2D5E1F12104ECA60F9A2BC7@aus-ex-01.adprod.bmc.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!atl-c02.usenetserver.com!news.usenetserver.com!atl-c04.usenetserver.com!news.usenetserver.com!newsfeed.berkeley.edu!ucberkeley!sn-xit-02!sn-xit-06!sn-xit-14!supernews.com!149.173.6.116.MISMATCH!foggy!vm.sas.com!bmc.com!Chris_Blaicher

Show Full Headers
Complete Article Headers
X-Google-Thread: fcdcb,3e46d196c2b56e33
X-Google-Attributes: gidfcdcb,public
X-Google-Language: ENGLISH,ASCII-7-bit
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!atl-c02.usenetserver.com!news.usenetserver.com!atl-c04.usenetserver.com!news.usenetserver.com!newsfeed.berkeley.edu!ucberkeley!sn-xit-02!sn-xit-06!sn-xit-14!supernews.com!149.173.6.116.MISMATCH!foggy!vm.sas.com!bmc.com!Chris_Blaicher
From: "Blaicher, Chris" <Chris_Blaicher@bmc.com>
Newsgroups: bit.listserv.asm370
Subject: Re: Shifting memory to the right
Date: Fri, 30 Sep 2005 13:25:24 -0500
Organization: SAS Inc.
Lines: 89
Sender: IBM Mainframe Assembler List <ASSEMBLER-LIST@LISTSERV.UGA.EDU>
Message-ID: <4C38B972143E1A4BA2D5E1F12104ECA60F9A2BC7@aus-ex-01.adprod.bmc.com>
NNTP-Posting-Host: mozart.unx.sas.com
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Trace: foggy.unx.sas.com 1128105512 22475 10.19.150.41 (30 Sep 2005 18:38:32 GMT)
X-Complaints-To: usenet@unx.sas.com
NNTP-Posting-Date: Fri, 30 Sep 2005 18:38:32 +0000 (UTC)
Comments: Gated by NETNEWS@VM.SAS.COM
Return-Path: <owner-assembler-list@LISTSERV.UGA.EDU>
X-MimeOLE: Produced By Microsoft Exchange V6.0.6603.0
content-class: urn:content-classes:message
Thread-Topic: Re: Shifting memory to the right
Thread-Index: AcXFydScro0Or7ksQSumTCMZ+phurQABSQZQAAbmfjA=
X-OriginalArrivalTime: 30 Sep 2005 18:25:24.0621 (UTC)
                       FILETIME=[530C83D0:01C5C5EC]
X-Spamicity: Yes, tests=bogofilter, spamicity=0.999742, version=0.94.14
X-MIME-Autoconverted: from quoted-printable to 8bit by listserv.cc.uga.edu id
                      j8UIPPsW017324
Approved-By: "Blaicher, Chris" <Chris_Blaicher@BMC.COM>
Return-Path: owner-assembler-list@LISTSERV.UGA.EDU
X-Mime-Autoconverted: from 8bit to 7bit by mime827
Originator: daemon@mozart.unx.sas.com