source
stringlengths
3
92
c
stringlengths
26
2.25M
convolution-3d.c
/* POLYBENCH/GPU-OPENMP * * This file is a part of the Polybench/GPU-OpenMP suite * * Contact: * William Killian <killian@udel.edu> * * Copyright 2013, The University of Delaware */ #include <stdio.h> #include <unistd.h> #include <string.h> #include <math.h> /* Include polybench common header. */ #include <po...
GB_binop__band_int32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http:...
main.c
/*************************************************************************** *cr *cr (C) Copyright 2007 The Board of Trustees of the *cr University of Illinois *cr All Rights Reserved *cr ********************************************************************...
concurrent_unordered_map.cuh.h
/* * Copyright (c) 2017-2018, NVIDIA CORPORATION. All rights reserved. * * 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 License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless ...
Huuugefile.c
1 #include <stdio.h>2 #include <stdlib.h>3 #include <string.h>4 #include <time.h>5 voidMerge(int*a1,intn1,int*a2,intn2,int*r)6 {inti1,i2,i;7 for(i1=0,i2=0,i=0;i1<n1&&i2<n2;)8 if(a1[i1]<a2[i2])9 r[i++]=a1[i1++];10 else11 r[i++]=a2[i2++];12 while(i1<n1)r[i++]=a1[i1++];13 while(i2<n2)r[i++]=a2[i2++...
main.c
/* ******************************************************************************** * Polytech'Nice Sophia * * * Filename : main.c * Programmer : Loïc ROSE * Description : algorithm to find the maximal subsequence of an array ******************************************************...
GB_unop__identity_int64_fc32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-Li...
GB_unop__ainv_int32_int32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-Li...
GB_unop__identity_fc32_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...
nested_thread_num.c
// RUN: %libomp-compile-and-run | FileCheck %s // RUN: %libomp-compile-and-run | %sort-threads | FileCheck --check-prefix=THREADS %s // REQUIRES: ompt // UNSUPPORTED: gcc-4, gcc-5, gcc-6, gcc-7 #define TEST_NEED_PRINT_FRAME_FROM_OUTLINED_FN #include "callback.h" #include <omp.h> #include <unistd.h> int main() { int ...
openmp_workspace.c
/** * * @file runtime_workspace.c * * PLASMA is a software package provided by: * University of Tennessee, US, * University of Manchester, UK. * * @copyright 2018 King Abdullah University of Science and Technology (KAUST). * All rights reserved. * * @brief AL4SAN Workspace routin...
asm-1.c
/* PR middle-end/30263 */ /* { dg-do compile } */ /* { dg-options "-O2 -fopenmp" } */ extern int omp_get_thread_num (void); void foo (void) { int s0, s1 = 5, s2 = 6; int p0, p1, p2; int f0 = 4, f1 = 5, f2 = 6; #pragma omp parallel shared (s0, s1, s2) private (p0, p1, p2) \ firstprivate (f0, f1, f2) { ...
pjenccc1.c
// Copyright (c) 2018 Intel Corporation // // 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 the rights // to use, copy, modify, merge, publ...
7.norace3.c
// RUN: clang %loadLLOV %s -o /dev/null 2>&1 | FileCheck %s #include <omp.h> #define M 200 #define N 200 int main() { double A[M], B[M][N], C[N], sum0 = 0.0; #pragma omp parallel for private(sum0) num_threads(20) for (int i = 0; i < M; i++) { for (int j = 0; j < N; j++) { sum0 += B[i][j] * C[j]; } ...
nbodysystem.h
/*MIT License Copyright (c) 2021 Keigo Nitadori 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 the rights to use, copy, modify, merge, publish, ...
CorrCoef.c
#include "Python.h" #include "numpy/arrayobject.h" #include <fcntl.h> #include <math.h> #include <omp.h> #define VERSION "0.1" PyArrayObject * pearson(const double *d, const unsigned long n, const unsigned long l) { PyArrayObject *coef; double *c; unsigned long *dim; unsigned long ik, i, k, o, nn; double mk, sk...
fq2cnt.c
/* * fq2cnt.c * * Code generation for function 'fq2cnt' * */ /* Include files */ #include "rt_nonfinite.h" #include "yaapt.h" #include "fq2cnt.h" #include "error1.h" #include "yaapt_emxutil.h" #include "eml_int_forloop_overflow_check.h" #include "yaapt_data.h" #include "blas.h" #include "lapacke.h" /* Variable D...
GB_binop__bget_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:...
vssched.h
#pragma omp parallel for for (long j = GZ; j < N + GZ; j += TILEJ) for (long i = GZ; i < N + GZ; i += TILEI)
imginputfileconn.h
/** * DeepDetect * Copyright (c) 2014 Emmanuel Benazera * Author: Emmanuel Benazera <beniz@droidnik.fr> * * This file is part of deepdetect. * * deepdetect 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 F...
residual_based_adjoint_static_scheme.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: // #if !defined(KRATOS_RESIDUAL_BASED_ADJOINT_STATI...
cmat.c
/* * Cheap maxtrix library for C * * Copyright (C) 2019 Hiroshi Kuwagata <kgt9221@gmail.com> */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include <math.h> #include <float.h> #include "cmat.h" #if defined(ENABLE_NEON) && (!defined(__ARM_NEON) && !defined(__ARM_NEON__)) #error "ARM NEON instruc...
test_omp.c
#include <stdio.h> #include "omp.h" int main(int argc, char ** argv){ int n = 5; omp_set_num_threads(n); int i; #pragma omp parallel for private(i) for(i=20/5*(omp_get_thread_num()-1); i < 20/5*omp_get_thread_num(); i++){ printf("%d: %d\n",omp_get_thread_num(), i); } return 0; }
GB_binop__le_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...
nr_sgx_direct.c
/* Copyright 2014-2018 The PySCF Developers. All Rights Reserved. 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 License at http://www.apache.org/licenses/LICENSE-2.0 Unless requi...
pi_loop.c
/** * This program will numerically compute the integral of * 4/(1+x*x) * from 0 to 1. The value of this integral is pi -- which * is great since it gives us an easy way to check the answer. * * The program was parallelized using OpenMP by adding just * four lines * * (1) A line to include omp.h -- the...
swap.c
#include <stdio.h> #include <stdlib.h> #include <time.h> #define N 1000 int s[N], res[N]; double cal_time(struct timespec *t_end, struct timespec *t_start) { double elapsedTime; elapsedTime = (t_end->tv_sec - t_start->tv_sec) * 1000.0; elapsedTime += (t_end->tv_nsec - t_start->tv_nsec) / 1000000.0; return elap...
image_manipulation.h
////////////////////////////////////////////////////////////////////////// // Software License Agreement (BSD License) // // // // Copyright (c) 2009 // // Engin Tola ...
update_ops_qft.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include "constant.h" #include "update_ops.h" #ifdef _OPENMP #include <omp.h> #endif void CUz_gate(double angle, UINT c_bit, UINT t_bit, CTYPE *psi, ITYPE dim) { //ITYPE i; ITYPE j; ITYPE head, body, tail; ITYPE basis00, basis11; ITYPE lef...
BPMaximalMatching.h
#ifndef BP_MAXIMAL_MATCHING_H #define BP_MAXIMAL_MATCHING_H #include "CombBLAS/CombBLAS.h" #include <iostream> #include <functional> #include <algorithm> #include <vector> #include <limits> #include "Utility.h" #include "MatchingDefs.h" #define NO_INIT 0 #define GREEDY 1 #define KARP_SIPSER 2 #define DMD 3 MTRand Glo...
GB_binop__gt_uint64.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http:...
HybridRealAdoptor.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: Ye Luo, y...
sha3_512_fmt_plug.c
/* SHA3-512 cracker patch for JtR. Hacked together during May, 2015 * by Dhiru Kholia <dhiru.kholia at gmail.com>. * * Thanks to https://github.com/codedot/keccak (Jim McDevitt) for the * "delimited suffix" stuff. * * This file is part of John the Ripper password cracker, * Copyright (c) 2012 by Solar Designer ...
sum_openmp.c
/* Copyright (C) 2018 Francesc Alted http://blosc.org License: BSD 3-Clause (see LICENSE.txt) Example program showing how to operate with compressed buffers. To compile this program for synthetic data (default): $ gcc -fopenmp -O3 sum_openmp.c -o sum_openmp -lblosc2 To run: $ OMP_PROC_BIND=spread ...
GB_dense_ewise3_noaccum_template.c
//------------------------------------------------------------------------------ // GB_dense_ewise3_noaccum_template: C = A+B where all 3 matrices are dense //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. /...
VectorofVector.h
/* * VectorofVector.h * * Created on: 21/feb/2017 * Author: samuele */ #ifndef UTILITIES_VECTOROFVECTOR_H_ #define UTILITIES_VECTOROFVECTOR_H_ #include <numeric> #include <vector> #include <memory> #include <stdexcept> #include <cassert> using namespace std; #define NDEBUG template<typename T> class Vecto...
prop3DAcoIsoDenQ_DEO2_FDTD.h
#ifndef PROP3DACOISODENQ_DEO2_FDTD_H #define PROP3DACOISODENQ_DEO2_FDTD_H #include <omp.h> #include <stddef.h> #include <stdlib.h> #include <stdio.h> #include <math.h> #include <fftw3.h> #include <complex> #include "propagatorStaticFunctions.h" #define MIN(x,y) ((x)<(y)?(x):(y)) class Prop3DAcoIsoDenQ_DEO2_FDTD { ...
GB_unop__identity_uint32_uint16.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http://...
GB_binop__max_fp64.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_binop__pair_uint16.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
local_response_norm.h
// Copyright 2018 Xiaomi, Inc. All rights reserved. // // 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 License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicab...
ellipticSEMFEMSetup.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 wi...
ctl_scroll.c
/********************************************************************[libaroma]* * Copyright (C) 2011-2015 Ahmad Amarullah (http://amarullz.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...
prepress.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
ray_tracing_funcs.c
#include <assert.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <math.h> #include <stdint.h> #include <fitsio.h> //#include <omp.h> //#include "mycosmology.h" //-------------------------------------------------------------------- void inverse_cic_omp(double *in_map, double *posy1, double *posy2...
MicroMlpAffine.h
// -------------------------------------------------------------------------- // Binary Brain -- binary neural net framework // // Copyright (C) 2018 by Ryuji Fuchikami // https://github.com/ryuz // ryuji.fuch...
core_math.h
// == mojo ==================================================================== // // Copyright (c) gnawice@gnawice.com. All rights reserved. // See LICENSE in root folder // // Permission is hereby granted, free of charge, to any person obtaining a // copy of this software and associated documentation...
dictionary-omp.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <sys/types.h> #include <omp.h> #include "dictionary-util.c" #include "../globals.h" int compare_candidates(FILE **file, char *password_hash, int verbose); /** * dictionary_crack() - OpenMP Implementation * * The OpenMP implementation of the dictio...
tti-so8-mpi.c
#define _POSIX_C_SOURCE 200809L #include "stdlib.h" #include "math.h" #include "sys/time.h" #include "xmmintrin.h" #include "pmmintrin.h" #include "mpi.h" #include "omp.h" struct dataobj { void *restrict data; int * size; int * npsize; int * dsize; int * hsize; int * hofs; int * oofs; } ; struct neighbo...
Parser.h
//===--- Parser.h - C Language Parser ---------------------------*- 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 // //===---------------------------...
ft_ao.c
/* Copyright 2014-2018 The PySCF Developers. All Rights Reserved. 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 License at http://www.apache.org/licenses/LICENSE-2.0 Unless required ...
GB_unaryop__lnot_uint64_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...
GB_unaryop__lnot_int8_bool.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
summarystatsreduce.h
/* * summarystatsreduce.h * * Created on: Jan 19, 2016 * Author: agibsonccc */ #ifndef SUMMARYSTATSREDUCE_H_ #define SUMMARYSTATSREDUCE_H_ #include <templatemath.h> #include <dll.h> #include <shape.h> #include <op.h> #ifdef __CUDACC__ #include <cuda.h> #include <cuda_runtime.h> #endif #ifdef __CUDACC__ #in...
GB_binop__isgt_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...
matrix_op-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 ...
omp_loop_static.h
// -*- C++ -*- // Copyright (C) 2007-2015 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library 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 3...
GB_binop__isgt_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-...
sphmap.h
#ifndef SPHMAP_H #define SPHMAP_H #include <omp.h> #include <vector> #include <map> #include <unordered_map> #include <cmath> #include <algorithm> #include <glm/vec3.hpp> #include <glm/mat3x3.hpp> #include <glm/geometric.hpp> #include <glm/gtx/scalar_multiplication.hpp> #include "sphparticle.h" #define LOG 0 using ...
matrix.c
#include <omp.h> #include <stdlib.h> #include <string.h> #include <limits.h> #include <matrix/matrix.h> int mtx_init(struct mtx* const m, size_t rows, size_t columns, mpfr_prec_t prec) { m->nrows = rows; m->ncols = columns; m->storage = (mpfr_t*) malloc(sizeof(mpfr_t) * m->nrows * m->ncols); if (NULL == m->stor...
k-nearest_gpu.c
/* Erro parar gerar struct. Erro na anotação dos parâmetros This program performs K nearest neighbors on the GPU with dynamically allocated matrices. Author: Gleison Souza Diniz Mendon?a Date: 04-01-2015 version 2.0 Run: ipmacc k-nearest_gpu.c -o k-nearest ./k-nearest matrix-size ...
hmm.c
/* * Copyright (C) 2017 by Benedict Paten (benedictpaten@gmail.com) * * Released under the MIT license, see LICENSE.txt */ #include "margin.h" // OpenMP #if defined(_OPENMP) #include <omp.h> #define CELL_BUFFER_SIZE 1000 #endif inline double logAddP(double a, double b, bool maxNotSum) { /* * Local funct...
statistic.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
gen_fffc.c
/****************************************************************************** * Copyright 1998-2019 Lawrence Livermore National Security, LLC and other * HYPRE Project Developers. See the top-level COPYRIGHT file for details. * * SPDX-License-Identifier: (Apache-2.0 OR MIT) **************************************...
rar5_fmt_plug.c
/* RAR 5.0 cracker patch for JtR. Hacked together during May of 2013 by Dhiru * Kholia. * * http://www.rarlab.com/technote.htm * * This software is Copyright (c) 2013 Dhiru Kholia <dhiru at openwall.com> and * it is hereby released to the general public under the * following terms: * * Redistribution and use i...
dis-ok1.c
#include <omp.h> #include <stdio.h> /* for(i=4;i<100;i++){ S1: a[i] = b[i-2] + 1; S2: c[i] = b[i-1] + f[i]; S3: b[i] = a[i-1] + 2; S4: d[i] = d[i+1] + b[i-1]; } */ #define Iter 100000 int a[Iter],b[Iter],c[Iter],d[Iter],f[Iter]; int a1[Iter],b1[Iter],c1[Iter]...
fft.c
/* -*- mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- * vim: sw=4 ts=8 et tw=80 */ /* fft.c * * Provide OMP'd FFTW3 wrappers, using the real<->complex transforms * (that seem to be twice as fast as numpy, in addition to * parallelization). */ #include "pyactpol.h" #include "myassert....
info.c
// RUN: %libomptarget-compile-nvptx64-nvidia-cuda \ // RUN: -gline-tables-only -fopenmp-extensions // RUN: env LIBOMPTARGET_INFO=63 %libomptarget-run-nvptx64-nvidia-cuda 2>&1 | \ // RUN: %fcheck-nvptx64-nvidia-cuda -allow-empty -check-prefix=INFO // REQUIRES: nvptx64-nvidia-cuda #include <stdio.h> #include <omp....
cpl_io_fits.c
/* * This file is part of the ESO Common Pipeline Library * Copyright (C) 2001-2017 European Southern Observatory * * This program 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 ...
diagsv_x_sky_n.c
#include "alphasparse/kernel.h" #include "alphasparse/util.h" #include "alphasparse/opt.h" #include <memory.h> #ifdef _OPENMP #include <omp.h> #endif alphasparse_status_t ONAME(const ALPHA_Number alpha, const ALPHA_SPMAT_SKY *A, const ALPHA_Number *x, ALPHA_Number *y) { ALPHA_Number diag[A->rows]; memset(diag...
cacheable.h
#ifndef INCLUDE_CACHEABLE_H_ #define INCLUDE_CACHEABLE_H_ #ifdef _OPENMP #include <omp.h> #endif #include <unordered_map> #include <iostream> namespace myccg { template<typename T> class Cacheable { public: typedef const T* Cached; Cacheable() { #pragma omp atomic capture id_ = ids_()++; } ...
epollex_test.c
/* * This file is part of ABCDK. * * MIT License * */ #include <stdio.h> #include <assert.h> #include <unistd.h> #include <string.h> #include <sys/sendfile.h> #include "abcdk-util/general.h" #include "abcdk-util/getargs.h" #include "abcdk-util/clock.h" #include "abcdk-util/thread.h" #include "abcdk-util/signal.h...
elu_kernel_arm.c
/* * 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 ma...
GB_unaryop__minv_uint64_uint64.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http...
GB_unop__cosh_fp32_fp32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-Li...
GB_unaryop__identity_uint32_int32.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
rose_v1_matrixmultiply.c
/* Naive matrix-matrix multiplication(mmm) By C. Liao */ #define N 1000 #define M 1000 #define K 1000 #include <omp.h> int i; int j; int k; double a[1000][1000]; double b[1000][1000]; double c[1000][1000]; int mmm() { //#pragma omp parallel for private(i,j,k) shared(a,b,c) #pragma omp parallel for private (i,j,k) ...
par_relax.c
/****************************************************************************** * Copyright 1998-2019 Lawrence Livermore National Security, LLC and other * HYPRE Project Developers. See the top-level COPYRIGHT file for details. * * SPDX-License-Identifier: (Apache-2.0 OR MIT) **************************************...
ast-dump-openmp-target-teams-distribute-simd.c
// RUN: %clang_cc1 -triple x86_64-unknown-unknown -fopenmp -ast-dump %s | FileCheck --match-full-lines -implicit-check-not=openmp_structured_block %s void test_one(int x) { #pragma omp target teams distribute simd for (int i = 0; i < x; i++) ; } void test_two(int x, int y) { #pragma omp target teams distribute ...
task1_omp.c
#include <math.h> #include <string.h> #include "timer.h" #define NN 1024 #define NM 1024 float A[NN][NM]; float Anew[NN][NM]; int main(int argc, char** argv) { const int n = NN; const int m = NM; const int iter_max = 1000; const double tol = 1.0e-6; double error = 1.0; memset(A,...
threads.c
/* * Copyright (c) 2003 Matteo Frigo * Copyright (c) 2003 Massachusetts Institute of Technology * * This program 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...
GB_binop__bxor_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...
3d25pt.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-2, 3D 25 point stencil * Adapted from PLUTO and Pochoir test bench * * Tar...
binarytrees.c
#include <stdlib.h> #include <stdio.h> typedef off_t off64_t; #include <apr_pools.h> const size_t LINE_SIZE = 64; struct node { int i; struct node *left; struct node *right; }; int node_check(const struct node *n) { if (n->left) { int lc = node_check (n->left); int rc = node_check (n->right)...
simulation.c
#include "utils.h" #include "plate.h" #include "logging.h" #include "simulation.h" #include "paralellUtils.h" #include <omp.h> #include <stdlib.h> #include <stdio.h> #include <stddef.h> #include <sys/time.h> long measureTime(){ struct timeval time; gettimeofday(&time, NULL); long micros = (time.tv_sec * 100...
CCGSubSurf_legacy.c
/* * ***** BEGIN GPL LICENSE BLOCK ***** * * This program 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 option) any later version. * * This program is d...
convolution_sgemm_int8.h
// Tencent is pleased to support the open source community by making ncnn available. // // Copyright (C) 2022 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 ...
gather_nd_op_cpu_impl.h
/* Copyright 2016 The TensorFlow Authors. All Rights Reserved. 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 License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or a...
test_trans.c
#include <stdlib.h> #include <stdio.h> #include <omp.h> #include <blis/blis.h> #include "test_base.h" #include "../src/gemm_blis.h" #include "../src/im2row_nhwc.h" #include "../src/im2col_nchw.h" int main(int argc, char *argv[]) { TEST_INIT float *image = random_alloc(b * h * w * c); float *out = random...
GB_unaryop__ainv_uint16_int32.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
reduction-clauseModificado2.c
#include <stdio.h> #include <stdlib.h> #ifdef _OPENMP #include <omp.h> #else #define omp_get_thread_num() 0 #endif int main(int argc, char **argv) { int i, n=20, a[n],suma=10; if(argc < 2) { fprintf(stderr,"Falta iteraciones\n"); exit(-1); } n = atoi(argv[1]); if (n>20) {n=20; printf("n=%d",n);} ...
globalsums.c
#include <stdlib.h> #include <stdio.h> #include <time.h> #include <math.h> #include <omp.h> double do_sum_novec(double *var, long ncells); double do_sum(double *var, long ncells); double do_kahan_sum(double *var, long ncells); double do_serial_sum_fog_v(double *var, long ncells); double do_serial_sum_fog_v8(double *va...
knn.h
/* Copyright (c) 2020, Intel Corporation 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 above copyright notice, this list of conditions and the following disclaimer. * ...
2DConvolution.c
/** * 2DConvolution.c: This file was adapted from PolyBench/GPU 1.0 test suite * to run on GPU with OpenMP 4.0 pragmas and OpenCL driver. * * http://www.cse.ohio-state.edu/~pouchet/software/polybench/GPU * * Contacts: Marcio M Pereira <mpereira@ic.unicamp.br> * Rafael Cardoso F Sousa <rafael.cardoso@st...
GB_binop__bget_uint32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http:...
compute.h
#pragma once #include <volk.h> #include <string_view> #include <vector> #include <create.h> #include <locator.h> #include <shader.h> #include <swapchain.h> #include <command.h> class Compute { public: VkExtent2D& extent() { return cboExtent; } VkImage& color(u_int32_t frame, ...
transposition_network_4symbol_alphabet_bit.h
//// //// Created by nikita on 30.07.2020. //// // //#ifndef CPU_TRANSPOSITION_NETWORK_4SYMBOL_ALPHABET_BIT_H //#define CPU_TRANSPOSITION_NETWORK_4SYMBOL_ALPHABET_BIT_H // //#include <vector> //#include <cmath> // // //template<class Input> //inline void loop_upper_half_mpi(int lower_bound, int upper_bound, int rev_cou...
sageInterface.h
#ifndef ROSE_SAGE_INTERFACE #define ROSE_SAGE_INTERFACE #include "sage3basic.hhh" #include <stdint.h> #include <utility> #include "rosePublicConfig.h" // for ROSE_BUILD_JAVA_LANGUAGE_SUPPORT #if 0 // FMZ(07/07/2010): the argument "nextErrorCode" should be call-by-reference SgFile* determineFileType ( std::vector<...
dsysv.c
/** * * @file * * PLASMA is a software package provided by: * University of Tennessee, US, * University of Manchester, UK. * * @generated from /home/luszczek/workspace/plasma/bitbucket/plasma/compute/zhesv.c, normal z -> d, Fri Sep 28 17:38:06 2018 * **/ #include "plasma.h" #include "plasma_async.h" #incl...
gutoga.c
#include <float.h> #include <omp.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <time.h> #include "gutoga.h" struct gutoga_mutex_t *gutoga_mutex_new() { struct gutoga_mutex_t *lock; lock = calloc(1, sizeof(*lock)); if (lock == NULL) { return NULL; } omp_init_lock(&lock->l); return lock...