Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -148,11 +148,6 @@ ENDIF()
# Architechture Definitions
INCLUDE(${CMAKE_MODULE_PATH}/TargetArch.cmake)
target_architecture(ARCH)
IF(${ARCH} STREQUAL "x86_64")
ADD_DEFINITIONS(-DARCH_64)
ELSE(${ARCH})
ADD_DEFINITIONS(-DARCH_32)
ENDIF()

INCLUDE(${CMAKE_MODULE_PATH}/Version.cmake)

Expand Down
2 changes: 1 addition & 1 deletion src/api/c/imageio.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -760,7 +760,7 @@ af_err af_load_image_memory(af_array *out, const void* ptr)
return AF_ERR_NOT_CONFIGURED;
}

af_err af_save_image_memory(void **ptr, const char* filename, const af_array in_)
af_err af_save_image_memory(void **ptr, const af_array in_, const af_image_format format)
{
printf("Error: Image IO requires FreeImage. See https://github.com/arrayfire/arrayfire\n");
return AF_ERR_NOT_CONFIGURED;
Expand Down
3 changes: 0 additions & 3 deletions src/backend/cpu/math.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@ namespace cpu
uint abs(uint val) { return val; }
uchar abs(uchar val) { return val; }
uintl abs(uintl val) { return val; }
#if !(defined(OS_WIN) || (defined(ARCH_32) && defined(OS_LNX))) // Not(Windows or Tegra)
size_t abs(size_t val) { return val; }
#endif

cfloat scalar(float val)
{
Expand Down
3 changes: 0 additions & 3 deletions src/backend/cpu/math.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,6 @@ namespace cpu
uint abs(uint val);
uchar abs(uchar val);
uintl abs(uintl val);
#if !(defined(OS_WIN) || (defined(ARCH_32) && defined(OS_LNX))) // Not(Windows or Tegra)
size_t abs(size_t val);
#endif

template<typename T> static inline T min(T lhs, T rhs) { return std::min(lhs, rhs); }
cfloat min(cfloat lhs, cfloat rhs);
Expand Down
10 changes: 3 additions & 7 deletions src/backend/cpu/platform.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -172,15 +172,11 @@ CPUInfo::CPUInfo()
namespace cpu
{

static const char *get_system(void)
static const std::string get_system(void)
{
return
#if defined(ARCH_32)
"32-bit "
#elif defined(ARCH_64)
"64-bit "
#endif
std::string arch = (sizeof(void *) == 4) ? "32-bit " : "64-bit ";

return arch +
#if defined(OS_LNX)
"Linux";
#elif defined(OS_WIN)
Expand Down
10 changes: 3 additions & 7 deletions src/backend/cuda/platform.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -116,15 +116,11 @@ static inline bool card_compare_num(const cudaDevice_t &l, const cudaDevice_t &r
return 0;
}

static const char *get_system(void)
static const std::string get_system(void)
{
return
#if defined(ARCH_32)
"32-bit "
#elif defined(ARCH_64)
"64-bit "
#endif
std::string arch = (sizeof(void *) == 4) ? "32-bit " : "64-bit ";

return arch +
#if defined(OS_LNX)
"Linux";
#elif defined(OS_WIN)
Expand Down
10 changes: 3 additions & 7 deletions src/backend/opencl/platform.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,15 +60,11 @@ static const std::string CL_GL_SHARING_EXT = "cl_APPLE_gl_sharing";
static const std::string CL_GL_SHARING_EXT = "cl_khr_gl_sharing";
#endif

static const char *get_system(void)
static const std::string get_system(void)
{
return
#if defined(ARCH_32)
"32-bit "
#elif defined(ARCH_64)
"64-bit "
#endif
std::string arch = (sizeof(void *) == 4) ? "32-bit " : "64-bit ";

return arch +
#if defined(OS_LNX)
"Linux";
#elif defined(OS_WIN)
Expand Down