source
stringlengths
3
92
c
stringlengths
26
2.25M
GB_unop__identity_fc64_int32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-Li...
elemwise_binary_scalar_op.h
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you ...
draw.c
#include "image.h" #include <assert.h> #include <stdlib.h> void heman_draw_points(heman_image* target, heman_points* pts, HEMAN_FLOAT val) { HEMAN_FLOAT* src = pts->data; for (int k = 0; k < pts->width; k++) { HEMAN_FLOAT x = src[0]; HEMAN_FLOAT y = src[1]; src += pts->nbands; i...
matrix_multiplication2.c
/****************************************************************************** * FILE: omp_mm.c * DESCRIPTION: * OpenMp Example - Matrix Multiply - C Version * Demonstrates a matrix multiply using OpenMP. Threads share row iterations * according to an auto chunk size. ******************************************...
GB_unaryop__lnot_uint32_uint32.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
declare-variant-14.c
/* { dg-do compile { target vect_simd_clones } } */ /* { dg-additional-options "-fdump-tree-gimple -fdump-tree-optimized" } */ /* { dg-additional-options "-mno-sse3" { target { i?86-*-* x86_64-*-* } } } */ int f01 (int); int f02 (int); int f03 (int); #pragma omp declare variant (f01) match (device={isa("avx512f")}) /*...
GB_unaryop__lnot_uint32_fp64.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
Vector.h
/* Copyright (c) 2016-2019 Liav Turkia See LICENSE.md for full copyright information */ #pragma once #ifndef MACE__UTILITY_VECTOR_H #define MACE__UTILITY_VECTOR_H #include <MACE/Core/Constants.h> #include <MACE/Core/Error.h> #include <MACE/Utility/Math.h> #include <array> #include <string> #include <ostream> #include...
GB_unaryop__lnot_uint8_int64.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http...
lock.c
// RUN: %libomp-compile-and-run | FileCheck %s // REQUIRES: ompt #include "callback.h" #include <omp.h> int main() { //need to use an OpenMP construct so that OMPT will be initalized #pragma omp parallel num_threads(1) print_ids(0); omp_lock_t lock; printf("%" PRIu64 ": &lock: %" PRIu64 "\n", ompt_get_thr...
GB_unop__identity_int64_int32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-Li...
draw.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
kernels.h
#ifndef _CUBIC_BSPLINE_PREFILTER_KERNEL_H_ #define _CUBIC_BSPLINE_PREFILTER_KERNEL_H_ // The code below is based on the work of Philippe Thevenaz. // See <http://bigwww.epfl.ch/thevenaz/interpolation/> #define POLE (sqrtf(3.0f)-2.0f) //pole for cubic b-spline typedef unsigned int uint; typedef unsigned char uchar;...
jacobi.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> int main() { int INTERLINES = 50; int TERM_ITERATION = 3; /* double ***Matrix = NULL; */ /* double *M = NULL; */ int N = (INTERLINES * 8) + 9 - 1; double h = 1.0/N; int stat_iteration = 0; double stat_precision = 0.0; doub...
GB_unop__ainv_int16_int16.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-Li...
GB_cast_array.c
//------------------------------------------------------------------------------ // GB_cast_array: typecast or copy an array //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-License-Identifier: Apach...
rii.h
#ifndef RII_H #define RII_H #include <iostream> #include <cassert> #include "pqkmeans.h" #include "./distance.h" // For py::array_t // See http://pybind11.readthedocs.io/en/master/advanced/pycpp/numpy.html#direct-access #include <pybind11/pybind11.h> #include <pybind11/numpy.h> namespace py = pybind11; namespace ri...
omp_workshare1.c
/****************************************************************************** * FILE: omp_workshare1.c * DESCRIPTION: * OpenMP Example - Loop Work-sharing - C/C++ Version * In this example, the iterations of a loop are scheduled dynamically * across the team of threads. A thread will perform CHUNK iterations *...
broadcast_reduce-inl.h
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you ...
FasterGossipCommMulti.h
/* Copyright 2020 NVIDIA Corporation. All rights reserved. * * Please refer to the NVIDIA end user license agreement (EULA) associated * with this source code for terms and conditions that govern your use of * this software. Any use, reproduction, disclosure, or distribution of * this software and related documen...
Q2_Solution_Incremental_Per_Comment.h
#pragma once #include <queue> #include <algorithm> #include <cassert> #include <numeric> #include <memory> #include <set> #include "utils.h" #include "load.h" #include "Q2_Solution_Batch.h" class Q2_Solution_Incremental_Per_Comment : public Q2_Solution_Batch { std::vector<score_type> last_result; std::optiona...
target_data_array_extension.c
// -------------------------------------------------- // Check extends before // -------------------------------------------------- // RUN: %libomptarget-compile-generic \ // RUN: -fopenmp-version=51 -DEXTENDS=BEFORE // RUN: %libomptarget-run-fail-generic 2>&1 \ // RUN: | %fcheck-generic // ------------------------...
NewTimer.h
////////////////////////////////////////////////////////////////////////////////////// // This file is distributed under the University of Illinois/NCSA Open Source License. // See LICENSE file in top directory for details. // // Copyright (c) 2016 Jeongnim Kim and QMCPACK developers. // // File developed by: Ken Esler...
taskloop_misc_messages.c
// RUN: %clang_cc1 -fsyntax-only -fopenmp -triple x86_64-unknown-unknown -verify %s -Wuninitialized // RUN: %clang_cc1 -fsyntax-only -fopenmp-simd -triple x86_64-unknown-unknown -verify %s -Wuninitialized // expected-error@+1 {{unexpected OpenMP directive '#pragma omp taskloop'}} #pragma omp taskloop // expected-err...
matmul_cpu_omp_kernel.c
#include <homp.h> #include "matmul.h" #ifdef USE_INTEL_MKL #include <mkl.h> #endif void matmul_cpu_omp_wrapper(omp_offloading_t *off, long i, long j,long k,float *A,float *B,float *C) { int num_omp_threads = off->dev->num_cores; long ii, jj, kk; // omp_set_num_threads(off->dev->num_cores); //printf("%d...
fft.c
/* Copyright 2013-2014. The Regents of the University of California. * Copyright 2016-2018. Martin Uecker. * Copyright 2018. Massachusetts Institute of Technology. * All rights reserved. Use of this source code is governed by * a BSD-style license which can be found in the LICENSE file. * * Authors: * 2011-2018 ...
convolution_2x2.h
// Tencent is pleased to support the open source community by making ncnn available. // // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. // // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except // in compliance with the License. You may obtain a copy ...
ark_heat1D_omp.c
/*--------------------------------------------------------------- * Programmer(s): Shelby Lockhart @ LLNL *--------------------------------------------------------------- * Based on the serial code ark_heat1D.c developed by * Daniel R. Reynolds @ SMU and parallelized with OpenMP *----------------------------------...
3d7pt_var.c
/* * Order-1, 3D 7 point stencil with variable coefficients * Adapted from PLUTO and Pochoir test bench * * Tareq Malas */ #include <stdio.h> #include <stdlib.h> #include <sys/time.h> #ifdef LIKWID_PERFMON #include <likwid.h> #endif #include "print_utils.h" #define TESTS 2 #define MAX(a,b) ((a) > (b) ? a : b) #...
lis_vector_opv.c
/* Copyright (C) 2002-2012 The SSI Project. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of condition...
t.c
# 1 "qla-1.7.1/QLA_D3_V_vpeq_M_times_pV.c" # 1 "<built-in>" 1 # 1 "<built-in>" 3 # 341 "<built-in>" 3 # 1 "<command line>" 1 # 1 "<built-in>" 2 # 1 "qla-1.7.1/QLA_D3_V_vpeq_M_times_pV.c" 2 # 1 "/usr/include/stdio.h" 1 3 4 # 27 "/usr/include/stdio.h" 3 4 # 1 "/usr/include/x86_64-linux-gnu/bits/libc-header-start.h" 1 3...
polybench.h
/** * polybench.h: This file is part of the PolyBench/C 3.2 test suite. * * * Contact: Louis-Noel Pouchet <pouchet@cse.ohio-state.edu> * Web address: http://polybench.sourceforge.net */ /* * Polybench header for instrumentation. * * Programs must be compiled with `-I utilities utilities/polybench.c' * * Opti...
UtilitiesOMP.h
// // UtilitiesOMP.h // Gauss // // Created by David Levin on 6/7/17. // // #ifndef UtilitiesOMP_h #define UtilitiesOMP_h inline int omp_thread_count() { int n = 0; #pragma omp parallel reduction(+:n) n += 1; return n; } #endif /* UtilitiesOMP_h */
cancel-2.c
/* { dg-do compile } */ void foo (void) { #pragma omp parallel { #pragma omp cancel parallel if (1) if (1) /* { dg-error "too many 'if' clauses without modifier" } */ #pragma omp cancel parallel if (cancel: 1) if (cancel: 1) /* { dg-error "too many 'if' clauses with 'cancel' modifier" } */ #pragma om...
hoGdSolver.h
/** \file hoGdSolver.h \brief Implement the optimizer for the gradient descent algorithm \author Hui Xue */ #pragma once #include "solver.h" #include "linearOperator.h" namespace Gadgetron { template <typename Array_Type, typename Proximal_Oper_Type> class hoGdSolver; template <typename Ar...
rar_fmt_plug.c
/* RAR 3.x cracker patch for JtR. Hacked together during * April of 2011 by Dhiru Kholia <dhiru.kholia at gmail.com> for GSoC. * magnum added -p mode support, using code based on libclamav * and OMP, AES-NI and OpenCL support. * jimf added dyna_salt support, Oct 2014. * * This software is Copyright (c) 2011, Dhir...
GB_unaryop__minv_uint64_uint64.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
GB_binop__isne_uint8.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX...
GB_Matrix_diag.c
//------------------------------------------------------------------------------ // GB_Matrix_diag: construct a diagonal matrix from a vector //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-License-...
program_evaluator.h
// Ceres Solver - A fast non-linear least squares minimizer // Copyright 2010, 2011, 2012 Google Inc. All rights reserved. // http://code.google.com/p/ceres-solver/ // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are met: // ...
scaffold.c
/* Copyright 2007, 2008 Daniel Zerbino (zerbino@ebi.ac.uk) This file is part of Velvet. Velvet is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your opt...
linop.h
#pragma once #include <Eigen/Dense> #include <Eigen/Sparse> #include <Eigen/IterativeLinearSolvers> #include <SmurffCpp/Utils/MatrixUtils.h> #include <SmurffCpp/Utils/Error.h> #include <SmurffCpp/Utils/counters.h> #include <SmurffCpp/SideInfo/SparseSideInfo.h> namespace smurff { namespace linop { class AtA; } } ...
GB_unop__abs_int8_int8.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-Li...
DeclOpenMP.h
//===- DeclOpenMP.h - Classes for representing OpenMP directives -*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===------------------------------------------------------...
GB_binop__lxor_int16.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX...
GrB_Matrix_ncols.c
//------------------------------------------------------------------------------ // GrB_Matrix_ncols: number of columns of a sparse matrix //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-License-Ide...
reduction.c
#include <stdio.h> #include <stdlib.h> #define N 100 int main(int argc, char *argv[]) { int i; int sum = 0; double A[N]; for (i = 0; i < N; i++) { A[i] = 1; } #pragma omp parallel for reduction(+:sum) for (i = 0; i < N; i++) { sum = sum + A[i]; } printf("sum = %d\n", sum); return EXIT_...
bc.c
/* * ============================ bc ===================== * BC sets the boundary conditions * ATMS 502 / CSE 566, Spring 2016 * * Arguments: * * q1 real array values at current time step * i1,i2 integers indices bounding array data * nx integer main array size, not including * extra 'ghost' zones/points ...
3d7pt.lbpar.c
#include <omp.h> #include <math.h> #define ceild(n,d) ceil(((double)(n))/((double)(d))) #define floord(n,d) floor(((double)(n))/((double)(d))) #define max(x,y) ((x) > (y)? (x) : (y)) #define min(x,y) ((x) < (y)? (x) : (y)) /* * Order-1, 3D 7 point stencil * Adapted from PLUTO and Pochoir test bench * * Tare...
GB_unaryop__abs_bool_int16.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
lcs.c
/* Dynamic Programming solution to find length of the longest common substring Adapted from http://www.geeksforgeeks.org/longest-common-substring/ */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include <omp.h> /* Programa sequencial: real 0m7.898s user 0m6.769s sys 0m1.115s Progra...
helloOMP.c
#include <stdio.h> #include <omp.h> int main(void) { #pragma omp parallel printf("(%d:!!!Hello world!!!)",omp_get_thread_num()); return(0); }
GB_binop__rdiv_int16.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http:...
3d25pt.c
/* * Order-2, 3D 25 point stencil * Adapted from PLUTO and Pochoir test bench * * Tareq Malas */ #include <stdio.h> #include <stdlib.h> #include <sys/time.h> #ifdef LIKWID_PERFMON #include <likwid.h> #endif #include "print_utils.h" #define TESTS 2 #define MAX(a,b) ((a) > (b) ? a : b) #define MIN(a,b) ((a) < (b)...
fib.c
#include <stdio.h> #include <inttypes.h> #include <stdlib.h> #include "omp.h" int64_t fib(int64_t n) { if (n < 2) return n; int64_t x, y; if (n < 19) { x = fib(n - 1); y = fib(n - 2); } else { #pragma omp task shared(x) x = fib(n - 1); #pragma omp task shared(y) y ...
DRB099-targetparallelfor2-orig-no.c
/* Copyright (c) 2017, Lawrence Livermore National Security, LLC. Produced at the Lawrence Livermore National Laboratory Written by Chunhua Liao, Pei-Hung Lin, Joshua Asplund, Markus Schordan, and Ian Karlin (email: liao6@llnl.gov, lin32@llnl.gov, asplund1@llnl.gov, schordan1@llnl.gov, karlin1@llnl.gov) LLNL-CODE-73214...
GB_binop__bshift_int16.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX...
fc3.c
/* Copyright (C) 2015 Atsushi Togo */ /* All rights reserved. */ /* This file is part of phonopy. */ /* Redistribution and use in source and binary forms, with or without */ /* modification, are permitted provided that the following conditions */ /* are met: */ /* * Redistributions of source code must retain the abo...
requires_unified_address.c
// Based on sollve_vv/tests/5.0/requires/test_requires_unified_address.c #include <stdio.h> #include <omp.h> #define N 1024 #pragma omp requires unified_address int unified_address() { int errors = 0; int i; int * mem_ptr = (int *)malloc(N * sizeof(int)); #pragma omp target map(to: mem_ptr) { ...
DRB069-sectionslock1-orig-no.c
/* Copyright (c) 2017, Lawrence Livermore National Security, LLC. Produced at the Lawrence Livermore National Laboratory Written by Chunhua Liao, Pei-Hung Lin, Joshua Asplund, Markus Schordan, and Ian Karlin (email: liao6@llnl.gov, lin32@llnl.gov, asplund1@llnl.gov, schordan1@llnl.gov, karlin1@llnl.gov) LLNL-CODE-73214...
spmv_hicoo_mat.c
/* This file is part of HiParTI!. HiParTI! is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. HiParTI! is distr...
test-mempool.c
/* xZTL: Zone Translation Layer User-space Library * * Copyright 2019 Samsung Electronics * * Written by Ivan L. Picoli <i.picoli@samsung.com> * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the Lic...
unroll_indexed.c
#include <unistd.h> #include <stdlib.h> #include <stdio.h> #include <string.h> #include "constants.h" /** * Deinterleave (transpose) an IQUV ring buffer page to the ordering needed for FITS files * Note that this is probably a slow function, and is not meant to be run real-time * * data in: tab, channel/4, tim...
GB_binop__band_int32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
single_private.c
#include <stdio.h> #include "omp_testsuite.h" int check_single_private (FILE * logFile) { int nr_threads_in_single = 0; int result = 0; int myresult = 0; int myit = 0; int nr_iterations = 0; int i; #pragma omp parallel private(i,myresult,myit) { myresult = 0; myit = 0; for (i = 0; i < LOOPCOU...
GB_binop__min_int64.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
OpenMPClause.h
//===- OpenMPClause.h - Classes for OpenMP clauses --------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===---------------------------...
GB_binop__isgt_uint16.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX...
single_misc_messages.c
// RUN: %clang_cc1 -fsyntax-only -fopenmp -verify %s -Wuninitialized // RUN: %clang_cc1 -fsyntax-only -fopenmp-simd -verify %s -Wuninitialized void xxx(int argc) { int x; // expected-note {{initialize the variable 'x' to silence this warning}} #pragma omp single argc = x; // expected-warning {{variable 'x' is uni...
sparselu-task.c
/**********************************************************************************************/ /* This program is part of the Barcelona OpenMP Tasks Suite */ /* Copyright (C) 2009 Barcelona Supercomputing Center - Centro Nacional de Supercomputacion */ /* Copyright (C) 2009 Univer...
GB_unop__asinh_fp32_fp32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-Li...
attribute.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
GB_subassign_16.c
//------------------------------------------------------------------------------ // GB_subassign_16: C(I,J)<!M> += A ; using S //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http://suitesparse.com See...
algorithm.h
// ----------------------------------------------------------------------------- // // Copyright (C) 2021 CERN & University of Surrey for the benefit of the // BioDynaMo collaboration. All Rights Reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compl...
omp_for_schedule_static.c
// RUN: %libomp-compile-and-run #include <stdio.h> #include <stdlib.h> #include "omp_testsuite.h" #include "omp_my_sleep.h" #define CFSMAX_SIZE 1000 #define MAX_TIME 0.01 #ifdef SLEEPTIME #undef SLEEPTIME #define SLEEPTIME 0.0005 #endif int test_omp_for_schedule_static() { int threads; int i,lasttid; int * tid...
subCycleHex3D.c
/* The MIT License (MIT) Copyright (c) 2017 Tim Warburton, Noel Chalmers, Jesse Chan, Ali Karakus Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation t...
target_teams_distribute_parallel_for_simd_misc_messages.c
// RUN: %clang_cc1 -fsyntax-only -fopenmp -verify %s // RUN: %clang_cc1 -fsyntax-only -fopenmp-simd -verify %s // expected-error@+1 {{unexpected OpenMP directive '#pragma omp target teams distribute parallel for simd'}} #pragma omp target teams distribute parallel for simd // expected-error@+1 {{unexpected OpenMP di...
GB_binop__lxor_int8.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
transform.h
/*! * Copyright 2018 XGBoost contributors */ #ifndef XGBOOST_COMMON_TRANSFORM_H_ #define XGBOOST_COMMON_TRANSFORM_H_ #include <dmlc/omp.h> #include <dmlc/common.h> #include <xgboost/data.h> #include <utility> #include <vector> #include <type_traits> // enable_if #include "xgboost/host_device_vector.h" #include "x...
MergeImages.h
/****************************************************************************** * SOFA, Simulation Open-Framework Architecture, development version * * (c) 2006-2017 INRIA, USTL, UJF, CNRS, MGH * * * ...
tinyexr.h
#ifndef TINYEXR_H_ #define TINYEXR_H_ /* Copyright (c) 2014 - 2019, Syoyo Fujita and many contributors. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain th...
3d7pt.c
/* * Order-1, 3D 7 point stencil * Adapted from PLUTO and Pochoir test bench * * Tareq Malas */ #include <stdio.h> #include <stdlib.h> #include <sys/time.h> #ifdef LIKWID_PERFMON #include <likwid.h> #endif #include "print_utils.h" #define TESTS 2 #define MAX(a,b) ((a) > (b) ? a : b) #define MIN(a,b) ((a) < (b) ...
tes.h
//Sabet Maulana Mubarok 2006577353 /* header ini berisikan tentang pengolahan data pasien didalam sistem */ //linked list untuk menyimpan data pasien. struct Pasien { char nama[255]; char gender[10]; int tanggal; int bulan; int tahun; char status_pasien[50]; struct Pasien *next; }; typedef st...
Hello-World.c
#include <stdio.h> #include <omp.h> int main(void) { #pragma omp parallel printf("(%d:!!!Hello world!!!)", omp_get_thread_num()); return(0); }
GB_convert_sparse_to_hyper.c
//------------------------------------------------------------------------------ // GB_convert_sparse_to_hyper: convert a matrix from sparse to hyperspasre //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. //...
expramp.c
#include<Python.h> #include<numpy/arrayobject.h> #include<math.h> #include<omp.h> #define IND(a,i) *((double *)(a->data+i*a->strides[0])) static PyObject *expramp(PyObject *self, PyObject *args, PyObject *keywds); static PyObject *expramp(PyObject *self, PyObject *args, PyObject *keywds) { PyObject *etc; PyArray...
atomic.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> int main(int argc, char **argv) { int i, n=20, a[n],suma=0,sumalocal; if(argc < 2) { fprintf(stderr,"\nFalta iteraciones\n"); exit(-1); } n = atoi(argv[1]); if (n>20) n=20; for (i=0; i<n; i++) a[i] = i; #pragma omp par...
GB_reduce_to_scalar_template.c
//------------------------------------------------------------------------------ // GB_reduce_to_scalar_template: s=reduce(A), reduce a matrix to a scalar //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // ...
ompcompress.c
#ifdef _OPENMP /* compress 1d contiguous array in parallel */ static void _t2(compress_omp, Scalar, 1)(zfp_stream* stream, const zfp_field* field) { /* array metadata */ const Scalar* data = (const Scalar*)field->data; uint nx = field->nx; /* number of omp threads, blocks, and chunks */ uint threads = threa...
cones.c
#include "cones.h" #include "linalg.h" #include "scs.h" #include "scs_blas.h" /* contains BLAS(X) macros and type info */ #include "util.h" #define CONE_RATE (2) #define CONE_TOL (1e-8) #define CONE_THRESH (1e-6) #define EXP_CONE_MAX_ITERS (100) #define POW_CONE_MAX_ITERS (20) #ifdef USE_LAPACK void BLAS(syevr)(const...
GrB_Matrix_wait.c
//------------------------------------------------------------------------------ // GrB_Matrix_wait: wait for a matrix to complete //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-License-Identifier:...
Sema.h
//===--- Sema.h - Semantic Analysis & AST Building --------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===---------------------------...
task_set.c
#include "communicator.h" #include "task_set.h" #include <stdlib.h> #ifdef __cplusplus extern "C" { #endif #if TCI_USE_OPENMP_THREADS || TCI_USE_PTHREADS_THREADS || TCI_USE_WINDOWS_THREADS void tci_task_set_init(tci_task_set* set, tci_comm* comm, unsigned ntask, uint64_t work) { set->comm ...
GB_unaryop__one_fp64_fp64.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
pooling_2x2_pack8.h
// Tencent is pleased to support the open source community by making ncnn available. // // Copyright (C) 2019 THL A29 Limited, a Tencent company. All rights reserved. // // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except // in compliance with the License. You may obtain a copy...
convolution_3x3.h
// Tencent is pleased to support the open source community by making ncnn available. // // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. // // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except // in compliance with the License. You may obtain a copy ...
GB_binop__remainder_fp32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
dropout-inl.h
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you ...
column_matrix_obl.h
/*! * Copyright 2017 by Contributors * Modifications Copyright 2020 by Secure XGBoost Contributors * \file column_matrix.h * \brief Utility for fast column-wise access * \author Philip Cho */ #ifdef __ENCLAVE_OBLIVIOUS__ #ifndef XGBOOST_COMMON_COLUMN_MATRIX_H_ #define XGBOOST_COMMON_COLUMN_MATRIX_H_ #include <...
encode.c
/* * encode.c * * Created on: 2011-09-18 * Author: francis */ #define _GNU_SOURCE #include <stdlib.h> #include <stdio.h> #include <time.h> #include <math.h> #include <assert.h> #include <string.h> #include <getopt.h> #include <inttypes.h> #include <sys/resource.h> #include <sys/time.h> #include <errno.h> #i...