Mercurial > mplayer.hg
comparison TOOLS/cpuinfo.c @ 18847:0e2d54a7cb61
merges two asm constraints to one, patch by Zuxy Meng zuxy PP meng AHH gmail PP com
author | gpoirier |
---|---|
date | Thu, 29 Jun 2006 14:47:07 +0000 |
parents | 2d996eb065d4 |
children | 5f31565951f7 |
comparison
equal
deleted
inserted
replaced
18846:2e73bc9d4b1c | 18847:0e2d54a7cb61 |
---|---|
61 | 61 |
62 | 62 |
63 static int64_t | 63 static int64_t |
64 rdtsc(void) | 64 rdtsc(void) |
65 { | 65 { |
66 unsigned int i, j; | 66 uint64_t i; |
67 #define RDTSC ".byte 0x0f, 0x31; " | 67 #define RDTSC ".byte 0x0f, 0x31; " |
68 asm volatile (RDTSC : "=a"(i), "=d"(j) : ); | 68 asm volatile (RDTSC : "=A"(i) : ); |
69 return ((int64_t)j<<32) + (int64_t)i; | 69 return i; |
70 } | 70 } |
71 | 71 |
72 static const char* | 72 static const char* |
73 brandname(int i) | 73 brandname(int i) |
74 { | 74 { |