AnsweredAssumed Answered

T4240 calculation speed

Question asked by Andre Westerholz on Oct 8, 2015
Latest reply on Oct 27, 2015 by LPP

Hello,

 

I´ve compared the calculation speed of a T4240DSQ and a P4080DS. What I´ve found out is that the T4 has advantages by the calculation itself (especially at double multiplications) but reading/writing to values takes more time than on the P4080:

 

Here is the test code:

 

volatile double dA;

volatile double dB;

volatile double dC;

volatile double dD;

volatile double dE;

volatile double dF;

volatile double dG;

volatile double dH;

volatile double dI;

volatile double dJ;

 

 

void MemWrite10Int(int NoOfRuns, int CountVal)

{

   while(NoOfRuns != 0)

   {

      iA = 0;

      iB = 1;

      iC = 2;

      iD = 3;

      iE = 4;

      iF = 5;

      iG = 6;

      iH = 7;

      iI = 8;

      iJ = 9;

      NoOfRuns -= CountVal;

   }

}

 

NoOfRunsare 5e6

CountVal is 1

 

 

The execution time of these functions on the P4080 takes ~31 ms and on the T4240 ~71 ms. So the T4 is much slower.

 

The switches on the T4240 DSQ – board are configured to have SYS_CLK and DDR_CLK at 66.66 MHz

 

The RCW is configured as in the Quick start guide:

Reset Configuration Word (RCW):

       00000000: 14180019 0c101914 00000000 00000000

       00000010: 04383063 30548c00 1c020000 1d000000

       00000020: 00000000 ee0000ee 00000000 000307fc

       00000030: 00000000 00000000 00000000 00000020

 

We are currently uses a T4240 Revision 1. Operating system is VxWorks.

 

The only discrepancy that I have found is that the default RCW configuration of MEM_PLL_RAT is 0x18 (24d). This value is in the Reference Manual and in the Technical Data sheet described as reserved.

 

Could this be the reason for the slow value writing? Or is there any other reason why the T4 is significant slower writing to values?

Outcomes