Search found 95 matches

by Baldhead
Thu Dec 12, 2019 6:27 pm
Forum: Hardware
Topic: Integer division performance ????
Replies: 25
Views: 1403

Re: Integer division performance ????

Hi ESP_Angus, "Right, sorry I missed that. I checked with the peripheral teams, both fields need to be set: EOF=1 causes an EOF interrupt to be triggered when the descriptor is reached, but the DMA operation will continue until it reaches a field where the next descriptor pointer is NULL." Strange. ...
by Baldhead
Wed Dec 11, 2019 5:45 pm
Forum: Hardware
Topic: Integer division performance ????
Replies: 25
Views: 1403

Re: Integer division performance ????

Hi ESP_Angus, "You're asking me if code you haven't written yet might have a problem?" I would like to know if i need or i dont need both "instructions" at the same time on last node of linked list: dma_desc_buf_a[ last node ].eof = 1; dma_desc_buf_a[ last node ].qe.stqe_next = ( lldesc_t* ) NULL; I...
by Baldhead
Tue Dec 10, 2019 11:46 pm
Forum: Hardware
Topic: Integer division performance ????
Replies: 25
Views: 1403

Re: Integer division performance ????

Hi ESP_Angus, Below follows what i'm doing. Called only in startup. static DMA_ATTR uint32_t buf_a[ 15360 ]; static DMA_ATTR lldesc_t dma_desc_buf_a[ 16 ]; static void init_dma_descriptors_a( ) { for ( uint32_t i = 0 ; i < descriptor_size ; i++ ) // descriptor_size = 16 { dma_desc_buf_a[i].size = 40...
by Baldhead
Tue Dec 10, 2019 11:24 pm
Forum: Hardware
Topic: Integer division performance ????
Replies: 25
Views: 1403

Re: Integer division performance ????

Hi ESP_Angus,


At first i think it's good the way it is.

From 4.1us to 3us ( -Og compiler optimization ).
From 4.1us to 1,9 us ( -Os compiler optimization ).


Thank's for the help.
by Baldhead
Tue Dec 10, 2019 7:21 pm
Forum: Hardware
Topic: Integer division performance ????
Replies: 25
Views: 1403

Re: Integer division performance ????

Hi, I changed the static variable to no static variable. ie: static uint32_t length = 0; uint32_t length = 0; And the time saved was: From 4.1us to 3us ( -Og compiler optimization ). From 4.1us to 1,9 us ( -Os compiler optimization ). len are not constant. When len = 15360 bytes. I always thought st...
by Baldhead
Tue Dec 10, 2019 6:58 pm
Forum: Hardware
Topic: Integer division performance ????
Replies: 25
Views: 1403

Re: Integer division performance ????

Hi ESP_Angus, You wrote: "(Note this will clear any other values in the struct, but that doesn't matter here.)". it does matter yes, because the "lldesc_t dma_desc_buf_a[ i ].xxxx" are only initialized at esp32 startup and after startup i only change .length and .eof for the sake of performance. Tha...
by Baldhead
Tue Dec 10, 2019 6:34 am
Forum: General Discussion
Topic: What would you like to see in The Next Chip?
Replies: 343
Views: 114276

Re: What would you like to see in The Next Chip?

Hi,

K210.

8MB of internal ram.
"Generic dma".

The external 8MB of esp32 are unusable in dma.
by Baldhead
Tue Dec 10, 2019 5:50 am
Forum: Hardware
Topic: Integer division performance ????
Replies: 25
Views: 1403

Re: Integer division performance ????

Hi,

Thank's by the answers.

Maybe 2.4 ms are ok, but it is to atualize a lcd display, so the faster the better.
320x480x2 bytes in 30 hz.

With respect to static variables i thought that it saves time because don't have to create that variable through stack all time that function are called.
by Baldhead
Tue Dec 10, 2019 2:18 am
Forum: Hardware
Topic: Integer division performance ????
Replies: 25
Views: 1403

Re: Integer division performance ????

Hi ESP_Angus, Below is the function i want to optimize processing time. It can be called 600 times per second. When len = 15360 bytes the function takes 4,1 us. I'm finding a lot of time for 240 Mhz. static DMA_ATTR lldesc_t dma_desc_buf_a[ 16 ]; static inline int fill_dma_descriptor_a ( uint32_t le...
by Baldhead
Tue Dec 10, 2019 12:53 am
Forum: Hardware
Topic: Integer division performance ????
Replies: 25
Views: 1403

Re: Integer division performance ????

Hi ESP_Angus, Thank's for your reply. "Built with default config (ie default compiler optimisation level which is -Os, if you want max performance then set this to Performance)." Where i can change to "The “Performance” setting will add the -O2 flag to CFLAGS". In menuconfig -> compiler options -> O...

Go to advanced search