source stringlengths 3 92 | c stringlengths 26 2.25M |
|---|---|
print_affinity.c | #define _GNU_SOURCE
#include <stdio.h>
#include <unistd.h> // gethostname, getopt
#ifdef _OPENMP
#include <omp.h>
#endif
#ifndef __APPLE__
#include <sched.h> // sched_getaffinity
extern void runnable (cpu_set_t *, int *, int *);
void print_affinity_ ()
{
char hnbuf[64];
int thread = 0;
int lo;
int hi;
cpu... |
cpl_test.c | /*
* This file is part of the ESO Common Pipeline Library
* Copyright (C) 2001-2017 European Southern Observatory
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the ... |
GB_wait.c | //------------------------------------------------------------------------------
// GB_wait: finish all pending computations on a single matrix
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX-Licen... |
par_csr_matvec.c | /******************************************************************************
* Copyright 1998-2019 Lawrence Livermore National Security, LLC and other
* HYPRE Project Developers. See the top-level COPYRIGHT file for details.
*
* SPDX-License-Identifier: (Apache-2.0 OR MIT)
**************************************... |
omp.c | #include <stdio.h>
#include <omp.h>
int a, b, i, tid;
float x;
#pragma omp threadprivate(a, x)
int main(int argc, char *argv[]) {
/* Explicitly turn off dynamic threads */
omp_set_dynamic(0);
printf("1st Parallel Region:\n");
#pragma omp parallel private(b,tid)
{
tid = omp_get_thread_num(... |
ocp_nlp_common.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... |
ThreadPool.h | /*
Copyright (c) 2017, Michael Kazhdan
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this list
of conditions and the following di... |
GB_unop__tanh_fc32_fc32.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX-Li... |
GB_binop__lxor_uint32.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
band.h | // Copyright (c) 2013-2017 Anton Kozhevnikov, Thomas Schulthess
// 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 copyright notic... |
spmm.h | /*!
* Copyright (c) 2020 by Contributors
* \file array/cpu/spmm.h
* \brief SPMM CPU kernel function header.
*/
#ifndef DGL_ARRAY_CPU_SPMM_H_
#define DGL_ARRAY_CPU_SPMM_H_
#include <dgl/array.h>
#include <dgl/bcast.h>
#include <limits>
#include <algorithm>
namespace dgl {
namespace aten {
namespace cpu {
/*!
* ... |
fopenmp-extensions.c | // RUN: %clang_cc1 -verify=ompx -fopenmp %s
// RUN: %clang_cc1 -verify=ompx -fopenmp-simd %s
// RUN: %clang_cc1 -verify=ompx -fopenmp -fopenmp-extensions %s
// RUN: %clang_cc1 -verify=ompx -fopenmp-simd -fopenmp-extensions %s
// RUN: %clang_cc1 -verify=omp -fopenmp -fno-openmp-extensions %s
// RUN: %clang_cc1 -verify... |
ep.c |
/*[]*/
struct __sFILEX ;
/*[]*/
int printf(const char *restrict , ...);
/*[]*/
extern double log(double );
/*[]*/
extern double fabs(double );
/*[]*/
extern double pow(double , double );
/*[]*/
extern double sqrt(double );
/*[]*/
typedef int boolean;
/*[]*/
extern double randlc(double *, double );
/*[]*/
extern void v... |
commondraw.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... |
main.c | #include <stdio.h>
#include <math.h>
#include <omp.h>
#define mm 15
#define npart 4*mm*mm*mm
/*
* Function declarations
*/
void
dfill(int,double,double[],int);
void
domove(int,double[],double[],double[],double);
void
dscal(int,double,double[],int);
void
fcc(double[],int,int,d... |
threshold.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
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... |
private.c | #include <omp.h>
#include <stdio.h>
int alpha[10],beta[10],i;
#pragma omp threadprivate(alpha)
main()
{
/* first parallel region */
#pragma omp parallel private(i,beta)
{ int id ;
id = omp_get_thread_num();
for(i=0;i<10;i++)
alpha[i] = beta[i] = id * i;
}
/* second parallel region */
#pragma om... |
laplace2d.c | #include <stdio.h>
#include <math.h>
#include <string.h>
#include "timer.h"
#define NN 4096
#define NM 4096
double A[NN][NM];
double Anew[NN][NM];
int main(int argc, char** argv)
{
const int n = NN;
const int m = NM;
const int iter_max = 1000;
const double tol = 1.0e-6;
double error = 1.... |
Example_copyin.1.c | /*
* @@name: copyin.1c
* @@type: C
* @@compilable: yes
* @@linkable: no
* @@expect: success
*/
#include <stdlib.h>
float* work;
int size;
float tol;
#pragma omp threadprivate(work,size,tol)
void build()
{
int i;
work = (float*)malloc( sizeof(float)*size );
for( i = 0; i < size; ++i ) work[i] = tol;
}
void cop... |
gmm.c | /*
* gmm.c
*
* Contains definitions of functions for training
* Gaussian Mixture Models
*
* Copyright (C) 2015 Sai Nitish Satyavolu
*/
#include "gmm.h"
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <math.h>
#ifdef _OPENMP
#include <omp.h>
#endif
#ifdef MEX_COMPILE
#in... |
image.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
mm.best-par.c |
#include <stdio.h>
#include <sys/time.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))
#define M NCONT
#define N NCONT
#define K CONT
double A[M][K]... |
convolution_1x1_pack4_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 ... |
fig4.72-num-threads-clause.c | /*
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
Copyright 2009 Sun Microsystems, Inc. All rights reserved.
The contents of this file are subject to the terms of the BSD License("BSD")(the "License").
You can obtain a copy of the License at: http://www.opensparc.net/pubs/t1/licenses/BSD+_Lice... |
fourier.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
GB_unop__frexpe_fp32_fp32.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-Li... |
GB_binop__max_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-... |
utils.c | #include <cdnn/utils.h>
float cache;
int return_cache;
int nn_threads;
/**!
* Creates a matrix filled with zeros.
* @param dims An array of matrix dimensions (int)[rows,columns]
* @result A pointer to the created matrix.
* @return A pointer to the created matrix.
*/
dARRAY * zeros(int * dims){
dARRAY * matr... |
MLFDeserializer.h | //
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE.md file in the project root for full license information.
//
#pragma once
#include <boost/noncopyable.hpp>
#include "HTKDeserializer.h"
#include "CorpusDescriptor.h"
#include "MLFUtils.h"
#include "FileWrapper.h"
#inclu... |
simd_utils.h | /*
* Project : SIMD_Utils
* Version : 0.2.2
* Author : JishinMaster
* Licence : BSD-2
*/
#pragma once
#ifdef __cplusplus
extern "C" {
#endif
#define MAJOR_VERSION 0
#define MINOR_VERSION 2
#define SUB_VERSION 2
#ifdef OMP
#include <omp.h>
#endif
#include <math.h>
#include <stdint.h>
#i... |
OMPIRBuilder.h | //===- IR/OpenMPIRBuilder.h - OpenMP encoding builder for LLVM IR - 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
//
//===---------------------------... |
versaoA.c | // Fernanda Lyra Alves
// Ivan Dos Santos Muniz
// Programação Concorrente e Distribuída - 2020.2
#include <omp.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/time.h>
static const int cel_morta = 0;
static const int cel_viva = 1;
static const unsigned int num_geracoes = 2000;
static cons... |
GB_builder.c | //------------------------------------------------------------------------------
// GB_builder: build a matrix from tuples
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
// http://suitesparse.com See Gra... |
schedbench.c | /****************************************************************************
* *
* OpenMP MicroBenchmark Suite - Version 3.1 *
* *
* ... |
whirlpool_fmt_plug.c | /* whirlpool 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 bin... |
pr85956.c | /* PR middle-end/85956 */
/* { dg-do compile } */
/* { dg-additional-options "-O2 -Wall" } */
void
foo (int n, void *p)
{
int (*a)[n] = (int (*)[n]) p;
#pragma omp parallel shared(a) default(none)
#pragma omp master
a[-1][-1] = 42; /* { dg-warning "array subscript -1 is below array bounds" } */
}
|
nowait.c | #include <stdio.h>
#include <omp.h>
#define N 1000
#define CHUNKSIZE 100
int main(int argc, char *argv[]) {
int i, chunk;
float a[N], b[N], c[N];
/* Some initializations */
for (i = 0; i < N; i++)
{
a[i] = b[i] = i;
}
chunk = CHUNKSIZE;
for (i = 0; i < N; i++)
{
pr... |
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... |
forest.c | #include "forest.h"
#ifdef USING_MPI
const MPI_Comm comm = MPI_COMM_WORLD;
int myrank, size;
#endif
int main(int argc, char** argv) {
int i, y, seed;
args* myArgs;
forest* f;
cell** swapGrid;
struct random_data* rand_state;
char rand_buf[256];
memset(rand_buf, 'q', (size_t)256);
int ... |
loop1.c | #include <stdio.h>
#include <omp.h>
int main()
{
int i,j;
// int innerreps = 100;
#pragma omp parallel private(j)
{
// for (j=0; j<innerreps; j++)
{
#pragma omp for schedule(static,2)
for (i=0; i<32; i++)
{
printf ("thread %d is executing %d \n",omp_get_thread_num(),i);
// ... |
t.simple.c | #include <stdlib.h>
#include <stdio.h>
#include "omp.h"
#pragma offload_attribute(push, target(mic))
#include "mkl.h"
#pragma offload_attribute(pop)
int manual_sync;
omp_lock_t offload_lock;
__declspec(target(mic))
void local_dgemm(int N, int LD, double *A, double *B, double *C)
{
cblas_dgemm(CblasColMajor, CblasN... |
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... |
BlockOps.h |
/*****************************************************************************
*
* Copyright (c) 2003-2018 by The University of Queensland
* http://www.uq.edu.au
*
* Primary Business: Queensland, Australia
* Licensed under the Apache License, version 2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Development unt... |
laplace2d.c | /*
* Copyright 2012 NVIDIA Corporation
*
* 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 ... |
Vec.h | /*************************************************************************
* Copyright (c) 2014 Zhang Dongdong
* 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
*... |
transition_matrix.h | /*
* Created on: Mar 22, 2016
* Author: Steffen Rechner <steffen.rechner@informatik.uni-halle.de>
*
* This file is part of the marathon software.
*
* Copyright (c) 2016, Steffen Rechner
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation... |
extern_init.c | #include <stdio.h>
#include "assert.h"
#include <unistd.h>
#define NZ 3
#pragma omp declare target
int colstat[NZ]={1,2,3};
#pragma omp end declare target
int main(){
#pragma omp target map(alloc:colstat[0:NZ])
{
colstat[1] = 1111;
}
fprintf(stderr, "BEFORE colstat[0..2] %d %d %d \n", colstat[0], colstat[1], ... |
SoaDistanceTableAA.h | //////////////////////////////////////////////////////////////////////////////////////
// This file is distributed under the University of Illinois/NCSA Open Source License.
// See LICENSE file in top directory for details.
//
// Copyright (c) 2016 Jeongnim Kim and QMCPACK developers.
//
// File developed by: Jeongnim ... |
GB_unaryop__lnot_bool_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... |
omp-loop03.c | extern void abort (void);
int a;
void
foo ()
{
int i;
a = 30;
#pragma omp barrier
#pragma omp for lastprivate (a)
for (i = 0; i < 1024; i++)
{
a = i;
}
if (a != 1023)
abort ();
}
int
main (void)
{
#pragma omp parallel num_threads (64)
foo ();
return 0;
}
|
GB_unaryop__ainv_int32_fp32.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http... |
ops.h | /*******************************************************************************
* Copyright (c) 2015-2018 Skymind, Inc.
*
* This program and the accompanying materials are made available under the
* terms of the Apache License, Version 2.0 which is available at
* https://www.apache.org/licenses/LICENSE-2.0.
*
*... |
GB_assign_zombie5.c | //------------------------------------------------------------------------------
// GB_assign_zombie5: delete entries in C for C_replace_phase
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-License... |
NeighborhoodGraph.h | #ifndef _SPTAG_COMMON_NG_H_
#define _SPTAG_COMMON_NG_H_
#include "../VectorIndex.h"
#include "CommonUtils.h"
#include "Dataset.h"
#include "FineGrainedLock.h"
#include "QueryResultSet.h"
namespace SPTAG
{
namespace COMMON
{
class NeighborhoodGraph
{
public:
NeighborhoodGr... |
DRB050-functionparameter-orig-yes.c | /*
Copyright (c) 2017, Lawrence Livermore National Security, LLC.
Produced at the Lawrence Livermore National Laboratory
Written by Chunhua Liao, Pei-Hung Lin, Joshua Asplund,
Markus Schordan, and Ian Karlin
(email: liao6@llnl.gov, lin32@llnl.gov, asplund1@llnl.gov,
schordan1@llnl.gov, karlin1@llnl.gov)
LLNL-CODE-73214... |
GB_binop__lor_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-... |
GB_hyper_prune.c | //------------------------------------------------------------------------------
// GB_hyper_prune: remove empty vectors from a hypersparse Ap, Ah list
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPD... |
GB_unaryop__lnot_uint32_uint64.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
// http... |
bli_gemm_ref.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... |
utils.h | #pragma once
#ifdef WIN32
#define _USE_MATH_DEFINES
#include <math.h>
#else
#include <math.h>
#endif
#include <float.h>
#include <omp.h>
#include <string.h>
#include <chrono>
#include <memory>
#include <mutex>
#include <random>
#include <vector>
#include <open3d/geometry/Geometry.h>
#include <open3d/geometry/PointClo... |
omp_for_schedule_guided.c | // RUN: %libomp-compile-and-run
/* Test for guided scheduling
* Ensure threads get chunks interleavely first
* Then judge the chunk sizes are decreasing to a stable value
* Modified by Chunhua Liao
* For example, 100 iteration on 2 threads, chunksize 7
* one line for each dispatch, 0/1 means thread id
* 0 0 0 0 ... |
blas_l1_kernel.c | /*******************************************************************************
* Copyright 2019 UChicago Argonne, LLC.
* (c.f. AUTHORS, LICENSE)
*
* This file is part of the AML project.
* For more info, see https://github.com/anlsys/aml
*
* SPDX-License-Identifier: BSD-3-Clause
******************************... |
image.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
data_augmentation.h | /*
Copyright (c) 2019, Sanaxen
All rights reserved.
Use of this source code is governed by a MIT license that can be found
in the LICENSE file.
*/
#ifndef _DATA_AUGMANTATION_H
#define _DATA_AUGMANTATION_H
namespace cpp_torch
{
namespace test
{
void Image3CannelDataAugment(std::vector<tiny_dnn::vec_t>& train_imag... |
GB_binop__isge_uint32.c | //------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-... |
triplet_kpoint.c | /* Copyright (C) 2015 Atsushi Togo */
/* All rights reserved. */
/* These codes were originally parts of spglib, but only develped */
/* and used for phono3py. Therefore these were moved from spglib to */
/* phono3py. This file is part of phonopy. */
/* Redistribution and use in source and binary forms, with or witho... |
ast-dump-openmp-target-parallel-for.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_one(int x) {
#pragma omp target parallel for
for (int i = 0; i < x; i++)
;
}
void test_two(int x, int y) {
#pragma omp target parallel for
for (int i ... |
p99.h | /* This may look like nonsense, but it really is -*- mode: C -*- */
/* */
/* Except for parts copied from previous work and as explicitly stated below, */
/* the authors and copyright holders for this work are as follows: ... |
trsm_x_sky_n_hi_row.c | #include "alphasparse/kernel.h"
#include "alphasparse/util.h"
#include "alphasparse/opt.h"
#include <memory.h>
#ifdef _OPENMP
#include <omp.h>
#endif
alphasparse_status_t ONAME(const ALPHA_Number alpha, const ALPHA_SPMAT_SKY *A, const ALPHA_Number *x, const ALPHA_INT columns, const ALPHA_INT ldx, ALPHA_Number *y, cons... |
bitmap.h | /*!
* Copyright 2014 by Contributors
* \file bitmap.h
* \brief a simple implement of bitmap
* NOTE: bitmap is only threadsafe per word access, remember this when using bitmap
* \author Tianqi Chen
*/
#ifndef XGBOOST_COMMON_BITMAP_H_
#define XGBOOST_COMMON_BITMAP_H_
#include <dmlc/omp.h>
#include <vector>
names... |
CGOpenMPRuntime.h | //===----- CGOpenMPRuntime.h - Interface to OpenMP Runtimes -----*- 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
//
//===---------------------------... |
Forza.h | #ifndef Forza_h__
#define Forza_h__
struct PatternData
{
uint32_t Count;
uint32_t Size;
uint32_t Length[16];
uint32_t Skip[16];
__m128i Value[16];
};
void GeneratePattern(const char* Signature, const char* Mask, PatternData* Out)
{
auto l = strlen(Mask);
Out->Count = 0;
for (auto i = 0; i < l; i++)
{
if... |
elemwise_binary_scalar_op.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 ... |
3503.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... |
displacement_lagrangemultiplier_frictional_contact_criteria.h | // KRATOS ___| | | |
// \___ \ __| __| | | __| __| | | __| _` | |
// | | | | | ( | | | | ( | |
// _____/ \__|_| \__,_|\___|\__|\__,_|_| \__,_|_| MECHANICS
//
// License: BSD License
// ... |
util_test.c | /*
* This file is part of ABCDK.
*
* MIT License
*
*/
#include <stdio.h>
#include <assert.h>
#include <unistd.h>
#include <string.h>
#include <linux/serial.h>
#include "abcdk-util/general.h"
#include "abcdk-util/getargs.h"
#include "abcdk-util/geometry.h"
#include "abcdk-util/ffmpeg.h"
#include "abcdk-util/bmp.h... |
GB_unop__log1p_fp32_fp32.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX-Li... |
GB_binop__bget_uint16.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved.
// SPDX... |
rumi-64-128-18r.c | /*
* Date: 11 December 2015
* Contact: Thomas Peyrin - thomas.peyrin@gmail.com
*/
/*
* Simulation of boomerang analysis for Skinny
* Date: March 21, 2020
* Author: Hosein Hadipour
* Contact: hsn.hadipour@gmail.com
*/
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <math.h>
#incl... |
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... |
GB_unop__identity_fp32_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... |
omp_for_schedule_dynamic.c | // RUN: %libomp-compile-and-run
/*
* Test for dynamic scheduling with chunk size
* Method: calculate how many times the iteration space is dispatched
* and judge if each dispatch has the requested chunk size
* unless it is the last one.
* It is possible for two adjacent chunks are assigned to the same thre... |
GB_unop__identity_int64_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... |
black_kernel.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/2+1; row++)
{
int NUM_2 = NUM >> 1;
Real p_ij = pres_black(col, row);
Real p_im1j = pres_red(col - 1, row);
Real p_ip1j = pres_red(col + 1, row... |
segment.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
lcpi_logic.c | /*
* Copyright (c) 2011-2016 University of Texas at Austin. All rights reserved.
*
* $COPYRIGHT$
*
* Additional copyrights may follow
*
* This file is part of PerfExpert.
*
* PerfExpert is free software: you can redistribute it and/or modify it under
* the terms of the The University of Texas at Austin Resea... |
p4.c | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <time.h>
#include <omp.h>
#define ISIZE 1000
#define JSIZE 1000
int main(int argc, char **argv) {
double *a = new double[ISIZE*JSIZE];
double *A = new double[ISIZE*JSIZE];
FILE *ff;
int nth = 1;
if (argc == 2) nth = atoi(argv[1]);
... |
elemproduct.c | #include<stdio.h>
#include<omp.h>
void elemprod(double *c, double *a, double *b, int len){
int i;
#pragma omp parallel for
for(i=0;i<len;i++){
c[i] = a[i] * b[i];
printf("%f, %f, %f\n", a[i],b[i],c[i]);
}
}
int main(int argc, char *argv[]){
double v1[10] = {1,2,3,4,5,6,7,8,9,10};... |
bml_submatrix_ellpack.c | #include "../../macros.h"
#include "../bml_logger.h"
#include "../bml_submatrix.h"
#include "../bml_types.h"
#include "../dense/bml_types_dense.h"
#include "bml_submatrix_ellpack.h"
#include "bml_types_ellpack.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#ifdef _OPENMP
#include <o... |
GridInit.c | /*******************************************************************************
Copyright (c) 2016 Advanced Micro Devices, Inc.
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 so... |
salted_sha1_fmt_plug.c | /*
* generic salted-sha1 support for LDAP style password storage
*
* Copyright (c) 2003 Simon Marechal, salt length fixes (c) 2012 magnum
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted.
*/
#if FMT_EXTERNS_H
extern struct fmt_main fmt_saltedsha;
#elif FMT_REG... |
jacobi_cpu_omp_kernel.c | #include <homp.h>
#define REAL float
void jacobi_cpu_omp_wrapper2(omp_offloading_t *off, long n,long m,REAL *u,REAL *uold,long uold_n, long uold_m, int uold_0_offset, int uold_1_offset)
{
int i, j;
int num_omp_threads = off->dev->num_cores;
#pragma omp parallel for private(j,i) shared(m,n,uold,u,uold_0_offset,... |
LSH_query_batch.c | /* AUTORIGHTS
Copyright (C) 2007 Princeton University
This file is part of Ferret Toolkit.
Ferret Toolkit 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 2, or (at your option)
any later ver... |
GB_unaryop__lnot_int32_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... |
divsufsort.c | /*
* divsufsort.c for libdivsufsort
* Copyright (c) 2003-2008 Yuta Mori All Rights Reserved.
*
* 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 ... |
wow_srp_fmt_plug.c | /*
* This software was written by Jim Fougeron jfoug AT cox dot net
* in 2012. 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) 20... |
DRB030-truedep1-var-yes.c | /*
Copyright (c) 2017, Lawrence Livermore National Security, LLC.
Produced at the Lawrence Livermore National Laboratory
Written by Chunhua Liao, Pei-Hung Lin, Joshua Asplund,
Markus Schordan, and Ian Karlin
(email: liao6@llnl.gov, lin32@llnl.gov, asplund1@llnl.gov,
schordan1@llnl.gov, karlin1@llnl.gov)
LLNL-CODE-73214... |
test_1.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... |
MINDSSCbox.h |
void boxfilter(float* input,float* temp1,float* temp2,int hw,int m,int n,int o){
int sz=m*n*o;
for(int i=0;i<sz;i++){
temp1[i]=input[i];
}
for(int k=0;k<o;k++){
for(int j=0;j<n;j++){
for(int i=1;i<m;i++){
temp1[i+j*m+k*m*n]+=temp1[(i-1)+j*m+k*m*n];
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.