Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
 Welcome to our latest new user maak ! (Registered 2024-04-18) You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > REL files
2022-08-26 10:00
Krill

Registered: Apr 2002
Posts: 2821
REL files

... are useless and a waste of DOS ROM space to the detriment of proper seeking in files.

Change my mind! =)
 
... 9 posts hidden. Click here to view all posts....
 
2022-08-26 18:01
tlr

Registered: Sep 2003
Posts: 1702
Quoting Krill
CBM DOS implements a real filesystem, of course.

Fair enough, but very crude. As you know it's central directory and singly linked list only.

Quoting Krill
And seeking is just a matter of following the block links and having some bookkeeping. :)

Doable, although it consumes a bit of memory drive side. A file could potentially fill the whole disk.
2022-08-26 18:10
Krill

Registered: Apr 2002
Posts: 2821
Quoting tlr
Quoting Krill
And seeking is just a matter of following the block links and having some bookkeeping. :)
Doable, although it consumes a bit of memory drive side. A file could potentially fill the whole disk.
But you don't need a list with T/S of each and every file block, more link sync points for each further track the file occupies.
And i guess you can make them sparse (with a fixed maximum memory footprint) for a heavily fragmented file - just takes a bit longer to seek, but then fragmented files are slower than need be anyways.
2022-08-27 23:42
Silver Dream !

Registered: Nov 2005
Posts: 107
Quote: CBM DOS implements a real filesystem, of course.
And seeking is just a matter of following the block links and having some bookkeeping. :)


Aren't REL files exactly about the "bookkeeping" part? ;-)
2022-08-28 09:12
Krill

Registered: Apr 2002
Posts: 2821
Quoting Silver Dream !
Aren't REL files exactly about the "bookkeeping" part? ;-)
Sure, but with on-disk overhead (side sectors) and drawbacks (such as having no support for arbitrary binary payload data).

I meant RAM-only dynamic bookkeeping to maintain an index structure.
2022-08-28 23:19
Silver Dream !

Registered: Nov 2005
Posts: 107
Quoting Krill
[…] drawbacks (such as having no support for arbitrary binary payload data).


What do you mean by that? It's been literally decades since I wrote a huge (by C64 means - had to use 1581 almost to the limit) database using only REL files so I might not remember all the problems I had to overcome but I don't recall anything I could fit here. Or do you refer to the fact that one had to "predict" record length once and for all (records)?
2022-08-28 23:30
Silver Dream !

Registered: Nov 2005
Posts: 107
BTW - that reminds me... I was wondering whether we have an established "de facto" standard for flattening REL files, which would preserve enough structure information to allow"deflattening" file back into the REL form?
2022-08-28 23:48
chatGPZ

Registered: Dec 2001
Posts: 11092
what about the good old PC64 format? (.R00)
2023-08-31 06:56
doctorfargo

Registered: Aug 2011
Posts: 20
I know that a lot of early text adventure games used REL files because it was faster than SEQ files.
2023-08-31 08:14
tlr

Registered: Sep 2003
Posts: 1702
Quote: I know that a lot of early text adventure games used REL files because it was faster than SEQ files.

Haven’t seen that, could you give an example?
2023-09-20 22:45
JeeK

Registered: Nov 2019
Posts: 4
Some of my self-written DB-like applications used the REL file type. Typical address management stuff an so on. If I reminding right a program collection manager too.
The handling is much more complex and more or less error-prone. I think many projects might turn away from REL files in desperation to get it right.
My next generation program collection manager uses a bucket of SEQ files and works with parts of it directly in RAM. This gives a much better performance in handling large datasets ...

A REL file is the closest form of file organization in comparison to other typical (modern) filesystems. At least in sense of positioning to a random location into a file. Alas, some attributes are not easy to obtain, even such basic thing like the file size (but it can be calculated by a binary algorithm). Other things are missing at all, like a current position which could be used for continuous read/write/append of records (bytes or other data block).

But in retrospective I would say the linked blocked file type (PRG, SEQ, USR) are sufficient and very efficient for the typical needs those days. For 99.99 % loading programs this was and is still fine. Applications around databases in any kind was not the core application usage of a C64. But the business lines (PET, CBM II also known as B model line) do also use disk drives with the same or even newer DOS versions having one or other more business-like applications in mind to run on and which benefit from using REL files.
Previous - 1 | 2 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Oxbow/Xenon
AMB/Level 64
sebalozlepsi
iAN CooG/HVSC
JEZ
Higgie/Kraze/Onslaught
da Blondie/Resource
Sentinel/Excess/TREX
mutetus/Ald ^ Ons
Viti/Hokuto Force
Mihai
Guests online: 119
Top Demos
1 Next Level  (9.8)
2 Mojo  (9.7)
3 Coma Light 13  (9.7)
4 Edge of Disgrace  (9.6)
5 Comaland 100%  (9.6)
6 No Bounds  (9.6)
7 Uncensored  (9.6)
8 Wonderland XIV  (9.6)
9 The Ghost  (9.6)
10 Bromance  (9.6)
Top onefile Demos
1 It's More Fun to Com..  (9.9)
2 Party Elk 2  (9.7)
3 Cubic Dream  (9.6)
4 Copper Booze  (9.5)
5 Rainbow Connection  (9.5)
6 TRSAC, Gabber & Pebe..  (9.5)
7 Onscreen 5k  (9.5)
8 Dawnfall V1.1  (9.5)
9 Quadrants  (9.5)
10 Daah, Those Acid Pil..  (9.5)
Top Groups
1 Oxyron  (9.3)
2 Nostalgia  (9.3)
3 Booze Design  (9.3)
4 Censor Design  (9.3)
5 Crest  (9.3)
Top NTSC-Fixers
1 Pudwerx  (10)
2 Booze  (9.7)
3 Stormbringer  (9.7)
4 Fungus  (9.6)
5 Grim Reaper  (9.3)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.039 sec.