source stringlengths 3 92 | c stringlengths 26 2.25M |
|---|---|
pool_functors.h | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#pragma once
#include "core/platform/threadpool.h"
#include "core/util/eigen_common_wrapper.h"
#include "core/providers/cpu/nn/pool_base.h"
namespace onnxruntime {
template <typename T, typename PoolType>
struct Pool1DTask... |
serial_tree_learner.h | /*!
* Copyright (c) 2016 Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See LICENSE file in the project root for license information.
*/
#ifndef LIGHTGBM_TREELEARNER_SERIAL_TREE_LEARNER_H_
#define LIGHTGBM_TREELEARNER_SERIAL_TREE_LEARNER_H_
#include <LightGBM/dataset.h>
#include <Ligh... |
feature.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
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
... |
ompReduction.c |
#include <stdio.h>
#include <stdlib.h>
#include <omp.h>
int main(int argc, char **argv){
int threadCount = 20;
omp_set_num_threads(threadCount);
// still serial here
int i = 6;
int *v = (int*) calloc(threadCount, sizeof(int));
int badness, veryBad = 0;
// fork the program
#pragma omp parallel redu... |
GB_unaryop__one_uint16_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... |
jacobi-2d-imper.par2d.c | #include <math.h>
#include <omp.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))
int t1, t2, t3, t4, t5, t6;
register int lb, ub, lb1, ub1, lb2, ub2;
register int lbv... |
bprop.h | //
// bprop.h
//
#ifndef bprop_h
#define bprop_h
#include<omp.h>
#include<mpi.h>
#include<math.h>
struct model BProp(struct model model, float* y_hat, int* y, int batch_size, float learning_rate, int rank, int verbose){
int num_layers = model.num_layers;
int num_classes = model.layers[num_layers-1].n... |
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 ... |
mxAssembleMeshConnection.c | #ifdef _OPENMP
#include <omp.h>
#endif
#include "mex.h"
#include "math.h"
#define max(a, b) ((a > b) ? a : b)
#define min(a, b) ((a < b) ? a : b)
#define NRHS 13
#define NLHS 3
/**
* @brief
* @details
* [ EToM, EToE, EToF, EToB ] = mxAssembleMeshConnection( ...
MeshId1, MeshId2, K1, K2, Nface1, Nface2, ...
... |
Ooura_FFT.h | #ifndef _H_OOURA_FFT_
#define _H_OOURA_FFT_
#include <cmath>
class Ooura_FFT{
private:
int frame_size;
int channels;
double **a, **w;
int **ip;
public:
inline Ooura_FFT(int _frame_size, int _channels);
inline ~Ooura_FFT();
inline void FFT(double **);
inline void FFT(d... |
image_pyramid.h | /*
*
* This file is part of the open-source SeetaFace engine, which includes three modules:
* SeetaFace Detection, SeetaFace Alignment, and SeetaFace Identification.
*
* This file is part of the SeetaFace Detection module, containing codes implementing the
* face detection method described in the following paper:... |
RelativeNeighborhoodGraph.h | #ifndef _SPTAG_COMMON_RNG_H_
#define _SPTAG_COMMON_RNG_H_
#include "NeighborhoodGraph.h"
namespace SPTAG
{
namespace COMMON
{
class RelativeNeighborhoodGraph: public NeighborhoodGraph
{
public:
void RebuildNeighbors(VectorIndex* index, const int node, int* nodes, const Basi... |
omp_dem_search.h | //
// Project Name: Kratos
// Last Modified by: $Author: clabra $
// Date: $Date: 2007-03-29 19:37:47 $
// Revision: $Revision: 1.2 $
//
//
#if !defined(KRATOS_OMP_DEM_SEARCH_H_INCLUDED )
#define KRATOS_OMP_DEM_SEARCH_H_INCLUDED
// System includes
#include <string>
#includ... |
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 ... |
GB_unaryop__lnot_int64_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... |
CMultiClassRegionData.h | ///////////////////////////////////////////////////////////////////////////////
// $Id$
//
// 3DimViewer
// Lightweight 3D DICOM viewer.
//
// Copyright 2008-2016 3Dim Laboratory s.r.o.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the Licen... |
GB_binop__plus_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-... |
bicubic_interpolation.h | // This program is free software: you can use, modify and/or redistribute it
// under the terms of the simplified BSD License. You should have received a
// copy of this license along this program. If not, see
// <http://www.opensource.org/licenses/bsd-license.html>.
//
// Copyright (C) 2012, Javier Sánchez Pérez <jsan... |
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; ... |
com_qmp.c | /****************** com_qmp.c *****************************************/
/* Communications routines for the SU3 program
MIMD version 7.
This file is communications-scheme dependent.
QMP version - allegedly machine independent
*/
/* Modifications
5/09/02 officially split from com_mpi.c and modified for Q... |
ccl_power.c | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <gsl/gsl_integration.h>
#include <gsl/gsl_interp.h>
#include <gsl/gsl_spline.h>
#include <gsl/gsl_errno.h>
#include <gsl/gsl_sf_bessel.h>
#include "ccl.h"
#include "ccl_f2d.h"
#include "ccl_emu17.h"
#include "ccl_emu17_params.h"
// helper functions fo... |
GB_unaryop__identity_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... |
GB_unop__asin_fp64_fp64.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_subassign_05e.c | //------------------------------------------------------------------------------
// GB_subassign_05e: C(:,:)<M,struct> = scalar ; no S, C empty, M structural
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
... |
syrk.c | /**
* This version is stamped on May 10, 2016
*
* Contact:
* Louis-Noel Pouchet <pouchet.ohio-state.edu>
* Tomofumi Yuki <tomofumi.yuki.fr>
*
* Web address: http://polybench.sourceforge.net
*/
/* syrk.c: this file is part of PolyBench/C */
#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include... |
GB_subassign_01.c | //------------------------------------------------------------------------------
// GB_subassign_01: C(I,J) = scalar ; using S
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-License-Identifier: Apa... |
askewBD2.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)]
#defin... |
convolution_pack1to4.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 ... |
base.h | #include "callback.h"
#include <omp.h>
int main()
{
unsigned int i;
#pragma omp parallel for num_threads(4) schedule(SCHEDULE)
for (i = 0; i < 4; i++) {
}
// Check if libomp supports the callbacks for this test.
// CHECK-NOT: {{^}}0: Could not register callback 'ompt_callback_parallel_begin'
// CHECK-N... |
GeneralMatrixMatrix.h | // This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008-2009 Gael Guennebaud <gael.guennebaud@inria.fr>
//
// This Source Code Form is subject to the terms of the Mozilla
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You c... |
core_zlacpy.c | /**
*
* @file
*
* PLASMA is a software package provided by:
* University of Tennessee, US,
* University of Manchester, UK.
*
* @precisions normal z -> c d s
*
**/
#include <plasma_core_blas.h>
#include "plasma_types.h"
#include "plasma_internal.h"
#include "core_lapack.h"
/*******************************... |
571.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
*/
#define EXTRALARGE_DATASET
#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <math.h>
/* Include polybench co... |
GB_select_phase1.c | //------------------------------------------------------------------------------
// GB_select_count: count entries in eacn vector for C=select(A,thunk)
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// htt... |
bli_dotv_bgq_int.c | /*
BLIS
An object-based framework for developing high-performance BLAS-like
libraries.
Copyright (C) 2014, The University of Texas at Austin
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
- Redist... |
3d25pt.lbpar.c | #include <omp.h>
#include <math.h>
#define ceild(n,d) ceil(((double)(n))/((double)(d)))
#define floord(n,d) floor(((double)(n))/((double)(d)))
#define max(x,y) ((x) > (y)? (x) : (y))
#define min(x,y) ((x) < (y)? (x) : (y))
/*
* Order-2, 3D 25 point stencil
* Adapted from PLUTO and Pochoir test bench
*
* Tar... |
ibm128-unsupported.c | // RUN: %clang_cc1 -triple powerpc64le -emit-llvm-bc -fopenmp %s \
// RUN: -fopenmp-targets=powerpc64le,x86_64 -o %t-ppc-host.bc
// RUN: %clang_cc1 -verify -triple x86_64 -aux-triple powerpc64le -fopenmp \
// RUN: -fopenmp-is-device -fopenmp-host-ir-file-path %t-ppc-host.bc %s \
// RUN: -fsyntax-only
void foo(__... |
dem_fem_search.h | //
// Project Name: Kratos
// Last Modified by: $Author: msantasusana, croig $
// Date: $Date: 2015-10-26 19:37:47 $
// Revision: $Revision: 1.2 $
//
//
#if !defined(KRATOS_DEM_FEM_SEARCH_H_INCLUDED )
#define KRATOS_DEM_FEM_SEARCH_H_INCLUDED
// System includes
#include <st... |
convolution_winograd_dot_pack4.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 ... |
program_schedule_dynamic.c | #include <stdio.h>
#include <omp.h>
#include <stdlib.h>
#include <unistd.h>
int main(int argc, char* argv[]) {
int thread_count = strtol(argv[1], NULL, 10);
int n = strtol(argv[2], NULL, 10);
#pragma omp parallel for num_threads(thread_count) schedule(dynamic)
for (int i = 0; i < n; i ++) {
printf... |
c-omp.c | /* This file contains routines to construct GNU OpenMP constructs,
called from parsing in the C and C++ front ends.
Copyright (C) 2005, 2007, 2008 Free Software Foundation, Inc.
Contributed by Richard Henderson <rth@redhat.com>,
Diego Novillo <dnovillo@redhat.com>.
This file is part of GCC.
GCC is free... |
veccopy-ompt-target-wrong-return.c | #include <stdio.h>
#include <omp.h>
#include "callbacks.h"
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;
#pragma omp target parallel for
{
for (int j = 0; j< N; j++)
a[j]=b[j];
}
#pragma omp target teams distribu... |
GB_unaryop__ainv_fp32_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... |
test.c | #include <stdio.h>
int main()
{
int a[100];
int *p = &a[0];
int i;
for(i=0; i<100; i++) a[i] = i;
#pragma omp target data map(tofrom: a, p[0:100])
{
#pragma omp target map(tofrom: a, p[0:100])
{
int *q = p;
for(i=0; i<100; i++) {
a[i]++;
*q = (*q) + 1;
q++;
... |
openmp_reduction.c | #include <stdio.h>
#include <stdlib.h>
#include <sys/time.h>
#include <omp.h>
/*
Compilacao:
gcc -o openmp_reduction openmp_reduction.c -fopenmp -O3
Execucao:
./openmp_reduction 2048 2000 4
*/
#define SRAND_VALUE 1985
int tam;
int ger;
#define ESQ(i) (i + tam - 1) % tam
#define DIR(i) (i + 1) % tam
#define CIMA(i) ... |
OpenMPClause.h | //===- OpenMPClause.h - Classes for OpenMP clauses --------------*- 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
//
//===---------------------------... |
time.c | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <unistd.h>
#include <omp.h>
// Определение функции
double Func(double x) {
// Недействительные значения не должны вносить вклад в интеграл
if (x > 2) {
return 0;
}
return sqrt(4 - x*x);
}
// Формула Котеса рассчета определенного... |
GB_unop__one_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... |
openmp-ex11.c | #include <stdio.h>
#include <omp.h>
int main(void)
{
int N = 10;
#pragma omp parallel
{
int my_thread = omp_get_thread_num();
int i;
/* But openmp has a directive "for" for for loops */
#pragma omp for
for (i = 0; i < N; i++) {
printf("iteration %d, thread %d\n", i, my_thread);
}
}
... |
nested_mixed.c | // RUN: %libomp-compile && env OMP_DISPLAY_AFFINITY=true %libomp-run | %python %S/check.py -c 'CHECK' %s
#include <stdio.h>
#include <stdlib.h>
#include <omp.h>
#include "omp_testsuite.h"
int main(int argc, char** argv) {
omp_set_affinity_format("TESTER: tl:%L at:%a tn:%n nt:%N");
omp_set_nested(1);
#pragma omp... |
rose_plusAssign.c | #include "omp.h"
int main(int argc,char *argv[])
{
int i;
int j;
double a[20][20];
// memset(a,0,(sizeof(a)));
for (i = 0; i <= 18; i += 1) {
#pragma omp parallel for private (j)
for (j = 0; j <= 19; j += 1) {
a[i][j] += a[i + 1][j];
}
}
return 0;
}
|
tinyexr.h | /*
Copyright (c) 2014 - 2018, 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 the above copyright
notice, this l... |
openmp_cnn.h | #include "cnn.h"
#include "omp.h"
// #include <mutex>
#include <vector>
using namespace std;
class openmp_cnn
{
public:
global_config_t global_config;
block_config_t block_config;
int nthread_B, nthread_K, nthread_W, nthread_H;
vector<pair<int, int>>bound_B;
vector<pair<int, int>>bound_K;
vec... |
opi.c | #include <stdlib.h>
#include <stdio.h>
#ifdef _OPENMP
#include <omp.h>
#else
#define omp_get_max_threads() 1
#endif
int main(int argc, char **argv)
{
register double width,x;
double sum=0;
register int intervals, i;
double t;
if(argc < 2) {
fprintf(stderr,"\nFalta nº intervalos\n");
... |
mpi_cpd.c |
/******************************************************************************
* INCLUDES
*****************************************************************************/
#include "../splatt_mpi.h"
#include "../mttkrp.h"
#include "../timer.h"
#include "../thd_info.h"
#include "../tile.h"
#include "../util.h"
#includ... |
test.c |
#include <stdio.h>
#include <omp.h>
#include "../utilities/check.h"
#include "../utilities/utilities.h"
#define TRIALS (1)
#define N (992)
#define INIT() INIT_LOOP(N, {C[i] = 1; D[i] = i; E[i] = -i;})
#define ZERO(X) ZERO_ARRAY(N, X)
int main(void) {
check_offloading();
double A[N], B[N], C[N], D[N], E[N];
... |
GB_unop__identity_uint32_int64.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... |
PropagationMPlex.h | #ifndef _propagation_mplex_
#define _propagation_mplex_
#include "Matrix.h"
namespace mkfit {
inline void squashPhiMPlex(MPlexLV& par, const int N_proc)
{
#pragma omp simd
for (int n = 0; n < NN; ++n) {
if (par(n, 4, 0) >= Config::PI) par(n, 4, 0) -= Config::TwoPI;
if (par(n, 4, 0) < -Config::PI) par(n, ... |
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)... |
shared-clause.c | /*
gcc -fopenmp -O2 shared-clause.c -o shared-clause
*/
#include <stdio.h>
#ifdef _OPENMP
#include <omp.h>
#endif
main()
{
int i, n = 7;
int a[n];
for (i=0; i<n; i++)
a[i] = i+1;
// Se comparte la variable a por todas las hebras --> shared(a)
#pragma omp parallel for shared(a)
for (i=0; i<n; i++)
a[i] +... |
DemBones.h | ///////////////////////////////////////////////////////////////////////////////
// Dem Bones - Skinning Decomposition Library //
// Copyright (c) 2019, Electronic Arts. All rights reserved. //
///////////////////////////////////////////////////////////////////////////////
... |
dsysv.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/compute/zhesv.c, normal z -> d, Fri Sep 28 17:38:06 2018
*
**/
#include "plasma.h"
#include "plasma_async.h"
#incl... |
GB_binop__second_bool.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
tinyexr.h | /*
Copyright (c) 2014 - 2019, 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 the above copyright
notice, this l... |
GB_binop__band_int32.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
block-9.c | // { dg-do compile }
void foo(int i)
{
int j;
switch (i) // { dg-error "invalid entry" }
{
#pragma omp parallel
{ case 0:; }
#pragma omp for
for (j = 0; j < 10; ++ j)
{ case 1:; }
#pragma omp critical
{ case 2:; }
#pragma omp master
{ case 3:; }
#pragma omp sections
{ case 4... |
dsytrs.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/compute/zhetrs.c, normal z -> d, Fri Sep 28 17:38:07 2018
*
**/
#include "plasma.h"
#include "plasma_async.h"
#inc... |
test.c |
#include <stdio.h>
#include <omp.h>
#include "../utilities/check.h"
#include "../utilities/utilities.h"
#define TRIALS (1)
#define N (1024*3)
#define M (16*32)
#define INIT() INIT_LOOP(N, {C[i] = 1; D[i] = i; E[i] = -i;})
#define ZERO(X) ZERO_ARRAY(N, X)
double A[M][N], B[M][N], C[N], D[N], E[N];
double S[M];
d... |
segment.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
GB_unaryop__identity_bool_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... |
GB_transpose_bucket.c | //------------------------------------------------------------------------------
// GB_transpose_bucket: transpose and optionally typecast and/or apply operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserve... |
declare-simd-1.c | /* Test parsing of #pragma omp declare simd */
/* { dg-do compile } */
#pragma omp declare simd uniform (a) aligned (b : 8 * sizeof (int)) \
linear (c : 4) simdlen (8) notinbranch
#pragma omp declare simd uniform (c) aligned (b : 4 * sizeof (int)) linear (a \
: 4) simdlen (4) inbranch
int f1 (int a, ... |
stencil2d.c | #include <stdio.h>
#include <stdlib.h>
#define ROW 5
#define COL 5
#define LIMIT 2
int main(){
float *A = (float *)malloc(ROW*COL*sizeof(float)); //Matriz creada
float *B = (float *)malloc(ROW*COL*sizeof(float)); //2da Matriz, que usaremos para calcular valores.
//Primero vamos a inicializar la matri... |
idasFoodWeb_bnd_omp.c | /*
* -----------------------------------------------------------------
* Programmer(s): Daniel R. Reynolds and Ting Yan @ SMU
* Based on idaFoodWeb_bnd.c and parallelized with OpenMP
* -----------------------------------------------------------------
* SUNDIALS Copyright Start
* Copyright (c) 2002-2022, Lawr... |
GB_unaryop__identity_bool_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... |
omp_loop.h | // -*- C++ -*-
// Copyright (C) 2007-2020 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... |
pjenccc1.c | // Copyright (c) 2018 Intel Corporation
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publ... |
parfor.h | // Copyright 2019 Google LLC. 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
//
// https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicabl... |
ProgressBar.h | /**
* Copyright (c) 2021 Darius Rückert
* Licensed under the MIT License.
* See LICENSE file for more information.
*/
#pragma once
#include "saiga/config.h"
#include "saiga/core/math/imath.h"
#include "saiga/core/time/all.h"
#include "saiga/core/util/Thread/SpinLock.h"
#include "saiga/core/util/Thread/threadName.h... |
ordered-1.c | /* { dg-do run } */
/* { dg-options "-O2 -fopenmp-simd" } */
/* { dg-additional-options "-msse2" { target sse2_runtime } } */
/* { dg-additional-options "-mavx" { target avx_runtime } } */
#define N 1024
extern
#ifdef __cplusplus
"C"
#endif
void abort (void);
int last;
void
bar (unsigned char *a, int i, int safelen)... |
hybrid_whereami.c | /* hybrid_whereami.c is a driver
1.) Get line arguments (optional): help or number o seconds for load
2.) Start MPI
Option to EASILY set affinity here.
3.) Store map for each rank
4.) Start OpenMP parallel region
5.) Store map for each thread
) MPI call to report
6.) ... |
Operator.h | //
// Cubism3D
// Copyright (c) 2018 CSE-Lab, ETH Zurich, Switzerland.
// Distributed under the terms of the MIT license.
//
// Created by Guido Novati (novatig@ethz.ch) and Christian Conti.
//
#ifndef CubismUP_3D_Operator_h
#define CubismUP_3D_Operator_h
#include "../SimulationData.h"
CubismUP_3D_NAMESPACE_BEGI... |
graph_io_block.h | // Copyright 2016, National University of Defense Technology
// Authors: Xuhao Chen <cxh@illinois.edu> and Pingfan Li <lipingfan@163.com>
#include <vector>
#include <set>
#include <iostream>
#include <fstream>
#include <sstream>
#include <string.h>
#include <algorithm>
//#include <iomanip>
typedef float WeightT;
stru... |
colorspace.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
dufu17r.c | /*
* Date: 11 December 2015
* Contact: Thomas Peyrin - thomas.peyrin@gmail.com
*/
/*
* Boomerang cryptanalysis of SKINNY
* Date: March 21, 2020
* Author: Hosein Hadipour
* Contact: hsn.hadipour@gmail.com
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <mat... |
_phonopy.c | /* Copyright (C) 2011 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... |
draw.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
GB_unop__tan_fc64_fc64.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http://... |
sampling.c | // Copyright (c) 2018-2019 Osamu Hirose
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publ... |
strlib_akechi.h | #pragma once
#ifndef AKECHI_LIB_9f8vy8hhdsh93
#define AKECHI_LIB_9f8vy8hhdsh93
#include <algorithm>
#include <iostream>
#include <thread>
#include <string>
#include <vector>
#include <map>
#include <mutex>
#include <unordered_map>
#include <set>
#include <unordered_set>
#include <stack>
#include <sstream>
#include <fst... |
colorspace_ops.h | #ifndef colorspace_ops_h
#define colorspace_ops_h
#include <aRibeiroCore/aRibeiroCore.h>
#include <aRibeiroPlatform/aRibeiroPlatform.h>
using namespace aRibeiro;
#include <stdint.h>
#include <stdlib.h>
#include <memory.h>
#include <string.h>
#if defined(ARIBEIRO_SSE2)
#ifdef _MSC_VER //_WIN32
#include <i... |
GB_binop__copysign_fp64.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX... |
SpatialConvolutionMM.c | #ifndef TH_GENERIC_FILE
#define TH_GENERIC_FILE "generic/SpatialConvolutionMM.c"
#else
static inline void THNN_(SpatialConvolutionMM_shapeCheck)(
THTensor *input, THTensor *gradOutput,
THTensor *weight, THTensor *bias,
int kH, int kW, int dH, int dW, int padH, int padW) {
THArgCheck(kW > 0 && kH > 0, 9,
... |
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) ... |
close_enter_exit.c | // RUN: %libomptarget-compile-run-and-check-generic
// REQUIRES: unified_shared_memory
// UNSUPPORTED: clang-6, clang-7, clang-8, clang-9
// Fails on amdgpu with error: GPU Memory Error
// XFAIL: amdgcn-amd-amdhsa
// XFAIL: amdgcn-amd-amdhsa-newRTL
#include <omp.h>
#include <stdio.h>
#pragma omp requires unified_sh... |
block-10.c | // { dg-do compile }
void foo(int i)
{
int j;
switch (i) // { dg-error "invalid entry to OpenMP structured block" }
{
#pragma omp parallel // { dg-warning "statement will never be executed" }
{ case 0:; }
}
switch (i) // { dg-error "invalid entry to OpenMP structured block" }
{
#pragma omp for // {... |
conv_avx.h | #include <immintrin.h>
static float* channel(struct csi_tensor* t, int64_t c)
{
return (float*)t->data + c * t->dim[2] * t->dim[3];
}
static void conv_trans_kernel_avx(struct csi_tensor* o_kernel, struct csi_tensor* t_kernel)
{
float* kernel = o_kernel->data;
float* ret;
csi_tensor_copy(t_kernel, o_ke... |
MathTools.h | /**
* \file
* \copyright
* Copyright (c) 2012-2019, OpenGeoSys Community (http://www.opengeosys.org)
* Distributed under a Modified BSD License.
* See accompanying file LICENSE.txt or
* http://www.opengeosys.org/project/license
*/
#pragma once
#include <cstddef>
#ifdef _OP... |
GB_AxB_saxpy3_cumsum.c | //------------------------------------------------------------------------------
// GB_AxB_saxpy3_cumsum: finalize nnz(C(:,j)) and find cumulative sum of Cp
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
/... |
Example_target.1.c | extern void init(float*, float*, int);
extern void output(float*, int);
void vec_mult(int N)
{
int i;
float p[N], v1[N], v2[N];
init(v1, v2, N);
#pragma omp target
#pragma omp parallel for private(i)
for (i=0; i<N; i++)
p[i] = v1[i] * v2[i];
output(p, N);
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.