Re: [cc65] repeating code blocks

Date view Thread view Subject view

From: Ullrich von Bassewitz (uz_at_musoftware.de)
Date: 2000-05-22 22:48:22


Sorry for the late answer...

On Sat, May 20, 2000 at 10:10:11PM +0200, Groepaz wrote:
> am i just blind or is there really no possibility to repeat code blocks (eg
> in macros) ?! i thought it was a quite common thing to have macros like eg

You are right, there is currently no feature to repeat pieces of code and it
would be nice to have one. A .REPEAT pseudo instruction is planned for the
next release, and the token is already reserved in the current development
version.

> ... what one would expect from the above is, an output file like this:
>
> $0800-	scrn1.bin
> $0c00-  scrn2.bin
> $2000-  assembled "bogus.s"
>
> and that even, regardless the size of the scrn1/scrn2.bin files (as long as
> they dont exceed their segment size).
>
> but instead, the linker puts them seamlessly one after the other, since
> "fill=no" is the default value. maybe this is conveniant for use with
> compilers, but i think "fill=yes" would be more like what you would want
> when hand-writing asm code ;=P

Well, it is not, what I would expect:-)

More serious: The linker relocates the code and places it into the given
file(s). For anything else, it needs explicit commands. I don't think, using a
default of "fill=yes" will have any real advantages. It will give larger files
and will also fill the last segment, so the binary file will usually get a lot
larger than needed. 

Maybe this is more a documentation problem. What you expect from the linker is
a result of what you have read about it, so it seems the docs are not clear
enough about the memory layout of the resulting file. I will have a look at it
as soon as I find some time.

Regards


	Uz


--
Ullrich von Bassewitz                                  uz_at_musoftware.de
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo_at_musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.


Date view Thread view Subject view

This archive was generated by hypermail 2.1.3 : 2001-12-14 22:05:36 CET