source
stringlengths
3
92
c
stringlengths
26
2.25M
GB_binop__bclr_uint8.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
omptough.c
#include <pthread.h> #include <stdlib.h> #include <malloc.h> #include <unistd.h> #include <stdio.h> #include <omp.h> #include "papi_test.h" #define NITER (100000) int main( int argc, char *argv[] ) { int i; int ret; int nthreads; int *evtset; int *ctrcode; nthreads = omp_get_max_threads( ); evtset = ( int * ...
bn_layer.c
#include "bn_layer.h" bn_layer *bn_alloc(int in_channels, int in_spatial) { bn_layer *layer = aalloc(sizeof(*layer)); layer->in_channels = in_channels; layer->in_spatial = in_spatial; layer->gamma = matrix_alloc(1, layer->in_channels); layer->beta = matrix_alloc(1, layer->in_channels); la...
convolution_1x1.h
// Tencent is pleased to support the open source community by making ncnn available. // // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. // // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except // in compliance with the License. You may obtain a copy ...
GB_binop__land_uint64.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
tseb_eta.c
/*Norman and Kustas 2 source model */ /* code by Andrew French 2002 */ #include <stdio.h> #include <stddef.h> #include <stdlib.h> #include <string.h> #include <omp.h> #include <math.h> #include <gdal.h> #include "tseb_eta.h" void usage() { printf( "-----------------------------------------\n"); printf( "--Modis Pro...
convolution_sgemm_int8.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 ...
eltwise_hcl_arm.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 ma...
GB_unop__minv_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...
convolutiondepthwise_3x3_int8.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 // //...
a.27.1.c
/* { dg-do compile } */ void a27 () { int i, a; #pragma omp parallel private(a) { #pragma omp parallel for private(a) for (i = 0; i < 10; i++) { /* do work here */ } } }
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) ...
mathint.c
#include "mathint.h" #if (defined __AVX__ || defined __SSE4_2__) #include "math_x86.h" #endif double GL_value[] = { 0.0000875560264341, 0.0004612700113121, 0.0011333756872430, 0.0021036207325094, 0.0033714435498935, 0.0049360907541328, 0.0067966286377069, 0.0089519457821408, 0.0114007542680463, 0...
cpu_backend_math-inl.h
#ifndef SRC_BACKENDS_CPU_BACKEND_COMMON_INL_H_ #define SRC_BACKENDS_CPU_BACKEND_COMMON_INL_H_ static void RectlinApplyFunc( const CPUTensor<DType>* input, CPUTensor<DType>* output, DType slope) { CHECK_EQ(input->size(), output->size()); #pragma omp parallel for for (size_t i = 0; i < input->size(); ++i) { ...
task_dep_prob.c
#include <assert.h> #include <omp.h> #include <stdio.h> #include <stdlib.h> #define N 1000 int test_all_dependencies() { int errors = 0; int dep_1[N], dep_2[N]; // Initialize dep_1 and dep_2 for (int i = 0; i < N; ++i) { dep_1[i] = 0; dep_2[i] = 0; } #pragma omp target depend(out: dep_1) map(tofr...
cadscenefile.h
/* * Copyright (c) 2011-2021, 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 ...
rectangle.h
// This is AutoMine/GraphZero implementation #if 0 #pragma omp parallel for schedule(dynamic,1) reduction(+:counter) for (vidType v0 = 0; v0 < g.V(); v0++) { for (vidType v1 : g.N(v0)) { if (v1 >= v0) break; for (vidType v2 : g.N(v0)) { if (v2 >= v1) break; //counter += bounded_intersect(g, v1, v2...
RefGen21.h
/****************************************************************/ /* Parallel Combinatorial BLAS Library (for Graph Computations) */ /* version 1.6 -------------------------------------------------*/ /* date: 6/15/2017 ---------------------------------------------*/ /* authors: Ariful Azad, Aydin Buluc --------------...
parallel_reduction_messages.c
// RUN: %clang_cc1 -verify -fopenmp -fopenmp-version=50 -ferror-limit 150 -o - %s int incomplete[]; void test(int *p) { int a; #pragma omp parallel reduction( // expected-error {{expected identifier}} expected-error {{expected ')'}} expected-warning {{missing ':' after reduction identifier - ignoring}} expected-not...
fastexp.h
#ifndef FASTEXP_H #define FASTEXP_H #include "math.h" #include <cstdint> #include <cstddef> #include <vector> #include "product.h" #include "ieee.h" namespace fastexp { enum class Approximation {IEEE, PRODUCT}; /** \brief Fast approximate exponential. * * This function implements a fast, vectorizable approximatio...
logit_loss_delta.h
/** * Copyright (c) 2015 by Contributors */ #ifndef DIFACTO_LOSS_LOGIT_LOSS_DELTA_H_ #define DIFACTO_LOSS_LOGIT_LOSS_DELTA_H_ #include <cmath> #include <vector> #include "difacto/loss.h" #include "difacto/sarray.h" #include "common/range.h" #include "common/spmv.h" #include "dmlc/omp.h" #include "dmlc/logging.h" nam...
GB_unaryop__identity_int32_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...
rose_pointers.c
// x1 and x2 may alias to each other. If no-aliasing assumed, the loop can be parallelized. #include <omp.h> void foo(double *x,int jp,int begin,int end,double rh1) { double *x1; double *x2; x1 = x; x2 = x1 + jp; #pragma omp parallel for firstprivate (end,rh1) for (int i = begin; i <= end - 1; i += 1) { ...
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) >...
image-view.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % IIIII M M AAA GGGG EEEEE ...
ctl_fragment.c
/********************************************************************[libaroma]* * Copyright (C) 2011-2015 Ahmad Amarullah (http://amarullz.com/) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the Lic...
GB_binop__rdiv_int32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
convolution_sgemm_fp16s.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 ...
sample4.c
//htc vs hpc with samples /****************************************************************************** * FILE: omp_mm.c * DESCRIPTION: * OpenMp Example - Matrix Multiply - C Version * Demonstrates a matrix multiply using OpenMP. Threads share row iterations * according to a predefined chunk size. * AUTHOR: B...
l8t1qa.c
#include<stdio.h> #include "gdal.h" #include<omp.h> /* L8 Qa bits [4] Cloud * 0 -> class 0: Not Cloud * 1 -> class 1: Cloud */ unsigned int L8QA_cloud(unsigned int pixel) { unsigned int qa; pixel >>= 4; /*bits [4] become [0]*/ qa = (unsigned int) (pixel & 0x01); return qa; } /* L8 Qa bits [5-6] C...
core_dlacpy.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_zlacpy.c, normal z -> d, Fri Sep 28 17:38:19 2018 * **/ #include <plasma_core_blas.h> #include "pla...
GB_unaryop__minv_fp64_int16.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
main.c
/* Copyright (C) 2010 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:...
convolution_4x4.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 ...
5.c
#include <omp.h> #include <stdio.h> int main() { int w = 10; #pragma omp parallel num_threads(2) #pragma omp for for (int i = 0; i < 100; i++) { int id = omp_get_thread_num(); printf("T%d:ai%d w=%d\n", id, i, w++); } printf("W=%d\n", w); }
cheby.gold.h
#include "common/common.hpp" void cheby_step (double *out_def, double* Ac_def, double* Ap_def, double* RHS_def, double* Dinv_def, double h2inv, double c1, double c2, int N) { double (*Ap)[N][N] = (double (*)[N][N])Ap_def; double (*Ac)[N][N] = (double (*)[N][N])Ac_def; double (*out)[N][N] = (double (*)[N][N])out_def...
MzMLHandler.h
// -------------------------------------------------------------------------- // OpenMS -- Open-Source Mass Spectrometry // -------------------------------------------------------------------------- // Copyright The OpenMS Team -- Eberhard Karls University Tuebingen, // ETH Zurich, and Freie Universit...
integrateFullOrbit.c
/* Wrappers around the C integration code for Full Orbits */ #ifdef _WIN32 #include <Python.h> #endif #include <stdio.h> #include <stdlib.h> #include <stdbool.h> #include <math.h> #include <bovy_coords.h> #include <bovy_symplecticode.h> #include <leung_dop853.h> #include <bovy_rk.h> #include <integrateFullOrbit.h> //...
morphology.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
fused_rowwise_nbit_conversion_ops.h
#pragma once #include <algorithm> #include <vector> #ifdef _OPENMP #include <omp.h> #endif #include "caffe2/core/context.h" #include "caffe2/core/logging.h" #include "caffe2/core/operator.h" // for param_search_greedy #include "caffe2/operators/fused_rowwise_nbitfake_conversion_ops.h" #include "caffe2/perfkernels/fu...
omp_fill_taskqueue.c
// RUN: %libomp-compile && env KMP_ENABLE_TASK_THROTTLING=0 %libomp-run // RUN: %libomp-compile && env KMP_ENABLE_TASK_THROTTLING=1 %libomp-run #include<omp.h> #include<stdlib.h> #include<string.h> /** * Test the task throttling behavior of the runtime. * Unless OMP_NUM_THREADS is 1, the master thread pushes tasks ...
opencl_blockchain_fmt_plug.c
/* blockchain "My Wallet" cracker patch for JtR. Hacked together during June of * 2013 by Dhiru Kholia <dhiru at openwall.com>. * * See https://blockchain.info/wallet/wallet-format * This software is Copyright (c) 2012 Lukas Odzioba <ukasz at openwall.net> * and Copyright (c) 2013 Dhiru Kholia <dhiru at openwall....
clause-1.c
/* { dg-do compile } */ /* { dg-require-effective-target tls } */ #define p parallel extern void bar (void); extern char q[]; int t; #pragma omp threadprivate (t) void foo (int x) { char *pp; struct S { int i; int j; } s; char a[32]; double d; int i; const int c = 8; #pragma omp p shared (x, x) /* { dg-e...
GB_unop__bnot_int32_int32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http://...
GB_binop__first_int64.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX...
GB_binop__isne_fp32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http:...
omp_loop_static.h
// -*- C++ -*- // Copyright (C) 2007-2018 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the terms // of the GNU General Public License as published by the Free Software // Foundation; either version 3...
Sema.h
//===--- Sema.h - Semantic Analysis & AST Building --------------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
Shapes.h
/************************************************************************* > File Name: Shapes.h > Author: Yibo Lin > Mail: yibolin@utexas.edu > Created Time: Thu 06 Nov 2014 09:04:57 AM CST ************************************************************************/ #ifndef SIMPLEMPL_SHAPES_H #define SI...
hmacSHA1_fmt_plug.c
/* * This software is Copyright (c) 2012, 2013 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. * * Originally based on hmac-md5 by Bartavelle */ #if FMT_EXTERNS_H extern struct ...
ast-dump-openmp-target-data.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(int x) { #pragma omp target data map(x) ; } // CHECK: TranslationUnitDecl {{.*}} <<invalid sloc>> <invalid sloc> // CHECK: `-FunctionDecl {{.*}} <{{.*}}ast-...
convolution_3x3_pack8to1_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 ...
pfx_fmt_plug.c
/* pfx cracker patch for JtR. Hacked together during June of 2012 by * Dhiru Kholia <dhiru.kholia at gmail.com>. * * This software is Copyright (c) 2021, Dhiru Kholia <dhiru.kholia at gmail.com>, * and it is hereby released to the general public under the following terms: * Redistribution and use in source and bi...
displacement_lagrangemultiplier_frictional_contact_criteria.h
// KRATOS ___| | | | // \___ \ __| __| | | __| __| | | __| _` | | // | | | | | ( | | | | ( | | // _____/ \__|_| \__,_|\___|\__|\__,_|_| \__,_|_| MECHANICS // // License: BSD License // ...
find_global_nodal_neighbours_process.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: Riccardo Rossi // #if !defined(KRATOS_FIND_GLOB...
counters2parallel.c
//counters2 parallel version HPC Felix Feliu #include <stdlib.h> #include <stdio.h> #include <unistd.h> #include <errno.h> #include <sys/types.h> #include <memory.h> #include <malloc.h> #include <papi.h> #include <omp.h> #define SIZE 1000 int main(int argc, char** argv) { float matrixa[SIZE][SIZE], matrixb[SIZE...
nbodysystem.h
#include <cstdio> #include <cassert> #include <cmath> #include <vector> struct NbodySystem{ long nbody; long num_step, num_bstep; long num_step_tot, num_bstep_tot; typedef dd_real real_type; typedef qvec3 vect_type; real_type eps2; real_type tsys; real_type init_energy, prev_energy; real_type dt...
distributions.c
#include "randomkit.h" #include "distributions.h" #include <mkl_vsl.h> int rk_fill_bytes(rk_state *state, int device, long size, void *data) { int ret; VSLStreamStatePtr stream = state->rng_streams[device]; #pragma omp target device(device) map(to: stream, size, data) \ ...
GB_unaryop__ainv_uint32_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...
zlacpy.c
/** * * @file * * PLASMA is a software package provided by: * University of Tennessee, US, * University of Manchester, UK. * * @precisions normal z -> s d c * **/ #include "plasma.h" #include "plasma_async.h" #include "plasma_context.h" #include "plasma_descriptor.h" #include "plasma_internal.h" #include ...
testing_dpotrf.c
/** * * @file example_dpotrf.c * * PLASMA testing routines * PLASMA is a software package provided by Univ. of Tennessee, * Univ. of California Berkeley and Univ. of Colorado Denver * * @brief Example of Cholesky factorization * * @version 2.6.0 * @author Bilel Hadri * @date 2010-11-15 * @generated d Tu...
mttkrp.c
/****************************************************************************** * INCLUDES *****************************************************************************/ #include "base.h" #include "mttkrp.h" #include "thd_info.h" #include "tile.h" #include "util.h" /************************************************...
tinyexr.h
#ifndef TINYEXR_H_ #define TINYEXR_H_ /* Copyright (c) 2014 - 2021, Syoyo Fujita and many contributors. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain th...
local_sum-inl.h
// This is an example demonstrating the usage of mshadow ps #include <cstdio> // use openmp to launch multiple threads #include <omp.h> #include <mshadow/tensor.h> #include <mshadow-ps/mshadow_ps.h> // simple util to print result void Print_(mshadow::Tensor<mshadow::cpu, 2, float> ts) { for (mshadow::index_t i = 0; ...
GB_unop__lnot_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...
calculate_E_field_flat_all_in_one.h
int k_delta[3][3] = {{1,0,0}, {0,1,0}, {0,0,1}}; /* Calculate the electric flux on both faces in the input direction. */ void calculate_E_field_flat_all_in_one(const paramstruct *params,const REAL *auxevol_gfs,REAL *rhs_gfs,const int flux_dirn) { #include "GiRaFFE_standalone_...
GB_binop__ne_int64.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX...
drivers.c
// Driver routines for synthesis and analysis of harmonic polynomial transforms. #include "fasttransforms.h" void execute_sph_hi2lo(const RotationPlan * RP, double * A, const int M) { int N = RP->n; #pragma omp parallel for (int m = 2 + omp_get_thread_num(); m <= M/2; m += omp_get_num_threads()) { ...
fvde_fmt_plug.c
/* JtR format to crack FileVault 2 hashes. * * This software is Copyright (c) 2017, Dhiru Kholia <kholia at kth.se> 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. * * Big thanks to...
activations.c
#include "activations.h" #include <math.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <float.h> char *get_activation_string(ACTIVATION a) { switch(a){ case LOGISTIC: return "logistic"; case LOGGY: return "loggy"; case RELU: ...
GB_binop__rminus_int32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
omp_bar_bench.c
/* * Copyright (c) 2013-2016, 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, Universitaetstr. 6, CH-8092 Zurich. Attn: Systems Group. */ #include <omp.h> #include...
GB_unaryop__identity_int8_bool.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http...
zhesv.c
/** * * @file * * PLASMA is a software package provided by: * University of Tennessee, US, * University of Manchester, UK. * * @precisions normal z -> s d c * **/ #include "plasma.h" #include "plasma_async.h" #include "plasma_context.h" #include "plasma_descriptor.h" #include "plasma_internal.h" #include ...
OrthotropicOp.h
void forward_OrthotropicOp(double *y, const double *x, int n){ #pragma omp parallel for for(int i=0;i<n;i++){ y[i*9] = x[4*i+0]; y[i*9+1] = x[4*i+1]; y[i*9+2] = 0.0; y[i*9+3] = x[4*i+1]; y[i*9+4] = x[4*i+2]; y[i*9+5] = 0.0; y[i*9+6] = 0.0; y[i*9+7] = 0.0; y[i*9+8] = x[4*i+3]; }...
GB_unaryop__ainv_int64_uint32.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
lib_openmp.c
// This code makes some assumptions on the implementation of // base64_stream_encode_init(), base64_stream_encode() and base64_stream_decode(). // Basically these assumptions boil down to that when breaking the src into // parts, out parts can be written without side effects. // This is met when: // 1) base64_stream_en...
RungeSolver8_10.h
#include "../DifferentialSolver.h" #include <assert.h> /* Copy-past of DormandPrince method & light differences, based on http://sce.uhcl.edu/feagin/courses/rk10.pdf results to Runge-Kutta 10th order method with 17th stages see also: http://sce.uhcl.edu/rungekutta/ http://sce.uhcl.edu/rungekutta/rk108.txt */ template<...
GB_binop__ne_uint8.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
Main.c
#include "XSbench_header.h" #ifdef MPI #include<mpi.h> #endif int main( int argc, char* argv[] ) { // ===================================================================== // Initialization & Command Line Read-In // ===================================================================== int version = 17; int mype ...
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...
veccopy-ompt-target-tracing.c
#include <stdio.h> #include <assert.h> #include <omp.h> #include "callbacks.h" // Calls to start/stop/flush_trace to be injected by the tool int main() { int N = 100000; int a[N]; int b[N]; int i; for (i=0; i<N; i++) a[i]=0; for (i=0; i<N; i++) b[i]=i; start_trace(); #pragma omp target ...
gemm.c
#include "gemm.h" #include "utils.h" #include "im2col.h" #include "dark_cuda.h" #include <stdlib.h> #include <stdio.h> #include <math.h> #include <float.h> #include <string.h> #include <stdint.h> #ifdef _WIN32 #include <intrin.h> #endif #if defined(_OPENMP) #include <omp.h> #endif #define TILE_M 4 // 4 ops #define TIL...
nodal_residualbased_elimination_builder_and_solver_continuity_for_FSI.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: Riccardo Rossi, Alessandro...
matrix_op-inl.h
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you ...
update_ops_matrix_dense_single.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <assert.h> #include "constant.h" #include "update_ops.h" #include "utility.h" #ifdef _OPENMP #include <omp.h> #endif #ifdef _MSC_VER #include <intrin.h> #else #include <x86intrin.h> #endif //void single_qubit_dense_matrix_gate_old_single(UINT target_...
shape.h
/* * shape.h * * Created on: Dec 28, 2015 * Author: agibsonccc */ #ifndef SHAPE_H_ #define SHAPE_H_ #include <cstring> #include <cstdio> #include <dll.h> #include <nd4jmalloc.h> #include <templatemath.h> #include "pointercast.h" #define MAX_DIMENSION 0x7fffffff #define MAX_NUM_THREADS 1024 #define MAX_RA...
rhs-brisbane.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...
omp_atomic.c
/*Este codigo usa el modelo de montecarlo para estimar el valor de la constante PI */ /* este codigo es original de http://stackoverflow.com/questions/17659652/calculating-pi-using-monte-carlo-method-gives-imprecise-answer*/ /* Ha sido modificado por Alejandro Parra Briones para fines academicos*/ #include <stdio.h> ...
StochasticLutN.h
// -------------------------------------------------------------------------- // Binary Brain -- binary neural net framework // // Copyright (C) 2018 by Ryuji Fuchikami // https://github.com/ryuz // ryuji.fuch...
CALPHADSpeciesPhaseGibbsEnergyExpansion.h
#ifndef included_CALPHADSpeciesPhaseGibbsEnergyExpansion #define included_CALPHADSpeciesPhaseGibbsEnergyExpansion namespace Thermo4PFM { #ifdef HAVE_OPENMP_OFFLOAD #pragma omp declare target #endif template <typename ScalarType> class CALPHADSpeciesPhaseGibbsEnergyExpansion { public: CALPHADSpeciesPhaseGibbsEner...
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...
rose_ompfor2.c
/* loop scheduling */ #include <stdio.h> #ifdef _OPENMP #include <omp.h> #endif #include "libxomp.h" int a[20]; void foo(int lower,int upper,int stride) { int i; if (XOMP_single()) { printf("---------default schedule--------------\n"); } XOMP_barrier(); { int _p_i; long p_index_; long p_lowe...
format_avx512.h
#ifndef FORMAT_AVX512_H #define FORMAT_AVX512_H #include "common_avx512.h" #include "utils_avx512.h" template<typename iT, typename uiT> void generate_partition_pointer_s1_kernel(const iT *d_row_pointer, uiT *d_partition_pointer, ...
tiger_fmt_plug.c
/* Tiger cracker patch for JtR. Hacked together during April of 2013 by Dhiru * Kholia <dhiru at openwall.com>. * * This software is Copyright (c) 2013 Dhiru Kholia <dhiru at openwall.com> and * it is hereby released to the general public under the following terms: * * Redistribution and use in source and binary ...
blake2bp-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 Univers...
operator_tune-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 ...
GB_AxB_dot2_template.c
//------------------------------------------------------------------------------ // GB_AxB_dot2_template: C=A'B, C<!M>=A'*B, or C<M>=A'*B via dot products //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. //...
GB_nvec_nonempty.c
//------------------------------------------------------------------------------ // GB_nvec_nonempty: count the number of non-empty vectors //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-License-Id...
rmse.c
/*************************************************************************/ /** File: rmse.c **/ /** Description: calculate root mean squared error of particular **/ /** clustering. **/ /** Author: Sang-Ha Lee **/ /** University of Virginia....