URL
https://opencores.org/ocsvn/or1k/or1k/trunk
Go to most recent revision |
Show entire file |
Details |
Blame |
View Log
Rev 884 |
Rev 897 |
Line 754... |
Line 754... |
}
|
}
|
}
|
}
|
|
|
/* Outputs time in pretty form to dest string */
|
/* Outputs time in pretty form to dest string */
|
|
|
void generate_time_pretty (char *dest, long time_ps)
|
char *generate_time_pretty (char *dest, long time_ps)
|
{
|
{
|
int exp3 = 0;
|
int exp3 = 0;
|
if (time_ps) {
|
if (time_ps) {
|
while ((time_ps % 1000) == 0) {
|
while ((time_ps % 1000) == 0) {
|
time_ps /= 1000;
|
time_ps /= 1000;
|
exp3++;
|
exp3++;
|
}
|
}
|
}
|
}
|
sprintf (dest, "%i%cs", time_ps, "pnum"[exp3]);
|
sprintf (dest, "%i%cs", time_ps, "pnum"[exp3]);
|
|
return dest;
|
}
|
}
|
|
|
No newline at end of file
|
No newline at end of file
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.