Commit 5e1fad85 authored by Sergey Vojtovich's avatar Sergey Vojtovich

MDEV-6533 - MySQL Bug#72718 - CACHE_LINE_SIZE in innodb should be 128 on POWER

This patch is suggested by Stewart Smith.
Define CACHE_LINE_SIZE to 128 on POWER.
parent 665ea779
...@@ -32,7 +32,11 @@ Created 2012/04/12 by Sunny Bains ...@@ -32,7 +32,11 @@ Created 2012/04/12 by Sunny Bains
#include "os0thread.h" #include "os0thread.h"
/** CPU cache line size */ /** CPU cache line size */
#ifdef __powerpc__
#define CACHE_LINE_SIZE 128
#else
#define CACHE_LINE_SIZE 64 #define CACHE_LINE_SIZE 64
#endif
/** Default number of slots to use in ib_counter_t */ /** Default number of slots to use in ib_counter_t */
#define IB_N_SLOTS 64 #define IB_N_SLOTS 64
......
...@@ -32,7 +32,11 @@ Created 2012/04/12 by Sunny Bains ...@@ -32,7 +32,11 @@ Created 2012/04/12 by Sunny Bains
#include "os0thread.h" #include "os0thread.h"
/** CPU cache line size */ /** CPU cache line size */
#ifdef __powerpc__
#define CACHE_LINE_SIZE 128
#else
#define CACHE_LINE_SIZE 64 #define CACHE_LINE_SIZE 64
#endif
/** Default number of slots to use in ib_counter_t */ /** Default number of slots to use in ib_counter_t */
#define IB_N_SLOTS 64 #define IB_N_SLOTS 64
......
...@@ -504,7 +504,11 @@ UNIV_INTERN ulint srv_available_undo_logs = 0; ...@@ -504,7 +504,11 @@ UNIV_INTERN ulint srv_available_undo_logs = 0;
/* Ensure status variables are on separate cache lines */ /* Ensure status variables are on separate cache lines */
#ifdef __powerpc__
#define CACHE_LINE_SIZE 128
#else
#define CACHE_LINE_SIZE 64 #define CACHE_LINE_SIZE 64
#endif
#define CACHE_ALIGNED __attribute__ ((aligned (CACHE_LINE_SIZE))) #define CACHE_ALIGNED __attribute__ ((aligned (CACHE_LINE_SIZE)))
UNIV_INTERN byte UNIV_INTERN byte
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment