Intel® Moderncode for Parallel Architectures
Support for developing parallel programming applications on Intel® Architecture.

time i nmicrosecond in itanium

karimfath
初学者
377 次查看

hello

i want mesure the time elapsed in segment of code but in itanium rdstc is not supported then the question .how can i evaluate time of execution of segment of code in itanium processor

thanks for help

0 项奖励
1 回复
TimP
名誉分销商 III
377 次查看
Quoting - karimfath

i want mesure the time elapsed in segment of code but in itanium rdstc is not supported then the question .how can i evaluate time of execution of segment of code in itanium processor

unsigned long result;
/* gcc-IA64 version */
__asm__ __volatile__("mov %0=ar.itc" : "=r"(result) :: "memory");
while (__builtin_expect ((int) result == -1, 0))
__asm__ __volatile__("mov %0=ar.itc" : "=r"(result) :: "memory");

0 项奖励
回复