Altera Nios II C2H Compiler Manuel d'utilisateur Page 104

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 138
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 103
4–10 9.1 Altera Corporation
Nios II C2H Compiler User Guide November 2009
Performance
Performance
The performance section of the C2H build report details information
about each loop in the accelerated function. For each loop shown, the
report contains the following information:
File name and source line number
Loop latency
Cycles per loop iteration (CPLI)
Scheduling information per assignment
Scheduling information per state
In the following discussion of information shown in the performance
section, refer to Example 4–2.
Example 4–2. CRC32 (Ethernet CRC)
#pragma altera_accelerate connect_variable\
crc_calculation/data to onchipRAM1
#pragma altera_accelerate connect_variable\
crc_calculation/table to onchipRAM2
unsigned long crc_calculation
( unsigned char * __restrict__ data,
unsigned long * __restrict__ table,
unsigned long length)
{
unsigned long i, crc = 0xFFFFFFFF;
unsigned char lut_addr;
for (i = 0; i < length; i++)
{
lut_addr = (crc & 0xFF) ^ *data++;
crc = (crc >> 8) ^ table[lut_addr];
}
return (crc ^ 0xFFFFFFFF);
}
Source Line Number
The performance section of the build report shows a source line number
for each loop statement. The line number is determined by the beginning
of the loop, which is the source line containing the opening block
delimiter ({). If your coding style places the loop keyword (do, while, or
for) on a separate line from the delimiter, the report shows the line where
the delimiter appears.
Vue de la page 103
1 2 ... 99 100 101 102 103 104 105 106 107 108 109 ... 137 138

Commentaires sur ces manuels

Pas de commentaire