From 11ac4665c835a27a097e5021074cbf366bcb9765 Mon Sep 17 00:00:00 2001 From: Zhang Xianyi Date: Mon, 5 Oct 2015 14:14:32 -0500 Subject: [PATCH] Fixed #654. Make sure the gotoblas_init function is run before all other static initializations. --- driver/others/memory.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/driver/others/memory.c b/driver/others/memory.c index 49c57f911..f75a47d65 100644 --- a/driver/others/memory.c +++ b/driver/others/memory.c @@ -139,8 +139,8 @@ USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #define BITMASK(a, b, c) ((((a) >> (b)) & (c))) -#define CONSTRUCTOR __attribute__ ((constructor)) -#define DESTRUCTOR __attribute__ ((destructor)) +#define CONSTRUCTOR __attribute__ ((constructor(101))) +#define DESTRUCTOR __attribute__ ((destructor(101))) #ifdef DYNAMIC_ARCH gotoblas_t *gotoblas = NULL;