ref: 01a710a47d6a5f21f8cfda72f7cfc6d23563a090
parent: 53842cd07d8ebfb05ce2cba545279ed0cae58210
author: AntonioND <[email protected]>
date: Sat Apr 1 20:38:09 EDT 2017
Remove Zero Page linker patch `RPN_PCEZP` This patch isn't used because it's meant to be an optimization for labels in the memory region 0x2000-0x20FF. That memory region doesn't have anything special on the Game Boy, and there are no instructions optimized to read or write from there, so it was probably meant for another hardware that was supported by ASMotor in the past. Signed-off-by: AntonioND <[email protected]>
--- a/include/asm/mylink.h
+++ b/include/asm/mylink.h
@@ -86,7 +86,10 @@
RPN_HRAM,
- RPN_PCEZP,
+ /* TODO: This hasn't been removed in order not to break compatibility
+ * with the existing object files, but it will be removed in a future
+ * version. */
+ RPN_unused,
RPN_RANGECHECK,
--- a/include/link/mylink.h
+++ b/include/link/mylink.h
@@ -44,7 +44,10 @@
RPN_HRAM,
- RPN_PCEZP,
+ /* TODO: This hasn't been removed in order not to break compatibility
+ * with the existing object files, but it will be removed in a future
+ * version. */
+ RPN_unused,
RPN_RANGECHECK,
--- a/src/link/patch.c
+++ b/src/link/patch.c
@@ -175,15 +175,6 @@
pPatch->pzFilename, pPatch->nLineNo);
}
break;
- case RPN_PCEZP:
- t = rpnpop();
- rpnpush(t & 0xFF);
- if (t < 0x2000 || t > 0x20FF) {
- errx(1,
- "%s(%ld) : Value must be in the ZP area",
- pPatch->pzFilename, pPatch->nLineNo);
- }
- break;
case RPN_CONST:
/* constant */
t = (*rpn++);