Index: head/lang/beignet/Makefile =================================================================== --- head/lang/beignet/Makefile +++ head/lang/beignet/Makefile @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= beignet -PORTVERSION= 1.2.0 +PORTVERSION= 1.3.0 CATEGORIES= lang MASTER_SITES= https://01.org/sites/default/files/ DISTVERSIONSUFFIX= -source @@ -23,7 +23,7 @@ USE_XORG= sm ice x11 xext xfixes USE_GL= gl egl SHEBANG_FILES= src/git_sha1.sh backend/kernels/compile.sh -LLVMVER= 37 +LLVMVER= 39 CMAKE_ARGS+= -DLLVM_CONFIG_EXECUTABLE=${LOCALBASE}/bin/llvm-config${LLVMVER} Index: head/lang/beignet/distinfo =================================================================== --- head/lang/beignet/distinfo +++ head/lang/beignet/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1472595672 -SHA256 (beignet-1.2.0-source.tar.gz) = fc7af19efb7596b04510d26c558a576eba3e95e1ef86fd6951213c6a4bf58bff -SIZE (beignet-1.2.0-source.tar.gz) = 1076674 +TIMESTAMP = 1488314347 +SHA256 (beignet-1.3.0-source.tar.gz) = 63d98b4fe8fba3dbc0299d29fef84560625e5ac51b16b8fed453021d4afb5cd5 +SIZE (beignet-1.3.0-source.tar.gz) = 1133643 Index: head/lang/beignet/files/patch-CMakeLists.txt =================================================================== --- head/lang/beignet/files/patch-CMakeLists.txt +++ head/lang/beignet/files/patch-CMakeLists.txt @@ -1,6 +1,6 @@ ---- CMakeLists.txt.orig 2016-08-30 10:06:31 UTC +--- CMakeLists.txt.orig 2017-01-20 10:44:56 UTC +++ CMakeLists.txt -@@ -41,7 +41,6 @@ INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINA +@@ -31,7 +31,6 @@ INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINA INCLUDE (FindPkgConfig) @@ -8,7 +8,7 @@ set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/CMake/") INCLUDE (GNUInstallDirs OPTIONAL) # support old CMake without GNUInstallDirs -@@ -111,7 +110,7 @@ ELSE (USE_STANDALONE_GBE_COMPILER STREQU +@@ -101,7 +100,7 @@ ELSE (USE_STANDALONE_GBE_COMPILER STREQU ENDIF (USE_STANDALONE_GBE_COMPILER STREQUAL "true") @@ -17,7 +17,7 @@ # XLib Find_Package(X11) -@@ -230,7 +229,7 @@ IF(OCLIcd_FOUND) +@@ -219,7 +218,7 @@ IF(OCLIcd_FOUND) "intel-beignet.icd.in" "${ICD_FILE_NAME}" ) Index: head/lang/beignet/files/patch-CMake_FindLLVM.cmake =================================================================== --- head/lang/beignet/files/patch-CMake_FindLLVM.cmake +++ head/lang/beignet/files/patch-CMake_FindLLVM.cmake @@ -1,6 +1,6 @@ ---- CMake/FindLLVM.cmake.orig 2015-04-17 03:59:38.000000000 +0200 -+++ CMake/FindLLVM.cmake 2015-05-09 00:27:01.012701000 +0200 -@@ -52,21 +52,21 @@ +--- CMake/FindLLVM.cmake.orig 2017-01-20 10:40:51 UTC ++++ CMake/FindLLVM.cmake +@@ -46,21 +46,21 @@ endif (LLVM_FIND_VERSION_MAJOR AND LLVM_ if (LLVM_INSTALL_DIR) find_program(CLANG_EXECUTABLE Index: head/lang/beignet/files/patch-backend_src_backend_gen-insn-selection.cpp =================================================================== --- head/lang/beignet/files/patch-backend_src_backend_gen-insn-selection.cpp +++ head/lang/beignet/files/patch-backend_src_backend_gen-insn-selection.cpp @@ -1,16 +0,0 @@ -Error: No word lists can be found for the language "en_US". ---- backend/src/backend/gen_insn_selection.cpp.orig 2015-12-18 07:34:19.000000000 +0000 -+++ backend/src/backend/gen_insn_selection.cpp 2016-06-13 17:37:52.540024000 +0000 -@@ -1752,11 +1752,11 @@ - - // Boiler plate to initialize the selection library at c++ pre-main - static SelectionLibrary *selLib = NULL; -+ __attribute__((destructor)) - static void destroySelectionLibrary(void) { GBE_DELETE(selLib); } - static struct SelectionLibraryInitializer { - SelectionLibraryInitializer(void) { - selLib = GBE_NEW_NO_ARG(SelectionLibrary); -- atexit(destroySelectionLibrary); - } - } selectionLibraryInitializer; - Index: head/lang/beignet/files/patch-backend_src_backend_gen__insn__selection.cpp =================================================================== --- head/lang/beignet/files/patch-backend_src_backend_gen__insn__selection.cpp +++ head/lang/beignet/files/patch-backend_src_backend_gen__insn__selection.cpp @@ -0,0 +1,16 @@ +Error: No word lists can be found for the language "en_US". +--- backend/src/backend/gen_insn_selection.cpp.orig 2017-01-20 10:40:51 UTC ++++ backend/src/backend/gen_insn_selection.cpp +@@ -2456,11 +2456,11 @@ namespace gbe + + // Boiler plate to initialize the selection library at c++ pre-main + static SelectionLibrary *selLib = NULL; ++ __attribute__((destructor)) + static void destroySelectionLibrary(void) { GBE_DELETE(selLib); } + static struct SelectionLibraryInitializer { + SelectionLibraryInitializer(void) { + selLib = GBE_NEW_NO_ARG(SelectionLibrary); +- atexit(destroySelectionLibrary); + } + } selectionLibraryInitializer; + Index: head/lang/beignet/files/patch-backend_src_backend_gen__reg__allocation.cpp =================================================================== --- head/lang/beignet/files/patch-backend_src_backend_gen__reg__allocation.cpp +++ head/lang/beignet/files/patch-backend_src_backend_gen__reg__allocation.cpp @@ -1,5 +1,5 @@ ---- backend/src/backend/gen_reg_allocation.cpp.orig 2015-01-30 00:57:16.930955286 +0100 -+++ backend/src/backend/gen_reg_allocation.cpp 2015-01-30 00:57:53.886912927 +0100 +--- backend/src/backend/gen_reg_allocation.cpp.orig 2017-01-20 10:40:51 UTC ++++ backend/src/backend/gen_reg_allocation.cpp @@ -33,6 +33,7 @@ #include #include @@ -7,4 +7,4 @@ +#include - namespace gbe + #define HALF_REGISTER_FILE_OFFSET (32*64) Index: head/lang/beignet/files/patch-backend_src_ir_immediate.hpp =================================================================== --- head/lang/beignet/files/patch-backend_src_ir_immediate.hpp +++ head/lang/beignet/files/patch-backend_src_ir_immediate.hpp @@ -1,5 +1,5 @@ ---- backend/src/ir/immediate.hpp.orig 2015-01-30 01:06:19.873878476 +0100 -+++ backend/src/ir/immediate.hpp 2015-01-30 01:06:29.286877660 +0100 +--- backend/src/ir/immediate.hpp.orig 2017-01-20 10:40:51 UTC ++++ backend/src/ir/immediate.hpp @@ -25,6 +25,7 @@ #ifndef __GBE_IR_IMMEDIATE_HPP__ #define __GBE_IR_IMMEDIATE_HPP__ @@ -7,4 +7,4 @@ +#include #include #include "ir/type.hpp" - #include "sys/platform.hpp" + #include "ir/half.hpp" Index: head/lang/beignet/files/patch-backend_src_sys_alloc.cpp =================================================================== --- head/lang/beignet/files/patch-backend_src_sys_alloc.cpp +++ head/lang/beignet/files/patch-backend_src_sys_alloc.cpp @@ -1,5 +1,5 @@ ---- backend/src/sys/alloc.cpp.orig 2015-07-02 09:39:05.000000000 +0200 -+++ backend/src/sys/alloc.cpp 2015-08-26 11:57:00.901815000 +0200 +--- backend/src/sys/alloc.cpp.orig 2017-01-20 10:40:51 UTC ++++ backend/src/sys/alloc.cpp @@ -69,7 +69,7 @@ namespace gbe /*! Total number of allocations done */ volatile intptr_t allocNum; Index: head/lang/beignet/files/patch-src_cl__alloc.c =================================================================== --- head/lang/beignet/files/patch-src_cl__alloc.c +++ head/lang/beignet/files/patch-src_cl__alloc.c @@ -1,5 +1,5 @@ ---- src/cl_alloc.c.orig 2015-01-16 11:24:13.000000000 +0100 -+++ src/cl_alloc.c 2015-02-03 15:31:13.983452000 +0100 +--- src/cl_alloc.c.orig 2017-01-20 10:40:51 UTC ++++ src/cl_alloc.c @@ -22,7 +22,7 @@ #include @@ -9,7 +9,7 @@ static volatile int32_t cl_alloc_n = 0; -@@ -41,8 +41,13 @@ +@@ -41,8 +41,13 @@ cl_aligned_malloc(size_t sz, size_t alig { void * p = NULL; atomic_inc(&cl_alloc_n); Index: head/lang/beignet/files/patch-src_cl__api__kernel.c =================================================================== --- head/lang/beignet/files/patch-src_cl__api__kernel.c +++ head/lang/beignet/files/patch-src_cl__api__kernel.c @@ -0,0 +1,10 @@ +--- src/cl_api_kernel.c.orig 2017-01-20 10:40:51 UTC ++++ src/cl_api_kernel.c +@@ -26,6 +26,7 @@ + #include "CL/cl.h" + #include + #include ++#include + + cl_int + clGetKernelInfo(cl_kernel kernel, Index: head/lang/beignet/files/patch-src_cl__device__id.c =================================================================== --- head/lang/beignet/files/patch-src_cl__device__id.c +++ head/lang/beignet/files/patch-src_cl__device__id.c @@ -1,6 +1,6 @@ ---- src/cl_device_id.c.orig 2016-08-23 12:16:02.000000000 +0200 -+++ src/cl_device_id.c 2016-08-31 17:50:49.806646000 +0200 -@@ -35,7 +35,12 @@ +--- src/cl_device_id.c.orig 2017-01-20 10:40:51 UTC ++++ src/cl_device_id.c +@@ -34,7 +34,12 @@ #include #include #include @@ -13,7 +13,7 @@ #ifndef CL_VERSION_1_2 #define CL_DEVICE_BUILT_IN_KERNELS 0x103F -@@ -269,6 +274,7 @@ LOCAL cl_device_id +@@ -258,6 +263,7 @@ LOCAL cl_device_id cl_get_gt_device(void) { cl_device_id ret = NULL; @@ -21,7 +21,7 @@ const int device_id = cl_driver_get_device_id(); cl_device_id device = NULL; -@@ -737,7 +743,7 @@ kbl_gt4_break: +@@ -743,7 +749,7 @@ kbl_gt4_break: case PCI_CHIP_SANDYBRIDGE_M_GT2_PLUS: case PCI_CHIP_SANDYBRIDGE_BRIDGE_S: case PCI_CHIP_SANDYBRIDGE_S_GT: @@ -30,15 +30,15 @@ ret = NULL; break; default: -@@ -757,6 +763,7 @@ kbl_gt4_break: +@@ -764,6 +770,7 @@ kbl_gt4_break: /* Apply any driver-dependent updates to the device info */ cl_driver_update_device_info(ret); +#if defined(__linux__) - #define toMB(size) (size)&(0xfffffffffffffff<<20) + #define toMB(size) (size)&(UINT64_MAX<<20) /* Get the global_mem_size and max_mem_alloc size from * driver, system ram and hardware*/ -@@ -776,6 +783,24 @@ kbl_gt4_break: +@@ -783,6 +790,24 @@ kbl_gt4_break: ret->max_mem_alloc_size = toMB((ret->global_mem_size * 3 / 4 > maxallocmem) ? maxallocmem: ret->global_mem_size * 3 / 4); } Index: head/lang/beignet/files/patch-src_cl__enqueue.c =================================================================== --- head/lang/beignet/files/patch-src_cl__enqueue.c +++ head/lang/beignet/files/patch-src_cl__enqueue.c @@ -0,0 +1,10 @@ +--- src/cl_enqueue.c.orig 2017-01-20 10:40:51 UTC ++++ src/cl_enqueue.c +@@ -29,6 +29,7 @@ + #include + #include + #include ++#include + + static cl_int + cl_enqueue_read_buffer(enqueue_data *data, cl_int status) Index: head/lang/beignet/files/patch-src_cl__event.c =================================================================== --- head/lang/beignet/files/patch-src_cl__event.c +++ head/lang/beignet/files/patch-src_cl__event.c @@ -1,19 +0,0 @@ ---- src/cl_event.c.orig 2016-08-23 12:16:02.000000000 +0200 -+++ src/cl_event.c 2016-08-31 17:43:49.430217000 +0200 -@@ -27,6 +27,7 @@ - - #include - #include -+#include - - void cl_event_update_last_events(cl_command_queue queue, int wait) - { -@@ -657,7 +658,7 @@ cl_ulong cl_event_get_cpu_timestamp(cl_u - { - struct timespec ts; - -- if(clock_gettime(CLOCK_MONOTONIC_RAW,&ts) != 0){ -+ if(clock_gettime(CLOCK_MONOTONIC,&ts) != 0){ - printf("CPU Timmer error\n"); - return CL_FALSE; - } Index: head/lang/beignet/files/patch-src_git__sha1.sh =================================================================== --- head/lang/beignet/files/patch-src_git__sha1.sh +++ head/lang/beignet/files/patch-src_git__sha1.sh @@ -1,7 +1,7 @@ ---- src/git_sha1.sh.orig 2015-01-16 10:24:13 UTC +--- src/git_sha1.sh.orig 2017-02-28 21:01:04 UTC +++ src/git_sha1.sh @@ -1,4 +1,4 @@ --#!/bin/bash +-#!/usr/local/bin/bash +#!/bin/sh SOURCE_DIR=$1 Index: head/lang/beignet/files/patch-src_performance.c =================================================================== --- head/lang/beignet/files/patch-src_performance.c +++ head/lang/beignet/files/patch-src_performance.c @@ -1,5 +1,5 @@ ---- src/performance.c.orig 2015-08-26 11:58:45.989699000 +0200 -+++ src/performance.c 2015-08-26 11:59:40.117247000 +0200 +--- src/performance.c.orig 2017-01-20 10:40:51 UTC ++++ src/performance.c @@ -37,7 +37,6 @@ typedef struct storage @@ -8,7 +8,7 @@ static context_storage_node * prev_context_pointer = NULL; -@@ -170,6 +169,7 @@ static int cmp(const void *a, const void +@@ -174,6 +173,7 @@ static int cmp(const void *a, const void return 0; } @@ -16,7 +16,7 @@ static void print_time_info() { context_storage_node *p_context = record.context_storage; -@@ -273,11 +273,6 @@ static void print_time_info() +@@ -279,11 +279,6 @@ static void print_time_info() static void insert(cl_context context, const char *kernel_name, const char *build_opt, float time) { @@ -27,4 +27,4 @@ - } context_storage_node *p_context = find_context(context); kernel_storage_node *p_kernel = find_kernel(p_context, kernel_name, build_opt); - prev_context_pointer = p_context; + if(!p_kernel) Index: head/lang/beignet/files/patch-utests_CMakeLists.txt =================================================================== --- head/lang/beignet/files/patch-utests_CMakeLists.txt +++ head/lang/beignet/files/patch-utests_CMakeLists.txt @@ -1,6 +1,6 @@ ---- utests/CMakeLists.txt.orig 2015-02-02 21:01:26.000000000 +0100 -+++ utests/CMakeLists.txt 2015-02-02 22:19:04.185677000 +0100 -@@ -230,12 +230,12 @@ +--- utests/CMakeLists.txt.orig 2017-01-20 10:40:51 UTC ++++ utests/CMakeLists.txt +@@ -333,12 +333,12 @@ list (GET GBE_BIN_GENERATER -1 GBE_BIN_F if(GEN_PCI_ID) ADD_CUSTOM_COMMAND( OUTPUT ${kernel_bin}.bin Index: head/lang/beignet/files/patch-utests_builtin__exp.cpp =================================================================== --- head/lang/beignet/files/patch-utests_builtin__exp.cpp +++ head/lang/beignet/files/patch-utests_builtin__exp.cpp @@ -1,6 +1,6 @@ ---- utests/builtin_exp.cpp.orig 2015-01-16 10:24:13 UTC +--- utests/builtin_exp.cpp.orig 2017-01-20 10:40:51 UTC +++ utests/builtin_exp.cpp -@@ -25,7 +25,11 @@ static void cpu_compiler_math(float *dst +@@ -27,7 +27,11 @@ static void cpu_compiler_math(float *dst dst[0] = exp(x); dst[1] = exp2(x); Index: head/lang/beignet/files/patch-utests_utest.cpp =================================================================== --- head/lang/beignet/files/patch-utests_utest.cpp +++ head/lang/beignet/files/patch-utests_utest.cpp @@ -1,6 +1,6 @@ ---- utests/utest.cpp.orig 2015-08-26 12:00:07.664830000 +0200 -+++ utests/utest.cpp 2015-08-26 12:00:37.039946000 +0200 -@@ -44,6 +44,7 @@ +--- utests/utest.cpp.orig 2017-01-20 10:40:51 UTC ++++ utests/utest.cpp +@@ -52,6 +52,7 @@ vector v; RStatistics UTest::retStatistics; void releaseUTestList(void) { delete UTest::utestList; } @@ -8,7 +8,7 @@ void runSummaryAtExit(void) { // If case crashes, count it as fail, and accumulate finishrun if(UTest::retStatistics.finishrun != UTest::utestList->size()) { -@@ -113,7 +114,6 @@ +@@ -146,7 +147,6 @@ UTest::UTest(Function fn, const char *na utestList = new vector; catch_signal(); Index: head/lang/beignet/files/patch-utests_utest__math__gen.py =================================================================== --- head/lang/beignet/files/patch-utests_utest__math__gen.py +++ head/lang/beignet/files/patch-utests_utest__math__gen.py @@ -1,4 +1,4 @@ ---- utests/utest_math_gen.py.orig 2015-02-02 20:01:26 UTC +--- utests/utest_math_gen.py.orig 2017-01-20 10:40:51 UTC +++ utests/utest_math_gen.py @@ -241,10 +241,11 @@ static float atan2pi(float y, float x){ exp2Utests = func('exp2','exp2',[exp2_input_type],exp2_output_type,[exp2_input_values],'4 * FLT_ULP') Index: head/lang/beignet/pkg-plist =================================================================== --- head/lang/beignet/pkg-plist +++ head/lang/beignet/pkg-plist @@ -5,23 +5,28 @@ lib/beignet/include/ocl_as.h lib/beignet/include/ocl_async.h lib/beignet/include/ocl_atom.h +lib/beignet/include/ocl_atom_20.h lib/beignet/include/ocl_common.h lib/beignet/include/ocl_convert.h lib/beignet/include/ocl_defines.h +lib/beignet/include/ocl_enqueue.h lib/beignet/include/ocl_float.h lib/beignet/include/ocl_geometric.h lib/beignet/include/ocl_image.h lib/beignet/include/ocl_integer.h lib/beignet/include/ocl_math.h +lib/beignet/include/ocl_math_20.h lib/beignet/include/ocl_memcpy.h lib/beignet/include/ocl_memset.h lib/beignet/include/ocl_misc.h +lib/beignet/include/ocl_pipe.h lib/beignet/include/ocl_printf.h lib/beignet/include/ocl_relational.h lib/beignet/include/ocl_simd.h lib/beignet/include/ocl_sync.h lib/beignet/include/ocl_types.h lib/beignet/include/ocl_vload.h +lib/beignet/include/ocl_vload_20.h lib/beignet/include/ocl_work_group.h lib/beignet/include/ocl_workitem.h lib/beignet/libcl.so