1
0
mirror of https://github.com/cc65/cc65.git synced 2024-11-19 06:31:31 +00:00
cc65 - a freeware C compiler for 6502 based systems
Go to file
Oliver Schmidt 3d08abcfa8 Load INITBSS segment from disk.
Conceptually the INITBSS segment is not initialized in any way. Therefore it makes sense to not load it from disk. However the INIT segment has to be loaded from disk and therefore moved to its run location above the INITBSS segment. The necessary move routine increases runtime RAM usage :-(

Therefore we now "unnecessarily" load the INITBSS segment from disk too meaning that the INIT segment is loaded at its run location. Therefore there's no need for the move routine anymore.

After all we trade disk space for (runtime) RAM space - an easy decision ;-)

Notes:

- The code allowing to re-run a program without re-load present so far could not have worked as far as I can see as it only avoided to re-run the move routine but still tried to re-run the code in the INIT segment that was clobbered by zeroing the BSS. Therefore I removed the code in question altogether. I'm personally not into this "dirty re-run" but if someone wants to add an actually working solution I won't block that.

- INITBSS is intentionally not just merged with the DATA segment as ROM-based targets can't reuse the INIT segment for the BSS and therefore have no reason to place the INIT segment above INITBSS.

- Because ROM-based targets don't copy INITBSS from the ROM (like it is done with the DATA segment) all users of INITBSS _MUST_NOT_ presume INITBSS to be initialized with zeros!
2016-02-28 19:45:36 +01:00
asminc Merge pull request #238 from mrdudz/gamate 2016-02-27 18:44:26 +01:00
cfg Load INITBSS segment from disk. 2016-02-28 19:45:36 +01:00
doc Merge pull request #238 from mrdudz/gamate 2016-02-27 18:44:26 +01:00
include Merge pull request #238 from mrdudz/gamate 2016-02-27 18:44:26 +01:00
libsrc Load INITBSS segment from disk. 2016-02-28 19:45:36 +01:00
samples fix hello.c 2015-11-30 19:48:10 +01:00
src Merge pull request #238 from mrdudz/gamate 2016-02-27 18:44:26 +01:00
test Added a cc65 regression test for pointer and offset addition operations. 2016-01-01 11:39:55 -05:00
testcode Merge pull request #238 from mrdudz/gamate 2016-02-27 18:44:26 +01:00
util dont use that silly buffer 2015-11-29 21:15:10 +01:00
.gitignore use 'testwrk' dir for bdiff 2014-11-25 12:56:45 +01:00
.travis.yml Update package index (as recommended by Travis CI). 2015-12-16 12:24:47 +01:00
LICENSE Simplified license. 2015-05-05 21:56:23 +02:00
Makefile Create zip file. 2014-03-09 00:20:17 +01:00
Makefile.travis Fixed file name of Windows binary snapshot. 2015-01-20 21:00:44 +01:00
README.md Merge pull request #238 from mrdudz/gamate 2016-02-27 18:44:26 +01:00

Windows Snapshot

Documentation

Wiki

Build Status

cc65 is a complete cross development package for 65(C)02 systems, including a powerful macro assembler, a C compiler, linker, librarian and several other tools.

cc65 has C and runtime library support for many of the old 6502 machines, including

  • the following Commodore machines:
    • VIC20
    • C16/C116 and Plus/4
    • C64
    • C128
    • CBM 510 (aka P500)
    • the 600/700 family
    • newer PET machines (not 2001).
  • the Apple ][+ and successors.
  • the Atari 8 bit machines.
  • the Atari 5200 console.
  • GEOS for the C64, C128 and Apple //e.
  • the Bit Corporation Gamate console.
  • the NEC PC-Engine (aka TurboGrafx-16).
  • the Nintendo Entertainment System (NES) console.
  • the Watara Supervision console.
  • the Oric Atmos.
  • the Lynx console.
  • the Ohio Scientific Challenger 1P.

The libraries are fairly portable, so creating a version for other 6502s shouldn't be too much work.