1
0
mirror of https://github.com/cc65/cc65.git synced 2024-08-16 12:29:03 +00:00
Commit Graph

1574 Commits

Author SHA1 Message Date
uz
ee6028993e Added a new "--force-import" command line option to the linker.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4052 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-27 14:43:44 +00:00
uz
2b15f40424 Use the new AddrSizeFromStr function.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4051 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-27 14:19:47 +00:00
uz
6f39a15eff Added an AddrSizeFromStr function.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4050 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-27 14:11:07 +00:00
uz
8fa42540c1 Disable handling of tossubax since it won't work as implemented in many cases.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4047 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-20 21:01:01 +00:00
uz
f63964e23c Added several constraints to the optimizer functions to avoid breaking code.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4046 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-20 16:06:20 +00:00
uz
4a93f188a0 Fixed a bug reported by Greg King: Initialized data for constant arrays was
not placed in the RODATA but in the DATA segment.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4044 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-20 10:55:38 +00:00
uz
b9c0d6ac85 Also handle ldaxysp as a valid load insn before a push.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4042 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-19 13:36:26 +00:00
uz
8a0d80bbf0 Inline the left shift routines.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4041 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-19 13:20:28 +00:00
uz
57ef34f041 Apply OptTransfers3 again in a later step, so it gets another chance.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4040 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-19 12:47:30 +00:00
uz
f3b639f835 Generate more predictable code.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4039 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-19 10:17:10 +00:00
uz
2e8d62cf88 Add an additional precondition check for safety.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4038 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-19 10:14:14 +00:00
uz
824ab8b137 Serval improvements, handling of tossubax.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4037 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-18 15:10:15 +00:00
uz
45aa228489 Change order of insns in generated sequence in OptPtrLoad17.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4034 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-17 16:25:54 +00:00
uz
430c13f658 Added/corrected code info.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4033 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-17 16:23:29 +00:00
uz
97c0e45c9f Rewrite of the main function.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4032 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-17 12:52:50 +00:00
uz
548dfd3060 Change order, so that the forced imports for main() go into the global
segments and not the one for main().


git-svn-id: svn://svn.cc65.org/cc65/trunk@4031 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-16 23:37:09 +00:00
uz
1bd4abdc67 Use correct adddressing mode for "asl a".
git-svn-id: svn://svn.cc65.org/cc65/trunk@4030 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-16 21:01:16 +00:00
uz
cbf4884f13 Some more pattern replacements.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4029 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-16 20:56:33 +00:00
uz
e646d35db0 Output an apropriate error message when a floating point type is encountered
(instead of an internal compiler error).


git-svn-id: svn://svn.cc65.org/cc65/trunk@4028 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-16 19:23:07 +00:00
uz
3aa4d74b18 Added more function info
git-svn-id: svn://svn.cc65.org/cc65/trunk@4026 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-16 16:38:25 +00:00
uz
582506b7fc Check also sreg in OptSize1. Added information about shortcut functions for
longs that clear the high word of the right operand on entry.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4024 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 21:00:27 +00:00
uz
d0f9a0d6a7 Fixed wrong insertion order that caused problems with labels.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4022 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 16:49:46 +00:00
uz
14b00447a8 Fixed wrong insertion order that caused problems with labels.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4021 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 16:45:02 +00:00
uz
b4fda62df9 clc should always be the insn before adc.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4020 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 16:00:30 +00:00
uz
15c420fd39 Some branch improvements.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4019 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 15:58:21 +00:00
uz
3381311674 Inline some forms of aslax1
git-svn-id: svn://svn.cc65.org/cc65/trunk@4018 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 15:27:43 +00:00
uz
f495a9edc3 Fixed an error
git-svn-id: svn://svn.cc65.org/cc65/trunk@4017 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 14:43:59 +00:00
uz
61195d914e Replace ldaxidx by inline code.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4016 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 14:20:26 +00:00
uz
33f6c85753 Add more function to the "harmless calls" list.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4015 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 14:18:00 +00:00
uz
b391929acb Minor improvement in last change
git-svn-id: svn://svn.cc65.org/cc65/trunk@4014 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 13:42:40 +00:00
uz
3717443f3b Try to generate more predictable code.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4013 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 13:25:40 +00:00
uz
fbe009a182 Remove even more transfer instructions.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4012 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 13:16:56 +00:00
uz
14f213cadb Remove unnecessary transfer instructions.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4011 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 12:49:15 +00:00
uz
b68db83a2b Remove more push/pop sequences.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4010 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 10:27:41 +00:00
uz
d27664036d Change order of replacement code in OptPtrLoad10 to allow detection in other
steps.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4009 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-15 10:14:04 +00:00
uz
0c4144c586 Don't generate inlined codes for integers shifts. If necessary the optimizer
can do that. 


git-svn-id: svn://svn.cc65.org/cc65/trunk@4007 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-14 22:17:47 +00:00
uz
0b7b9354dc Don't generate short code for the tosxxx functions when X is zero or similar.
Let the optimizer do it. This reduces the number of possible patterns that
must be detected by the optimizer. Add tosicmp0 as a shortcut function.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4006 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-14 22:10:04 +00:00
uz
fdfa1678d4 Tell the compiler more about the runtime library functions.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4004 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-14 20:21:47 +00:00
uz
4a5ceb13c7 Removed debug code
git-svn-id: svn://svn.cc65.org/cc65/trunk@4003 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-14 18:32:11 +00:00
uz
50b410eb32 Do size improvements always if they have no impact on speed.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4002 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-14 18:23:29 +00:00
uz
f374e746af Improvements in array index code.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4001 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-14 17:28:32 +00:00
uz
a9b2226956 Moved part of codeopt into coptptrload for better modularization.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4000 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-14 17:09:24 +00:00
uz
cb1870de74 Fixed an off-by-one error (reported by Greg King - thanks).
git-svn-id: svn://svn.cc65.org/cc65/trunk@3996 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-05 14:29:30 +00:00
cpg
9cafacaf6d introduce STARTUP segment to Atari platform
git-svn-id: svn://svn.cc65.org/cc65/trunk@3995 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-04 20:04:41 +00:00
uz
3ce7717bd2 Don't allow to call subroutines that aren't actual functions.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3994 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-04 19:23:15 +00:00
uz
70d2d9e50f Fixed an off-by-one bug
git-svn-id: svn://svn.cc65.org/cc65/trunk@3993 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-04 19:22:15 +00:00
uz
ca73116a03 New function IsLocalLabelName.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3992 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-08-04 19:12:34 +00:00
uz
3d95c9453f There's no longer a need to link in the startup file, it's done my magic
instead.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3991 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-07-31 13:39:07 +00:00
uz
8216bf1d6a Force an import of the special symbol __STARTUP__ in the C compiler when
main() is encountered. Define this symbol in the startup code. This will
automatically force linking of the startup code which can then reside inside
the standard library as any other object file.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3988 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-07-31 12:05:42 +00:00
uz
66391bfc25 Inline shifts in g_asl as is already the case in g_scale.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3987 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-07-30 19:41:25 +00:00