This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

The limit write and read speed applying SATA2 interface of OMAP-L138 chip

Other Parts Discussed in Thread: OMAP-L138

Hi,

   I am trying to test the write and read speed of the sata2 interface on OMAP-L138, the harddisk is Segate 320GB 7200.10 16M, the format is FAT32, I wrote a simple program running on the arm side as followed:

#include <sys/types.h>

#include <sys/stat.h>

#include <unistd.h>

#include <fcntl.h>

#include <stdio.h>

#include <errno.h>

extern int errno;

#define NUM 1024000

 int main()

{   

long int i;

int fd;

int buf[NUM] ={0};

fd = open("/mnt/posix.data",O_CREAT | O_RDWR | O_EXCL, S_IRWXU);

if (-1 == fd) {

  switch (errno) {

case EEXIST:

    printf("File exist!\n");

break;

   default:

    printf("open file fail!\n");

break;

   }

return 0;

}

write (fd, buf, NUM);

   for(i=0;i<999;i++) 

  {

  lseek(fd,0,SEEK_END);

       write (fd, buf, NUM);

  }

close (fd);

}

  A array of 1MB was written into the harddisk for about 1000 times cycle to make the posix.data file locate in the /mnt directory about 1GB, as I tested, the write speed is about 17MB/s, but when I refer to the TI wiki website http://processors.wiki.ti.com/index.php/DaVinci_PSP_03.20.00.14_Device_Driver_Features_and_Performance_Guide#SATA , I found that the average write speed of the sata2 interface is about 21.6MB/s @300 MHz . Could you help me analyse this problem please? Are there something wrong with my program or the format of the hardisk which leading to this lower write speed happend? How can I make the sata2 interface working on a higher write speed? 

   Beyond this, I am working on the configuration of the DSPLink to make the two cores in the OMAP-L138 to communicate with each other, but I found it difficult to start with, could you please give me some advice to get start with the Dsplink?

  Thank you very much for your help.

   Regards,

    Saul.


  • For your DSPLink question, have you read through the wiki here: http://processors.wiki.ti.com/index.php/DSPLink_Overview?

    Jeff

  • The performance numbers in the data sheet referred in the post is for EXT2. FAT is not a Linux native file-system and it is not optimized for better performance.

    Following section in the SATA FAQ have some tips on improving FAT32 throughput http://processors.wiki.ti.com/index.php/TI_SATA_FAQ#How_to_improve_VFAT_performance_in_Linux

    If the disk is accessed directly without filesystem and other OS overhead, the throughput numbers will be very high.

    Jeff

  • Hi Jeff,

       Thanks for your help. A filesystem is necessary for me to make it easier to read the data in the harddisk on Windows OS. Is the 21.6MB/s write performance @300MHz of OMAP-L138 the limiting performance? Is the write performance conneted to the cpu clock speed? Cause I care the write performance of the SATA2 interface most, so I want to make sure the limiting write performance applying the sata2 interface of the OMAP-L138 chip with a filesystem in the harddisk. 

       Besides, will the write performance of the OMAP A8168 chip under the same condition(the same harddisk, with a filesystem) much more faster than OMAP-L138?

       My problem is so general, thanks for your time to read and answer it.

       Thanks.

       Regards.

        Saul.

  • Hi Saul,

    Apart from the cpu speed there are various other parameters like interconnect speed, memory speed, cache size/cache line size which could impact the performance. DM8168 is Cortex-A8 running @ 1Ghz and the memory speed is >= 800Mhz data rate (in our experiments).

    Yes, for the same harddisk/filesystem, DM8168 would definetely perform better.

    The table available @ http://processors.wiki.ti.com/index.php/TI_SATA_FAQ#EXT2_Write_Performance have some comparison on the throughput numbers between these devices.

     

    Regards

    Mansoor