Re: [cc65] [PATCH 1/3] Allow Bcc from one segment to another.

From: Spiro Trikaliotis <ml-cc651trikaliotis.net>
Date: 2012-08-20 21:09:15
Hello Uz,

* On Mon, Aug 20, 2012 at 09:05:45AM +0200 Ullrich von Bassewitz wrote:
> 
> Hi Spiro,
> 
> your patch was indeed correct and the only change needed.

Nice to hear that.

 
> On Fri, Aug 17, 2012 at 09:11:39PM +0200, Spiro Trikaliotis wrote:
> > ld65 handles these branches correctly as long as there is no range error
> > (-128 .. 127); unfortunately, if the range is too big, bit the
> > difference would fit into 1 byte, ld65 does not emit an error, but
> > generates wrong code.
> 
> ld65 should and - according to my tests - does handle the expression
> correctly. Do you have a test case where this doesn't happen?

You're right, my test case was wrong.

I worked with 3 segments. Then, I added a fourth "filler" segment with
up to 256 byte. As ld65 did not emit any errors, I thought it behaved
wrong.

Unfortunately, the filler segment was not placed between the bne and its
target, thus, ld65 had no reason to complain.

Sorry for the additional work for you to find my error.

Regards,
Spiro.

-- 
Spiro R. Trikaliotis
http://www.trikaliotis.net/
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Mon Aug 20 21:10:32 2012

This archive was generated by hypermail 2.1.8 : 2012-08-20 21:10:36 CEST