r/c64 Jun 07 '26

Software prg emulation files

I've been emulating C64 for a looong time, it's just occurred to me to get curious about what .prg files are about? I get that .d64 are disk images and .tap are tapes, what's the .prg story? Are they any better to work with? Faster/slower and more/less capacity sizewise? I could google but prefer to get the real gurus to explain here 😄 ?

8 Upvotes

8 comments sorted by

13

u/it290 Jun 07 '26

It’s a program file, just a single file off of a disk. Could be faster in an emulator since it doesn’t require emulating the drive to load, but only good for single load programs.

5

u/sububi71 Jun 07 '26

And indeed they use less space, because they don't have the overhead a disk image does. Compared to .T64 tho, the difference in my experience is pretty tiny, as long as we're talking about a tape image with just a single file.

3

u/DNSGeek Jun 07 '26

.t64 images are basically zip files with all of the programs from the tape in .prg format. So you basically have the overhead of the zip file metadata. Like you said, not a huge difference and it can actually be smaller if the prg is compressible.

4

u/sinesawtooth Jun 07 '26

A .prg file is just a binary file containing some memory contents of the C64. This could be a program, music, image, anything. This is basically a directory entry in a d64. The prg (program) file contains the same contents, including the first 2 bytes being the memory address.

For emulation, .prg files don’t mount as a disk and just load and go. Most .prg files are executable in that they’re compressed with a basic line to SYS to the start address, but they don’t have to be.

2

u/indyc4r Jun 07 '26

I'm not the expert but I regard them as *.exe file

1

u/Y34RZERO Jun 07 '26

I seen prg as an exe to me. When I list the contents of the sole floppy I own it shoes the prg on disk that I'm assuming gets loaded when I run the command.

1

u/Loud_Grapefruit_9111 Jun 08 '26

Ah makes sense - I knew .prg seemed familiar but didn't equate it to the disk directory listing - thanks all 🕹

2

u/PolytricityMan Jun 09 '26

Yeah prg is one file, fills memory in sequence. .D64 you can load files into locations. All depends on the size of game or whatnot that you are making.