source
stringlengths
3
92
c
stringlengths
26
2.25M
gemm.c
#include "gemm.h" #include "utils.h" #include "cuda.h" #include <stdlib.h> #include <stdio.h> #include <math.h> void gemm_bin(int M, int N, int K, float ALPHA, char *A, int lda, float *B, int ldb, float *C, int ldc) { int i,j,k; for(i = 0; i < M; ++i){ for(k = 0; k < K; ++k){...
rwpng.c
/*--------------------------------------------------------------------------- pngquant: RGBA -> RGBA-palette quantization program rwpng.c --------------------------------------------------------------------------- © 1998-2000 by Greg Roelofs. © 2009-2015 by Kornel Lesiński. All rights res...
omp-getcpu.c
#define _GNU_SOURCE #include <omp.h> #include <stdio.h> #include <sched.h> #define THREADS 8 int main(void) { int i=0; #pragma omp parallel num_threads(THREADS) { printf("Thread %d/%d on cpu %d\n", omp_get_thread_num(), omp_get_num_threads(), sched_getcpu() ...
simde-diagnostic.h
/* SPDX-License-Identifier: MIT * * 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, ...
omp_for_schedule_guided.c
<ompts:test> <ompts:testdescription>Test which checks the guided option of the omp for schedule directive.</ompts:testdescription> <ompts:ompversion>2.0</ompts:ompversion> <ompts:directive>omp for schedule(guided)</ompts:directive> <ompts:dependences>omp flush,omp for nowait,omp critical,omp single</ompts:dependences> ...
util.h
#include <math.h> #include <iostream> #include <omp.h> //------------------------------------------------------------------- //--initialize array with maximum limit //------------------------------------------------------------------- template<typename datatype> void fill(datatype *A, const int n, const datatype maxi){...
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...
nanopore_hdp.c
// // nanopore_hdp.c // // // Created by Jordan Eizenga on 1/8/16. // // // in 0-based index #define ALIGNMENT_KMER_COL 9 #define ALIGNMENT_STRAND_COL 4 #define ALIGNMENT_SIGNAL_COL 13 #define ASSIGNMENT_KMER_COL 0 #define ASSIGNMENT_STRAND_COL 1 #define ASSIGNMENT_SIGNAL_COL 2 // number of expected column in the ...
ocp_nlp_sqp.c
/* * Copyright 2019 Gianluca Frison, Dimitris Kouzoupis, Robin Verschueren, * Andrea Zanelli, Niels van Duijkeren, Jonathan Frey, Tommaso Sartor, * Branimir Novoselnik, Rien Quirynen, Rezart Qelibari, Dang Doan, * Jonas Koenemann, Yutao Chen, Tobias Schöls, Jonas Schlagenhauf, Moritz Diehl * * This file is part o...
tinyexr.h
/* Copyright (c) 2014 - 2017, Syoyo Fujita 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 the above copyright notice, this list of conditions and t...
ZQ_CNN_BBoxUtils.h
#ifndef _ZQ_CNN_BBOX_UTILS_H_ #define _ZQ_CNN_BBOX_UTILS_H_ #pragma once #include "ZQ_CNN_BBox.h" #include <string> #include <math.h> #include <stdlib.h> #include <algorithm> namespace ZQ { class ZQ_CNN_BBoxUtils { public: enum PriorBoxCodeType { PriorBoxCodeType_CORNER = 0, PriorBoxCodeType_CORNER_SIZE...
FindHaloes.c
// Re-write of find_halos.c from the original 21cmFAST // ComputeHaloField takes in a k_space box of the linear overdensity field // and filters it on decreasing scales in order to find virialized halos. // Virialized halos are defined according to the linear critical overdensity. // ComputeHaloField outputs a cube ...
atomic-10.c
/* PR middle-end/28046 */ /* { dg-do compile } */ /* { dg-options "-fopenmp -fdump-tree-gimple" } */ /* LLVM LOCAL test not applicable */ /* { dg-require-fdump "" } */ int a[3], b; struct C { int x; int y; } c; int bar (void), *baz (void); void foo (void) { #pragma omp atomic a[2] += bar (); #pragma omp atomic ...
ex01.c
/* Copyright (c) 2019 CSC Training */ /* Copyright (c) 2021 ENCCS */ #include <stdio.h> #include <math.h> #define NX 102400 int main(void) { double vecA[NX],vecB[NX],vecC[NX]; double r=0.2; /* Initialization of vectors */ for (int i = 0; i < NX; i++) { vecA[i] = pow(r, i); vecB[i] = 1.0; } /* dot p...
bli_cntx_init_a64fx.c
/* BLIS An object-based framework for developing high-performance BLAS-like libraries. Copyright (C) 2014, The University of Texas at Austin Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - Redist...
GB_unop__expm1_fc32_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...
omp_version.c
/****************************************************************************** * * FILE: omp_version.c * * DESCRIPTION: * * OMP VERSION - C/C++ Version * * AUTHOR: Victor Rodriguez * ******************************************************************************/ #include <omp.h> #include <stdio.h> #include ...
swater2D-omp.c
/* * shwater2d solves the two dimensional shallow water equations * using the Lax-Friedrich's scheme */ #include <unistd.h> #include <stdlib.h> #include <stdio.h> #include <math.h> //#include <omp.h> #include <sys/time.h> #define cell_size 3 #define xstart 0.0 #define ystart 0.0 #define xend 4.0 #...
pcpaes_cfbdecrypt.c
/******************************************************************************* * Copyright 2013-2019 Intel Corporation * All Rights Reserved. * * If this software was obtained under the Intel Simplified Software License, * the following terms apply: * * The source code, information and material ("Material") co...
sb_sphkmeans.c
/*! \file \brief A parallel spherical k-means program \date Started 4/20/2013 \author George */ #define _SVID_SOURCE #define _DEFAULT_SOURCE #if 0 int main() {} #else #include <GKlib.h> #include <bdmpi.h> #include <sys/types.h> #include <sys/time.h> #include <sys/resource.h> #include <sys/mman.h> #include <unistd.h> ...
data_4D.c
/* This file is part of the MCsquare software Copyright © 2016-2017 Université catholique de Louvain (UCL) All rights reserved. The MCsquare software has been developed by Kevin Souris from UCL in the context of a collaboration with IBA s.a. Each use of this software must be attributed to Université catholique de Louv...
DRB056-jacobi2d-tile-no.c
/** * jacobi-2d-imper.c: This file is part of the PolyBench/C 3.2 test suite. * Jacobi with array copying, no reduction. with tiling and nested SIMD. * * Contact: Louis-Noel Pouchet <pouchet@cse.ohio-state.edu> * Web address: http://polybench.sourceforge.net * License: /LICENSE.OSU.txt */ #include <stdio.h> #inc...
pi-v10.c
/* * Compute pi by approximating the area under the curve f(x) = 4 / (1 + x*x) * between 0 and 1. * * parallel version using OpenMP */ #include <stdio.h> #include <stdlib.h> #include <omp.h> /* OpenMP */ #if _DEBUG_ #define _DEBUG_ 1 #else #define _DEBUG_ 0 #endif int main(int argc, char *argv[]) { do...
atomic-3.c
/* { dg-do run } */ /* { dg-options "-fopenmp -O0" } */ #include <omp.h> #include <stdlib.h> short e[64]; int g; _Complex double d, f; int num_threads; __attribute__((noinline)) void foo (int x, long long y) { #pragma omp parallel num_threads (4) { int i; #pragma omp barrier for (i = 0; i < 2400; i++) ...
2-8t.c
#include <stdio.h> #include <omp.h> int main() { omp_set_num_threads(8); #pragma omp parallel { printf(" Hello "); } printf("\n\n GoodBye – Team Destroyed – Exiting Program \n\n"); }
GB_unaryop__minv_uint64_uint16.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http...
irbuilder_unroll_partial_heuristic.c
// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --function-signature --include-generated-funcs // RUN: %clang_cc1 -fopenmp-enable-irbuilder -verify -fopenmp -fopenmp-version=51 -x c -triple x86_64-unknown-unknown -emit-llvm %s -o - | FileCheck %s // expected-no-diagnostics #ifnd...
tree-ssa-loop-ivcanon.c
/* Induction variable canonicalization and loop peeling. Copyright (C) 2004-2017 Free Software Foundation, Inc. This file is part of GCC. GCC 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, ...
Layers.h
/* * Layers.h * * Created by Guido Novati on 29.10.18. * Copyright 2018 ETH Zurich. All rights reserved. * */ #pragma once #include "Activations.h" #ifdef USE_MKL #include "mkl_cblas.h" #else #ifndef __STDC_VERSION__ //it should never be defined with g++ #define __STDC_VERSION__ 0 #endif #include "cblas.h" #...
fx.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
generated-funcs.c
// Check that the CHECK lines are generated for clang-generated functions // RUN: %clang_cc1 -no-opaque-pointers -triple x86_64-unknown-linux-gnu -fopenmp %s -emit-llvm -o - | FileCheck --check-prefix=OMP %s // RUN: %clang_cc1 -no-opaque-pointers -triple x86_64-unknown-linux-gnu %s -emit-llvm -o - | FileCheck --check-p...
interpolation_pc.c
//------------------------------------------------------------------------------------------------------------------------------ // Samuel Williams // SWWilliams@lbl.gov // Lawrence Berkeley National Lab //------------------------------------------------------------------------------------------------------------------...
hello_world_omp.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> int main (int argc, char *argv[]) { int th_id, nthreads; #pragma omp parallel private(th_id) { /*Every thread says hello */ th_id = omp_get_thread_num(); printf("Hello, World from thread %d\n", th_id); #pragma omp barrier if (th_id == 0) ...
task_multiple_producer_omp.c
/* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil ; -*- */ /* * See LICENSE.txt in top-level directory. */ #include <assert.h> #include <omp.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> #define NUM_TASKS 5000000 #define NUM_REPS 1 #define USLEEP usleep(100); /* Pragma ...
SplineHybridAdoptorReaderP.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: Jeremy Mc...
key_value_rand_hash.h
/* * (C) copyright 2011, Ismael Garcia, (U.Girona/ViRVIG, Spain & INRIA/ALICE, France) * * 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/licens...
serial_tree_learner.h
#ifndef LIGHTGBM_TREELEARNER_SERIAL_TREE_LEARNER_H_ #define LIGHTGBM_TREELEARNER_SERIAL_TREE_LEARNER_H_ #include <LightGBM/tree_learner.h> #include <LightGBM/utils/random.h> #include <LightGBM/utils/array_args.h> #include <LightGBM/dataset.h> #include <LightGBM/tree.h> #include "feature_histogram.hpp" #include "spli...
hello.c
#include <stdio.h> #include <omp.h> int main(int argc, char *argv[]){ printf("Hello from master thread.\n"); #pragma omp parallel { printf("Team member %d reporting from team of %d\n", omp_get_thread_num(), omp_get_num_threads() ); } printf("Master thread finished, goodbye.\n"); }
nukedclan_fmt_plug.c
/* Nuked-Klan CMS DB cracker patch for JtR. Hacked together during * July of 2012 by Dhiru Kholia <dhiru.kholia at gmail.com>. * * This software is Copyright (c) 2012, Dhiru Kholia <dhiru.kholia at gmail.com>, * and it is hereby released to the general public under the following terms: * Redistribution and use in ...
omp_workshare2.c
/****************************************************************************** * FILE: omp_workshare2.c * DESCRIPTION: * OpenMP Example - Sections Work-sharing - C/C++ Version * In this example, the OpenMP SECTION directive is used to assign * different array operations to threads that execute a SECTION. Each *...
draw.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
lud_omp.ref.c
#include <sys/time.h> #include <time.h> #include <stdio.h> static unsigned long long current_time_ns() { #ifdef __MACH__ clock_serv_t cclock; mach_timespec_t mts; host_get_clock_service(mach_host_self(), CALENDAR_CLOCK, &cclock); clock_get_time(cclock, &mts); mach_port_deallocate(mach_task_self(), c...
barrier-1.c
/* { dg-do compile } */ /* { dg-options "-fopenmp -fdump-tree-gimple" } */ void f1(void) { #pragma omp barrier } void f2(_Bool p) { if (p) { #pragma omp barrier } } /* { dg-final { scan-tree-dump-times "GOMP_barrier" 2 "gimple" } } */ /* { dg-final { cleanup-tree-dump "gimple" } } */
6439.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...
trmv_c_csr_n_lo_conj.c
#include "alphasparse/kernel.h" #include "alphasparse/util.h" #include "alphasparse/opt.h" #ifdef _OPENMP #include <omp.h> #endif #include <memory.h> #include<stdlib.h> static alphasparse_status_t trmv_x_csr_n_lo_conj_omp(const ALPHA_Number alpha, c...
bug_proxy_task_dep_waiting.c
// RUN: %libomp-compile-and-run // The runtime currently does not get dependency information from GCC. // UNSUPPORTED: gcc #include <stdio.h> #include <omp.h> #include <pthread.h> #include "omp_my_sleep.h" /* An explicit task can have a dependency on a target task. If it is not directly satisfied, the runtime shoul...
blake2sp-ref.c
/* BLAKE2 reference source code package - reference C implementations Copyright 2012, Samuel Neves <sneves@dei.uc.pt>. You may use this under the terms of the CC0, the OpenSSL Licence, or the Apache Public License 2.0, at your option. The terms of these licenses can be found at: - CC0 1.0 Universal :...
cpu_ctc.h
#pragma once #include <tuple> #include <cmath> #include <limits> #include <algorithm> #include <numeric> #include <dmlc/omp.h> #include "ctc_helper.h" namespace mxnet_warpctc { template<typename ProbT> class CpuCTC { public: // Noncopyable CpuCTC(int alphabet_size, int minibatch, void* workspace, ...
Example_declare_target.1.c
/* * @@name: declare_target.1c * @@type: C * @@compilable: yes * @@linkable: no * @@expect: success * @@version: omp_4.0 */ #pragma omp declare target extern void fib(int N); #pragma omp end declare target #define THRESHOLD 1000000 void fib_wrapper(int n) { #pragma omp target if(n > THRESHOLD) { fib(n); ...
bp.h
#pragma once #include <stdint.h> #include <algorithm> #include <functional> #include <memory> #include <boost/endian/conversion.hpp> #include "ecc.h" #include "misc.h" #include "multiexp.h" #include "tick.h" namespace bp { namespace detail { inline size_t PackGCount(size_t count) { assert(cou...
prob2.c
#include <stdio.h> #include <stdint.h> #include <stdlib.h> #include <time.h> #include <omp.h> int32_t main() { size_t n = 10000000; clock_t tic, toc; // The usual reduction tic = clock(); size_t sum1 = 0; #pragma omp parallel for num_threads( 8 ) reduction(+:sum1) for( size_t i = 0; i < n;...
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) #...
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...
gt.filter.c
/* * PROJECT: GEM-Tools library * FILE: gt.filter.c * DATE: 02/08/2012 * AUTHOR(S): Santiago Marco-Sola <santiagomsola@gmail.com> * DESCRIPTION: Application to filter {MAP,SAM,FASTQ} files and output the filtered result */ #ifdef HAVE_OPENMP #include <omp.h> #endif #include "gem_tools.h" #define GT_FILTER_FLOAT...
GB_unop__identity_fp64_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...
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) ...
cp-tree.h
/* Definitions for C++ parsing and type checking. Copyright (C) 1987-2020 Free Software Foundation, Inc. Contributed by Michael Tiemann (tiemann@cygnus.com) This file is part of GCC. GCC is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by ...
ompt.h
/* * include/45/ompt.h.var */ #ifndef __OMPT__ #define __OMPT__ /***************************************************************************** * system include files *****************************************************************************/ #include <stdint.h> /********************************************...
evolve.c
#include <tgmath.h> #include <stdio.h> #include <stdlib.h> #ifdef _OPENMP #include <omp.h> #endif #include "evolve.h" #include "evolve_shared.h" #include "evolve_shared_collisions.h" #include "evolve_sf.h" #include "evolve_cc.h" #include "evolve_kepler.h" #include "evolve_ok.h" #include "evolve_bs.h" #ifdef EVOLVE_OPE...
3d25pt_var.c
/* * Order-1, 3D 25 point stencil with axis-symmetric ariable 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) >...
get_visibilities.c
#include <math.h> #include <complex.h> #include <stdio.h> #include <omp.h> void getvis(int nf, int nbl, int nsource, double *f, double *ux, double *uy, double *source_flux, double *l, double *m, int nthreads, double complex *vis){ /* Generate visibilities from a list of point sources and thei...
matmul_para.c
/* Generated by Cython 0.15.1 on Mon Feb 11 15:34:06 2013 */ #define PY_SSIZE_T_CLEAN #include "Python.h" #ifndef Py_PYTHON_H #error Python headers needed to compile C extensions, please install development version of Python. #else #include <stddef.h> /* For offsetof */ #ifndef offsetof #define offsetof(type, mem...
GB_unop__identity_int32_uint8.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_kroner.c
//------------------------------------------------------------------------------ // GB_kroner: Kronecker product, C = kron (A,B) //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-License-Identifier: A...
DRB029-truedep1-orig-yes.c
/* Copyright (C) 1991-2018 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it andor modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the L...
num_diff.h
#if !defined(__num_diff_h) #define __num_diff_h /* Library for numerical differentiation. Derivative in j direction: partial_j f'(x) = 1/h_j sum_{i=1}^n a_i f(x + b_i*h_j e_j) + A h_j^p f^{(p+1)}(c) direction: x in T^d e_j = ( delta_{kj} )_{k=1}^d Ref: * http:...
targc-272328.c
struct test_type { int *p1; } tt; #include "stdlib.h" #include "stdio.h" int C[10]; int main() { int i; int *p; tt.p1 = (int*) malloc(10*sizeof(int)); p=tt.p1; for (i=0; i<10; i++) { tt.p1[i] = i+100; C[i] = 0; } #pragma omp target map(tofrom: C) map(to: tt,...
transfer.c
/** @file transfer.c Documented transfer module. * * Julien Lesgourgues, 28.07.2013 * * This module has two purposes: * * - at the beginning, to compute the transfer functions \f$ * \Delta_l^{X} (q) \f$, and store them in tables used for * interpolation in other modules. * * - at any time in the code, to ...
GB_unaryop__ainv_fp64_uint16.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
gemm.c
/** * gemm.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@students.ic...
UAS.c
#include <stdio.h> #include <string.h> #include <stdlib.h> #include <errno.h> #include <omp.h> //Inisialisasi linked list, dibuat oleh rionaldi struct data { char nama[20]; int umur; char alamat[30]; int urutan; struct data * next; }; //prototype dari function encoding dan decoding void encoding(int k,struc...
GB_binop__cmplx_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...
gauss-seidel.c
/* * Copyright (c) 2018 Maxime Schmitt <max.schmitt@unistra.fr> * * 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 conditi...
9125.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...
transform.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
pr39591-2.c
/* PR other/39591 */ /* { dg-do run } */ /* { dg-options "-O2" } */ extern void abort (void); int err; void __attribute__((noinline)) foo (int *array) { #pragma omp task { int j; for (j = 0; j < sizeof array / sizeof array[0]; j++) if (array[j] != 0x55555555) #pragma omp atomic err++; } } int mai...
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_unop__identity_int8_fc64.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http://...
loop_multiple_variables_omp.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> int main() { int* a = (int*)malloc(sizeof(int)*4); int* b = (int*)malloc(sizeof(int)*4); a[0] = 0; a[1] = 1; a[2] = 2; a[3] = 3; #pragma omp parallel for { for(int i = 0; i < 4; i++) { b[i] = a[i]; ...
GB_msort_2b.c
//------------------------------------------------------------------------------ // GB_msort_2b: sort a 2-by-n list of integers, using A[0:1][ ] as the key //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. //...
DRB046-doall2-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...
s_aatritemp.h
/* * Mesa 3-D graphics library * * Copyright (C) 1999-2007 Brian Paul All Rights Reserved. * * 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 l...
lexer.c
#include <stdlib.h> #include <string.h> #include <ctype.h> #include <stdio.h> #include <math.h> #include "lexer.h" static char OPERATOR_CHARS[] = { '+', '-', '*', '/', '^', '=', '|', '&', '~', ':', '%', '<', '>', '?', '!' }; static char* OPERATOR_LIST[] = { "++", "--", "+=", "-=", "*=", "/=", "^=", "<=", ">=", ...
__clang_openmp_device_functions.h
/*===- __clang_openmp_device_functions.h - OpenMP device function declares -=== * * 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 * *===----------------------------...
DRACC_OMP_026_MxV_Missing_Exit_Data_yes.c
/* Matrix Vector multiplication without copying back the result c, while utilising the enter data construct. */ #include <stdio.h> #include <stdbool.h> #include <stdlib.h> #define C 512 int *a; int *b; int *c; int init(){ for(int i=0; i<C; i++){ for(int j=0; j<C; j++){ b[j+i*C]=1; } ...
picolrn.c
/* * This code is released under the MIT License. * Copyright (c) 2013 Nenad Markus */ #include <stdio.h> #include <malloc.h> #include <math.h> #include <stdint.h> #include <omp.h> // hyperparameters #define NRANDS 1024 /* auxiliary stuff */ #define MAX(a, b) ((a)>(b)?(a):(b)) #define MIN(a, b) ((a)<(b)?(a):...
mapreduce_wc.c
/* Suggested makefile: ---------- P=mapreduce_wc objects=string_utilities.o CFLAGS=`pkg-config --cflags glib-2.0` -g -Wall -std=gnu99 -O3 -fopenmp LDLIBS=`pkg-config --libs glib-2.0` -fopenmp $(P): $(objects) ---------- */ #include "stopif.h" #include "wordcount.c" int main(int argc, char **argv){ argc--; arg...
StmtOpenMP.h
//===- StmtOpenMP.h - Classes for OpenMP directives ------------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
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)...
vector.c
/*BHEADER********************************************************************** * Copyright (c) 2008, Lawrence Livermore National Security, LLC. * Produced at the Lawrence Livermore National Laboratory. * This file is part of HYPRE. See file COPYRIGHT for details. * * HYPRE is free software; you can redistribute...
agent_uid_map.h
// ----------------------------------------------------------------------------- // // Copyright (C) The BioDynaMo Project. // 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. // // See the LICENSE file distrib...
Efficient_RANSAC.h
// Copyright (c) 2015 INRIA Sophia-Antipolis (France). // All rights reserved. // // This file is part of CGAL (www.cgal.org). // 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 of the License, or (at your op...
RCCE_lib_pwr.h
// // Copyright 2010 Intel Corporation // // 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 applica...
TransferFunction.h
#ifndef TRANSFERTFUNCTION_INC #define TRANSFERTFUNCTION_INC #include <cstdint> #include <cstdlib> #include "SciVisColor.h" #include <algorithm> #include <vector> #ifdef _OPENMP #include <omp.h> #endif namespace sereno { /** \brief Basic class for transfer function computation */ class TF { pub...
bli_trsm_ref.c
/* BLIS An object-based framework for developing high-performance BLAS-like libraries. Copyright (C) 2014, The University of Texas at Austin Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - Redist...
GB_unop__identity_uint16_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...
parallel-firstprivate.c
/* * parallel-firstprivate.c -- Archer testcase */ //===----------------------------------------------------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // // See tools/archer/LICENSE.txt for details. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exce...
bml_trace_dense_typed.c
#ifdef BML_USE_MAGMA #include "magma_v2.h" #endif #include "../../macros.h" #include "../../typed.h" #include "../blas.h" #include "../bml_logger.h" #include "../bml_parallel.h" #include "../bml_trace.h" #include "../bml_types.h" #include "bml_trace_dense.h" #include "bml_types_dense.h" #include <complex.h> #include ...
GB_sparse_masker_template.c
//------------------------------------------------------------------------------ // GB_sparse_masker_template: R = masker (C, M, Z) where R is sparse/hyper //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. /...
CRC64.h
/* * Copyright (C) 2015, UChicago Argonne, LLC * All Rights Reserved * * Generic IO (ANL-15-066) * Hal Finkel, Argonne National Laboratory * * OPEN SOURCE LICENSE * * Under the terms ...