Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
v3:memory_model [2022/12/29 19:05] – [Commodore-64] neilsv3:memory_model [2024/07/03 19:52] (current) – [Zeropage] neils
Line 1: Line 1:
 ====== Memory model ====== ====== Memory model ======
  
-The following addresses are subject to change, even between minor versions.+The following addresses are subject to change. Visit this page for updates.
 ===== Zeropage ===== ===== Zeropage =====
  
-[pet] [vic20] [c64] [c16] [cplus4] [c128]+[pet] [vic20] [c64] [c16] [cplus4] [c128] [m65]
  
-| $02-$14    | 18 bytes     | XC=BASIC Virtual Registers        | +| $02-$14    | 19 bytes     | XC=BASIC Virtual Registers        | 
-| $15-$3A    | 37 bytes     | Floating point workspace      | +| $15-$3A    | 38 bytes     | Floating point workspace      | 
-| $3B-$69    | 46 bytes     | Free space for [[v3:variables#fast_variables|FAST variables]]  |+| $3B-$69    | 47 bytes     | Free space for [[v3:variables#fast_variables|FAST variables]]  |
  
 [x16] [x16]
  
-| $22-$34    | 18 bytes     | XC=BASIC Virtual Registers        | +| $22-$34    | 19 bytes     | XC=BASIC Virtual Registers        | 
-| $35-$7F    | 74 bytes     | Free space for [[v3:variables#fast_variables|FAST variables]]               | +| $35-$7F    | 75 bytes     | Free space for [[v3:variables#fast_variables|FAST variables]]               | 
-| $A9-$CE    | 37 bytes     | Floating point workspace      |+| $A9-$CE    | 38 bytes     | Floating point workspace      |
  
 ===== Other reserved areas ===== ===== Other reserved areas =====
Line 20: Line 20:
 [vic20] [c64] [c16] [cplus4] [c128] [vic20] [c64] [c16] [cplus4] [c128]
  
-| $033C-$03FC    | 192 bytes     | Temporary storage during string operations  |+| $033C-$03FB    | 192 bytes     | Temporary storage during string operations  |
  
 [pet] [pet]
  
-| $033A-$03FA    | 192 bytes     | Temporary storage during string operations  |+| $033A-$03F9    | 192 bytes     | Temporary storage during string operations  |
  
 [x16] [x16]
Line 31: Line 31:
 ===== Program code and data ===== ===== Program code and data =====
  
-[c64]+==== Commodore-64 ====
  
 | $0801 - $080C | 12 bytes | BASIC Loader (can be disabled) | | $0801 - $080C | 12 bytes | BASIC Loader (can be disabled) |
Line 83: Line 83:
 | ???? - $7EFF | | Function stack (growing downwards) | | ???? - $7EFF | | Function stack (growing downwards) |
 | $7F00 - $7FFF | | String stack | | $7F00 - $7FFF | | String stack |
 +
 +==== Commodore-128 ====
 +
 +| $1001 - $100C | 12 bytes | BASIC Loader (can be disabled) |
 +| $100D - ???? | | Program code |
 +| ???? - ???? | | Library |
 +| ???? - ???? | | Variables |
 +| ???? - $BEFF | | Function stack (growing downwards) |
 +| $BF00 - $BFFF | 256 bytes | String stack |
 +==== Commander X16 ====
 +
 +| ???? - $06FF | | Function stack (growing downwards) |
 +| $0700 - $07FF | 256 bytes | String stack |
 +| $0801 - $080C | 12 bytes | BASIC Loader (can be disabled) |
 +| $080D - ???? | | Program code |
 +| ???? - ???? | | Library |
 +| ???? - ???? | | Variables |