>> they use:
>>   ADD 3 1 2
>
> yes but if you look carefully then you will find that number of registers
> in such implementation is reduced to 256 what also reduce maximal number
> of local variables which have to be less or equal (depending on code) to
> the number of registers. To keep compatibility with clipper we will have
> to use different opcode set which will not be such optimal. The tables with
> constant values are quite interesting method of RT speed optimization with
> some additional cost of startup initialization but here I also see some
> serious limitation for the maximal number of items.
> I do not want to say that moving from stack to register based language
> is bad idea. I only want to say that some improvements reached in LUA
> cannot be adopted to Harbour without introducing some limitations to the
> language.

If we add the register based calling convention on the top
of current implementation (I know it's bloat), we can simply
revert to stack based for cases when > 256 local vars are
used, I expect this to happen very rarely, but I agree we
must support it. In other cases (which is the majority) reg
based could be used.

Also the numeric var detection than native C type usage
in -gc3 mode could greatly improve core .prg code loop speed.

Brgds,
Viktor
_______________________________________________
Harbour mailing list
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to