source stringlengths 3 92 | c stringlengths 26 2.25M |
|---|---|
transpose.h | // This code is part of the Problem Based Benchmark Suite (PBBS)
// Copyright (c) 2011-2016 Guy Blelloch and the PBBS team
//
// 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 restri... |
dfe.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/mpi/blrm/dfe.c
* @version 0.3.0
* @author... |
GB_binop__lt_int16.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
csr_matop.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)
**************************************... |
sol1.c | /**
* \file
* \brief [Problem 14](https://projecteuler.net/problem=14) solution
* \author [Krishna Vedala](https://github.com/kvedala)
*
* Since the computational values for each iteration step are independent,
* we can compute them in parallel. However, the maximum values should be
* updated in synchrony so tha... |
GB_binop__lor_uint32.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
cache.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
MD5_std.c | /*
* This file is part of John the Ripper password cracker,
* Copyright (c) 1996-2001,2003,2006,2011 by Solar Designer
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted.
*
* There's ABSOLUTELY NO WARRANTY, express or implied.
*
* This implementation of FreeBSD... |
top_k_v2_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... |
MatrixInverseModel.h | /*
* Copyright 2016 [See AUTHORS file for list of authors]
*
* 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 require... |
transpose.h | #ifndef _TRANSPOSE_H_
#define _TRANSPOSE_H_
#include <atomic>
/**
** while the name suggests CSR -> CSC,
** one can simply use this to transpose a matrix in CSR format to its transpose also in CSR format
** or vice versa: transpose a matrix in CSC format to its transpose also in CSC format
** just read CSR relat... |
GB_unop__identity_fc32_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... |
convolution_1x1_pack8to1_int8.h | // Tencent is pleased to support the open source community by making ncnn available.
//
// Copyright (C) 2022 THL A29 Limited, a Tencent company. All rights reserved.
//
// Licensed under the BSD 3-Clause License (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy ... |
device-1.c | /* { dg-do run } */
/* { dg-require-effective-target offload_device_nonshared_as } */
#include <omp.h>
#include <stdlib.h>
int main ()
{
int a = 100;
int b = 0;
int c, d;
#pragma omp target if(a > 200 && a < 400) map(from: c)
c = omp_is_initial_device ();
#pragma omp target data map(to: b) if(a > 200 ... |
out.c | #define max(a,b) (((a) < (b))? (b) : (a))
#define min(a,b) (((a) < (b))? (a) : (b))
#include <omp.h>
void lufac(int M, int N, int K, double alpha, double *A, int lda, double *L, int LDB, double beta, double *U, int LDC) {
int i;
int j;
int k;
int k_bk_1;
int k_bk_2;
int i_bk_3;
int j_bk_4;
double _A_0_0;
double _... |
par_lr_interp.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)
**************************************... |
kwallet_fmt_plug.c | /* KDE KWallet cracker patch for JtR. Written by Narendra Kangralkar
* <narendrakangralkar at gmail.com> and Dhiru Kholia <dhiru at openwall.com>.
*
* Also see https://github.com/gaganpreet/kwallet-dump ;)
*
* This software is Copyright (c) 2013 by above authors and it is hereby
* released to the general public u... |
displacement_contact_criteria.h | // KRATOS ___| | | |
// \___ \ __| __| | | __| __| | | __| _` | |
// | | | | | ( | | | | ( | |
// _____/ \__|_| \__,_|\___|\__|\__,_|_| \__,_|_| MECHANICS
//
// License: BSD License
// ... |
reduction-clause.c | #include <stdio.h>
#include <stdlib.h>
#ifdef _OPENMP
#include <omp.h>
#else
#define omp_get_thread_num() 0
#endif
main(int argc, char **argv) {
int i, n=20, a[n],suma=10;
if(argc < 2) {
fprintf(stderr,"Falta iteraciones\n");
exit(-1);
}
n = atoi(argv[1]);
if (n>20) {
n=20;
printf("n=%d",... |
attribute.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
convolution_sgemm_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 ... |
TRPO_MuJoCo.c | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <sys/time.h>
#include "omp.h"
#include "TRPO.h"
#include "mujoco.h"
#include "mjmodel.h"
#include "lbfgs.h"
double TRPO_MuJoCo (TRPOparam param, const int NumIter, const size_t NumThreads) {
//////////////////// Read Parameter... |
tree.h | #ifndef LIGHTGBM_TREE_H_
#define LIGHTGBM_TREE_H_
#include <LightGBM/meta.h>
#include <LightGBM/dataset.h>
#include <string>
#include <vector>
#include <memory>
#include <map>
namespace LightGBM {
#define kCategoricalMask (1)
#define kDefaultLeftMask (2)
/*!
* \brief Tree model
*/
class Tree {
public:
/*!
* \... |
functionCalls.c | int foobar() {
int x;
bar(1, 0);
#pragma omp barrier
x = 10;
}
int bar(int x, int y) {
foobar();
}
int foo() {
int i = 10, j = 20;
bar(i, j);
// foobar();
}
int main() {
int p = 10, q = 30;
foo();
// bar(p, q);
// foobar();
}
|
as400_des_fmt_plug.c | // AS/400 DES plugin for JtR
// This software is Copyright (c) 2016 Rob Schoemaker (@5up3rUs3r) and Bart Kulach (@bartholozz)
// 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.
//
// See http... |
Sema.h | //===--- Sema.h - Semantic Analysis & AST Building --------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===---------------------------... |
util.h | /*
Copyright (c) 2013, Taiga Nomi
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 conditi... |
fourier.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
pf3dbench.h | extern rcomplex *t0, *t2, *t0_sav, *t2_sav, *tN_new;
extern rcomplex *t0_big, *t0_big_sav;
extern real *thetb_sav, *thetbig;
extern long nbig;
extern int nxy_mx;
extern int num_thr;
extern double *rnd;
extern double tot_tim;
extern real *iptmp, *optmp;
extern rcomplex *sndbuf, *rcvbuf;
extern rcomplex *afftb... |
decorate.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
GB_unaryop__ainv_uint64_bool.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2020, All Rights Reserved.
// http... |
task_if0-depend.c | // RUN: %libomp-compile-and-run | %sort-threads | FileCheck %s
// REQUIRES: ompt
#include "callback.h"
#include <omp.h>
int main() {
int x = 0;
#pragma omp parallel num_threads(2)
{
#pragma omp master
{
print_ids(0);
printf("%" PRIu64 ": address of x: %p\n", ompt_get_thread_data()->value,
... |
DRB026-targetparallelfor-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... |
par_interp.c | /*BHEADER**********************************************************************
* Copyright (c) 2008, Lawrence Livermore National Security, LLC.
* Produced at the Lawrence Livermore National Laboratory.
* This file is part of HYPRE. See file COPYRIGHT for details.
*
* HYPRE is free software; you can redistribute... |
jacobi_omp.c | /* An example code
*
* */
#include <stdio.h>
#include <math.h>
void driver (void);
void initialize (void);
void jacobi (void);
void error_check (void);
#define MSIZE 200
int n, m, mits;
double tol, relax = 1.0, alpha = 0.0543;
double u[MSIZE][MSIZE], f[MSIZE][MSIZE], uold[MSIZE][MSIZE];
double dx, dy;
int
main (v... |
lastpass_fmt_plug.c | /* LastPass offline cracker patch for JtR. Hacked together during January of 2013 by
* Dhiru Kholia <dhiru.kholia at gmail.com>.
*
* All the hard work was done by Milen (author of hashkill).
*
* This software is Copyright (c) 2012, Dhiru Kholia <dhiru.kholia at gmail.com>,
* and it is hereby released to the gener... |
j3d7pt.gold.h | #include <cstring>
using std::memcpy;
template <class T>
void jacobi_gold(T *fout, const T *fin, double h2inv, double a, double b, int L, int M, int N) {
double (*out)[M][N] = (double (*)[M][N]) fout;
double (*in)[M][N] = (double (*)[M][N]) fin;
auto ftemp1 = new T[L * M * N];
auto ftemp2 = new T[L * M * N];
mems... |
SumaVectoresOMPsections.c | #include <stdlib.h> // biblioteca con funciones atoi(), malloc() y free()
#include <stdio.h> // biblioteca donde se encuentra la función printf()
#ifdef _OPENMP
#include <omp.h>
#else
#define omp_get_thread_num() 0
#endif
//#define PRINTF_ALL
#define MAX 67108864 //=2^26
//#define MAX 4294967295 //=2^32-1
doub... |
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... |
cgels.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/zgels.c, normal z -> c, Fri Sep 28 17:38:05 2018
*
**/
#include "plasma.h"
#include "plasma_async.h"
#incl... |
dnnl_requantize-inl.h | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... |
Sema.h | //===--- Sema.h - Semantic Analysis & AST Building --------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===---------------------------... |
hello_world_openmp.c | #include <omp.h>
#include <stdio.h>
#include <stdlib.h>
int main (int argc, char *argv[]) {
int tid, nthreads;
#pragma omp parallel private(tid, nthreads)
{
tid = omp_get_thread_num();
nthreads = omp_get_num_threads();
printf("Hello World from thread %d out of %d from process %d out of %d\n",
tid, ... |
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... |
example2.c | // calculation example of electromagnetic field intensity distributions
#include "emf_mie_ms.h"
int main(int argc,char *argv[])
{
MSPD msp;
FILE *fp1,*fp2;
double complex e[3],h[3];
double rang,dr,r[3],*ie,*ih,mf;
int max,i,j,sn;
if(argc!=2 && argc!=4){
printf("Usage : %s datafile_name [sampling_numb... |
DRB049-fprintf-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... |
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.
*/
#... |
fill_nr_s8.c | /* Copyright 2014-2018 The PySCF Developers. 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 requi... |
gradf_adj_mex.c | #include <inttypes.h>
#include <omp.h>
#include "mex.h"
void gradf_adjf(float *du,
const float *x, const float *y, const float *z,
const double *h, const size_t *sz);
void gradf_adjd(double *du,
const double *x, const double *y, const double *z,
const d... |
main.c | /* Copyright (C) 2010 The Trustees of Indiana University. */
/* */
/* Use, modification and distribution is subject to the Boost Software */
/* License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at */
/* http:... |
ScatterHelper.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.
*
*... |
target_enter_data.c | // RUN: %libomptarget-compile-generic -fopenmp-version=51
// RUN: %libomptarget-run-fail-generic 2>&1 \
// RUN: | %fcheck-generic
#include <stdio.h>
int main() {
int i;
// CHECK: addr=0x[[#%x,HOST_ADDR:]], size=[[#%u,SIZE:]]
fprintf(stderr, "addr=%p, size=%ld\n", &i, sizeof i);
// CHECK-NOT: Libomptarget
#... |
GB_unop__round_fp32_fp32.c | //------------------------------------------------------------------------------
// GB_unop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX-Li... |
relative_fm.h | /*
Copyright (c) 2015, 2016, 2017 Genome Research Ltd.
Copyright (c) 2014 Jouni Siren
Author: Jouni Siren <jouni.siren@iki.fi>
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 ... |
factorize_gmp_primes.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 the... |
MultiwayMerge.h | #ifndef _MULTIWAY_MERGE_H_
#define _MULTIWAY_MERGE_H_
#include "CombBLAS.h"
namespace combblas {
/***************************************************************************
* Find indices of column splitters in a list of tuple in parallel.
* Inputs:
* tuples: an array of SpTuples each tuple is (rowid, coli... |
GB_unaryop__lnot_int64_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... |
for-loop.c | #include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <stdlib.h>
#include <stdint.h>
#include <omp.h>
#include <sys/time.h>
#include <time.h>
int fib_seq (int n)
{/*{{{*/
if (n<2)
return n;
else
return fib_seq(n-1) + fib_seq(n-2);
}/*}}}*/
long get_usecs(void)
{/*{{{*/
struct timeval t;
... |
omp_loop.c | #include <omp.h>
#include <stdio.h>
#define N 100000
int main () {
int i,tid,NTHR;
float a[N], b[N], c[N];
/* Some initializations */
for (i=0; i < N; i++)
a[i] = b[i] = i * 1.0;
double start = omp_get_wtime();
//omp_set_dynamic(0);
//omp_set_num_threads(4);
#pragma o... |
shallow_water_variables_utility.h | // | / |
// ' / __| _` | __| _ \ __|
// . \ | ( | | ( |\__ `
// _|\_\_| \__,_|\__|\___/ ____/
// Multi-Physics
//
// License: BSD License
// Kratos default license: kratos/license.txt
//
// Main authors: Miguel Maso Sotomayor
//
#if ... |
explicit_builder.h | // | / |
// ' / __| _` | __| _ \ __|
// . \ | ( | | ( |\__ `
// _|\_\_| \__,_|\__|\___/ ____/
// Multi-Physics
//
// License: BSD License
// Kratos default license: kratos/license.txt
//
// Main authors: Ruben Zorrilla
//
//
#if !def... |
optimize.c | /*
This source file is part of the Geophysical Fluids Modeling Framework (GAME), which is released under the MIT license.
Github repository: https://github.com/OpenNWP/GAME
*/
/*
The Lloyd algorithm is implemented here.
*/
#include <stdlib.h>
#include <stdio.h>
#include <geos95.h>
#include "../../src/game_types.h"
#i... |
mem.c | /* Copyright 2013-2015. The Regents of the University of California.
* Copyright 2016. Martin Uecker.
* All rights reserved. Use of this source code is governed by
* a BSD-style license which can be found in the LICENSE file.
*
* Authors:
* 2012-2016 Martin Uecker <martin.uecker@med.uni-goettingen.de>
*
*/
#inc... |
make_general_basis.h | #ifndef _MAKE_GENERAL_BASIS_H
#define _MAKE_GENERAL_BASIS_H
#include <iostream>
#include "general_basis_core.h"
#include "numpy/ndarraytypes.h"
#include "openmp.h"
#include "misc.h"
#include <cmath>
#include <cfloat>
#include <vector>
#include <utility>
#include <algorithm>
#include <functional>
#if defined(_WIN64)
... |
critical.c | #include <stdio.h>
#include <stdlib.h>
#include <omp.h>
int main(int argc, char **argv) {
int i, n=20, a[n],suma=0,sumalocal;
if(argc < 2) {
fprintf(stderr,"\nFalta iteraciones\n"); exit(-1);
}
n = atoi(argv[1]); if (n>20) n=20;
for (i=0; i<n; i++) a[i] = i;
#pragma omp parallel p... |
c-tree.h | /* Definitions for C parsing and type checking.
Copyright (C) 1987-2019 Free Software Foundation, Inc.
This file is part of GCC.
GCC 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, or (at yo... |
mxEvaluateSourceTopography1d.c | #include "../../@SWEAbstract1d/private/mxSWE1d.h"
#include "mex.h"
#define NRHS 4
#define NLHS 1
#define NVAR 2
void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[]) {
/* check input & output */
if (nrhs != NRHS) {
mexPrintf("Matlab:%s:InvalidNumberInput,\n", __FILE__);
mexPrintf("%... |
reduction_minus_2.c | // PASS: *
// RUN: ${CATO_ROOT}/src/scripts/cexecute_pass.py %s -o %t
// RUN: diff <(mpirun -np 4 %t) %s.reference_output
#include <stdio.h>
#include <stdlib.h>
#include <omp.h>
int main()
{
int result = 100;
#pragma omp parallel reduction(-:result)
{
result -= omp_get_thread_num();
}
pri... |
TwoCore.c | #include <stdlib.h>
#include <stdio.h>
#include <omp.h>
int main(int argc, char *argv[]){
omp_set_num_threads(2);
#pragma omp parallel
{
if(omp_get_thread_num()){
system("gcc testFile0.c -o test0");
} else {
system("gcc testFile1.c -o test1");
}
}
... |
expected_output.c | #include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <math.h>
#include <polybench.h>
#include "gemver.h"
/**
* 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
*/
/*g... |
gemm.c | #include "gemm.h"
#include "utils.h"
#include "cuda.h"
#include <stdlib.h>
#include <stdio.h>
#include <math.h>
void gemm_bin(int M, int N, int K, float ALPHA,
char *A, int lda,
float *B, int ldb,
float *C, int ldc)
{
int i,j,k;
for(i = 0; i < M; ++i){
for(k = 0; k < K; ++k){... |
primitives.h | #pragma once
#include <vector>
#include <cstdint>
#include <omp.h>
#include "local_buffer.h"
using namespace std;
#define CACHE_LINE_ENTRY (16)
#define LOCAL_BUDGET (8*1024*1024)
template<typename T>
void MemSetOMP(T *arr, int val, size_t size) {
size_t tid = omp_get_thread_num();
size_t max_omp_threads =... |
statistic.c | /*
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %
% %
% ... |
data_absent_at_exit.c | // RUN: %libomptarget-compile-run-and-check-aarch64-unknown-linux-gnu
// RUN: %libomptarget-compile-run-and-check-powerpc64-ibm-linux-gnu
// RUN: %libomptarget-compile-run-and-check-powerpc64le-ibm-linux-gnu
// RUN: %libomptarget-compile-run-and-check-x86_64-pc-linux-gnu
// RUN: %libomptarget-compile-run-and-check-nvpt... |
callback_openmp.c | // RUN: %clang_cc1 -triple i386-unknown-unknown -fopenmp -O1 %s -emit-llvm -o - | FileCheck %s
// RUN: %clang_cc1 -triple i386-unknown-unknown -fopenmp -O1 %s -emit-llvm -o - | opt -ipconstprop -S | FileCheck --check-prefix=IPCP %s
// CHECK: declare !callback ![[cid:[0-9]+]] void @__kmpc_fork_call
// CHECK: declare !c... |
fft_host.h | #include <stdio.h>
#include <assert.h>
#include <vector>
#include <iostream>
#include <math.h>
size_t bitreverse_host(size_t n, const size_t l)
{
size_t r = 0;
for (size_t k = 0; k < l; ++k)
{
r = (r << 1) | (n & 1);
n >>= 1;
}
return r;
}
template<typename FieldT>
void _basic_seri... |
GB_unop__identity_int8_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... |
6edef_gcc_so8.c | #define _POSIX_C_SOURCE 200809L
#define START_TIMER(S) \
struct timeval start_##S, end_##S; \
gettimeofday(&start_##S, NULL);
#define STOP_TIMER(S, T) \
gettimeofday(&end_##S, NULL); \
T->S += (double)(end_##S.tv_sec - start_##S.tv_sec) + (double)(end_##S.tv_usec - start_##S.tv_usec) / 1000... |
GB_unaryop__abs_uint32_int16.c | //------------------------------------------------------------------------------
// GB_unaryop: hard-coded functions for each built-in unary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved.
// http... |
DRB001-antidep1-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... |
sectionsModificado.c | #include <stdio.h>
#include <omp.h>
void funcA() {
printf("En funcA: esta sección la ejecuta el thread %d\n",
omp_get_thread_num());
}
void funcB() {
printf("En funcB: esta sección la ejecuta el thread %d\n",
omp_get_thread_num());
}
int main() {
#pragma omp parallel sections
{
#pragma omp section
... |
simd_misc_messages.c | // RUN: %clang_cc1 -fsyntax-only -fopenmp -fopenmp-version=45 -verify=expected,omp45 %s -Wuninitialized
// RUN: %clang_cc1 -fsyntax-only -fopenmp -fopenmp-version=50 -verify=expected,omp50 %s -Wuninitialized
// RUN: %clang_cc1 -fsyntax-only -fopenmp-simd -fopenmp-version=45 -verify=expected,omp45 %s -Wuninitialized
//... |
rose_Stress-1.c | //#include <float.h>
//#include <math.h>
#define MIN(a, b) ( (a < b) ? a : b)
#define MAX(a, b) ( (a > b) ? a : b)
#include "omp.h"
typedef double real8;
void StressCheckEpsFail(real8 *newSxx,real8 *newSyy,real8 *newSzz,real8 *newTxy,real8 *newTxz,real8 *newTyz,real8 *eps,real8 eps_failure_model,const int *zoneset,in... |
transfer.c | /** @file transfer.c Documented transfer module.
*
* Julien Lesgourgues, 28.07.2013
*
* This module has two purposes:
*
* - at the beginning, to compute the transfer functions \f$
* \Delta_l^{X} (q) \f$, and store them in tables used for
* interpolation in other modules.
*
* - at any time in the code, to ... |
4525.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... |
triad.h | #ifndef TRIAD_H
#define TRIAD_H
#include <iostream>
#include <vector>
#include <random>
#include <set>
namespace TSnap {
/////////////////////////////////////////////////
// Triads and clustering coefficient
/// Computes the average clustering coefficient as defined in Watts and Strogatz, C... |
BEIntegratorWave.h | /*!
* @file BEIntegratorWave.h
* @author Michal Merta
* @author Jan Zapletal
* @date December 12, 2013
* @brief Header file for class BEIntegratorWave
*
*/
#ifndef BEINTEGRATORWAVE_H
#define BEINTEGRATORWAVE_H
#include <algorithm>
#include "BEIntegrator.h"
#ifndef EXPERIMENTAL_WAVE
// use ordina... |
dmul_eq_omp.c | /*
This file is part of ParTI!.
ParTI! is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as
published by the Free Software Foundation, either version 3 of
the License, or (at your option) any later version.
ParTI! is distributed... |
kernel_cpu.c | // #ifdef __cplusplus
// extern "C" {
// #endif
//========================================================================================================================================================================================================200
// DEFINE/INCLUDE
//=============================================... |
tinyexr.h | /*
Copyright (c) 2014 - 2018, Syoyo Fujita
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 t... |
fisher.c | /** @file fisher.c
** @brief Fisher - Declaration
** @author David Novotny
**/
/*
Copyright (C) 2013 David Novotny and Andrea Vedaldi.
All rights reserved.
This file is part of the VLFeat library and is made available under
the terms of the BSD license (see the COPYING file).
*/
/**
<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~... |
parallel_section_reduction.c | #include <stdio.h>
#include <math.h>
#include "omp_testsuite.h"
int
check_parallel_section_reduction (FILE * logFile)
{
int sum = 7;
int known_sum;
double dpt, dsum = 0;
double dknown_sum;
double dt = 0.5; /* base of geometric row for + and - test */
double rounding_error = 1.E-5;
int diff;
double ddi... |
population.h | #ifndef POPULATION_H
#define POPULATION_H
#include "ind_data.h"
#include "rndutils.hpp"
#include <vector>
struct pop_param
{
pop_param(int n_inds = 1,
double mut_rate_w = 0.01,
double mut_st = 0.1,
double mut_rate_act = 0.001,
double mut_rate_dupl = 0.001,
... |
GB_binop__isle_uint32.c |
//------------------------------------------------------------------------------
// GB_binop: hard-coded functions for each built-in binary operator
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved.
// SPDX... |
declare_variant_messages.c | // RUN: %clang_cc1 -triple=x86_64-pc-win32 -verify -fopenmp -x c -std=c99 -fms-extensions -Wno-pragma-pack %s
// RUN: %clang_cc1 -triple=x86_64-pc-win32 -verify -fopenmp-simd -x c -std=c99 -fms-extensions -Wno-pragma-pack %s
#pragma omp declare // expected-error {{expected an OpenMP directive}}
int foo(void);
#pra... |
exception.h | //==================================================================================
// BSD 2-Clause License
//
// Copyright (c) 2014-2022, NJIT, Duality Technologies Inc. and other contributors
//
// All rights reserved.
//
// Author TPOC: contact@openfhe.org
//
// Redistribution and use in source and binary forms, wi... |
GB_unaryop__minv_int16_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... |
wave1d_b.c | /* Generated by TAPENADE (INRIA, Ecuador team)
Tapenade 3.14 (r7079) - 5 Oct 2018 09:55
*/
#include <adBuffer.h>
/*
Differentiation of wave1d in reverse (adjoint) mode:
gradient of useful results: *u *u_1 *u_2
with respect to varying inputs: *u *u_1 *u_2
RW status of diff variables: *u:i... |
Pi.c | #include <stdio.h>
#include <omp.h>
static long num_steps = 100000;
double step;
#define NUM_THREADS 4
// follow the SPMD mode
int main(int argc, char const *argv[])
{
int i;
double pi, sum[NUM_THREADS], start_time, end_time;
step = 1.0 / (double)num_steps;
omp_set_num_threads(NUM_THREADS);
start... |
ast-dump-openmp-target-data.c | // RUN: %clang_cc1 -triple x86_64-unknown-unknown -fopenmp -ast-dump %s | FileCheck --match-full-lines -implicit-check-not=openmp_structured_block %s
void test(int x) {
#pragma omp target data map(x)
;
}
// CHECK: TranslationUnitDecl {{.*}} <<invalid sloc>> <invalid sloc>
// CHECK: `-FunctionDecl {{.*}} <{{.*}}ast-... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.