summaryrefslogtreecommitdiff
path: root/libgomp
Commit message (Collapse)AuthorAgeFilesLines
* Add libgomp.oacc-c-c++-common/f-asyncwait-{1,2,3}.cvries2017-11-154-0/+430
| | | | | | | | | | | | | 2017-11-15 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.oacc-c-c++-common/f-asyncwait-1.c: New test, copied from asyncwait-1.f90. Rewrite into C. Rewrite from float to int. * testsuite/libgomp.oacc-c-c++-common/f-asyncwait-2.c: New test, copied from asyncwait-2.f90. Rewrite into C. Rewrite from float to int. * testsuite/libgomp.oacc-c-c++-common/f-asyncwait-3.c: New test, copied from asyncwait-3.f90. Rewrite into C. Rewrite from float to int. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254769 138bc75d-0d04-0410-961f-82ee72b054a4
* Allow asyncwait-1.c to run for non-nvidia devicesvries2017-11-142-2/+19
| | | | | | | | | 2017-11-14 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.oacc-c-c++-common/asyncwait-1.c: Allow to run for non-nvidia devices. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254723 138bc75d-0d04-0410-961f-82ee72b054a4
* PR c++/82835jakub2017-11-072-0/+39
| | | | | | | | | | * cp-gimplify.c (cxx_omp_clause_apply_fn): For methods pass i - 1 to convert_default_arg instead of i. * testsuite/libgomp.c++/pr82835.C: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254511 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix -Wreturn-type fallout.marxin2017-11-067-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2017-11-06 Martin Liska <mliska@suse.cz> * c-c++-common/cilk-plus/AN/pr57541-2.c (foo1): Return a value for functions with non-void return type, or change type to void, or add -Wno-return-type for test. (foo2): Likewise. * c-c++-common/cilk-plus/AN/pr57541.c (foo): Likewise. (foo1): Likewise. * c-c++-common/cilk-plus/CK/errors.c: Likewise. * c-c++-common/cilk-plus/CK/pr60197.c: Likewise. * c-c++-common/cilk-plus/CK/spawn_in_return.c: Likewise. * c-c++-common/fold-masked-cmp-1.c (test_pic): Likewise. (test_exe): Likewise. * c-c++-common/fold-masked-cmp-2.c (test_exe): Likewise. * g++.dg/cilk-plus/AN/builtin_fn_mutating_tplt.cc (my_func): Likewise. * g++.dg/cilk-plus/CK/pr68997.cc (fa2): Likewise. * g++.dg/eh/sighandle.C (dosegv): Likewise. * g++.dg/ext/vector14.C (foo): Likewise. (main): Likewise. * g++.dg/graphite/pr41305.C: Likewise. * g++.dg/graphite/pr42930.C: Likewise. * g++.dg/opt/pr46640.C (struct QBasicAtomicInt): Likewise. (makeDir): Likewise. * g++.dg/other/i386-8.C (foo): Likewise. * g++.dg/pr45788.C: Likewise. * g++.dg/pr64688.C (at_c): Likewise. * g++.dg/pr65032.C (G::DecodeVorbis): Likewise. * g++.dg/pr71633.C (c3::fn2): Likewise. * g++.dg/stackprotectexplicit2.C (A): Likewise. * g++.old-deja/g++.law/weak.C (main): Likewise. 2017-11-06 Martin Liska <mliska@suse.cz> * testsuite/libgomp.c++/loop-2.C: Return a value for functions with non-void return type, or change type to void, or add -Wno-return-type for test. * testsuite/libgomp.c++/loop-4.C: Likewise. * testsuite/libgomp.c++/parallel-1.C: Likewise. * testsuite/libgomp.c++/shared-1.C: Likewise. * testsuite/libgomp.c++/single-1.C: Likewise. * testsuite/libgomp.c++/single-2.C: Likewise. 2017-11-06 Martin Liska <mliska@suse.cz> * testsuite/27_io/basic_fstream/cons/char/path.cc (main): Return a value for functions with non-void return type, or change type to void, or add -Wno-return-type for test. * testsuite/27_io/basic_ifstream/cons/char/path.cc (main): Likewise. * testsuite/27_io/basic_ofstream/open/char/path.cc (main): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254451 138bc75d-0d04-0410-961f-82ee72b054a4
* Remove semicolon after do {} while (false) in HSA_LOGvries2017-10-312-3/+10
| | | | | | | | | | | 2017-10-31 Tom de Vries <tom@codesourcery.com> * plugin/plugin-hsa.c (HSA_LOG): Remove semicolon after "do {} while (false)". (init_single_kernel, GOMP_OFFLOAD_async_run): Add missing semicolon after HSA_DEBUG call. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254264 138bc75d-0d04-0410-961f-82ee72b054a4
* * target.c (struct gomp_coalesce_buf): New type.jakub2017-10-282-34/+207
| | | | | | | | | | | | | | | | | (MAX_COALESCE_BUF_SIZE, MAX_COALESCE_BUF_GAP): Define. (gomp_coalesce_buf_add, gomp_to_device_kind_p): New functions. (gomp_copy_host2dev): Add CBUF argument, if copying into the cached ranges, memcpy into buffer instead of copying into device. (gomp_map_vars_existing, gomp_map_pointer, gomp_map_fields_existing): Add CBUF argument, pass it through to other calls. (gomp_map_vars): Aggregate copies from host to device if small enough and with small enough gaps in between into memcpy into a buffer and fewer host to device copies from the buffer. (gomp_update): Adjust gomp_copy_host2dev caller. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254194 138bc75d-0d04-0410-961f-82ee72b054a4
* Restore "dg-do run" directives for libgomp.oacc-fortran/declare-*.f90tschwinge2017-10-176-0/+17
| | | | | | | | | | | | libgomp/ * testsuite/libgomp.oacc-fortran/declare-1.f90: Restore "dg-do run" directive. * testsuite/libgomp.oacc-fortran/declare-2.f90: Likewise. * testsuite/libgomp.oacc-fortran/declare-3.f90: Likewise. * testsuite/libgomp.oacc-fortran/declare-4.f90: Likewise. * testsuite/libgomp.oacc-fortran/declare-5.f90: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253808 138bc75d-0d04-0410-961f-82ee72b054a4
* Enable libgomp.oacc-*/declare-*.{c,f90} for non-nvidia devicesvries2017-10-1610-15/+17
| | | | | | | | | | | | | | | | | | 2017-10-16 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.oacc-c-c++-common/declare-1.c: Don't require openacc_nvidia_accel_selected. * testsuite/libgomp.oacc-c-c++-common/declare-2.c: Same. * testsuite/libgomp.oacc-c-c++-common/declare-4.c: Same. * testsuite/libgomp.oacc-fortran/declare-2.f90: Same. * testsuite/libgomp.oacc-fortran/declare-4.f90: Same * testsuite/libgomp.oacc-fortran/declare-5.f90: Same. * testsuite/libgomp.oacc-c-c++-common/declare-5.c: Don't require openacc_nvidia_accel_selected. Skip for shared memory device. * testsuite/libgomp.oacc-fortran/declare-1.f90: Same. * testsuite/libgomp.oacc-fortran/declare-3.f90: Same. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253779 138bc75d-0d04-0410-961f-82ee72b054a4
* [PR 82416] Do not extend operands to at least 32 bitsjamborm2017-10-092-0/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2017-10-09 Martin Jambor <mjambor@suse.cz> PR hsa/82416 gcc/ * hsa-common.h (hsa_op_with_type): New method extend_int_to_32bit. * hsa-gen.c (hsa_extend_inttype_to_32bit): New function. (hsa_type_for_scalar_tree_type): Use it. Always force min32int for COMPLEX types. (hsa_fixup_mov_insn_type): New function. (hsa_op_with_type::get_in_type): Use it. (hsa_build_append_simple_mov): Likewise. Allow sub-32bit immediates in an assert. (hsa_op_with_type::extend_int_to_32bit): New method. (gen_hsa_insns_for_bitfield): Fixup instruction and intermediary types. Convert to dest type if necessary. (gen_hsa_insns_for_bitfield_load): Fixup load type if necessary. (reg_for_gimple_ssa): Pass false as min32int to hsa_type_for_scalar_tree_type. (gen_hsa_addr): Fixup type when creating addresable temporary. (gen_hsa_cmp_insn_from_gimple): Extend operands if necessary. (gen_hsa_unary_operation): Extend operands and convert to dest type if necessary. Call hsa_fixup_mov_insn_type. (gen_hsa_binary_operation): Changed operand types to hsa_op_with_type, extend operands and convert to dest type if necessary. (gen_hsa_insns_for_operation_assignment): Extend operands and convert to dest type if necessary. (set_output_in_type): Call hsa_fixup_mov_insn_type. Just ude dest if conversion nt necessary and size matches. (gen_hsa_insns_for_load): Call hsa_fixup_mov_insn_type, convert to dest type if necessary. (gen_hsa_insns_for_store): Call hsa_fixup_mov_insn_type. (gen_hsa_insns_for_switch_stmt): Likewise. Also extend operands if necessary. (gen_hsa_clrsb): Likewise. (gen_hsa_ffs): Likewise. (gen_hsa_divmod): Extend operands and convert to dest type if necessary. (gen_hsa_atomic_for_builtin): Change type of op to hsa_op_with_type. libgomp/ * testsuite/libgomp.hsa.c/pr82416.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253538 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix libgomp.oacc-fortran/{firstprivate-1,parallel-reduction}.f90 for ↵vries2017-10-073-3/+10
| | | | | | | | | | | | | non-nvidia devices 2017-10-07 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.oacc-fortran/firstprivate-1.f90 (firstprivate): Remove acc_device_nvidia references. * testsuite/libgomp.oacc-fortran/parallel-reduction.f90 (reduction): Same. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253507 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix libgomp.oacc-c-c++-common/{loop-red-g-1,routine-g-1}.c for non-nvidia ↵vries2017-10-053-2/+8
| | | | | | | | | | | | devices 2017-10-05 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.oacc-c-c++-common/loop-red-g-1.c (main): Remove vector_length(32) clause from acc parallel directive. * testsuite/libgomp.oacc-c-c++-common/routine-g-1.c (main): Same. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253439 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix openacc float reduction testcasesvries2017-10-044-3/+20
| | | | | | | | | | | | | | 2017-10-04 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.oacc-c-c++-common/par-loop-comb-reduction-3.c (main): Reduce sum of arr elements. Assert that hres is exactly representable in 32-bit floating point. * testsuite/libgomp.oacc-c-c++-common/par-loop-comb-reduction-4.c (main): Reduce sum of arr elements. Assert that hres and hmres are exactly representable in 32-bit floating point. * testsuite/libgomp.oacc-c-c++-common/reduction-7.c (gwv_np_4): Same. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253398 138bc75d-0d04-0410-961f-82ee72b054a4
* Remove superfluous -fopenmp from libgomp testcasesvries2017-09-2827-27/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Thomas Schwinge <thomas@codesourcery.com> 2017-09-28 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.c++/for-12.C: Remove superfluous -fopenmp option setting. * testsuite/libgomp.c++/pr69393.C: Same. * testsuite/libgomp.c++/taskloop-1.C: Same. * testsuite/libgomp.c++/taskloop-3.C: Same. * testsuite/libgomp.c++/taskloop-4.C: Same. * testsuite/libgomp.c/for-4.c: Same. * testsuite/libgomp.c/pr66199-3.c: Same. * testsuite/libgomp.c/pr66199-4.c: Same. * testsuite/libgomp.c/pr66199-6.c: Same. * testsuite/libgomp.c/taskloop-1.c: Same. * testsuite/libgomp.c/taskloop-3.c: Same. * testsuite/libgomp.c/taskloop-4.c: Same. * testsuite/libgomp.fortran/aligned1.f03: Same. * testsuite/libgomp.fortran/condinc1.f: Same. * testsuite/libgomp.fortran/condinc3.f90: Same. * testsuite/libgomp.fortran/crayptr1.f90: Same. * testsuite/libgomp.fortran/crayptr2.f90: Same. * testsuite/libgomp.fortran/crayptr3.f90: Same. * testsuite/libgomp.fortran/omp_cond1.f: Same. * testsuite/libgomp.fortran/omp_cond3.F90: Same. * testsuite/libgomp.fortran/pr66199-1.f90: Same. * testsuite/libgomp.fortran/pr66199-2.f90: Same. * testsuite/libgomp.fortran/recursion1.f90: Same. * testsuite/libgomp.fortran/target2.f90: Same. * testsuite/libgomp.fortran/target5.f90: Same. * testsuite/libgomp.fortran/task3.f90: Same. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253250 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix libgomp.oacc-c-c++-common/loop-g-{1,2}.c for non-nvidia devicesvries2017-09-283-2/+8
| | | | | | | | | | 2017-09-28 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.oacc-c-c++-common/loop-g-1.c (main): Remove vector_length(32) clause from acc parallel directive. * testsuite/libgomp.oacc-c-c++-common/loop-g-2.c (main): Same. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253249 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix libgomp.oacc-c-c++-common/parallel-reduction.c for non-nvidia devicesvries2017-09-272-2/+7
| | | | | | | | | 2017-09-27 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.oacc-c-c++-common/parallel-reduction.c (main): Remove acc_device_nvidia references. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253228 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix condition folding in c_parser_omp_for_loopvries2017-09-162-0/+51
| | | | | | | | | | | | 2017-09-16 Tom de Vries <tom@codesourcery.com> PR c/81875 * c-parser.c (c_parser_omp_for_loop): Fold only operands of cond, not cond itself. * testsuite/libgomp.c-c++-common/pr81875.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@252873 138bc75d-0d04-0410-961f-82ee72b054a4
* Introduce libgomp/testsuite/libgomp.c-c++-commonvries2017-09-145-6/+24
| | | | | | | | | | | | | | 2017-09-14 Tom de Vries <tom@codesourcery.com> * testsuite/libgomp.c++/cancel-taskgroup-1.C: Remove. * testsuite/libgomp.c/cancel-taskgroup-1.c: Move to ... * testsuite/libgomp.c-c++-common/cancel-taskgroup-1.c: ... here. * testsuite/libgomp.c/c.exp: Include test-cases from libgomp.c-c++-common. * testsuite/libgomp.c++/c++.exp: Same. Force c++-mode compilation of .c files. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@252775 138bc75d-0d04-0410-961f-82ee72b054a4
* PR c++/81314jakub2017-09-142-0/+43
| | | | | | | | | | * cp-gimplify.c (omp_var_to_track): Look through references. (omp_cxx_notice_variable): Likewise. * testsuite/libgomp.c++/pr81314.C: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@252770 138bc75d-0d04-0410-961f-82ee72b054a4
* * libgomp.texi (Top): www.openacc.org now uses https.gerald2017-09-082-40/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (Enabling OpenACC): Ditto. (acc_get_num_devices): Ditto. (acc_set_device_type): Ditto. (acc_get_device_type): Ditto. (acc_set_device_num): Ditto. (acc_get_device_num): Ditto. (acc_async_test): Ditto. (acc_async_test_all): Ditto. (acc_wait): Ditto. (acc_wait_all): Ditto. (acc_wait_all_async): Ditto. (acc_wait_async): Ditto. (acc_init): Ditto. (acc_shutdown): Ditto. (acc_on_device): Ditto. (acc_malloc): Ditto. (acc_free): Ditto. (acc_copyin): Ditto. (acc_present_or_copyin): Ditto. (acc_create): Ditto. (acc_present_or_create): Ditto. (acc_copyout): Ditto. (acc_delete): Ditto. (acc_update_device): Ditto. (acc_update_self): Ditto. (acc_map_data): Ditto. (acc_unmap_data): Ditto. (acc_deviceptr): Ditto. (acc_hostptr): Ditto. (acc_is_present): Ditto. (acc_memcpy_to_device): Ditto. (acc_memcpy_from_device): Ditto. (acc_get_current_cuda_device): Ditto. (acc_get_current_cuda_context): Ditto. (acc_get_cuda_stream): Ditto. (acc_set_cuda_stream): Ditto. (ACC_DEVICE_TYPE): Ditto. (ACC_DEVICE_NUM): Ditto. (OpenACC Library Interoperability): Ditto. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@251888 138bc75d-0d04-0410-961f-82ee72b054a4
* PR c/81687jakub2017-08-103-0/+56
| | | | | | | | | | | | | | | * omp-low.c (omp_copy_decl): Don't remap FORCED_LABEL or DECL_NONLOCAL LABEL_DECLs. * tree-cfg.c (move_stmt_op): Don't adjust DECL_CONTEXT of FORCED_LABEL or DECL_NONLOCAL labels. (move_stmt_r) <case GIMPLE_LABEL>: Adjust DECL_CONTEXT of FORCED_LABEL or DECL_NONLOCAL labels here. * testsuite/libgomp.c/pr81687-1.c: New test. * testsuite/libgomp.c/pr81687-2.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@251019 138bc75d-0d04-0410-961f-82ee72b054a4
* PR c/69389jakub2017-08-073-0/+133
| | | | | | | | | | | | | * gimplify.c (goa_stabilize_expr): Handle BIT_INSERT_EXPR and BIT_FIELD_REF. * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields. * testsuite/libgomp.c/pr69389.c: New test. * testsuite/libgomp.c++/pr69389.C: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@250929 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix diff_type in expand_oacc_for char iter_typevries2017-08-073-1/+51
| | | | | | | | | | | | 2017-08-07 Tom de Vries <tom@codesourcery.com> PR middle-end/78266 * omp-expand.c (expand_oacc_for): Ensure diff_type is large enough. * testsuite/libgomp.oacc-c-c++-common/vprop-2.c: New test. * testsuite/libgomp.oacc-c-c++-common/vprop.c: Remove xfail. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@250925 138bc75d-0d04-0410-961f-82ee72b054a4
* PR c/45784jakub2017-07-273-0/+52
| | | | | | | | | | | | * c-omp.c (c_finish_omp_for): If the condition is wrapped in rhs of COMPOUND_EXPR(s), skip them and readd their lhs into new COMPOUND_EXPRs around the rhs of the comparison. * testsuite/libgomp.c/pr45784.c: New test. * testsuite/libgomp.c++/pr45784.C: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@250635 138bc75d-0d04-0410-961f-82ee72b054a4
* Add v2di support for nvptxvries2017-07-192-0/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2017-07-19 Tom de Vries <tom@codesourcery.com> * config/nvptx/nvptx-modes.def: Add V2DImode. * config/nvptx/nvptx-protos.h (nvptx_data_alignment): Declare. * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Handle V2DImode. (nvptx_output_mov_insn): Handle lack of mov.b128. (nvptx_print_operand): Handle 'H' and 'L' codes. (nvptx_vector_mode_supported): Allow V2DImode. (nvptx_preferred_simd_mode): New function. (nvptx_data_alignment): New function. (TARGET_VECTORIZE_PREFERRED_SIMD_MODE): Redefine to nvptx_preferred_simd_mode. * config/nvptx/nvptx.h (STACK_BOUNDARY, BIGGEST_ALIGNMENT): Change from 64 to 128 bits. (DATA_ALIGNMENT): Define. Set to nvptx_data_alignment. * config/nvptx/nvptx.md (VECIM): Add V2DI. * gcc.target/nvptx/decl-init.c: Update alignment. * gcc.target/nvptx/slp-2-run.c: New test. * gcc.target/nvptx/slp-2.c: New test. * gcc.target/nvptx/v2di.c: New test. * testsuite/libgomp.oacc-c/vec.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@250341 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix secure_getenv.h include in plugin-hsa.cvries2017-07-032-1/+5
| | | | | | | | 2017-07-03 Tom de Vries <tom@codesourcery.com> * plugin/plugin-hsa.c: Fix secure_getenv.h include. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@249918 138bc75d-0d04-0410-961f-82ee72b054a4
* Show value of GOMP_OPENACC_DIM in libgomp nvptx pluginvries2017-06-272-1/+16
| | | | | | | | | 2017-06-27 Tom de Vries <tom@codesourcery.com> * plugin/plugin-nvptx.c (notify_var): New function. (nvptx_exec): Use notify_var for GOMP_OPENACC_DIM. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@249695 138bc75d-0d04-0410-961f-82ee72b054a4
* Use secure_getenv for GOMP_DEBUGvries2017-06-275-33/+124
| | | | | | | | | | | | | | | | 2017-06-27 Tom de Vries <tom@codesourcery.com> * env.c (parse_unsigned_long_1): Factor out of ... (parse_unsigned_long): ... here. (parse_int_1): Factor out of ... (parse_int): ... here. (parse_int_secure): New function. (initialize_env): Use parse_int_secure for GOMP_DEBUG. * secure_getenv.h: Factor out of ... * plugin/plugin-hsa.c: ... here. * testsuite/libgomp.oacc-c-c++-common/gomp-debug-env.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@249694 138bc75d-0d04-0410-961f-82ee72b054a4
* PR c++/81130jakub2017-06-212-0/+46
| | | | | | | | | | * gimplify.c (omp_add_variable): Don't force GOVD_SEEN for types with ctors/dtors if GOVD_SHARED is set. * testsuite/libgomp.c++/pr81130.C: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@249445 138bc75d-0d04-0410-961f-82ee72b054a4
* Get rid of dg-skip-if etc. default argsro2017-06-173-2/+9
| | | | | | | | | | | | | | | | | libstdc++-v3: * testsuite: Remove dg-skip-if, dg-xfail-if, dg-xfail-run-if default args. libgomp: * testsuite/libgomp.fortran/strassen.f90: Remove dg-skip-if default args. * testsuite/libgomp.oacc-c-c++-common/vprop.c: Remove dg-xfail-run-if default args. gcc/testsuite: Remove dg-skip-if, dg-xfail-if, dg-xfail-run-if default args. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@249339 138bc75d-0d04-0410-961f-82ee72b054a4
* gcc:edlinger2017-06-023-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de> * doc/invoke.texi: Document the -Wsizeof-pointer-div warning. gcc/c-family: 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de> * c.opt (Wsizeof-pointer-div): New warning option. gcc/c: 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de> * c-parser.c (c_parser_binary_expression): Implement the -Wsizeof_pointer_div warning. (c_parser_postfix_expression): Allow SIZEOF_EXPR as expr.original_code from a parenthesized expression. (c_parser_expr_list): Use c_last_sizeof_loc. * c-tree.h (c_last_sizeof_loc): New external. * c-typeck.c (c_last_sizeof_loc): New variable. (c_expr_sizeof_expr, c_expr_sizeof_type): Assign c_last_sizeof_loc. gcc/cp: 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de> * typeck.c (cp_build_binary_op): Implement the -Wsizeof_pointer_div warning. gcc/testsuite: 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de> * c-c++-common/Wsizeof-pointer-div.c: New test. * gcc.dg/Wsizeof-pointer-memaccess1.c: Add test cases with parens. * gcc.dg/torture/Wsizeof-pointer-memaccess1.c: Likewise. * gcc.target/i386/sse-init-v4hi-1.c: Fix test case. * gcc.target/i386/sse-init-v4sf-1.c: Likewise. * gcc.target/i386/sse-set-ps-1.c: Likewise. * gcc.target/i386/sse2-init-v16qi-1.c: Likewise. * gcc.target/i386/sse2-init-v2di-1.c: Likewise. * gcc.target/i386/sse2-init-v4si-1.c: Likewise. * gcc.target/i386/sse2-init-v8hi-1.c: Likewise. * gcc.target/i386/sse2-set-epi32-1.c: Likewise. * gcc.target/i386/sse2-set-epi64x-1.c: Likewise. * gcc.target/i386/sse4_1-init-v16qi-1.c: Likewise. * gcc.target/i386/sse4_1-init-v2di-1.c: Likewise. * gcc.target/i386/sse4_1-init-v4sf-1.c: Likewise. * gcc.target/i386/sse4_1-init-v4si-1.c: Likewise. * gcc.target/i386/sse4_1-set-epi32-1.c: Likewise. * gcc.target/i386/sse4_1-set-epi64x-1.c: Likewise. * gcc.target/i386/sse4_1-set-ps-1.c: Likewise. * libgomp.c/pr39591-2.c: Likewise. * libgomp.c/pr39591-3.c: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248811 138bc75d-0d04-0410-961f-82ee72b054a4
* PR libgomp/80822jakub2017-05-302-83/+98
| | | | | | | | | | * config/linux/affinity.c (gomp_affinity_init_level_1): New function. (gomp_affinity_init_level): Use it. Always analyze the core and thread sibling lists, depending on level just pick up what CPUs to put together into a place vs. whether add multiple ordered places. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248683 138bc75d-0d04-0410-961f-82ee72b054a4
* OpenACC 1.0 compatibility: acc_async_wait, acc_async_wait_alltschwinge2017-05-2410-7/+188
| | | | | | | | | | | | | | | | | libgomp/ * openacc.h (acc_async_wait, acc_async_wait_all): New prototypes. * libgomp.map (OACC_2.0.1): Add these. * oacc-async.c (acc_async_wait, acc_async_wait_all): New aliases for "acc_wait", and "acc_wait_all", respectively. * openacc.f90 (acc_async_wait, acc_async_wait_all): New interfaces for "acc_wait", and "acc_wait_all", respectively. * openacc_lib.h (acc_async_wait, acc_async_wait_all): Likewise. * libgomp.texi (acc_wait, acc_wait_all): Update. * testsuite/libgomp.oacc-c-c++-common/par-reduction-2.c: Update. * testsuite/libgomp.oacc-fortran/par-reduction-2-1.f: New file. * testsuite/libgomp.oacc-fortran/par-reduction-2-2.f: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248413 138bc75d-0d04-0410-961f-82ee72b054a4
* Fortran OpenACC "openacc_lib.h": acc_pcopyin, acc_pcreatetschwinge2017-05-244-69/+42
| | | | | | | | | | | | libgomp/ * openacc_lib.h (acc_pcopyin, acc_pcreate): Route to acc_present_or_copyin and acc_present_or_create procedures, respectively. * testsuite/libgomp.oacc-fortran/lib-32-1.f: Exercise these, and generally different variants of OpenACC Runtime Library functions. * testsuite/libgomp.oacc-fortran/lib-32-2.f: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248412 138bc75d-0d04-0410-961f-82ee72b054a4
* Translate libgomp.oacc-c-c++-common/lib-32.c into Fortrantschwinge2017-05-244-0/+356
| | | | | | | | libgomp/ * testsuite/libgomp.oacc-fortran/lib-32-1.f: New file. * testsuite/libgomp.oacc-fortran/lib-32-2.f: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248411 138bc75d-0d04-0410-961f-82ee72b054a4
* C/C++ OpenACC: acc_pcopyin, acc_pcreatetschwinge2017-05-247-87/+272
| | | | | | | | | | | | | | | | | | | libgomp/ * openacc.h (acc_pcopyin, acc_pcreate): Provide prototypes instead of preprocessor definitions. * libgomp.h (strong_alias): Guard by "#ifdef HAVE_ATTRIBUTE_ALIAS". * oacc-mem.c: Provide "acc_pcreate" as alias for "acc_present_or_create", and "acc_pcopyin" as alias for "acc_present_or_copyin". * libgomp.map: New version "OACC_2.0.1". (OACC_2.0.1): Add "acc_pcopyin", and "acc_pcreate". * testsuite/libgomp.oacc-c-c++-common/lib-38.c: Remove, merging its content into... * testsuite/libgomp.oacc-c-c++-common/lib-32.c: ... this file. Extend testing. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248410 138bc75d-0d04-0410-961f-82ee72b054a4
* libgomp nvptx plugin: Debugging output when disabling nvptx offloadingtschwinge2017-05-242-2/+15
| | | | | | | | libgomp/ * plugin/plugin-nvptx.c (nvptx_get_num_devices): Debugging output when disabling nvptx offloading. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248400 138bc75d-0d04-0410-961f-82ee72b054a4
* OpenACC 2.5 kernels construct: num_gangs, num_workers, vector_length clausestschwinge2017-05-234-6/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gcc/c/ * c-parser.c (OACC_KERNELS_CLAUSE_MASK): Add "PRAGMA_OACC_CLAUSE_NUM_GANGS", "PRAGMA_OACC_CLAUSE_NUM_WORKERS", "VECTOR_LENGTH". gcc/cp/ * parser.c (OACC_KERNELS_CLAUSE_MASK): Add "PRAGMA_OACC_CLAUSE_NUM_GANGS", "PRAGMA_OACC_CLAUSE_NUM_WORKERS", "VECTOR_LENGTH". gcc/fortran/ * openmp.c (OACC_KERNELS_CLAUSES): Add "OMP_CLAUSE_NUM_GANGS", "OMP_CLAUSE_NUM_WORKERS", "OMP_CLAUSE_VECTOR_LENGTH". gcc/ * omp-offload.c (execute_oacc_device_lower): Remove the parallelism dimensions function attributes for unparallelized OpenACC kernels constructs. gcc/testsuite/ * c-c++-common/goacc/parallel-dims-1.c: Update. * c-c++-common/goacc/parallel-dims-2.c: Likewise. * c-c++-common/goacc/routine-1.c: Likewise. * c-c++-common/goacc/uninit-dim-clause.c: Likewise. * g++.dg/goacc/template.C: Likewise. * gfortran.dg/goacc/kernels-tree.f95: Likewise. * gfortran.dg/goacc/routine-3.f90: Likewise. * gfortran.dg/goacc/sie.f95: Likewise. * gfortran.dg/goacc/uninit-dim-clause.f95: Likewise. libgomp/ * testsuite/libgomp.oacc-c-c++-common/kernels-loop-2.c: Update. * testsuite/libgomp.oacc-c-c++-common/parallel-dims.c: Likewise. * testsuite/libgomp.oacc-fortran/kernels-loop-2.f95: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248370 138bc75d-0d04-0410-961f-82ee72b054a4
* Runtime checking of OpenACC parallelism dimensions clausestschwinge2017-05-235-12/+548
| | | | | | | | | | | | | | libgomp/ * testsuite/libgomp.oacc-c-c++-common/parallel-dims.c: Rewrite. * testsuite/lib/libgomp.exp (check_effective_target_openacc_nvidia_accel_configured): New proc. * testsuite/libgomp.oacc-c++/c++.exp (check_effective_target_c) (check_effective_target_c++): New procs. * testsuite/libgomp.oacc-c/c.exp (check_effective_target_c) (check_effective_target_c++): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248358 138bc75d-0d04-0410-961f-82ee72b054a4
* PR middle-end/80809jakub2017-05-223-0/+81
| | | | | | | | | | | | | * omp-low.c (finish_taskreg_remap): New function. (finish_taskreg_scan): If unit size of ctx->record_type is non-constant, unshare the size expression and replace decls in it with possible outer var refs. * testsuite/libgomp.c/pr80809-2.c: New test. * testsuite/libgomp.c/pr80809-3.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248346 138bc75d-0d04-0410-961f-82ee72b054a4
* PR middle-end/80809jakub2017-05-222-0/+32
| | | | | | | | | | | | * gimplify.c (omp_add_variable): For GOVD_DEBUG_PRIVATE use GOVD_SHARED rather than GOVD_PRIVATE with it. (gimplify_adjust_omp_clauses_1, gimplify_adjust_omp_clauses): Expect GOVD_SHARED rather than GOVD_PRIVATE with GOVD_DEBUG_PRIVATE. * testsuite/libgomp.c/pr80809-1.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248345 138bc75d-0d04-0410-961f-82ee72b054a4
* PR middle-end/80853jakub2017-05-222-0/+34
| | | | | | | | | | | * omp-low.c (lower_reduction_clauses): Pass OMP_CLAUSE_PRIVATE as last argument to build_outer_var_ref for pointer bases of array section reductions. * testsuite/libgomp.c/pr80853.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248344 138bc75d-0d04-0410-961f-82ee72b054a4
* OpenACC 2.5 default (present) clausetschwinge2017-05-196-12/+125
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gcc/c/ * c-parser.c (c_parser_omp_clause_default): Handle "OMP_CLAUSE_DEFAULT_PRESENT". gcc/cp/ * parser.c (cp_parser_omp_clause_default): Handle "OMP_CLAUSE_DEFAULT_PRESENT". gcc/fortran/ * gfortran.h (enum gfc_omp_default_sharing): Add "OMP_DEFAULT_PRESENT". * dump-parse-tree.c (show_omp_clauses): Handle it. * openmp.c (gfc_match_omp_clauses): Likewise. * trans-openmp.c (gfc_trans_omp_clauses): Likewise. gcc/ * tree-core.h (enum omp_clause_default_kind): Add "OMP_CLAUSE_DEFAULT_PRESENT". * tree-pretty-print.c (dump_omp_clause): Handle it. * gimplify.c (enum gimplify_omp_var_data): Add "GOVD_MAP_FORCE_PRESENT". (gimplify_adjust_omp_clauses_1): Map it to "GOMP_MAP_FORCE_PRESENT". (oacc_default_clause): Handle "OMP_CLAUSE_DEFAULT_PRESENT". gcc/testsuite/ * c-c++-common/goacc/default-1.c: Update. * c-c++-common/goacc/default-2.c: Likewise. * c-c++-common/goacc/default-4.c: Likewise. * gfortran.dg/goacc/default-1.f95: Likewise. * gfortran.dg/goacc/default-4.f: Likewise. * c-c++-common/goacc/default-5.c: New file. * gfortran.dg/goacc/default-5.f: Likewise. libgomp/ * testsuite/libgomp.oacc-c++/template-reduction.C: Update. * testsuite/libgomp.oacc-c-c++-common/nested-2.c: Update. * testsuite/libgomp.oacc-fortran/data-4-2.f90: Likewise. * testsuite/libgomp.oacc-fortran/default-1.f90: Likewise. * testsuite/libgomp.oacc-fortran/non-scalar-data.f90: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248280 138bc75d-0d04-0410-961f-82ee72b054a4
* libgomp hsa plugin: debug output for HSA runtime library loading failuretschwinge2017-05-192-2/+11
| | | | | | | | libgomp/ * plugin/plugin-hsa.c (DLSYM_FN, init_hsa_runtime_functions): Debug output for failure. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@248277 138bc75d-0d04-0410-961f-82ee72b054a4
* Load new scanlang.expro2017-05-122-0/+5
| | | | | | | | | | | | | libitm: * testsuite/lib/libitm.exp: Load scanlang.exp. libgomp: * testsuite/lib/libgomp.exp: Load scanlang.exp. libatomic: * testsuite/lib/libatomic.exp: Load scanlang.exp. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@247959 138bc75d-0d04-0410-961f-82ee72b054a4
* PR bootstrap/80531jakub2017-04-272-0/+8
| | | | | | | | * configure.tgt (*-*-aix*): Add -frandom-seed=$@ to XCFLAGS to avoid bootstrap compare failures. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@247350 138bc75d-0d04-0410-961f-82ee72b054a4
* omp-low: fix lastprivate/linear lowering for SIMTamonakov2017-04-202-0/+22
| | | | | | | | | | | | gcc/ * omp-low.c (lower_lastprivate_clauses): Correct handling of linear and lastprivate clauses in SIMT case. libgomp/ * testsuite/libgomp.c/target-36.c: New testcase. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@247029 138bc75d-0d04-0410-961f-82ee72b054a4
* * plugin/plugin-nvptx.c (cuda_lib_inited): Use signed char typejakub2017-04-132-1/+6
| | | | | | | instead of char. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@246918 138bc75d-0d04-0410-961f-82ee72b054a4
* PR libgomp/80394jakub2017-04-112-0/+27
| | | | | | | | | | * omp-low.c (scan_omp_task): Don't optimize away empty tasks if they have any depend clauses. * testsuite/libgomp.c/pr80394.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@246849 138bc75d-0d04-0410-961f-82ee72b054a4
* PR libgomp/79876jakub2017-04-045-2/+98
| | | | | | | | | | | | | * config/posix/thread-stacksize.h: New file. * config/darwin/thread-stacksize.h: New file. * config/nvptx/thread-stacksize.h: New file. * env.c: Include thread-stacksize.h. (initialize_env): Initialize stacksize to GOMP_DEFAULT_STACKSIZE instead of 0. Call pthread_attr_setstacksize even if GOMP_DEFAULT_STACKSIZE is non-zero. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@246675 138bc75d-0d04-0410-961f-82ee72b054a4
* * env.c (initialize_env): Initialize stacksize to 0.jakub2017-03-302-1/+5
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@246598 138bc75d-0d04-0410-961f-82ee72b054a4