LPC4350 SD card benchmarking

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LPC4350 SD card benchmarking

431 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by bowerymarc on Wed Apr 24 13:05:24 MST 2013

I'm hoping others will share their results here.  I've benchmarked the SD card using the Hitex EVA4350, a hacked version of the hitext_eva-4350_periph_sdmmc example code from LPCOpen to do a benchmark (I'll post the code if anyone cares), and a Sandisk Ultra 8GB SD card (actually it's a uSD with an adaptor).  It looks like the SD is being set up for 4-bit datapath and 25MHz clock (when I simply upped that clock to 50MHz in the code, the program failed).


 


<pre>Initializing RTC (might take few seconds)...Done</pre>
<pre>Hello NXP Semiconductors</pre>
<pre> </pre>
<pre>***SDCARD demo***</pre>
<pre>SD Card Benchmark, 1048576 bytes in 4096 blocks</pre>
<pre>Open root directory.</pre>
<pre>Directory listing...</pre>
<pre>    1048576  BENCH.TXT</pre>
<pre>Creating BENCH.TXT</pre>
<pre>BYTES WRITTEN: 1048576</pre>
<pre>CPU    SPEED: 204.0 (MHz)</pre>
<pre>START   TIME: 2072797338 (ticks)</pre>
<pre>END     TIME: 2274637693 (ticks)</pre>
<pre>Total time: 989413 (uSec)</pre>
<pre>Write time: 963147 (uSec)</pre>
<pre>Write speed: 1088 (kB/S)</pre>
<pre>Open &amp; read benchmark.txt</pre>
<pre>BYTES READ: 1048576</pre>
<pre>CPU    SPEED: 204.0 (MHz)</pre>
<pre>START   TIME: 2278692453 (ticks)</pre>
<pre>END     TIME: 2359377293 (ticks)</pre>
<pre>Total time: 395513 (uSec)</pre>
<pre>Read time: 393769 (uSec)</pre>
<pre>Read speed: 2662 (kB/S)</pre>
<pre>Open root directory.</pre>
<pre>Directory listing...</pre>
<pre>    1048576  BENCH.TXT</pre>
<pre>Test completed.</pre>

 


So basically, 1MB/s write, 2.6MB/s read speeds with 1MB data file, 4K chunks at a time.  Not very impressive.... maybe I'm missing something?

Labels (1)
0 Kudos
5 Replies

395 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Wouter on Fri Jul 26 06:02:26 MST 2013
Hi,

The performance you mention indeed does not live up to the expectation! I'm sure big improvements can be made.
We have a demo of the LPC1788 (120MHz part) achieving an average read speed of 7.6MiB/s:
http://lpcware.com/content/blog/frame-video-player-lpc1788

The LPC4300 should be able to get at least a similar performance.

I can imagine the performance is low due to two main reasons:
- The example in LPCopen is intended as a basic example, and uses a non-optimized driver. The LPC1788 project in the blog in the link above is more optimized.
- It uses the flashless LPC4350. I'm not really sure about the lpcopen project, but it looks like it uses SPIFI for code execution. Executing from internal RAM or from internal flash (with an flash-based part, e.g. LPC4357) will boost performance (especially when the SPIFI clock is not running at max speed).

Regards,
Wouter
0 Kudos

395 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by bowerymarc on Thu Jun 13 15:59:41 MST 2013

Interesting (a bit late, I already decided against this processor for the project I'm on...).


I don't think it's the SD card itself though, because a few years ago I had benchmarked these with the Freescale iMX.31 and gotten blistering speeds with small chunks reading.


How to prove, however?


Adding the cost of a large external SDRAM is not feasible for this project - if it were, then maybe I could use uClinux, and get better performance from the SD card.


I didn't see the SDMMC raw performance application, do you have a relative pathname to it's directory?

0 Kudos

395 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by BangaragiriGovindaraju on Wed May 15 03:33:01 MST 2013

Hi,


  I tried the same application with LPCOpen V1.03 release with the following modifcations (Code attached in zip file):


  a. Entire bench data transferred at a time instead of transferring in 4KB/64Kb chunks


  b. The buffer is located in SDRAM since 1MB buffer not fit in IRAM


  I am getting the following results:


  Initializing RTC (might take few seconds)...Done


Hello NXP Semiconductors


 


***SDCARD demo***


SD Card Benchmark, 1048576 bytes in 1048576 blocks


 


Open root directory.


Directory listing...


       1310  IMPORT~1.TXT


         14  HELLO.TXT


    1048576  BENCH.TXT


         74  MESSAGE.TXT


Creating BENCH.TXT


BYTES WRITTEN: 1048576


CPU    SPEED: 204.0 (MHz)


START   TIME: 1722771677 (ticks)


END     TIME: 1774314134 (ticks)


Total time: 252659 (uSec)


Write time: 225940 (uSec)


Write speed: 4640 (kB/S)


Open &amp; read benchmark.txt


BYTES READ: 1048576


CPU    SPEED: 204.0 (MHz)


START   TIME: 1778300004 (ticks)


END     TIME: 1811442817 (ticks)


Total time: 162464 (uSec)


Read time: 161473 (uSec)


Read speed: 6493 (kB/S)


Open root directory.


Directory listing...


       1310  IMPORT~1.TXT


         14  HELLO.TXT


    1048576  BENCH.TXT


         74  MESSAGE.TXT


Test completed. 


  Also in LPCOpen V1.03 release, there is SDMMC measurement application which will measure the SDMMC raw performance (without FATFS) with code executed from IRAM.


0 Kudos

395 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by bowerymarc on Thu Apr 25 10:25:23 MST 2013

Sorry but they're not too small, I expect much better performance with that size.


But 64K does improve things.


<pre>Initializing RTC (might take few seconds)...Done</pre>
<pre>Hello NXP Semiconductors</pre>
<pre> </pre>
<pre>***SDCARD demo***</pre>
<pre>SD Card Benchmark, 1048576 bytes in 65536 blocks</pre>
<pre> </pre>
<pre>Open root directory.</pre>
<pre>Directory listing...</pre>
<pre>    1048576  BENCH.TXT</pre>
<pre>Creating BENCH.TXT</pre>
<pre>BYTES WRITTEN: 1048576</pre>
<pre>CPU    SPEED: 204.0 (MHz)</pre>
<pre>START   TIME: 6835245 (ticks)</pre>
<pre>END     TIME: 52824045 (ticks)</pre>
<pre>Total time: 225435 (uSec)</pre>
<pre>Write time: 176184 (uSec)</pre>
<pre>Write speed: 5951 (kB/S)</pre>
<pre>Open &amp; read benchmark.txt</pre>
<pre>BYTES READ: 1048576</pre>
<pre>CPU    SPEED: 204.0 (MHz)</pre>
<pre>START   TIME: 56787755 (ticks)</pre>
<pre>END     TIME: 86477660 (ticks)</pre>
<pre>Total time: 145538 (uSec)</pre>
<pre>Read time: 143525 (uSec)</pre>
<pre>Read speed: 7305 (kB/S)</pre>
<pre>Open root directory.</pre>
<pre>Directory listing...</pre>
<pre>    1048576  BENCH.TXT</pre>
<pre>Test completed.</pre>
<pre> </pre>
<pre>Better but still under-par.  Source attached for you to play with.  Unzip so you have a folder hitex_eva_4350_periph_sdmmc_benchmark at the same directory and level as the hitex_eva_4350_periph_sdmmc project, and then import (without copying).
0 Kudos

395 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by wmues on Thu Apr 25 07:26:57 MST 2013

4 K chunks is too small. Try 64KByte.

0 Kudos