Hi Tristan, This has and is being looked at. The linker appears to be the problem. I have tried a few things like changes to the macros with some success. With these successes the image sizes grow. The run time execution loop is able to function until it hits a halfword address then it exceptions out. As a temporary workaround I am looking at handling the exception gracefully and resuming the execution loop, this way the image size can be kept smaller. The good news is that it (amForth) is able to co-exist with my existing application which is a mix of C and inline assembler routines.
Regards, John S On Tue, Jan 6, 2026 at 1:53 PM <[email protected]> wrote: > Hi John, > > Check your compiler/assembler/linker options to see whether they allow > free reign to use RISC-V compressed instructions wherever they think > appropriate. Then, as a first cut, turn that off globally. There are > various ways to be more selective, but it very much depends on how much > their use matters to you. > > Best wishes, > Tristan > > On 2026-01-06 16:33, John Sarabacha wrote: > > Hi everyone, > > When mixing C *.c and assembler *.s files in your amForth build you can > > run > > into random 32 bit alignment issues with the dictionary. The Cortex-M4 > > and > > RISCV on CH32V307 appears to be more forgiving than CH32X033/CH32X035 > > is. > > Using the -m32 switch for GCC/assembler chain doesn't help. The > > strange > > part is that the 32 bit mis-alignment doesn't always occur. It only > > happens for certain dictionary elements like > > 000015be <XT_DOLITERAL>: > > 15be: 15c2 > > 000015c2 <PFA_DOLITERAL>: > > > > Regards, > > John S > > > > _______________________________________________ > > Amforth-devel mailing list for http://amforth.sf.net/ > > [email protected] > > https://lists.sourceforge.net/lists/listinfo/amforth-devel > > > _______________________________________________ > Amforth-devel mailing list for http://amforth.sf.net/ > [email protected] > https://lists.sourceforge.net/lists/listinfo/amforth-devel > _______________________________________________ Amforth-devel mailing list for http://amforth.sf.net/ [email protected] https://lists.sourceforge.net/lists/listinfo/amforth-devel
