DSP lib for esp8266?

708 views
Skip to first unread message

Geoff Lethbridge

unread,
May 9, 2016, 5:26:11 PM5/9/16
to esp8266-re
Could you please help me find some answers to the following questions, as I have been unable to find any answers on the net?

Is there a DSP library (that is optimized for the L106/106Micro) for the esp8266?

Or do any of the esp products (ESP8266, ESP-WROOM-02, ESP32) have any of the following options included in the CPU?:
  • 16-bit Integer Multiply Option
  • 32-bit Integer Multiply Option
  • 32-bit Integer Divide Option
  • MAC16 Option
A better question may be just - what options, as listed in "4.1Overview of Options" of the "Xtensa Instruction Set Architecture (ISA) Reference Manual" are included in the L106/106Micro that is in the ESP products?


Regards
Geoff

Alex Stewart

unread,
May 10, 2016, 2:45:28 AM5/10/16
to esp82...@googlegroups.com
I'm not aware of any DSP library specifically for the ESP8266, though I have to admit I haven't really looked for one..

I believe all of the ESP modules (i.e. ESP-12, ESP-WROOM-02, etc) all have the same core chip (the ESP8266EX), and thus all have the same Xtensa/LX106 configuration options.  I've never seen any official documentation for which processor options are actually enabled on the ESP8266, but luckily a lot of this can be tested.  I just ran some quick tests on one of my ESP-12 modules and from what I can tell:
  • 16-bit Integer Multiply Option -- Yes
  • 32-bit Integer Multiply Option -- Partial (MULL supported, MULUH/MULSH unsupported)
  • 32-bit Integer Divide Option -- No
  • MAC16 Option -- No
So it looks like they didn't include any of the really fancy/useful stuff for DSP, but did at least include some basic hardware multiply support..  (Note that MULL, at least, is not even supported by gcc for inline assembly.  I had to use the GNU Assembler directly to test that one..)


--
You received this message because you are subscribed to the Google Groups "esp8266-re" group.
To unsubscribe from this group and stop receiving emails from it, send an email to esp8266-re+...@googlegroups.com.
To post to this group, send email to esp82...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/esp8266-re/67ec7b09-7a63-4ff6-9da2-1cf415d1a772%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Geoff Lethbridge

unread,
May 10, 2016, 7:51:16 AM5/10/16
to esp8266-re
Thank you for your help, that is great:-)

While it may not be what I had hoped, you have answered the questions I was needing to know. And I didn't think to ask about gcc supporting the options.

Running some small test program's to check out the the CPU sounds like a good practice for me adopt when looking at using new hardware:-)

Thank you.

Regards
Geoff

Angus Gratton

unread,
May 10, 2016, 8:16:06 PM5/10/16
to esp82...@googlegroups.com
On Tue, May 10, 2016 at 04:51:15AM -0700, Geoff Lethbridge wrote:
> Running some small test program's to check out the the CPU sounds like a good practice for me adopt when looking at using new hardware:

Hi Geoff,

Because you asked about ESP32 as well I thought I'd look at this a second way, which might be of interest.

The Xtensa overlay files for the toolchains contain a header - core-isa.h - that has a set of flags for a particular Xtensa CPU core's features.

You can get them for lx106 (ESP8266) and esp108 (ESP32) here:
https://github.com/jcmvbkbc/crosstool-NG/tree/esp108-1.21.0/overlays

They're in tar archives but here's a diff of just that header between lx106 and esp108:
https://gist.github.com/projectgus/3990f0b599ec34ac6b03f167d5e6e6ab/revisions

This indicates that ESP32 will have all of the options you mentioned (16-bit Integer Multiply Option, 32-bit Integer Multiply Option, 32-bit Integer Divide Option, MAC16 Option).

Of course the information given there might still be inaccurate. Noone outside Espressif has ESP32 at the moment, and only a few people have the ESP31 prerelease hardware (which might still change a bit for ESP32).


Angus

Alex Stewart

unread,
May 10, 2016, 8:38:50 PM5/10/16
to esp82...@googlegroups.com
That's really interesting..  I'm not entirely clear on whether the "lx106" stuff there actually represents exactly the same set of configuration options Espressif has chosen for the particular lx106 core in the ESP8266, but given the core ID of "esp108_v1_2_s5_512int_2" in the newer overlays, that does suggest that at least those options are probably a reasonably close representation of what the Espressif esp108 core will support..


--
You received this message because you are subscribed to the Google Groups "esp8266-re" group.
To unsubscribe from this group and stop receiving emails from it, send an email to esp8266-re+...@googlegroups.com.
To post to this group, send email to esp82...@googlegroups.com.

Geoff Lethbridge

unread,
May 11, 2016, 6:13:27 PM5/11/16
to esp8266-re
Hi Angus

Thank you :-)

That's good to know that the new esp's will/should have that functionality.  
Reply all
Reply to author
Forward
0 new messages