source
stringlengths
3
92
c
stringlengths
26
2.25M
decorate.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
GB_unaryop__ainv_int8_fp64.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http...
omp_taskloop_grainsize.c
// RUN: %libomp-compile-and-run // RUN: %libomp-compile && env KMP_TASKLOOP_MIN_TASKS=1 %libomp-run // These compilers don't support the taskloop construct // UNSUPPORTED: gcc-4, gcc-5, icc-16 // GCC 6 has support for taskloops, but at least 6.3.0 is crashing on this test // UNSUPPORTED: gcc-6 /* * Test for taskloop...
poismf.c
/* Poisson Factorization for sparse matrices Based on alternating proximal gradient iteration or conjugate gradient. Variables must be initialized from outside the main function ('run_poismf'). Writen for C99 standard and OpenMP 2.0 or later. Reference paper is: Cortes, David. "Fa...
spotfit.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <math.h> #include "pix.h" /*------------------------------------------------------------------------- * * Functions to fit the image pixels to locate spot coordinate. * *------------------------------------------------------------------------*/ type...
GB_unaryop__identity_uint8_uint8.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
image_random-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 may no...
w9_e2_errors.c
#include <stdlib.h> #include <stdio.h> #include <omp.h> int main(int argc, char const *argv[]) { int i, N=100000; double *u = malloc(N * sizeof *u); double *v = malloc(N * sizeof *v); for (i=0; i<N; i++) { u[i] = 0.001*(i - N/2); } v[0] = u[0]; v[N-1] = u[N-1]; #pragma omp ...
feature.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
StomOmpc_02.c
/* poe -rmpool 1 -procs 1 mpcc_r -qsmp=noauto:omp:explicit -O3 -qarch=pwr3 -qtune=pwr3 ompc_02.c bind.o -lm -o ompc_02 */ #define FLT double #define INT int #include "mpi.h" #include <stdlib.h> #include <stdio.h> #include <time.h> #include <math.h> #if macintosh #include <console.h> #endif FLT **matrix(INT nrl,INT nr...
SpatialConvolutionLocal.c
#ifndef TH_GENERIC_FILE #define TH_GENERIC_FILE "generic/SpatialConvolutionLocal.c" #else static inline void THNN_(SpatialConvolutionLocal_shapeCheck)( THTensor *input, THTensor *gradOutput, THTensor *weight, THTensor *bias, int kH, int kW, int dH, int dW, int padH, int padW, int64_t inputHeight, i...
mandel_par.c
/* ** PROGRAM: Mandelbrot area (solution) ** ** PURPOSE: Program to compute the area of a Mandelbrot set. ** The correct answer should be around 1.510659. ** ** USAGE: Program runs without input ... just run the executable ** ** ADDITIONAL EXERCISES: Experiment with the schedule clause to fix ...
vecops.c
/* Copyright 2013-2015. The Regents of the University of California. * Copyright 2016. Martin Uecker. * Copyright 2017. University of Oxford. * All rights reserved. Use of this source code is governed by * a BSD-style license which can be found in the LICENSE file. * * Authors: * 2011-2016 Martin Uecker <martin....
DRB011-minusminus-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...
irbuilder_nested_openmp_parallel_empty.c
// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py // RUN: %clang_cc1 -verify -fopenmp -fopenmp-enable-irbuilder -x c++ -emit-llvm %s -triple x86_64-unknown-unknown -fexceptions -fcxx-exceptions -o - | FileCheck %s --check-prefixes=ALL,IRBUILDER // %clang_cc1 -fopenmp -fopenmp-enable-irbuild...
variable_utils.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: Riccardo Rossi // Ruben Zorrill...
nn07.c
/* Description: This program implements a Neural Network of one hidden and one output layer Abides by Lab 5 Exercise 4 requirements Author: Georgios Evangelou (1046900) Year: 5 Parallel Programming in Machine Learning Problems Electrical and Computer Engineering ...
sum_int.c
//sum.c #include <stdio.h> #include <stdlib.h> #include <time.h> #include <sys/timeb.h> #include <malloc.h> #define N_RUNS 1000 #define N 120000 // read timer in second double read_timer() { struct timeb tm; ftime(&tm); return (double) tm.time + (double) tm.millitm / 1000.0; } //Create a matrix and a vec...
GB_unaryop__one_int8_int8.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
08 - openMP.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> #define SIZE_GAU 8 #define SIZE_JVL 15 int JAVA_COUNT = SIZE_JVL; omp_lock_t table; omp_lock_t hungry; void replaceJAVALIS() { omp_set_lock(&table); JAVA_COUNT = SIZE_JVL; printf(" < The Cooker Made his Magic n Replace All The Java's >\n\n"); omp_uns...
axpy_float.c
//axpy.c #include <stdio.h> #include <stdlib.h> #include <time.h> #include <sys/timeb.h> #include <malloc.h> #define N_RUNS 20 #define N 102400000 // read timer in second double read_timer() { struct timeb tm; ftime(&tm); return (double) tm.time + (double) tm.millitm / 1000.0; } //Create a matrix and a v...
GB_unaryop__lnot_bool_uint8.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http...
convolution_3x3_pack8to4_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 copy ...
matrix.c
// // Created by Javier Peralta on 9/16/17. // #include "matrix.h" //#include <omp.h> void vectorScalar (double *v, double d, int size){ for(int i = 0; i < size; ++i ){ v[i] *= d; } } void restaVector(double *v1, double *v2, double* out, int size){ //#pragma omp parallel for for(int i = 0; i < size; ++i ){ ...
GB_binop__bor_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-...
GB_subassign_04.c
//------------------------------------------------------------------------------ // GB_subassign_04: C(I,J) += A ; using S //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http://suitesparse.com See Gra...
convolution_3x3_pack8to1_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 ...
measure.c
#include <stdio.h> #include <stdlib.h> #include <stdbool.h> #include <string.h> #include <assert.h> #include <math.h> #include <sys/time.h> #include <omp.h> int collapse_cluster(FILE *input_fptr, FILE *output_fptr, int rank, int subcircuit_idx, int num_instance, int cluster_circ_size, int **correspondece_map, int num_...
verlet_stream_and_noise.c
#include "cloud.h" #include "verlet.h" void verlet_step_stream_and_noise (int Np, double dt_stream, double dt_noise, cse6230rand_t *rand, double *restrict X[3], const double *restrict U[3]) { if (dt_noise) { size_t tag; tag = cse6230rand_get_tag (...
gradfm_adj_mex.c
#include <inttypes.h> #include <omp.h> #include "mex.h" void gradfm_adjf(float *du, const float *x, const float *y, const float *z, const uint8_t *G, const double *h, const size_t *sz); void gradfm_adjd(double *du, const double *x, const double *y, const double *z, ...
main.h
#ifndef _MAIN_CK_H #define _MAIN_CK_H #include <util/time_cps.h> #include <alg/a2a/grid_lanczos.h> #include <alg/ktopipi_jobparams.h> //Useful functions for main programs CPS_START_NAMESPACE void ReadGaugeField(const MeasArg &meas_arg, bool double_latt = false){ double time = -dclock(); const char *cname = "main...
CoarseAndFine.c
#include <omp.h> #include <stdio.h> #include <math.h> #include<stdlib.h> #define ArraySize 32678 float Array[ArraySize]; float Ranf(float min, float max) { return min + (((float) rand() * (max-min))/ (float) (RAND_MAX)); } int main( int argc, char *argv[ ] ) { int i,j; double prod; omp_set_num_threads( NUMT );...
mkl_util.h
/* Copyright 2017 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 ...
GB_unop__tanh_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...
mea_pb_traco.c
#include <stdio.h> #include <stdlib.h> #include <limits.h> #include <omp.h> #include <math.h> #define min(a,b) (((a)<(b))?(a):(b)) #define MIN(a,b) (((a)<(b))?(a):(b)) #define max(a,b) (((a)>(b))?(a):(b)) #define MAX(a,b) (((a)>(b))?(a):(b)) #define floord(n,d) floor(((double)(n))/((double)(d))) #define ceild(n,d) ce...
filter.c
#ifndef _FILTER_ #define _FILTER_ #include "Parameter_files/INIT_PARAMS.H" /* Function FILTER filters the k-space box, <box>, using filter type <filter_type> on a characteristic comoving scale <R> (in Mpc), where: 0 = top-hat real space filter 1 = top-hat k-space filter 2 = gaussian Relavant box paramete...
fox_floats_timer_caching_omp_fileIO_benchmark.c
/* fox_floats_timer_caching_omp_fileIO_benchmark.c -- uses Fox's algorithm to multiply two square matrices * * Implementation of parallel matrix multiplication: * LaTeX: $C_{i,j} = \sum_{k} A_{i,k}B_{k,j}$ * * Input: * Input Matrix file name: A.dat, B.dat * * Output: * Output Matrix file name: C.dat...
exchange_boundary_overlap.c
//------------------------------------------------------------------------------------------------------------------------------ // Samuel Williams // SWWilliams@lbl.gov // Lawrence Berkeley National Lab //------------------------------------------------------------------------------------------------------------------...
GB_unop__ceil_fp64_fp64.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...
clauses-2.c
/* { dg-skip-if "PR 68733" { hppa*-*-hpux* && { ! lp64 } } } */ struct S { int r; int *s; int t[10]; }; void bar (int *); void foo (int *p, int q, struct S t, int i, int j, int k, int l) { #pragma omp target map (q), firstprivate (q) /* { dg-error "appears both in data and map clauses" } */ bar (&q); #pragma o...
Heuristic.h
#ifndef HEURISTIC_H #define HEURISTIC_H #include "Matrix.h" const vector<int> offset{-1, 1}; inline bool AddVerticalNeighbors(const unsigned &i, const unsigned &j, const unsigned &m, Matrix *matrix, set<unsigned> *F_aligned, Alignment *sure) { bool added = false; for (auto &p :...
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...
GB_binop__times_uint32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
GB_unaryop__lnot_int32_fp32.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__gt_uint32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
conv4x4s4_neon.h
// Tencent is pleased to support the open source community by making ncnn available. // // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. // // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except // in compliance with the License. You may obtain a copy ...
core_ctrtri.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_ztrtri.c, normal z -> c, Fri Sep 28 17:38:24 2018 * **/ #include <plasma_core_blas.h> #include "pla...
gost_fmt_plug.c
/* * GOST 3411 cracker patch for JtR. Hacked together during * May of 2012 by Dhiru Kholia <dhiru.kholia at gmail.com>, * Sergey V. <sftp.mtuci at gmail com>, and JimF * * This software is Copyright (c) 2012, Dhiru Kholia <dhiru.kholia at gmail.com>, * Sergey V. <sftp.mtuci at gmail com>, and JimF * and it is he...
GB_binop__land_int16.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
points.c
#include "image.h" #include <stdlib.h> #include <memory.h> #include <assert.h> #include <limits.h> #include <kazmath/vec2.h> // Transforms even the sequence 0,1,2,3,... into reasonably good random numbers. inline unsigned int randhash(unsigned int seed) { unsigned int i = (seed ^ 12345391u) * 2654435769u; i ^=...
GB_unaryop__identity_uint16_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...
fx.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
GB_binop__bshift_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...
SwathFileConsumer.h
// -------------------------------------------------------------------------- // OpenMS -- Open-Source Mass Spectrometry // -------------------------------------------------------------------------- // Copyright The OpenMS Team -- Eberhard Karls University Tuebingen, // ETH Zurich, and Freie Universit...
voxelize.c
#include "voxelGen.h" /* * Un-comment them to have debug messages or internal performance measurements */ //#define DEBUG_LOG //#define PERF_LOG /* * the type Vertex is defined in the file "voxelGen.h", in any case * the type definition is also written above (commented out) in * between lines 7to 13 */ void pr...
diagmv_x_sky_u.c
#include "alphasparse/kernel.h" #include "alphasparse/util.h" #include "alphasparse/opt.h" #ifdef _OPENMP #include <omp.h> #endif static alphasparse_status_t ONAME_omp(const ALPHA_Number alpha, const ALPHA_SPMAT_SKY *A, const...
GB_unaryop__identity_fp64_int64.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http...
lsm3d_blsm_openmp_v1.c
#include "openst/eikonal/lsm.h" #define M_LSM3D_IMP_NAME "BLSMv1" const char OPENST_LSM3D_COMPUTEPARTIAL_IMP_NAME[] = M_LSM3D_IMP_NAME; const size_t OPENST_LSM3D_COMPUTEPARTIAL_IMP_NAME_LENGTH = sizeof(M_LSM3D_IMP_NAME); int OpenST_LSM3D_ComputePartial(OPENST_FLOAT *U, char *LSM_UNLOCKED, OPENST_FLOAT *V, ...
convolution_sgemm.h
// Tencent is pleased to support the open source community by making ncnn available. // // Copyright (C) 2021 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 ...
compress.c
/*-------------------------------------------------------------*/ /*--- Compression machinery (not incl block sorting) ---*/ /*--- compress.c ---*/ /*-------------------------------------------------------------*/ /* ---------------------------------------------------...
kgraph-data.h
#ifndef WDONG_KGRAPH_DATA #define WDONG_KGRAPH_DATA #include <cmath> #include <cstring> #include <malloc.h> #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 ...
omp_matrix_vector.c
#include <omp.h> #include <stdio.h> #define R 100 #define C 100 main () { double mat[R][C]; double vec[C]; double tmp; int i=0,j=0; /* Some initializations */ for(i=0; i<R; i++){ for(j=0; j<C; j++){ mat[i][j]=1; } } for(i=0; i<C; i++) vec[i]...
count_omp_threads.c
/****************************************************************************** * FILE: count_threads_omp.c ******************************************************************************/ #include <omp.h> #include <stdio.h> #include <stdlib.h> int main (int argc, char *argv[]) { int nthreads, tid; /* Fork ...
argmax.h
/* Authors: Mayank Rathee Copyright: Copyright (c) 2020 Microsoft Research 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,...
cglobals.h
#ifndef RTGLOBALS #define RTGLOBALS #define BLOCK_SIZE_X 16 #define BLOCK_SIZE_Y 16 #define WARP_SIZE 32 #define Z_ORDER_BLOCK_SIZE 16 #define CMP_RESULTS_BLOCK_SIZE 256 #define HRT_RAY_MISS 0xFFFFFFFE #define HRT_RAY_HIT 0xFFFFFFFF #define GMAXVARS 64 #define INVALID_TEXTURE 0xFFFFFFFE #define TEX_POINT_SAM ...
GB_unaryop__lnot_uint8_fp32.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
pomp.h
// license:BSD-3-Clause // copyright-holders:Couriersud #ifndef POMP_H_ #define POMP_H_ /// /// \file pomp.h /// /// Wrap all OPENMP stuff here in a hopefully c++ compliant way. /// #include "pconfig.h" #include "ptypes.h" #include <cstdint> #if PHAS_OPENMP #include "omp.h" #endif namespace plib { namespace omp {...
file.c
#include <stdio.h> int main(){ #pragma omp parallel { printf("hello openmp!\n"); } return 0; }
race.c
#include <assert.h> #include <stdio.h> #include <stdlib.h> int main() { int i, counter; #pragma omp parallel for (i = 0; i < 100000; i++) counter++; printf("counter=%d\n", counter); return 0; }
evolve_cc.c
/* * The Connected Components Hamiltonian split uses a connected component search * on the time step graph of the system to find isolated subsystems with fast * interactions. These subsystems are then evolved at greater accuracy compared * to the rest system. * Equation numbers in comments refer to: J\"anes, Pelup...
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...
inner_product.c
/* This source file is part of the Geophysical Fluids Modeling Framework (GAME), which is released under the MIT license. Github repository: https://github.com/OpenNWP/GAME */ /* In this file, the inner product weights are computed. */ #include <stdlib.h> #include <stdio.h> #include <geos95.h> #include "../../src/gam...
convolution_sgemm_pack4to16.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 ...
raytracer.h
#pragma once #include <algorithm> #include <memory> #include <set> #include <chrono> #include <glm/glm.hpp> #include "camera.h" #include "entities.h" #include "image.h" #include "octree.h" #include "omp.h" #include <ctime> #include "util.h" #include "halton_enum.h" #include "halton_sampler.h" #include "photonMap.h" ...
ompcompute.c
#include <omp.h> #include <stdio.h> #include <stdlib.h> #include <inttypes.h> #ifndef LOG_LIM #define LOG_LIM 29 #endif #define N 2 int main(int argc, char **argv) { int64_t i, acc[N], id; printf("Computation started\n"); fflush(stdout); omp_set_num_threads(N); for( i=0; i<N; i++ ) acc[i] = 7+i; #p...
pastix.c
/* CalculiX - A 3-dimensional finite element program */ /*Copyright (C) 1998-2021 Guido Dhondt*/ /* 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(version 2);*/ /**/ /* This program is di...
variable_utils.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: Riccardo Rossi // Ruben Zorrill...
TSDFVoxelGridImpl.h
// ---------------------------------------------------------------------------- // - Open3D: www.open3d.org - // ---------------------------------------------------------------------------- // The MIT License (MIT) // // Copyright (c) 2018-2021 www.open3d.org // // Perm...
Scan.h
/* This file is part of the implementation for the technical paper Field-Aligned Online Surface Reconstruction Nico Schertler, Marco Tarini, Wenzel Jakob, Misha Kazhdan, Stefan Gumhold, Daniele Panozzo ACM TOG 36, 4, July 2017 (Proceedings of SIGGRAPH 2017) Use of this source code is granted via a BSD-style l...
GB_binop__bshift_int8.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX...
vlad.c
/** @file vlad.c ** @brief VLAD - Declaration ** @author David Novotny ** @author Andrea Vedaldi **/ /* Copyright (C) 2013 David Novotny and Andera Vedaldi. All rights reserved. This file is part of the VLFeat library and is made available under the terms of the BSD license (see the COPYING file). */ /** <!-- ~~...
Matrix.h
#pragma once #include <algorithm> #include <exception> #include <functional> #include <iostream> #include <omp.h> #include <stdexcept> #include <type_traits> #include <vector> namespace cppmath { template <typename T> class Matrix { static_assert(std::is_floating_point<T>::value, "An specializa...
reductions.c
/* Here we will investigate the performance of reductions using omp. We will take different reductions on consecutive numbers. */ #include <stdint.h> #include <stdio.h> #include <stdlib.h> #include "omp.h" #include "./fasttime.h" #define NUM_THREADS 4 void reduce_ADD(uint64_t); void reduce_MUL(uint64_t); void reduce...
sgemm-openmp-kevin.c
#include <stdio.h> #include <stdlib.h> #include <emmintrin.h> #include <math.h> #include <float.h> #include <string.h> #include <omp.h> #define NUM_THREADS 16 void mm_28( int m, int n, int ind1, int ind2, float *An, float *Cn); void p_tail_4( int m, int r, int a, int x, int ind1, int ind2, float *An, float *Cn); void t...
irbuilder_for_unsigned_dynamic_chunked.c
// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --function-signature --include-generated-funcs // RUN: %clang_cc1 -no-opaque-pointers -fopenmp-enable-irbuilder -verify -fopenmp -fopenmp-version=45 -x c++ -triple x86_64-unknown-unknown -emit-llvm %s -o - | FileCheck %s // expected...
naive_math_impl.h
// Copyright (c) 2019 PaddlePaddle 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...
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 // //===---------------------------...
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) >...
simulation.c
/******************************************************************************* * Copyright (C) 2015-2019 Commissariat a l'energie atomique et aux energies alternatives (CEA) * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the...
GB_binop__times_uint32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX...
read_omp.c
#include <stdio.h> #include <stdlib.h> #include <math.h> #define STB_IMAGE_IMPLEMENTATION #include "stb_image.h" #include <omp.h> // module load gnu/9.3.0 // export OMP_NUM_THREADS=10 // # compiling: link header in stb folder // gcc -fopenmp -std=gnu99 read_omp.c -o read_omp.x -Istb/ -lm // # insida a computational no...
profile.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
trmv_x_dia_n_hi.c
#include "alphasparse/kernel.h" #include "alphasparse/opt.h" #include "alphasparse/util.h" #include <string.h> #ifdef _OPENMP #include <omp.h> #endif static alphasparse_status_t ONAME_omp(const ALPHA_Number alpha, const ALPHA_SPMAT_DIA* A, const ALPHA_Number* x, const ALPHA_N...
main.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <float.h> #include <math.h> #ifdef _OPENMP # include <omp.h> #endif #include "main.h" #define min(a, b) ((a<b)?a:b) #define max(a, b) ((a>b)?a:b) void parse(int argc, char* argv[], struct user_parameters* params) { int i; for(i=1; i<argc; ...
GB_unop__identity_bool_int64.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...
clean.h
/**************************************************************************** * VCGLib o o * * Visual and Computer Graphics Library o o * * _ O _ * * Copyri...
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)...
GB_unaryop__abs_int32_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...
conv_im2col_sgemm_sse_pack.h
// BUG1989 is pleased to support the open source community by supporting ncnn available. // // Copyright (C) 2019 BUG1989. 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 of the License at // //...
ast-dump-openmp-parallel.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 parallel ; } // CHECK: TranslationUnitDecl {{.*}} <<invalid sloc>> <invalid sloc> // CHECK: `-FunctionDecl {{.*}} <{{.*}}ast-dump-openmp...