Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implementation for github triSYCL issue #126 and enterprise issue #4 …
…and llvm-mirror#7 : triSYCL issue #126 : triSYCL/triSYCL#126 Improve SYCL-args-flattening pass to work in quite more cases. enterprise issue #4 : https://gitenterprise.xilinx.com/rkeryell/triSYCL/issues/4 Add missing SPIR calling convention to device functions. enterprise issue llvm-mirror#7 : https://gitenterprise.xilinx.com/rkeryell/triSYCL/issues/7 Rename function and basic block names to avoid choking xocc with some C++ lambda mangled names. Squashed commit of the following: commit 516bd0f3aba3554eedf6e76a4f338877db664b86 Author: Lin Ya Yu <yu810226@gmail.com> Date: Mon Feb 5 16:03:35 2018 +0000 Minor fix for SYCLKernel.cpp 1. Reorder the include headers to follow the dictionary order. 2. Simplified the syntax. commit bd7f02901143915765367df79cdf14558393d450 Author: Lin Ya Yu <yu810226@gmail.com> Date: Mon Feb 5 11:38:59 2018 +0000 Minor fix for SYCLKernel.cpp Since we change the data structure from vector to SmallPtrSet. Change push_back to insert. Fix for -> commit 03342bbf1740dbf36f4028d51f7fb751c0f03510 Author: Lin Ya Yu <yu810226@gmail.com> Date: Mon Feb 5 11:36:00 2018 +0000 Minor fix for lib/SYCL/inSPIRation.cpp Since there would be a warning that the syntax might be ambiguous if we remove { here, put it back. commit f1ee3c6240dc48d065433b672ab8dd55314a57c2 Author: Lin Ya Yu <yu810226@gmail.com> Date: Fri Feb 2 18:13:15 2018 +0000 Fix for SYCL.h, SYCLArgsFlattening.cpp, and SYCLKernel.cpp Change data structure from vector to SmallPtrSet. Change function name, argument name and add comments for more clearer explanation of the code. fix Spurious space and typo commit db40fc502961349ade4ccbb13541fc6f1d2049a9 Author: Lin Ya Yu <yu810226@gmail.com> Date: Fri Feb 2 18:11:11 2018 +0000 Minor fix for inSPIRation.cpp and LoopIdiomRecognize.cpp Fix Spurious space and typo commit d5fb8c8aef18f851e2aac580615a44c9ff59c612 Author: Lin Ya Yu <yu810226@gmail.com> Date: Thu Jan 11 20:56:09 2018 +0000 Modify SYCL Argument flattening pass 1. Modify SYCL Argument flattening pass for better complexity to find out functions having kernel as an ancestor. 2. Add comment for SYCL Argument flattening pass. 3. Clean up code for SYCLKernel.cpp commit cd4672e8def78c729b4fe98d3e00b6ad1177b1f1 Author: Lin Ya Yu <yu810226@gmail.com> Date: Thu Jan 11 20:46:20 2018 +0000 Add new functions to support detecting functions that have kernel as an ancestor commit 27f9afb2f14d22e696bda48c8c1e536d04ec9755 Author: Lin Ya Yu <yu810226@gmail.com> Date: Thu Jan 11 12:07:58 2018 +0000 Remove code that force not executing loop idiom pass for some functions in host side For host, skip loop idiom pass here, and execute it after SYCL arguments flattening pass. commit ff75f05bce8963a580c660847d2e77aa1a83f0fb Author: Lin Ya Yu <yu810226@gmail.com> Date: Tue Jan 9 12:04:55 2018 +0000 Modify function to test if function is called by kernel/ Minor fix for files commit 43f10dfbc66a0229e69923d5c377cea6ddc81889 Author: Lin Ya Yu <yu810226@gmail.com> Date: Tue Jan 9 11:43:32 2018 +0000 Move code in SYCLCleanUpFuncName.cpp inside inSPIRation.cpp commit 06763f74f0bf91959b19d0f315231dd44c0b5057 Author: Lin Ya Yu <yu810226@gmail.com> Date: Mon Jan 8 21:09:02 2018 +0000 Fix SYCLArgsFlattening.cpp to deal with nested call commit ca9dcbfd2348d0cd800b4dfbf37dced14cd35f6b Author: Lin Ya Yu <yu810226@gmail.com> Date: Mon Jan 8 21:04:37 2018 +0000 Modify SYCL pass name and add new function in SYCLKernel.cpp Modify pass SYCLModifySPIRFuncName.cpp to SYCLCleanUpFuncName.cpp Change SYCL function called by kernel names to have sycl_func_ prefix. Add new function detecting call site is kernel function in SYCLKernel.cpp Other minor fixes for comments or indentation. commit 02e3781dfee75dac43ec93414c6452b94fa5e595 Author: Lin Ya Yu <yu810226@gmail.com> Date: Mon Jan 8 15:52:26 2018 +0000 Minor fix for LoopIdiomRecognize.cpp commit 2f1e1f5c0a2d8518103200c560eca4f3d9d9e109 Author: Lin Ya Yu <yu810226@gmail.com> Date: Mon Jan 8 15:50:55 2018 +0000 Simplified inSPIRation.cpp commit 727faab31b26c001f01c0b06074fb88a752c3ede Author: Lin Ya Yu <yu810226@gmail.com> Date: Mon Jan 8 15:49:08 2018 +0000 Remove copy-paste files. Keep them under SYCL directory only. commit 2ed9262512163c389b3e70bc4eb8697b29ac1a86 Author: Lin Ya Yu <yu810226@gmail.com> Date: Tue Dec 19 14:43:31 2017 +0000 Rename basic block name to avoid $ produced Solution for issue https://gitenterprise.xilinx.com/rkeryell/triSYCL/issues/7 commit 508c4c3edc1344e5a16633061733dcac808f5d91 Author: Lin Ya Yu <yu810226@gmail.com> Date: Tue Dec 5 19:44:59 2017 +0000 Modify name and calling convention for SPIR functions 1. SYCLModifySPIRFuncName.cpp pass is added for modifying function names for functions called in SYCL kernel. 2. In inSPIRation.cpp, add code to modify functions called in SYCL kernel to have SPIR_FUNC calling convention. commit 77c2d772c0bc60b8b855d23183fa30dba8fc5dab Author: Lin Ya Yu <yu810226@gmail.com> Date: Tue Dec 5 14:25:24 2017 +0000 Modify SYCLArgsFlattening.cpp This pass is modified for solving problem in example yu810226/triSYCL@70fb460#diff-bbbcbcbc399a038ddcd05dbbdb685226 While the kernel is big enough, device compiler generated a function inside instantiate_kernel function in pre_kernel.ll file leading to argument flattening pass not working. This modification is aim to solve this. commit 63f6a379b2632c5ae5d4393d44ddf31c1d734512 Author: Lin Ya Yu <yu810226@gmail.com> Date: Thu Nov 30 15:03:43 2017 +0000 Modify LoopIdiomRecognize.cpp to skip loop idiom optimization for kernel and functions called in the kernel This branch is aim to solve problem trigger in this example: https://gitenterprise.xilinx.com/linyay/triSYCL/commit/2a0dbdb485293c32d1ce380a68d35ea897269b06#diff-4beb17f5a3dbac38d7cb72c001c1b27d Since argument promotion can only be done with GEP instructions that only used by loads. And if there are llvm.memcpy instruction, there will always a bitcast instruction before to cast the pointer, so force kernel and functions called in the kernel in per_kernel_caller.ll to skip loop idiom opt pass. commit 6c9df37bd74b97f528866a22599d98cb837db140 Author: Lin Ya Yu <yu810226@gmail.com> Date: Mon Nov 13 11:50:32 2017 +0000 Add EnableLoopIdiom to PassManagerBuilder to control loop-idiom pass execution in PassManagerBuilder
- Loading branch information