Hello,

Pocl_version 0.13 + llvm 3.8 are both VERY old. I would be surprised if half 
type works there, especially in combination with 64bit ARM. I recommend you get 
LLVM 6 and pocl at least 1.1, otherwise you'll experience problems.


Regards,

-- mb


________________________________
From: Wuweijia <[email protected]>
Sent: Monday, August 13, 2018 5:33:46 AM
To: Portable Computing Language development discussion
Cc: Fanbohao
Subject: [pocl-devel] 【Hi】 There is Question about half2


Hi:

     I write the opencl demo. In this demo , I wrote the half2 type .  But it 
compile it failed.



   The output as below:

                2018-07-13 03:24:42.805561780] POCL: in fn void 
pocl_incr_device_ref() at line 294:

*** INFO ***  [GPUStub] void pocl_incr_device_ref() devices_ref=2

### use a saved llvm::Module

### fetching kernel metadata for kernel testHalf program 0x7f80a43000 input 
llvm::Module 0x7f80bf9580

[2018-07-13 03:24:42.805712080] POCL: in fn cl_mem POclCreateBuffer(cl_context, 
cl_mem_flags, size_t, void *, cl_int *) at line 94:

[2018-07-13 03:24:42.805752880] POCL: in fn cl_int 
POclEnqueueNDRangeKernel(cl_command_queue, cl_kernel, cl_uint, const size_t *, 
const size_t *, const size_t *, cl_uint, const cl_event *, cl_event *) at line 
133:

*** INFO ***  Preferred WG size multiple 8

[2018-07-13 03:24:42.805786020] POCL: in fn cl_int 
POclEnqueueNDRangeKernel(cl_command_queue, cl_kernel, cl_uint, const size_t *, 
const size_t *, const size_t *, cl_uint, const cl_event *, cl_event *) at line 
209:

*** INFO ***  Queueing kernel testHalf with local size 1 x 1 x 1 group sizes 3 
x 1 x 1...

### calling the kernel compiler for kernel testHalf local_x 1 local_y 1 local_z 
1 parallel_filename: 
/sdcard/pocl/kcache/HK/BOCDHECGLACEHDFDNAGEMLIFMJJKNKIKKHGMB/testHalf/1-1-1/parallel.bc

### cloning the preloaded LLVM IR

[2018-07-13 03:24:42.806801840] POCL: in fn llvm::Module 
*kernel_library(cl_device_id) at line 1341:

*** INFO ***  Using 
/data/data/org.pocl.libs/files/share/pocl/kernel-aarch64-unknown-linux-android-generic.bc
 as the built-in lib.

### autovectorizer enabled



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Found a loop: .lr.ph.i

LV: Can't if-convert the loop.

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Found a loop:

LV: Can't if-convert the loop.

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Found a loop:

LV: Can't if-convert the loop.

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Found a loop:

LV: Can't if-convert the loop.

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Found a loop:

LV: Can't if-convert the loop.

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Found a loop:

LV: Can't if-convert the loop.

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Not vectorizing: Cannot prove legality.



LV: Checking a loop in "_cl_printf" from /sdcard/pocl/kcache/temp_t6kfN4.cl

LV: Loop hints: force=? width=0 unroll=0

LV: Not vectorizing: Cannot prove legality.

/usr1/code/source/pocl/llvm-3.8.0.src/lib/Bitcode/Writer/ValueEnumerator.h:132: 
unsigned int llvm::ValueEnumerator::getTypeID(llvm::Type*) const: assertion "I 
!= TypeMap.end() && "Type not in ValueEnumerator!"" failed

libc: 
/usr1/code/source/pocl/llvm-3.8.0.src/lib/Bitcode/Writer/ValueEnumerator.h:132: 
unsigned int llvm::ValueEnumerator::getTypeID(llvm::Type*) const: assertion "I 
!= TypeMap.end() && "Type not in ValueEnumerator!"" failed



the test is abort now; I have add it ” pragma OPENCL EXTENSION cl_khr_fp16 : 
enable” to cl file  but it still faled



Env:

                CPU: AARCH64

                OS: LINUX / android

                Pocl_version 0.13 + llvm 3.8

                GPU: no






------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
pocl-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pocl-devel

Reply via email to