Does ESP32 have instruction set to accelerated math computing?

yanbin
Posts: 5
Joined: Fri Nov 09, 2018 7:01 am

Does ESP32 have instruction set to accelerated math computing?

Postby yanbin » Thu Nov 15, 2018 8:12 am

Hi,
My project need to do more mathematical operations (e.g. multiplication, division, exponentiation ..).
Does ESP32 have instruction set to accelerated math computing?

Thanks.

ESP_Sprite
Posts: 8921
Joined: Thu Nov 26, 2015 4:08 am

Re: Does ESP32 have instruction set to accelerated math computing?

Postby ESP_Sprite » Thu Nov 15, 2018 1:24 pm

The ESP32 has integer and (single-precision) floating point multiplication and division; no need to do anything special for those as GCC will automatically spit out the right instructions for that. There's also an 16-bit MAC instruction, but you may need to write some assembly for that.

yanbin
Posts: 5
Joined: Fri Nov 09, 2018 7:01 am

Re: Does ESP32 have instruction set to accelerated math computing?

Postby yanbin » Fri Nov 16, 2018 2:38 am

ESP_Sprite wrote:
Thu Nov 15, 2018 1:24 pm
The ESP32 has integer and (single-precision) floating point multiplication and division; no need to do anything special for those as GCC will automatically spit out the right instructions for that. There's also an 16-bit MAC instruction, but you may need to write some assembly for that.
Thank you @ESP_Sprite.

Does ESP32 support some features likes SIMD / NEON ?

Thanks.

ESP_Sprite
Posts: 8921
Joined: Thu Nov 26, 2015 4:08 am

Re: Does ESP32 have instruction set to accelerated math computing?

Postby ESP_Sprite » Fri Nov 16, 2018 3:58 am

No / hard to say. NEON is ARM-specific and SIMD is kinda vague. I know the MAC instruction is SIMD-ish, though.

yanbin
Posts: 5
Joined: Fri Nov 09, 2018 7:01 am

Re: Does ESP32 have instruction set to accelerated math computing?

Postby yanbin » Fri Nov 16, 2018 8:24 am

ESP_Sprite wrote:
Fri Nov 16, 2018 3:58 am
No / hard to say. NEON is ARM-specific and SIMD is kinda vague. I know the MAC instruction is SIMD-ish, though.
Thank you @ESP_Sprite.

Now because of the SIMD/NEON, my applicatio could run fast on the arm platform.
On ESP32, it was a bit slow.
Would you please share any experience about accelerated math computing on ESP32 ?

Thanks.

Who is online

Users browsing this forum: No registered users and 138 guests