Releases: hth313/Calypsi-tool-chains
Release 5.7.1
This is a bug fix release.
-Tree shaking could cause incorrect errors about undefined symbols when debug information was enabled.
- Expressions that shifted the operand first right then left, or vice versa, could in some situations generate incorrect code when
-O2
was used. - 6502 variants: Spilling a pseudo zero page register and then taking it back to a different location could in some situation result in incorrect register being used.
- 6502 variants: Reading a byte sized volatile and then writing it back to the same location was optimized away at optimization level 1 and above.
- 65816: Reading a byte or 16-bit word sized volatile and then writing it back to the same location was optimized away at optimization level 1 and above.
- 68000: Correct a problem with
struct
padding that could get wrong if an odd size element was followed by astruct
as the last element of thestruct
.
Release 5.7
- Fedora Linux host support.
- Enable tree shaking for C, which means that unreferenced functions are no longer included in the output. This can reduce the size of the application. You can enable the previous behavior with the linker option
--no-tree-shaking
. - Add local labels based on
---
and++++
sequences to the assembler. References to labels with minus characters goes backwards to closest label matching and references to labels with plus characters goes forward to the closest matching label. - Switch tables now use
#pragma clang section rodata
if active. - C library stub routines are now expected to return a negative
errno
value when there is a problem and should not set theerrno
variable. The existing board support routines and semi-hosting have been updated accordingly. - 6502: Improve use of
(dd),y
for addressing inside small arrays. This requires-O2
and that the compiler knows the size of the array, which typically meaning that the array needs to be inside astruct
. - MEGA65: The symbols
HTRAP00
toHTRAP3F
are now recognized as having arbitrary register effects and setting the carry flag. This prevents instructions from being optimized away when doing a Hyppo call from inline assembly. You will need to import the symbol used, e.g." .extern HTRAP00"\\n
. TheHTRAP
symbols are defined in the supplied MEGA65 library which is automatically linked with when using--target=mega65
. - 6502: Update Commodore board support for some fixes related to file I/O.
- Various bug fixes.
Release 5.6
- The Windows release is now packed as a
.zip
archive. - 6502: Foenix F256 target is removed, use the 65816 compiler with flat memory support instead,
- Improve code generation for various shift and mask patterns.
- Bitfield assignment operations now performs many operations in place without the normal unpacking and normalization, resulting in better code.
- 68000: Code generate immediate source operand with
AND
,OR
,MUL
andDIV
instructions. This did not previously happen due to a minor oversight. - Various bug fixes.
Release 5.5
- 65816: Add function attribute
saveds
which indicates that a function is an external entry point which needs to initialize the direct page and data bank registers. The previous values for the registers are restored on function return. - Assignment operators
*=
,/=
and%=
nowrewrites to bit shift or mask operations when possible, previously this was only done for normal operator without the assignment part. - Add command line option
--no-interprocedural-cross-jump
to disable jumps between functions. One situation when you may need this is when you are doing your own manual bank system and functions from the same compilation unit may not always be mapped in at the same time. - MEGA65: Add relocation operator
.swap
which swaps the bytes of a 16 bit operand. This can be used on the MEGA65 to swap the bytes for thePHW
immediate instruction to match the byte order used byJSR
for the return address. - Various corrections and improvements in the code generators, refer to the release notes file for details.
- Linker: Scatter to sections are no longer automatically aligned, as it could cause placement issues when the block was not placed on an alignment based on its size.
Release 5.4
- Add library build scripts to assist in rebuilding the C library with different settings. See the
library-build
folder in the installation directory. - The linker now gives precedence to a replacement C library given on the command line.
- Inlining a function in a loop with a parameter that was read only once as part of being the parameter to the inlined function, would get clobbered if it was written to inside the inlined function.
- 6502: Incorrect code could be generated in some rare situations with address expressions.
- MEGA65: Correct use/def semantics of
ASW
instruction which was not done right and could cause writes to zero page pseudo registers prior to be incorrectly optimized away. - MEGA65: Correct date table initializers for scattered sections, now also handling section operators.
- MEGA65: Correct routines that initialize variables, they expected a 32-bit pointer, but the table address passed from C startup was 16-bit. These are now both 16-bit.
- MEGA65: Data initializer table entries now use the scatter-to address if it exists, otherwise it falls back to the normal
address. - 65816: Incorrect code could be generated in some rare situations with address expressions.
- 65816: Casting between a compact code pointer and an integer type caused an internal error.
Release 5.3
-
Add new command option
--inline-on-matching-custom-text-section
which prevents inlining of functions placed in a custom section, unless the function being inlined into belongs to the same custom section. This is useful if the memory system is being manipulated and the function much execute in that specific custom section. -
#pragma clang section rodata="..."
now also affects the section used for string literals and compiler generated static initializers. -
6502: The linker is now less aggressive on merging memories in the PRG and RAW formats. Memories are only merged in the address range
0x0000
-0xffff
and can be prevented completely by specifying the--no-merge-raw-memories
command line option. -
6502: Add missing 65cnr02 libraries for Commander X16 targets.
-
6502: Provide default bank slots to the linker to prevent error message about
codeSlot
runtime attribute mismatch. -
65816: Add a new Compact code model. This is similar to the small code model, allowing any single bank to be used for code.
-
65816: Add a new board support for F256 flat memory model.
-
68000/Amiga: Add a significant amount of varargs stubs. These are normally part of
amiga.lib
, but here they are built into the Amiga board support package for Calypsi.
Release 5.2
- 6502: Add support for linking banked systems with the
scatter-to
memory property. - 6502: Avoid giving overlapping memory errors in the PRG and RAW output formats.` With banked and custom overlay systems, such overlaps are possible and now allowed.
- 6502: Add 65CNR02 core. This is the original 65C02 without Rockwell extensions. It can also be used to build code intended to work on both the 65C02 and the 65816 in emulation mode.
- 6502: Rename code and data slot options, from
--code-bank-block
to--code-slot
, and--data-bank-block
to--data-slot
. This is done to follow established naming. - Rename MMU relocation operators to use "slot" rather than "block", e.g.
.mmuslot5
replaces.mmublock5
. - 6502: Cross call and interprocedure cross jumps are disabled in the banked code model as a temporary measure, as it causes problems linking due to functions being placed in different banks.
- 6502: The default C stack size is now 4096 (was 256).
- 65816: Add the
__CALYPSI_HUGE_ATTRIBUTE_ENABLED__
macro which is defined when the--enable-huge-attribute
command is active. - 68000: Add partial support for 68080, including
ADDIW
,CMPIW
,DBcc.L
,EXTUB
,EXTUW
,MOV3Q
,MOVS
andMOVZ
instructions. - 68000: Add target and board support for TOS.
- Add
#pragma rtattr
- Add
--initialize-large-data
command line option to the linker. This is used to enable initializing object larger than 64K and objects that cross 64K banks, even when the Huge attribute is not active. This is mainly intended for the MEGA65 and 65816 targets. - Make the assembler directive
.incbin
load files relative to the current source directory. If that file path does not exist, it will
try as before, based on the given path, relative from the compilation directory. - Applications now downloaded 2-3 times faster when using the remote debugger. This is because the gdbserver
X
(binary write memory) command is used.
Release 5.1
- Inline assembly is now supported. Refer to the Calypsi C compiler guide for more details.
- Formatter variant for
printf()
andscanf()
are now automatically selected based by the linker based on the formatter strings used in the application. There is no longer a need to specify the formatter on the linker command line, but it can still be done that way if you for some reason want to override the selection mechanism. - The compiler will now use hex numbers in generated assembly code and list files. Small and certain even numbers are still emitted as decimal.
- 6502: Include board support packages for Commodore 64, MEGA65 and Commander X16.
- MEGA65/45GS02: Add support for previously missing conditional long branch instructions, using mnemonics with an
L
, e.g.LBCC
for a longbranch
on carry clear. - MEGA65/45GS02: The code generator now makes use of the MEGA65 math unit for integer multiply and divide.
- 6502: Add intrinsic function
__no_operation()
to emit aNOP
instruction. - 6502: Add intrinsic function
__break_with(n)
to emit aBRK n
instruction. - 65816: a new
simple_call
function attribute enables a simpler calling convention to make it easier to write assembly functions. - 65816: Add intrinsic function
__no_operation()
to emit aNOP
instruction. - 65816: Add intrinsic function
__coprocessor_with(n)
to emit aCOP n
instruction. - 65816: Add intrinsic function
__break_with(n)
to emit aBRK n
instruction. - 65816: Board support for Foenix C256 U, U+ and FMX are now provided.
- 68020 core is now supported by 68000 target.
- 68010, 68030, 68040 and 68060 cores are supported by the assembler. but C compiler only distinguish 68000 and 68020 for code generation.
- 68000 target provides a
simple_call
function attribute to enable a simpler calling convention that pushes all parameters on the stack. - Various code generator improvements and bug fixes.
Release 4.4
- Include board support for Foenix F256/6502
- Enable the
overloadable
attribute which allows for overloading functions similar to C++. Overloaded functions are subject to name mangling. - Enable the
unused
attribute. This can be used to silence diagnostics about unused entities that cannot be removed. - Simplify board support stub API
- Various corrections and improvements