1
0
mirror of https://github.com/cc65/cc65.git synced 2024-06-09 06:29:38 +00:00

In the generated assembly file, add import statements for all zero page

variables known by the runtime. They aren't currently accessed by the compiler
itself but may be useful for inline assembly.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4891 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
uz 2010-12-29 10:18:29 +00:00
parent f11067e260
commit 4a92522c82

View File

@ -6,7 +6,7 @@
/* */
/* */
/* */
/* (C) 1998-2009, Ullrich von Bassewitz */
/* (C) 1998-2010, Ullrich von Bassewitz */
/* Roemerstrasse 52 */
/* D-70794 Filderstadt */
/* EMail: uz@cc65.org */
@ -177,8 +177,9 @@ void g_preamble (void)
/* Tell the assembler if we want to generate debug info */
AddTextLine ("\t.debuginfo\t%s", (DebugInfo != 0)? "on" : "off");
/* Import the stack pointer for direct auto variable access */
AddTextLine ("\t.importzp\tsp, sreg, regsave, regbank, tmp1, ptr1, ptr2");
/* Import zero page variables */
AddTextLine ("\t.importzp\tsp, sreg, regsave, regbank");
AddTextLine ("\t.importzp\ttmp1, tmp2, tmp3, tmp4, ptr1, ptr2, ptr3, ptr4");
/* Define long branch macros */
AddTextLine ("\t.macpack\tlongbranch");