Added some kernel and driver/others objects.tags/v0.2.15^2
| @@ -56,12 +56,16 @@ endif () | |||||
| # TODO: CMAKE_SYSTEM_PROCESSOR doesn't seem to be correct - instead get it from the compiler a la c_check | # TODO: CMAKE_SYSTEM_PROCESSOR doesn't seem to be correct - instead get it from the compiler a la c_check | ||||
| set(ARCH ${CMAKE_SYSTEM_PROCESSOR}) | set(ARCH ${CMAKE_SYSTEM_PROCESSOR}) | ||||
| if (${ARCH} STREQUAL "AMD64") | if (${ARCH} STREQUAL "AMD64") | ||||
| set(ARCH "X86_64") | |||||
| set(ARCH "x86_64") | |||||
| endif () | endif () | ||||
| # If you are using a 32-bit compiler on a 64-bit system CMAKE_SYSTEM_PROCESSOR will be wrong | # If you are using a 32-bit compiler on a 64-bit system CMAKE_SYSTEM_PROCESSOR will be wrong | ||||
| if (${ARCH} STREQUAL "X86_64" AND BINARY EQUAL 32) | |||||
| set(ARCH X86) | |||||
| if (${ARCH} STREQUAL "x86_64" AND BINARY EQUAL 32) | |||||
| set(ARCH x86) | |||||
| endif () | |||||
| if (${ARCH} STREQUAL "X86") | |||||
| set(ARCH x86) | |||||
| endif () | endif () | ||||
| set(COMPILER_ID ${CMAKE_CXX_COMPILER_ID}) | set(COMPILER_ID ${CMAKE_CXX_COMPILER_ID}) | ||||
| @@ -69,9 +73,11 @@ if (${COMPILER_ID} STREQUAL "GNU") | |||||
| set(COMPILER_ID "GCC") | set(COMPILER_ID "GCC") | ||||
| endif () | endif () | ||||
| string(TOUPPER ${ARCH} UC_ARCH) | |||||
| file(WRITE ${TARGET_CONF} | file(WRITE ${TARGET_CONF} | ||||
| "#define OS_${HOST_OS}\t1\n" | "#define OS_${HOST_OS}\t1\n" | ||||
| "#define ARCH_${ARCH}\t1\n" | |||||
| "#define ARCH_${UC_ARCH}\t1\n" | |||||
| "#define C_${COMPILER_ID}\t1\n" | "#define C_${COMPILER_ID}\t1\n" | ||||
| "#define __${BINARY}BIT__\t1\n" | "#define __${BINARY}BIT__\t1\n" | ||||
| "#define FUNDERSCORE\t${FU}\n") | "#define FUNDERSCORE\t${FU}\n") | ||||
| @@ -29,9 +29,7 @@ if (SMP) | |||||
| endif () | endif () | ||||
| endif () | endif () | ||||
| add_library(COMMON_OBJS OBJECT | |||||
| ${MEMORY} | |||||
| ${SMP_SOURCES} | |||||
| set(COMMON_SOURCES | |||||
| xerbla.c | xerbla.c | ||||
| abs.c # TODO: this is split into c_abs (DOUBLE unset) and z_abs (DOUBLE set) in the Makefile | abs.c # TODO: this is split into c_abs (DOUBLE unset) and z_abs (DOUBLE set) in the Makefile | ||||
| openblas_set_num_threads.c | openblas_set_num_threads.c | ||||
| @@ -40,12 +38,12 @@ add_library(COMMON_OBJS OBJECT | |||||
| openblas_error_handle.c | openblas_error_handle.c | ||||
| ) | ) | ||||
| #ifeq ($(DYNAMIC_ARCH), 1) | |||||
| #COMMONOBJS += dynamic.$(SUFFIX) | |||||
| #else | |||||
| #COMMONOBJS += parameter.$(SUFFIX) | |||||
| #endif | |||||
| # | |||||
| if (DYNAMIC_ARCH) | |||||
| list(APPEND COMMON_SOURCES dynamic.c) | |||||
| else () | |||||
| list(APPEND COMMON_SOURCES parameter.c) | |||||
| endif () | |||||
| #ifdef EXPRECISION | #ifdef EXPRECISION | ||||
| #COMMONOBJS += x_abs.$(SUFFIX) qlamch.$(SUFFIX) qlamc3.$(SUFFIX) | #COMMONOBJS += x_abs.$(SUFFIX) qlamch.$(SUFFIX) qlamc3.$(SUFFIX) | ||||
| #endif | #endif | ||||
| @@ -62,6 +60,12 @@ add_library(COMMON_OBJS OBJECT | |||||
| #COMMONOBJS += profile.$(SUFFIX) | #COMMONOBJS += profile.$(SUFFIX) | ||||
| #endif | #endif | ||||
| add_library(COMMON_OBJS OBJECT | |||||
| ${MEMORY} | |||||
| ${SMP_SOURCES} | |||||
| ${COMMON_SOURCES} | |||||
| ) | |||||
| list(APPEND DBLAS_OBJS "COMMON_OBJS") | list(APPEND DBLAS_OBJS "COMMON_OBJS") | ||||
| #LIBOTHERS = libothers.$(LIBSUFFIX) | #LIBOTHERS = libothers.$(LIBSUFFIX) | ||||
| @@ -3,6 +3,14 @@ include_directories(${CMAKE_SOURCE_DIR}) | |||||
| # TODO: need to read ${KERNELDIR}/KERNEL into CMake vars | # TODO: need to read ${KERNELDIR}/KERNEL into CMake vars | ||||
| # Makeflie | |||||
| message(STATUS "${ARCH}") | |||||
| if (${ARCH} STREQUAL "x86") | |||||
| GenerateNamedObjects("${KERNELDIR}/cpuid.S" "") | |||||
| list(APPEND DBLAS_OBJS ${OBJ_LIST_OUT}) | |||||
| endif () | |||||
| # Makefile.L1 | # Makefile.L1 | ||||