source
stringlengths
3
92
c
stringlengths
26
2.25M
sync.c
/* * Copyright (c) 2009, 2010, 2011, ETH Zurich. * All rights reserved. * * This file is distributed under the terms in the attached LICENSE file. * If you do not find this file, copies can be found by writing to: * ETH Zurich D-INFK, Universitaetstrasse 6, CH-8092 Zurich. Attn: Systems Group. */ #include <stdl...
glove_cython.c
/* Generated by Cython 0.23.4 */ /* BEGIN: Cython Metadata { "distutils": { "depends": [], "extra_compile_args": [ "-fopenmp", "-ffast-math", "-march=native" ], "extra_link_args": [ "-fopenmp" ] } } END: Cython Metadata...
compute_pi.c
/* Example that uses the composite for simd construct The numerical solution for integration has a compute-intensive loop that is parallelized and vectorized. */ double compute_pi(int n) { const double dH = 1.0 / (double) n; double dX, dSum = 0.0; #pragma omp parallel for simd private(dX) \ ...
generator_gemm_common.c
/****************************************************************************** * Copyright (c) Intel Corporation - All rights reserved. * * This file is part of the LIBXSMM library. * * * ...
remarks_parallel_in_multiple_target_state_machines.c
// RUN: %clang_cc1 -verify=host -Rpass=openmp-opt -Rpass-analysis=openmp-opt -fopenmp -x c++ -triple powerpc64le-unknown-unknown -fopenmp-targets=nvptx64-nvidia-cuda -emit-llvm-bc %s -o %t-ppc-host.bc // RUN: %clang_cc1 -verify=all,safe -Rpass=openmp...
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) ...
relu6_ref.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...
MatriplexSym.h
#ifndef RecoTracker_MkFitCore_src_Matriplex_MatriplexSym_h #define RecoTracker_MkFitCore_src_Matriplex_MatriplexSym_h #include "MatriplexCommon.h" #include "Matriplex.h" //============================================================================== // MatriplexSym //=================================================...
statistic.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
GB_unop__identity_int8_uint32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http://...
0fb71d8c99a5efbcd5cf722837fd0590c524be99.c
#define _POSIX_C_SOURCE 200809L #include "stdlib.h" #include "math.h" #include "sys/time.h" #include "xmmintrin.h" #include "pmmintrin.h" #include "omp.h" struct dataobj { void *restrict data; int * size; int * npsize; int * dsize; int * hsize; int * hofs; int * oofs; } ; struct profiler { double sect...
matrix.c
#include <stdio.h> #include <omp.h> #define SIZE 1000 int a[SIZE][SIZE],b[SIZE][SIZE],res_seq[SIZE][SIZE],res_parallel[SIZE][SIZE]; void seq_matmul(int a[][SIZE],int b[][SIZE]) { int i,j,k; for(i=0;i<SIZE;++i) { for(j=0;j<SIZE;++j) { res_seq[i][j]=0; for(k=0;k<SIZE;++k) { res_seq[i][j] = res_seq[...
GB_binop__lt_fp64.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
random_par.c
//********************************************************** // Parallel Pseudo random number generator: // // USAGE: // // The pseudo random sequence is seeded with a range // // void seed(lower_limit, higher_limit) // // and then subsequent calls to the random number generator // generat...
create_from_mesh.h
// Copyright (c) 2017, The OctNet authors // 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 ...
graph_gen.c
#include <stdio.h> #include <stdlib.h> #include <assert.h> #include <string.h> #include <math.h> #ifdef _OPENMP #include "omp.h" #endif #if USE_MPI #include "mpi.h" #endif #include "graph.h" #include "RngStream.h" #define NPROCBINS 1 #define TIME_GRAPHGEN_STEPS 1 #define DEBUG_GRAPHGEN_VERBOSE 0 #define GRAPHGEN_RNG_...
nr_numint.c
/* * Author: Qiming Sun <osirpt.sun@gmail.com> */ #include <stdlib.h> #include <stdio.h> #include <string.h> #include "cint.h" #include "gto/grid_ao_drv.h" #include "np_helper/np_helper.h" #include "vhf/fblas.h" #include <assert.h> #define BOXSIZE 56 int VXCao_empty_blocks(char *empty, unsigned char *non0t...
simple_prof_c.c
/* * Copyright (c) 2015 - 2021, 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 condition...
convolution_3x3_pack8_fp16s.h
// Tencent is pleased to support the open source community by making ncnn available. // // Copyright (C) 2020 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 ...
GB_binop__bset_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:...
GB_unop__identity_fc64_uint16.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...
7248.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...
OpenMP_C.c
#include<stdio.h> int main( int ac, char **av) { #pragma omp parallel // specify the code between the curly brackets is part of an OpenMP parallel section. { printf("Hello World!!!\n"); } return 0; }
set_constants.c
//-------------------------------------------------------------------------// // // // This benchmark is a serial C version of the NPB BT code. This C // // version is developed by the Center for Manycore Programming at Seoul // // Nati...
GB_unop__minv_uint64_uint64.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...
_helpers.c
#include "_helpers.h" #include "../CDelta.h" #include "../XArray.h" #include "../utils.h" #define NO_IMPORT_ARRAY #include "../DQarrayobject.h" #include <math.h> /** * Update the positions of an array of fallers (periodic boundary * conditions). */ #define FUNCTION_NAME FallerArray_move #define BEGIN_ITER_CODE #d...
pt_to_pt_multiPingpong.c
/***************************************************************************** * * * Mixed-mode OpenMP/MPI MicroBenchmark Suite - Version 1.0 * * * * ...
Sieve.c
#include <sys/types.h> #include <string.h> #include <stdio.h> #include <stdlib.h> #include "hif.h" #define NSRCH 100 int a_declaration; main() { char *prime; int i; pers_attach(); prime = (char *) malloc(NSRCH*sizeof(prime)); memset(prime,1,NSRCH*sizeof(prime)); #pragma omp target { for(i=2;i<NSRCH;...
ClusterCreator.h
// class for running clustering algorithm on Charts struct ClusterCreator { // takes a chart id map that was created by grid/octree clusters, and creates a list of Chart objects static uint32_t create_chart_clusters_from_grid_clusters( Polyhedron& P, const double cost_threshold, const uint32_t chart_thr...
GB_binop__times_fc32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
CanonNE.c
#include <stdio.h> #include <omp.h> int main() { int numTeams=12800; int foo = 0; #pragma omp target teams distribute parallel for for (int j=0; j != numTeams; j++) { foo++; } printf("%d\n",foo); return 0; }
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 // //===---------------------------...
dpx.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
cpu_adam.h
#pragma once #include <cuda_fp16.h> #include <cuda_runtime_api.h> #include <stdio.h> #include <cassert> #include "cuda.h" #include "custom_cuda_layers.h" #include "simd.h" #define STEP(SPAN) \ void Step_##SPAN(float* _params, \ float* grads, ...
variational_distance_calculation_process.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: Riccardo Rossi // Ruben Zorrill...
carro.c
#include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <time.h> #include <omp.h> #include "carro.h" #include "client.h" static int messages = 0, empty = 0, brake = 0, throttle = 0, ambulance = 0; int security_manager(char * msg, Car * car) { // 0 - nenhum comando / manter // 1 - freie // 2 -...
oned_csr.c
/* Copyright (C) 2010-2011 The Trustees of Indiana University. */ /* */ /* Use, modification and distribution is subject to the Boost Software */ /* License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at */ /* http:...
GB_unop__identity_uint32_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_unaryop__minv_int32_int32.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_binop__ne_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-...
rowcolsum.c
#include <stdio.h> #include <omp.h> int main() { int N,i,j,chunk,nthreads; // printf("Enter the no of rows and columns: \n"); scanf("%d",&N); int a[N][N], rowSum[N],colSum[N]; // printf("Enter the matrix: \n"); for(i=0; i<N; i++) { for(j=0; j<N; j++) { scanf("%d",&a[i][j]); } } for(i=0;i<N;i++) { ...
valid.yolo8.src.h
#pragma once #include "ukr.h" #include "omp.h" #include "transpose.h" #include "gen_ukr_A6B2gemm_1_256_34_34_512_1_1.h" #include "gen_ukr_A4B2gemm_1_256_34_34_512_1_1.h" void testrun(float* A ,float*B, float*C, float*oriB ){ int tid = omp_get_thread_num(); int Nx = 34; int Ny = 34; int Nh = 1; long long...
masterSingle.c
#include <omp.h> int main (void) { int a,b; #pragma omp parallel { #pragma omp master a=a+1; #pragma omp single b=b+1; } return 0; }
pr58472.c
/* PR tree-optimization/58472 */ /* { dg-do compile } */ /* { dg-options "-O2 -Wall -fopenmp" } */ float a[1024], b[1024]; float foo () { float s = 0.f; unsigned int i; #pragma omp simd reduction(+:s) for (i = 0; i < 1024; ++i) s += a[i] * b[i]; return s; }
perft.h
// perft.h - PIGEON CHESS ENGINE (c) 2012-2016 Stuart Riffle namespace Pigeon { #ifndef PIGEON_PERFT_H__ #define PIGEON_PERFT_H__ struct Perft { static void GatherPerftParallelPositions( const Position& pos, int depth, std::vector< Position >* dest ) { MoveList valid; valid.FindMoves( ...
root-threads-affinity.c
// RUN: %libomp-compile && env LIBOMP_NUM_HIDDEN_HELPER_THREADS=0 OMP_PROC_BIND=close OMP_PLACES=cores KMP_AFFINITY=verbose %libomp-run 8 1 4 // REQUIRED: linux // // This test pthread_creates 8 root threads before any OpenMP // runtime entry is ever called. We have all the root threads // register with the runtime by ...
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 ...
3d7pt_var.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 with variable coefficients * Adapted from PLUTO and Po...
st_naive_up.c
#include <stdlib.h> #include <stdio.h> #include <math.h> #include <sys/time.h> #include <omp.h> /* multiprocessor support */ //#include "../PaulSwissPNG/png/mypng.h" #include "mypng.h" /***********************************************************************/ double* SteepestTangent(const uint8 *Image, const size_t N...
GB_unop__identity_int64_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...
Example_device.2.c
/* * @@name: device.2c * @@type: C * @@compilable: yes * @@linkable: no * @@expect: success * @@version: omp_4.0 */ #include <omp.h> extern void init(float *, float *, int); extern void output(float *, int); void vec_mult(float *p, float *v1, float *v2, int N) { int i; init(v1, v2, N); int ndev = omp_get_num_d...
GB_unop__ainv_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...
data.h
/*! * Copyright (c) 2015-2021 by Contributors * \file data.h * \brief The input data structure of xgboost. * \author Tianqi Chen */ #ifndef XGBOOST_DATA_H_ #define XGBOOST_DATA_H_ #include <dmlc/base.h> #include <dmlc/data.h> #include <dmlc/serializer.h> #include <xgboost/base.h> #include <xgboost/host_device_vec...
gi_ondemand_accurate_grad_builder.h
/* * * Copyright (C) 2018 Attila Gyulassy <jediati@sci.utah.edu> * All rights reserved. * * This software may be modified and distributed under the terms * of the BSD license. See the LICENSE file for details. */ #ifndef ONDEMAND_ACCURATE_GRAD_BUILDER_H #define ONDEMAND_ACCURATE_GRAD_BUILDER_H #include <vector> #i...
GB_binop__first_int64.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http:...
krb5pa-md5_fmt_plug.c
/* * Kerberos 5 etype 23 "PA ENC TIMESTAMP" by magnum * * Previously called mskrb5 because I had the idea it was Micro$oft specific. * * Pcap file -> input file: * 1. tshark -r capture.pcapng -T pdml > ~/capture.pdml * 2. krbng2john.py ~/capture.pdml > krb5.in * 3. Run john on krb5.in * * PA_DATA_ENC_TIMESTA...
omp6.c
// note not doing O0 below as to ensure we get tbaa // TODO: %clang -fopenmp -std=c11 -fno-vectorize -fno-unroll-loops -O1 -disable-llvm-optzns %s -S -emit-llvm -o - | %opt - %loadEnzyme -enzyme -S | %clang -fopenmp -x ir - -o %s.out && %s.out // TODO: if [ %llvmver -ge 9 ]; then %clang -fopenmp -std=c11 -fno-vectori...
core_sgeadd.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/core_blas/core_zgeadd.c, normal z -> s, Fri Sep 28 17:38:18 2018 * **/ #include <plasma_core_blas.h> #include "pla...
kgraph-data.h
#ifndef WDONG_KGRAPH_DATA #define WDONG_KGRAPH_DATA #include <cmath> #include <cstring> #include <cstdlib> #include <vector> #include <fstream> #include <stdexcept> #include <boost/assert.hpp> #ifdef __GNUC__ #ifdef __AVX__ #define KGRAPH_MATRIX_ALIGN 32 #else #ifdef __SSE2__ #define KGRAPH_MATRIX_ALIGN 16 #else #def...
single_value.c
#include <stdio.h> #include <omp.h> int main() { int x = 0; #pragma omp parallel { int y = x; printf("Y: %d\n", y); if(omp_get_thread_num() == 0) { x = 42; } } printf("X: %d\n", x); }
4103.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...
quantize.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
BSplineFFD.h
/** \file BSplineFFD.h \brief Class for BSpline FreeFormDeformation \author Hui Xue */ #pragma once #include "FFDBase.h" namespace Gadgetron { template <typename T, typename CoordType, unsigned int DIn, unsigned int DOut> class BSplineFFD : public FFDBase<T, CoordType, DIn, DOut> { public: ...
GB_unaryop__identity_uint16_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...
GB_unop__identity_uint8_bool.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...
dot_product.c
/* reduction Clause Example */ #include <omp.h> main(int argc, char *argv[]) { int i, n, chunk; float a[100], b[100], result; /* Some initializations */ n = 100; chunk = 10; result = 0.0; for (i=0; i < n; i++) { a[i] = i * 1.0; b[i] = i * 2.0; } #pragma omp parallel for ...
depthwise_convolution_5x5.c
/* * Copyright (C) 2016-2022 T-Head Semiconductor Co., Ltd. All rights reserved. * * SPDX-License-Identifier: Apache-2.0 * * 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 * * www.apache....
pbkdf2-hmac-md4_fmt_plug.c
/* * This software is Copyright (c) 2015 magnum and it is hereby released to * the general public under the following terms: * Redistribution and use in source and binary forms, with or without * modification, are permitted. */ #if FMT_EXTERNS_H extern struct fmt_main fmt_pbkdf2_hmac_md4; #elif FMT_REGISTERS_H jo...
DRB032-truedepfirstdimension-var-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...
pst_search.c
#include <omp.h> #include <string.h> #include "tldevel.h" #include "tlrng.h" #include "tlseqio.h" #include "tlmisc.h" #include "tlalphabet.h" #include "pst.h" #include "pst_structs.h" #include "pst_hash.h" #include "search_db.h" #define PST_SEARCH_IMPORT #include "pst_search.h" static int copy_sequences(struct tl...
GB_unop__identity_uint32_fc64.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...
main.c
// this creates an input device transform (idt) lookup table for a given camera // based on spectral sensitivity functions (ssf). works best with a high-res // high-quality spectral upsampling table, create via // `mkspectra 1024 /dev/null XYZ`. (note the lack of `-b`) // #define USE_LEVMAR #include "core/inpaint.h" #i...
par_map.h
#pragma once #include "Defs.h" template <typename T> void par_fill(T* dest, int w, int h, const T value) { #pragma omp parallel for for (int y = 0; y < h; y++) { for (int x = 0; x < w; x++) { const int idx = y * w + x; dest[idx] = value; } } } template <typename T> void par_map(T* src, T* dest, int w, in...
CTensor.h
// CTensor // A three-dimensional array // // Author: Thomas Brox #ifndef CTENSOR_H #define CTENSOR_H #include <iostream> #include <fstream> #include <string> #include <sstream> #include <stdexcept> #include "CMatrix.h" #include "NMath.h" #ifdef HAVE_PNG #include <png.h> #endif template <class T> class CTensor { pu...
atomic_write_codegen.c
// RUN: %clang_cc1 -verify -triple x86_64-apple-darwin10 -target-cpu core2 -fopenmp -x c -emit-llvm %s -o - | FileCheck %s // RUN: %clang_cc1 -fopenmp -x c -triple x86_64-apple-darwin10 -target-cpu core2 -emit-pch -o %t %s // RUN: %clang_cc1 -fopenmp -x c -triple x86_64-apple-darwin10 -target-cpu core2 -include-pch %t ...
GB_binop__eq_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-...
ConvolutionUnfold.h
#pragma once #include <string.h> #include <math.h> #include <algorithm> #include "General.h" #include "TensorRef.h" #include "Vector-inl.h" OPS_API int TS_Unfolded_Copy( TensorRef* finput, TensorRef* input, int kW, int kH, int dW, int dH, int padW, int padH, int nInputPlane, int inputWidth, int inputHeig...
GB_kroner.c
//------------------------------------------------------------------------------ // GB_kroner: Kronecker product, C = kron (A,B) //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http://suitesparse.com S...
common.h
/*! * Copyright (c) 2016 Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See LICENSE file in the project root for license information. */ #ifndef LIGHTGBM_UTILS_COMMON_H_ #define LIGHTGBM_UTILS_COMMON_H_ #if ((defined(sun) || defined(__sun)) && (defined(__SVR4) || defined(__svr4__))) #...
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 // //===---------------------------...
office_fmt_plug.c
/* Office 2007 cracker patch for JtR. Hacked together during March of 2012 by * Dhiru Kholia <dhiru.kholia at gmail.com> */ #if FMT_EXTERNS_H extern struct fmt_main fmt_office; #elif FMT_REGISTERS_H john_register_one(&fmt_office); #else #include <stdio.h> #include <stdlib.h> #include <string.h> #include <assert.h> #...
GB_binop__isle_fp64.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
omp_init_lock.c
// RUN: %libomp-compile-and-run #include "omp_testsuite.h" #include <stdio.h> // This should be slightly less than KMP_I_LOCK_CHUNK, which is 1024 #define LOCKS_PER_ITER 1000 #define ITERATIONS (REPETITIONS + 1) // This tests concurrently using locks on one thread while initializing new // ones on another thread. Th...
blake2bp.c
/* BLAKE2 reference source code package - optimized 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 Univers...
dragonfly4_fmt_plug.c
/* * This file is part of John the Ripper password cracker, * based on rawSHA256_fmt.c code * * This software is Copyright (c) 2012 magnum, and it is hereby released to the * general public under the following terms: Redistribution and use in source * and binary forms, with or without modification, are permitted...
Example_collapse.1.c
/* * @@name: collapse.1c * @@type: C * @@compilable: yes * @@linkable: no * @@expect: success * @@version: omp_3.0 */ void bar(float *a, int i, int j, int k); int kl, ku, ks, jl, ju, js, il, iu,is; void sub(float *a) { int i, j, k; #pragma omp for collapse(2) private(i, k, j) for (k=kl; k<=ku; k+=ks) ...
DRB009-lastprivatemissing-orig-yes.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...
threshold.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
symv_x_coo_u_hi.c
#include "alphasparse/kernel.h" #include "alphasparse/kernel_plain.h" #include "alphasparse/opt.h" #include "alphasparse/util.h" #include <string.h> #ifdef _OPENMP #include <omp.h> #endif static alphasparse_status_t symv_coo_u_hi_omp(const ALPHA_Number alpha, const ALPHA_SPMAT_COO *A, const ALPHA_Number *...
3d25pt_var.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 25 point stencil with axis-symmetric ariable coefficients * Adapted fr...
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...
tsp_rnd04.c
/* Description: This program executes my "Random Swapping" algorithm to solve the "Travelling Salesman Problem" Author: Georgios Evangelou (1046900) Year: 5 Parallel Programming in Machine Learning Problems Electrical and Computer Engineering Department, University of Patras System Specifications...
embedded_skin_utility.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: Ruben Zorrilla // #if !define...
coreMP.c
/** * @file coreMP.c * @author Chris Rebbelin s0548921 * @date 2018-07-01 * @brief Contains the main calculation logic for the wave * * @details This file implements the main calculation logic for the wave. */ #include <omp.h> #include "coreMP.h" // time step arrays double *previousStep, *currentStep, *nextSt...
mat_mul_blocks.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <omp.h> struct matrix { int ncols; int nrows; double* mat; }; #define BLOCKSIZE 64 void readMatrix(double** m, FILE* file, int rows, int cols); void printMatrix(double** m, FILE* file, int rows, int cols); void matrixMul(int BS, double** m1, doub...
target_data_messages.c
// RUN: %clang_cc1 -triple x86_64-apple-macos10.7.0 -verify -fopenmp -ferror-limit 100 -o - %s -Wuninitialized // RUN: %clang_cc1 -triple x86_64-apple-macos10.7.0 -verify -fopenmp-simd -ferror-limit 100 -o - %s -Wuninitialized void foo() { } void xxx(int argc) { int map; // expected-note {{initialize the variable ...
GB_binop__bxnor_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-...
sp.c
//-------------------------------------------------------------------------// // // // This benchmark is a serial C version of the NPB SP code. This C // // version is developed by the Center for Manycore Programming at Seoul // // Nati...
ast-dump-openmp-taskgroup.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(void) { #pragma omp taskgroup ; } // CHECK: TranslationUnitDecl {{.*}} <<invalid sloc>> <invalid sloc> // CHECK: `-FunctionDecl {{.*}} <{{.*}}ast-dump-openm...
main.c
#include <assert.h> #include <inttypes.h> #include <stdio.h> #include <stdlib.h> #include <sys/stat.h> #include <CL/cl.h> #include <omp.h> #define MAX_GPU 4 // maximum allowed gpu numbers #define MAX_CASES 10000 // maximum cases to process #define BLK_SIZE 256 // local buffer size #define BATCH_S...