Page 1 of 2

Compiler updates

Posted: Thu Mar 28, 2013 12:21 am
by basicchip
The Help files haven't caught up yet and we are still testing a couple new compiler features. We have followed the VB syntax

PARAMARRAY is now supported for calling SUB and FUNCTION

SUB x (PARAMARRAY z)
' you can use z(0) thru z(14) as values here -- z(15) contains the max index of the PARAMARRAY -- always limited to integers and 15 values
ENDSUB

main:

x(1,2,3) 'ok
x(5,6,7,8,9,10) ' also ok

------------------------------------------------

BYREF passing of INTEGER and SINGLE arrays to SUB and FUNCTION

FUNCTION f(z() AS SINGLE) AS SINGLE
return z(0)+z(1)
ENDFUNCTION

main:

DIM zz(10) AS SINGLE
zz(0)=1.111
zz(1)=2.222

print f(zz)

Re: Compiler updates

Posted: Fri Apr 26, 2013 3:19 pm
by basicchip
The compiler has been updated to allow the deprecated declaration of string$ in function and sub parameters. Much earlier versions of the compiler allowed this, but with the conversion to floating point that changed.

So our regression tests add tests for that and the compiler once again handles

function something(astring$(10))
...

This version also handles sub and functions with no parameters using the form

sub somethingelse()
...

The compiler did not allow () before.

Re: Compiler updates

Posted: Wed Jul 03, 2013 12:25 pm
by basicchip
This update covers extensions for LPC4xxx series parts which are being used in some custom designs. If demand drives it they may also become part of the product line.

In addition we found a bug in certain instances of the compiled code for interrupts for the Cortex parts LPC1114, LPC1751 and LPC1756. This has been corrected in this version.

Re: Compiler updates

Posted: Sat Aug 17, 2013 5:17 pm
by basicchip
This version of the compiler improves the compile time evaluation of most constants. Before if the constant was too complex it could get evaluated at run time.

This version also improves the handling of floating point code that also includes integer constants. This improves the performance of the simple test case by 30%. The test case is below

Code: Select all

DIM x as single
x=1000000
while x>0
  x=x-1
loop
For the SuperPRO that gets floating point performance close to 1 MFLOP in BASIC

Re: Compiler updates

Posted: Mon Jun 16, 2014 1:25 pm
by basicchip
This version of the compiler fixes an introduced bug for the statement

DIR(expression) = expression

We have added tests for that and most other pin functions into the test suite.
ARMbasic.exe
version 9.33a
(129.86 KiB) Downloaded 1463 times

Re: Compiler updates

Posted: Wed Jul 09, 2014 11:48 pm
by basicchip
We were getting short of opcodes for a while, and that meant some of the obsolete DATA statements shared an index with the new WAITMICRO, and in trying to support both depending on firmware version WAITMICRO got broken.

So for now we don't support the obsolete DATA statements, probably won't again. Version 9.33b fixes WAITMICRO
ARMbasic.exe
version 9.33b
(135.99 KiB) Downloaded 1253 times

Re: Compiler updates

Posted: Sat Aug 16, 2014 4:19 pm
by basicchip
BASICtools and the ARMbasic compiler have been updated to expand the variable dump debug tools. The code dump now shows all subroutines, and there is a variable address page that can be used to figure out what BYREF pointers are pointing at.

Too big to post here, so best is to download www.coridium.us/files/setupBASIC.exe

It has updated ARMbasic.exe, BASICtools.exe, TclTerm.tcl and numerous updates to the help file.

Re: Compiler updates

Posted: Fri Aug 22, 2014 2:25 pm
by basicchip
Since the last some more optimizations have been added for single arrays. Those are in this version 9.34e of the compiler.
ARMbasic.exe
(135.51 KiB) Downloaded 1415 times

Re: Compiler updates

Posted: Tue Aug 26, 2014 3:28 pm
by basicchip
This version tightens up handling of ? which is a special character used by BASICtools to communicate with the ARM PCB and the ARMbasic compiler.

version 9.34f
ARMbasic.exe
(129.88 KiB) Downloaded 1483 times

Re: Compiler updates

Posted: Tue Aug 26, 2014 3:33 pm
by olzeke51
wow - you got rid of 6k bytes over a "?" !!!