source
stringlengths
3
92
c
stringlengths
26
2.25M
GB_unaryop__minv_uint16_int64.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http...
makeYbus.h
/* * makYbus.cuh * * Created on: 23/09/2015 * Author: Igor M. Araújo */ #ifndef MAKEYBUS_CUH_ #define MAKEYBUS_CUH_ #include <util/complexUtils.h> #include <iostream> using namespace std; __host__ void mkl_computeCfCt( Branch *branches, cuDoubleComplex *cooValCf, int *cooRowCf, int *cooColCf, c...
ex4-matrix-product-openmp.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> #define VALIDATE 0 #if VALIDATE #include "validate.h" #endif void mat_prod(const size_t n, const int * restrict, const int * restrict, int * restrict); void usage(char**); int main(int argc, char **argv) { int *A,*B,*C; size_t i,n; double t0,t1; ...
test.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> #include <sys/types.h> #include <sys/wait.h> #include <unistd.h> #include <string.h> int main() { omp_set_dynamic(0); #pragma omp parallel num_threads(4) { int currentThread = omp_get_thread_num(); if(currentThread == 0) { printf("Master!\n"); ...
GB_binop__pair_fc64.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_int8_uint16.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http://...
b4soild.c
/*** B4SOI 12/16/2010 Released by Tanvir Morshed ***/ /********** * Copyright 2010 Regents of the University of California. All rights reserved. * Authors: 1998 Samuel Fung, Dennis Sinitsky and Stephen Tang * Authors: 1999-2004 Pin Su, Hui Wan, Wei Jin, b3soild.c * Authors: 2005- Hui Wan, Xuemei Xi, Ali Niknej...
comm.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 ...
libimagequant.c
/* ** © 2009-2018 by Kornel Lesiński. ** © 1989, 1991 by Jef Poskanzer. ** © 1997, 2000, 2002 by Greg Roelofs; based on an idea by Stefan Schneider. ** ** See COPYRIGHT file for license. */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include <stdarg.h> #include <stdbool.h> #include <stdint.h> #include ...
ocp_nlp_sqp_rti.c
/* * Copyright 2019 Gianluca Frison, Dimitris Kouzoupis, Robin Verschueren, * Andrea Zanelli, Niels van Duijkeren, Jonathan Frey, Tommaso Sartor, * Branimir Novoselnik, Rien Quirynen, Rezart Qelibari, Dang Doan, * Jonas Koenemann, Yutao Chen, Tobias Schöls, Jonas Schlagenhauf, Moritz Diehl * * This file is part o...
mish_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...
activation_functions.h
#ifndef ANAKIN_SABER_FUNCS_IMPL_X86_MATH_ACTIVATION_FUNCTIONS_H #define ANAKIN_SABER_FUNCS_IMPL_X86_MATH_ACTIVATION_FUNCTIONS_H #include <math.h> #include <string> #include "saber/saber_types.h" #include "utils/logger/logger.h" #include "saber/funcs/impl/x86/saber_avx2_math.h" namespace anakin { namespace s...
020_pi.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> double compute_partial_pi(long nr_tries, unsigned int *seed); int main() { const long nr_tries = 1000000; const int nr_blocks = 10; int num_threads = 1; double nr_success = 0.0; #pragma omp parallel default(none) shared(nr_success) shared(num_thr...
simd-3.c
/* { dg-do run } */ /* { dg-additional-options "-msse2" { target sse2_runtime } } */ /* { dg-additional-options "-mavx" { target avx_runtime } } */ #define N 100 #define EPS 0.0000000000000001 #include <stdlib.h> void init(double *a, double *a_ref, double *b, int n) { int i, s = -1; for ( i = 0; i < n; i++ ) {...
adam_op.h
/* Copyright (c) 2016 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 by applicable law or...
thdat.c
/* * Redistribution and use in source and binary forms, with * or without modification, are permitted provided that the * following conditions are met: * * 1. Redistributions of source code must retain this list * of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce t...
Interp1PrimFirstOrderUpwind.c
/*! @file Interp1PrimFirstOrderUpwind.c * @brief First order upwind Scheme (Component-wise application to vectors). * @author Debojyoti Ghosh */ #include <stdio.h> #include <stdlib.h> #include <basic.h> #include <arrayfunctions.h> #include <interpolation.h> #include <mpivars.h> #include <hypar.h> #ifdef with_omp ...
lowDimBD2.c
#include <R.h> #include <stdint.h> #include <x86intrin.h> #include <omp.h> #define min(A,B) ((A) < (B) ? (A) : (B)) #define max(A,B) ((A) > (B) ? (A) : (B)) #define Data(i,j) data[(j) * n + (i)] //R uses column-major order #define Sorted(i,j) sorted[(j) * n + (i)] #define Idx(i,j) idx[(j) * n + (i)] #d...
nodal_two_step_v_p_strategy.h
// // Project Name: KratosPFEMFluidDynamicsApplication $ // Last modified by: $Author: AFranci $ // Date: $Date: June 2018 $ // Revision: $Revision: 0.0 $ // // #ifndef KRATOS_NODAL_TWO_STEP_V_P_STRATEGY_H #define KRATO...
MetaballComponent.h
#pragma once #include "ECS.h" #include "TransformComponent.h" #include "MarchingCubeComponent.h" #include "glm/gtx/string_cast.hpp" #include <cstdint> #include <functional> class MetaballComponent : public Component { public: MetaballComponent(MarchingCubeComponent* __marchingCubeComponent, float __radius) : Compon...
GB_unaryop__ainv_uint64_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...
kmp_atomic.c
/* * kmp_atomic.c -- ATOMIC implementation routines * $Revision: 43421 $ * $Date: 2014-08-28 08:56:10 -0500 (Thu, 28 Aug 2014) $ */ //===----------------------------------------------------------------------===// // // The LLVM Compiler Infrastructure // // This file is dual licensed under the...
GB_unop__exp_fc32_fc32.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...
updater_basemaker-inl.h
/*! * Copyright 2014 by Contributors * \file updater_basemaker-inl.h * \brief implement a common tree constructor * \author Tianqi Chen */ #ifndef XGBOOST_TREE_UPDATER_BASEMAKER_INL_H_ #define XGBOOST_TREE_UPDATER_BASEMAKER_INL_H_ #include <rabit/rabit.h> #include <vector> #include <algorithm> #include <string>...
residual.c
//------------------------------------------------------------------------------------------------------------------------------ // Samuel Williams // SWWilliams@lbl.gov // Lawrence Berkeley National Lab //------------------------------------------------------------------------------------------------------------------...
denseOptimizedBlocksJacobi.h
// // Created by mbarb on 23/02/2018. // #ifndef PARALLELITERATIVE_DENSEOPTIMIZEDBLOCKJACOBI_H #define PARALLELITERATIVE_DENSEOPTIMIZEDBLOCKJACOBI_H #include "Eigen" #include "utils.h" #include "denseParallelJacobi.h" namespace Iterative { template <typename Scalar, long long SIZE> class denseOptimizedBloc...
iRCCE_isend.c
//*************************************************************************************** // Non-blocking send routines. //*************************************************************************************** // // Author: Rob F. Van der Wijngaart // Intel Corporation // Date: 008/30/2010 // //************...
pi_omp_profesor.c
//gcc pi_omp_profesor.c -o x -fopenmp -lm && ./x #include <stdio.h> #include <stdlib.h> #include <omp.h> #include <sys/time.h> #define ITERATIONS 2e09 #define THREADS 8 #define PAD 8 int calculatePi(double *piTotal, int ID) { int start, end; start = (ITERATIONS/omp_get_num_threads()) * ID; end = (ITERAT...
calculate_G.h
#pragma omp target teams distribute parallel for collapse(2) thread_limit(BLOCK_SIZE) for (int col = 1; col < NUM+1; col++) { for (int row = 1; row < NUM+1; row++) { if (row == NUM) { // top and bottom boundaries G(col, 0) = v(col, 0); G(col, NUM) = v(col, NUM); } else { // u velo...
GB_binop__lt_int8.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http:...
MINDSSCbox.h
void boxfilter(float* input,float* temp1,float* temp2, int hw, // mind_step int m,int n,int o){ int sz=m*n*o; for(int i=0;i<sz;i++){ temp1[i]=input[i];//copy to temp, initialization } ////y for(int k=0;k<o;k++){ for(int j=0;j<n;j++){ for(int i=1;i<m;i++){ ...
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) ...
1d_array_ptr.c
#include <stdlib.h> #include <omp.h> int main() { int* arr = malloc(sizeof(int) * 4); #pragma omp parallel { arr[0] = 0; arr[1] = 1; arr[2] = 2; arr[3] = 3; printf("[%d, %d, %d, %d]\n", arr[0], arr[1], arr[2], arr[3]); } free(arr); }
omp_parallel_default.c
<ompts:test> <ompts:testdescription>Test which checks the default option of the parallel construct.</ompts:testdescription> <ompts:ompversion>2.0</ompts:ompversion> <ompts:directive>omp parallel default</ompts:directive> <ompts:testcode> #include <stdio.h> #include <unistd.h> #include "omp_testsuite.h" int <ompts:tes...
3d7pt_var.c
/* * Order-1, 3D 7 point stencil with variable coefficients * Adapted from PLUTO and Pochoir test bench * * Tareq Malas */ #include <stdio.h> #include <stdlib.h> #include <sys/time.h> #ifdef LIKWID_PERFMON #include <likwid.h> #endif #include "print_utils.h" #define TESTS 2 #define MAX(a,b) ((a) > (b) ? a : b) #...
GB_unop__identity_uint16_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...
threading_utils.h
/*! * Copyright 2015-2019 by Contributors * \file common.h * \brief Threading utilities */ #ifndef XGBOOST_COMMON_THREADING_UTILS_H_ #define XGBOOST_COMMON_THREADING_UTILS_H_ #include <dmlc/common.h> #include <dmlc/omp.h> #include <algorithm> #include <limits> #include <type_traits> // std::is_signed #include <v...
ccl_cls.c
#include <stdio.h> #include <stdlib.h> #include <math.h> #include <string.h> #include <gsl/gsl_errno.h> #include <gsl/gsl_integration.h> #include "ccl.h" typedef struct{ double l; ccl_cosmology *cosmo; ccl_cl_tracer_collection_t *trc1; ccl_cl_tracer_collection_t *trc2; ccl_f2d_t *psp; int *status; } inte...
parallel_mmul.c
#include <stdio.h> #include "include/Matrix.h" int parallelMatrixMul(Matrix a, Matrix b, Matrix *result) { if (a.columnCount != b.rowCount) { printf("Error: wrong matrix dimensions.\n"); return 1; } #pragma omp parallel for collapse(2) for (int i = 0; i < a.rowCount; ++i) { fo...
a.35.2.c
/* { dg-do compile } */ void work (int, int); void work1 (int i, int n) { int j; /* incorrect nesting of loop regions */ #pragma omp for for (j = 0; j < n; j++) work (i, j); } void wrong2 (int n) { #pragma omp parallel default(shared) { int i; #pragma omp for for (i = 0; i < n; i++) work1 (...
spmv.h
#pragma once #include <thrust/functional.h> #include <cusp/detail/functional.h> //MW: add some OpenMP pragmas namespace cusp { namespace detail { namespace host { ////////////// // COO SpMV // ////////////// template <typename Matrix, typename Vector1, typename Vector2, typename UnaryFu...
Parallel.h
#pragma once #include <ATen/ATen.h> #include <atomic> #include <cstddef> #include <exception> #ifdef _OPENMP #include <omp.h> #endif namespace at { namespace internal { // This parameter is heuristically chosen to determine the minimum number of // work that warrants paralellism. For example, when summing an array, i...
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...
conv3x3s1_winograd64_neon4_BdB.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 ...
dragonfly3_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...
acado_integrator.c
/* * This file was auto-generated using the ACADO Toolkit. * * While ACADO Toolkit is free software released under the terms of * the GNU Lesser General Public License (LGPL), the generated code * as such remains the property of the user who used ACADO Toolkit * to generate this code. In partic...
parallel_levelset_distance_calculator.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: Riccardo Rossi // // #if !defined(KRATOS_PARALLE...
perftest.c
/** * Copyright (C) Mellanox Technologies Ltd. 2001-2014. ALL RIGHTS RESERVED. * Copyright (C) The University of Tennessee and The University * of Tennessee Research Foundation. 2015. ALL RIGHTS RESERVED. * Copyright (C) UT-Battelle, LLC. 2015. ALL RIGHTS RESERVED. * * See file LICENSE for terms. */ #...
irbuilder_unroll_partial_factor_for.c
// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --function-signature --include-generated-funcs // RUN: %clang_cc1 -fopenmp-enable-irbuilder -verify -fopenmp -fopenmp-version=51 -x c -triple x86_64-unknown-unknown -emit-llvm %s -o - | FileCheck %s // expected-no-diagnostics #ifnd...
OpenMPClause.h
//===- OpenMPClause.h - Classes for OpenMP clauses --------------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
GB_unop__identity_uint64_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...
dmml.c
/*! @copyright (c) 2017 King Abdullah University of Science and * Technology (KAUST). All rights reserved. * * STARS-H is a software package, provided by King Abdullah * University of Science and Technology (KAUST) * * @file src/backends/openmp/blrm/dmml.c * @version 0.3.0 * @au...
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...
GB_subassign_04.c
//------------------------------------------------------------------------------ // GB_subassign_04: C(I,J) += A ; using S //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http://suitesparse.com See Gra...
conv_dw_dilation_kernel_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...
CPUImplQPU.h
/* Copyright (c) 2017-2020 Origin Quantum Computing. All Right 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 la...
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...
Par-16-ParForLoopBarrier.c
int main(int argc, char **argv) { int a[4] = {1,2,3,4}; #pragma omp parallel { #pragma omp for for (int i = 0; i < 4; ++i) { a[i] = 3*a[i]; } #pragma omp barrier } return 0; }
2866.c
/* POLYBENCH/GPU-OPENMP * * This file is a part of the Polybench/GPU-OpenMP suite * * Contact: * William Killian <killian@udel.edu> * * Copyright 2013, The University of Delaware */ #include <stdio.h> #include <unistd.h> #include <string.h> #include <math.h> /* Include polybench common header. */ #include <po...
GB_unop__minv_int32_int32.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...
utils.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 ...
kmeans.c
/** @file kmeans.c ** @brief K-means - Declaration ** @author Andrea Vedaldi, David Novotny **/ /* Copyright (C) 2007-12 Andrea Vedaldi and Brian Fulkerson. Copyright (C) 2013 Andrea Vedaldi and David Novotny. All rights reserved. This file is part of the VLFeat library and is made available under the terms of the...
real_to_reciprocal.c
/* Copyright (C) 2015 Atsushi Togo */ /* All rights reserved. */ /* This file is part of phonopy. */ /* 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 abo...
soxr.c
/* SoX Resampler Library Copyright (c) 2007-13 robs@users.sourceforge.net * Licence for this file: LGPL v2.1 See LICENCE for details. */ #include <math.h> #include <stdlib.h> #include <string.h> #include <time.h> #include "soxr.h" #include "data-io.h" #include "internal.h" char const * soxr_...
GB_unop__identity_fc32_uint8.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...
graph_decomposition_ref.h
#ifndef __GRAPH_DECOMPOSITION_REF_H__ #define __GRAPH_DECOMPOSITION_REF_H__ #include "graph.h" #include <mutex> #include <random> #include <omp.h> static float* genExp_ref(int n, float rate, float* maxVal, int* maxId) { std::default_random_engine generator; // note this will always generate the same values - which ...
PairwiseSumByTask.c
#include <omp.h> double PairwiseSumBySubtask(double* restrict var, long nstart, long nend); double PairwiseSumByTask(double* restrict var, long ncells) { double sum; #pragma omp parallel { #pragma omp master { sum = PairwiseSumBySubtask(var, 0, ncells); } } return(sum); } do...
cli.h
#pragma once #include <gms/third_party/gapbs/command_line.h> #include <gms/third_party/clipp.h> #include "gms/common/format.h" #include "parameter.h" #include "args.h" #include "compat.h" namespace GMS::CLI { using clipp::option; using clipp::parameter; using clipp::value; class Parser { private...
GB_unaryop__minv_int64_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...
hilos.c
//Ejercicio EDAII. Profesor Francisco Javier Rodriguez /*Instrucción de compilación gcc -Wall -std=c99 hilos.c -fopenmp */ #include <stdio.h> #include <stdlib.h> // para system() y rand() #include <time.h> // para time() #include <omp.h> #define TAM 10 int main() { int a[TAM]; int b[TAM]; srand( ...
trmm_x_csr_n_hi_row.c
#include "alphasparse/kernel.h" #include "alphasparse/util.h" #include "alphasparse/opt.h" #include <memory.h> alphasparse_status_t ONAME(const ALPHA_Number alpha, const ALPHA_SPMAT_CSR *mat, const ALPHA_Number *x, const ALPHA_INT columns, const ALPHA_INT ldx, const ALPHA_Number beta, ALPHA_Number *y, const ALPHA_INT ...
factorize_gmp_2step_primtest.c
/******************************************************************************************************************* * Compiling: mpicc fattor.c -lgmp -fopenmp -o fattor * Running: mpirun -n PROCNUM --bind-to none fattor NUMBER * Note: PROCNUM is the number of processes that will be ran, and it must be >=2, NUMBER is t...
Math.h
// // Created by Jarlene on 2017/7/21. // #ifndef MATRIX_MATH_H #define MATRIX_MATH_H #include <math.h> #include <assert.h> #include <functional> #include <vector> #include <random> #include <sys/time.h> #include "Logger.h" #include "Eigen.h" #ifdef USE_MP #include <omp.h> #endif #ifdef USE_MKL #ifndef BLAS #define...
pdgstrs.c
/*! \file Copyright (c) 2003, The Regents of the University of California, through Lawrence Berkeley National Laboratory (subject to receipt of any required approvals from U.S. Dept. of Energy) All rights reserved. The source code is distributed under BSD license, see the file License.txt at the top-level directory. ...
gemm_x_coo_row.c
#include "alphasparse/kernel.h" #include "alphasparse/util.h" #include "alphasparse/opt.h" #ifdef _OPENMP #include <omp.h> #endif static void mm_coo_plain_outcols(const ALPHA_Number alpha, const ALPHA_SPMAT_COO *mat, const ALPHA_Number *x, const ALPHA_INT columns, const ALPHA_INT ldx, const ALPHA_Number beta, ALPHA_Nu...
perftest.c
/** * Copyright (C) Mellanox Technologies Ltd. 2001-2014. ALL RIGHTS RESERVED. * Copyright (C) The University of Tennessee and The University * of Tennessee Research Foundation. 2015. ALL RIGHTS RESERVED. * Copyright (C) UT-Battelle, LLC. 2015. ALL RIGHTS RESERVED. * Copyright (C) ARM Ltd. 2017-2021. A...
EmbeddingBag.h
/****************************************************************************** * Copyright (c) Intel Corporation - All rights reserved. * * This file is part of the LIBXSMM library. * * * ...
GB_binop__ge_fp32.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
GB_binop__isgt_uint16.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http:...
example2.c
// calculation example for electromagnetic field intensity distribution #include "multi_fbeam.h" int main() { Bobj bm; FILE *fp1,*fp2; double complex e[3],h[3]; double x[3],rang,dr,*ie,*ih; int max,i,j; init_mfb(&bm); read_data_mfb(&bm); print_data_mfb(&bm); setup_mfb(&bm); max=200; ...
openmp.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <OpenCL/opencl.h> // #include <omp.h> //Student ID: 21804416 //Name: SUN QIANG //Where use openmp speed up: //Here we have four tasks using openmp to speed up //1. use openmp to sort all columns //2. use openmp to generate blocks //3. The key point ...
GB_binop__isle_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...
XT_OffsetError.c
/* ============================================================================ * Copyright (c) 2015 K. Aditya Mohan (Purdue University) * All rights reserved. * * Redistribution and use in source and binary forms, with or without modification, * are permitted provided that the following conditions are met: * * ...
fs_csc_inspector.h
#include<vector> #include <cassert> #include<set> // Makes an edge inside dependence graph inline void connect(int v, int w, std::vector<std::vector<int>> &DAG){ DAG[v].push_back( w ); } /* ****** Inspector for level set parallelization of Forward Solve CSC's outer most loop */ void fs_csc_inspector(int n, int...
DRB021-reductionmissing-orig-yes.c
/* Copyright (C) 1991-2018 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it andor modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the L...
loops.h
// Cuda/host loops #pragma once #include "cutil.h" #include "debug.h" #include "preprocessor.h" #include "print.h" #include <optional> #include <type_traits> #ifndef __APPLE__ #include <omp.h> #endif namespace mandelbrot { using std::is_signed_v; using std::optional; using std::tuple; // For now, assume we fit in in...
GB_binop__pair_int8.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-...
bench.c
//------------------------------------------------------------------------------------------------------------------------------ // Samuel Williams // SWWilliams@lbl.gov // Lawrence Berkeley National Lab //------------------------------------------------------------------------------------------------------------------...
Parser.h
//===--- Parser.h - C Language Parser ---------------------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===---------------------------...
draw.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
SpatialMaxUnpooling.c
#ifndef TH_GENERIC_FILE #define TH_GENERIC_FILE "THNN/generic/SpatialMaxUnpooling.c" #else static void THNN_(SpatialMaxUnpooling_updateOutput_frame)(scalar_t *input_p, scalar_t *output_p, THIndex_t *ind_p, int n...
yescrypt-simd.c
/*- * Copyright 2009 Colin Percival * Copyright 2012-2014 Alexander Peslyak * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copy...
GB_binop__lor_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-...
DRB085-threadprivate-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...
DRB061-matrixvector1-orig-no.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...
GB_binop__gt_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...
dcraw.c
#ifndef IGNOREALL /* dcraw.c -- Dave Coffin's raw photo decoder Copyright 1997-2015 by Dave Coffin, dcoffin a cybercom o net This is a command-line ANSI C program to convert raw photos from any digital camera on any computer running any operating system. No license is required to download and use dcraw...
GB_unaryop__identity_int16_uint16.c
//------------------------------------------------------------------------------ // GB_unaryop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved. // http...
createlut.c
// this uses the coefficient cube optimiser from the paper: // // Wenzel Jakob and Johannes Hanika. A low-dimensional function space for // efficient spectral upsampling. Computer Graphics Forum (Proceedings of // Eurographics), 38(2), March 2019. // run like // make && ./createlut 512 lut.pfm XYZ && eu lut.pfm -w 14...
o3logon_fmt_plug.c
/* * This software was written by JimF jfoug AT cox dot net * in 2016. No copyright is claimed, and the software is hereby * placed in the public domain. In case this attempt to disclaim * copyright and place the software in the public domain is deemed * null and void, then the software is Copyright (c) 2016 JimF ...