X-Git-Url: http://git.liburcu.org/?p=urcu.git;a=blobdiff_plain;f=test_urcu_timing.c;h=8577b8f092e472f2e25fc5e0e4c10d070320a949;hp=5f75bae448ee3a3e883377e3a6e284c725df7fc7;hb=9fb223da744aff7501107d09d7502c2baadc421f;hpb=2c9689fe0485146fc5ff5e5023c941629eee124d diff --git a/test_urcu_timing.c b/test_urcu_timing.c index 5f75bae..8577b8f 100644 --- a/test_urcu_timing.c +++ b/test_urcu_timing.c @@ -32,6 +32,9 @@ #include #include +/* Make this big enough to include the POWER5+ L3 cacheline size of 256B */ +#define CACHE_LINE_SIZE 4096 + #if defined(_syscall0) _syscall0(pid_t, gettid) #elif defined(__NR_gettid) @@ -93,8 +96,8 @@ static int num_write; #define NR_READ num_read #define NR_WRITE num_write -static cycles_t __attribute__((aligned(128))) *reader_time; -static cycles_t __attribute__((aligned(128))) *writer_time; +static cycles_t __attribute__((aligned(CACHE_LINE_SIZE))) *reader_time; +static cycles_t __attribute__((aligned(CACHE_LINE_SIZE))) *writer_time; void *thr_reader(void *arg) {