Re: Execute compiled lua scripts directly from flash?

classic Classic list List threaded Threaded
3 messages Options
Amr Bekhit Amr Bekhit
Reply | Threaded
Open this post in threaded view
|

Re: Execute compiled lua scripts directly from flash?

Hi Martin and Bogdan, 

Thanks for your replies and sorry for the late response.

@Bodgan - I guess it makes sense why there is no drop in RAM usage - regardless of whether the script is initially uncompiled or not, the runtime will eventually load the compiled bytecode into RAM and execute it there, so me precompiling the scripts won't increase performance, it will just skip out the precompiling step at the beginning (and any RAM limits that may be hit during that step).

@Martin - thanks for the info - glad to hear that 0.9 can indeed run scripts directly from flash. Could you point me to the relevant pages in the documentation (if any) that describe this feature and how to use it, please?

Thanks,

Amr


On 3 October 2013 11:00, <[hidden email]> wrote:
Send eLua-dev mailing list submissions to
        [hidden email]

To subscribe or unsubscribe via the World Wide Web, visit
        https://lists.berlios.de/mailman/listinfo/elua-dev
or, via email, send a message with subject or body 'help' to
        [hidden email]

You can reach the person managing the list at
        [hidden email]

When replying, please edit your Subject line so it is more specific
than "Re: Contents of eLua-dev digest..."


Today's Topics:

   1. Re: Execute compiled lua scripts directly from flash? (Martin Guy)


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

Message: 1
Date: Thu, 3 Oct 2013 09:27:37 +0200
From: Martin Guy <[hidden email]>
To: "eLua Users and Development List (www.eluaproject.net)"
        <[hidden email]>
Subject: Re: [eLua-dev] Execute compiled lua scripts directly from
        flash?
Message-ID:
        <CAL4-wQohd3e26=ZaEZmWf1SCSB+ei7-W=-[hidden email]>
Content-Type: text/plain; charset=UTF-8

On 01/10/2013, Amr Bekhit <[hidden email]> wrote:
> *bump* any thoughts on this?
> On 17 Sep 2013 12:29, "Amr Bekhit" <[hidden email]> wrote:
>> I'm starting to hit the RAM limits on my eLua board (custom board running
>> LPC1778), and so I've been looking into using the ROMFS to execute my
>> compiled lua scripts directly from flash.

>> I was expecting see a similar drop in RAM usage.

>> Can you execute compiled lua code directly from flash, or is it still
>> loaded into RAM and executed there? I'm using eLua v0.8

Hi!
   Moving to eLua 0.9 should help, as it has more RAM optimizations,
including being able to read bytecode directly from Flash memory.
   On the Mizar32 branch there is a series of hacks to reduce code
size, but the only RAM advantages to be had by reconfiguring are not
to use the buffers on the serial port/console and the ADCs - there is
precious little else to be had in terms of RAM usage in that
direction.

Cheers, let us know if 0.9's bytecode-from-flash work makes any difference

    M


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

_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev

End of eLua-dev Digest, Vol 63, Issue 2
***************************************


_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
Martin Guy Martin Guy
Reply | Threaded
Open this post in threaded view
|

Re: Execute compiled lua scripts directly from flash?

On 08/11/2013, Amr Bekhit <[hidden email]> wrote:

> @Martin - thanks for the info - glad to hear that 0.9 can indeed run
> scripts directly from flash. Could you point me to the relevant pages in
> the documentation (if any) that describe this feature and how to use it,
> please?

I assume you just put an autorun.lc file in romfs.
I saw it in the elua-0.9 features list
http://www.eluaproject.net/news/elua-09-released
but haven't seen any other documentation - I assume it's does the
right thing automagically.

    M
_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev
BogdanM BogdanM
Reply | Threaded
Open this post in threaded view
|

Re: Execute compiled lua scripts directly from flash?

Hi,


On Sat, Nov 9, 2013 at 8:52 PM, Martin Guy <[hidden email]> wrote:
On 08/11/2013, Amr Bekhit <[hidden email]> wrote:

> @Martin - thanks for the info - glad to hear that 0.9 can indeed run
> scripts directly from flash. Could you point me to the relevant pages in
> the documentation (if any) that describe this feature and how to use it,
> please?

I assume you just put an autorun.lc file in romfs.
I saw it in the elua-0.9 features list
http://www.eluaproject.net/news/elua-09-released
but haven't seen any other documentation - I assume it's does the
right thing automagically.

You're right, it does this automatically. Any .lc script in /romfs (or /wofs) automatically benefits from this optimization.

Best,
Bogdan
 

    M
_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev


_______________________________________________
eLua-dev mailing list
[hidden email]
https://lists.berlios.de/mailman/listinfo/elua-dev