source
stringlengths
3
92
c
stringlengths
26
2.25M
covariance.c
/** * covariance.c: This file was adapted from PolyBench/GPU 1.0 test * suite to run on GPU with OpenMP 4.0 pragmas and OpenCL driver. * * http://www.cse.ohio-state.edu/~pouchet/software/polybench/GPU * * Contacts: Marcio M Pereira <mpereira@ic.unicamp.br> * Rafael Cardoso F Sousa <rafael.cardoso@stude...
lastpass_sniffed_fmt_plug.c
/* LastPass sniffed session cracker patch for JtR. Hacked together during * November of 2012 by Dhiru Kholia <dhiru at openwall.com>. * * Burp Suite is awesome. Open-source it! * * This software is Copyright (c) 2012 Dhiru Kholia <dhiru at openwall.com>, * and it is hereby released to the general public under the...
morn_image_transform.c
/* Copyright (C) 2019-2020 JingWeiZhangHuai <jingweizhanghuai@163.com> Licensed under the Apache License, Version 2.0; 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 agreed to in wri...
ast-dump-openmp-distribute-parallel-for-simd.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 distribute parallel for simd for (int i = 0; i < x; i++) ; } void test_two(int x, int y) { #pragma omp distribute parallel for ...
vlad.c
/** @file vlad.c ** @brief VLAD - Declaration ** @author David Novotny ** @author Andrea Vedaldi **/ /* Copyright (C) 2013 David Novotny and Andera 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). */ /** <!-- ~~...
kmer_counter.h
#ifndef KMER_COUNTER_H__ #define KMER_COUNTER_H__ #include <cstdint> #include <vector> #include <cstdlib> #include <type_traits> #include "khash64.h" #include "./encoder.h" namespace kmerc { KHASH_MAP_INIT_INT64(i16, uint16_t) KHASH_SET_INIT_INT64(i16s) template<typename C, typename IT=uint64_t, typename ArgType> st...
GB_unop__erf_fp64_fp64.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...
residualbased_newton_raphson_mpc_contact_strategy.h
// KRATOS ___| | | | // \___ \ __| __| | | __| __| | | __| _` | | // | | | | | ( | | | | ( | | // _____/ \__|_| \__,_|\___|\__|\__,_|_| \__,_|_| MECHANICS // // License: BSD License // ...
transpose.c
/* Copyright (c) 2013, Intel Corporation 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 disclaimer...
Parser.h
//===--- Parser.h - C Language Parser ---------------------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===---------------------------...
comm.h
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you ...
ellipticStressPartialAxCoeffHex3D.c
extern "C" void FUNC(ellipticStressPartialAxCoeffHex3D)(const dlong &Nelements, const dlong &offset, const dlong &loffset, const dlong* __restrict__ elementList, const dfloat* __restrict__ vgeo, ...
omp_for_reduction.c
<ompts:test> <ompts:testdescription>Test which checks the omp for reduction directive wich all its options.</ompts:testdescription> <ompts:ompversion>2.0</ompts:ompversion> <ompts:directive>omp for reduction</ompts:directive> <ompts:testcode> #include <stdio.h> #include <stdlib.h> #include <math.h> #include "omp_tests...
GB_unop__identity_fc64_uint32.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_unop__minv_uint64_uint64.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-Li...
sapG_fmt_plug.c
/* * this is a SAP PASSCODE (CODEVN G) plugin for john the ripper. * tested on linux/x86 only, rest is up to you.. at least, someone did the reversing :-) * * please note: this code is in a "works for me"-state, feel free to modify/speed up/clean/whatever it... * * (c) x7d8 sap loverz, public domain, btw * cheer...
core_dlansy.c
/** * * @file * * PLASMA is a software package provided by: * University of Tennessee, US, * University of Manchester, UK. * * @generated from /home/luszczek/workspace/plasma/bitbucket/plasma/core_blas/core_zlansy.c, normal z -> d, Fri Sep 28 17:38:21 2018 * **/ #include <plasma_core_blas.h> #include "pla...
time.c
#include <stdio.h> #include <stdlib.h> #include <math.h> #include <unistd.h> #include <omp.h> #include <time.h> // Определение функции double Func(double x) { // Недействительные значения не должны вносить вклад в интеграл if (x > 2) { return 0; } return sqrt(4 - x*x); } int main(int argc, ch...
TransferFunction.h
#ifndef TRANSFERTFUNCTION_INC #define TRANSFERTFUNCTION_INC #include <cstdint> #include <cstdlib> #include "SciVisColor.h" #include <algorithm> #include <vector> #ifdef _OPENMP #include <omp.h> #endif namespace sereno { /** \brief Basic class for transfer function computation */ class TF { pub...
lenet.c
#include "lenet.h" #include <memory.h> #include <time.h> #include <stdlib.h> #include <math.h> static void convolute_valid(double *src, double *conv, double *des, const long dh, const long dw, const long ch, const long cw) { const long sw = dw + cw - 1; for (long d0 = 0; d0 < dh; ++d0) for (long d1 = 0; d1 < dw; +...
Calculate_HFs.c
#include "num_of_threads.h" #include<omp.h> #include"utils.h" #include"structs.h" #include"matrix_ops.h" void Calculate_HFs(int *tlist,double *vlist,int nfac,int nvert,double *angles,HFstruct *HFs,double *offset,double *D,int dm,int dn,double *Weight,int Nfft,double A,double Gamma,double *scale,double *FT,double *FTd...
mysql_fmt_plug.c
/* MYSQL_half_fmt.c * * Copyright (c) 2008 by <earthquake at rycon.hu> * * John the ripper MYSQL-fast module * * * Note: The mysql hash's first 8byte is relevant, * the another ones depends on the first 8. Maybe * the passwords after 9-10character have collision * in the first 8byte, so we have to check the f...
heat.c
#include <omp.h> #include <stdio.h> #include <sys/time.h> #include "calc_up.h" int main() { int Nx,Ny,Nt; int t,x,y; Nx=1000; Ny=1000; Nt=1000; double u[Nx][Ny]; double up[Nx][Ny]; struct timeval start,end; float delta; // Boundary conditions for(x=0; x<Nx; x++) for(y=0; y<Ny; y++) { ...
CBbackproject_c.c
/* MEX Function to perform cone beam back projection of Nikon XTek Custom Bay data. Published as part of the SophiaBeads Datasets project. */ /* References: David Szotten, Limited Data Problems in X-ray and Polarized Light Tomography. PhD Thesis, School of Mathematics, University of Manchester. 2011. William Mic...
DRB064-outeronly2-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...
convolution_sgemm_pack8to4.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 ...
GB_unaryop__minv_fp64_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...
GB_binop__rdiv_uint8.c
//------------------------------------------------------------------------------ // GB_binop: hard-coded functions for each built-in binary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX...
MergeSort_OpenMP.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> #include <time.h> #define SIZE 2000 int array[SIZE]; double avg; void merge(int start, int mid, int finish){ int sizeLeft = mid - start + 1; int sizeRight = finish - mid; int left[sizeLeft]; int right[sizeRight]; int i = 0 , j = 0 , k = ...
vars1-omp.c
#include <stdio.h> #include <omp.h> int gvar = 12345; int main( int argc, char **argv ) { #pragma omp parallel { gvar = omp_get_thread_num(); #pragma omp barrier printf( "[%d] gvar=%d\n", omp_get_thread_num(), gvar ); } return 0; }
mxnet_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 ...
channel.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
workflow.h
#ifndef SRC_WORKFLOW_H #define SRC_WORKFLOW_H // #define R_BUILD #ifdef R_BUILD #include <Rcpp.h> #include <RcppEigen.h> // [[Rcpp::depends(RcppEigen)]] using namespace Rcpp; #else #include <Eigen/Eigen> #include "List.h" #endif #include <iostream> #include <vector> #include "Algorithm.h" #include "Data.h" #inc...
task_tied_thread_threadid.c
// RUN: %libomp-compile-and-run // REQUIRES: abt #include "omp_testsuite.h" #include <string.h> #include <stdio.h> int test_task_tied_thread_threadid(int num_threads) { int vals[num_threads]; memset(vals, 0, sizeof(int) * num_threads); omp_set_max_active_levels(2); #pragma omp parallel num_threads(num_threads...
memdbg.c
/* * This software was written by Jim Fougeron jfoug AT cox dot net * in 2013. 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...
for-3.c
void bar (int); int a[256]; void foo (int j) { int i; #pragma omp for for (i = 0; i != 64; i = i + 4) /* { dg-error "increment is not constant 1 or -1" } */ bar (i); #pragma omp for for (i = 128; i != 64; i = i - 4) /* { dg-error "increment is not constant 1 or -1" } */ bar (i); #pragma omp for ...
ssh_ng_fmt_plug.c
/* Fast cracker for SSH RSA / DSA key files. Hacked together during October * of 2012 by Dhiru Kholia <dhiru.kholia at gmail.com>. * * Support for cracking new openssh key format (bcrypt pbkdf) was added by * m3g9tr0n (Spiros Fraganastasis) and Dhiru Kholia in September of 2014. This * is dedicated to Raquel :-) ...
csrmv_merge.h
#ifndef __CSRMV_MERGE_H__ #define __CSRMV_MERGE_H__ #include <algorithm> #include "complex_ops.h" #include "openmp.h" #include "numpy/ndarraytypes.h" // See work my Merrill et. al. (http://ieeexplore.ieee.org/abstract/document/7877136/) for original work and implementation. // This code contains modified versions of...
8995.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 <...
GB_unop__isnan_bool_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...
siemens-s7_fmt_plug.c
/* Siemens S7 authentication protocol cracker. Written by Narendra Kangralkar * <narendrakangralkar at gmail.com> and Dhiru Kholia <dhiru at openwall.com>. * * This software is Copyright (c) 2013, Dhiru Kholia <dhiru.kholia at gmail.com> * and Narendra Kangralkar <narendrakangralkar at gmail.com> and it is hereby...
MolecularMechanics.c
/* MolecularMechanics.c */ /********************************************************************************************************** Copyright (c) 2002-2013 Abdul-Rahman Allouche. All rights reserved Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated document...
pi.c
#include <omp.h> #include <stdio.h> #include <stdlib.h> #define MAX_THREADS 4 static long steps = 1000000000; double step; int main (int argc, const char *argv[]) { int i,j; double x; double pi, sum = 0.0; double start, delta; step = 1.0/(double) steps; for (j=1; j<= MAX_THREADS; j++) { ...
DRB004-antidep2-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...
DRB085-threadprivate-orig-no.c
/* Copyright (c) 2017, Lawrence Livermore National Security, LLC. Produced at the Lawrence Livermore National Laboratory Written by Chunhua Liao, Pei-Hung Lin, Joshua Asplund, Markus Schordan, and Ian Karlin (email: liao6@llnl.gov, lin32@llnl.gov, asplund1@llnl.gov, schordan1@llnl.gov, karlin1@llnl.gov) LLNL-CODE-73214...
str-matching_gpu.c
/* This program performs string matching on the GPU with dynamically allocated vector. Author: Gleison Souza Diniz Mendonça Date: 04-01-2015 version 2.0 Run: ipmacc string-matching _gpu.c -o str ./str matrix-size */ #include "BenchmarksUtil.h" #include <assert.h> #include <limits.h> #inc...
Mod-DRB025-simdtruedep-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...
OpenMPClause.h
//===- OpenMPClause.h - Classes for OpenMP clauses --------------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
bd_cilk.c
#include <stdlib.h> #include <stdio.h> #include <unistd.h> // access #include <math.h> #include <assert.h> #include "timer.h" #include "bd.h" //#include <omp.h> #include <cilk/cilk.h> #include <cilk/cilk_api.h> #define NTHREADS 24 #define M_PI 3.14159265358979323846 #define my_EPS 0.000000001 void get_indices(int ind...
addn.h
// Copyright 2018 Xiaomi, Inc. 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 applicab...
nn_index.h
/*********************************************************************** * Software License Agreement (BSD License) * * Copyright 2008-2009 Marius Muja (mariusm@cs.ubc.ca). All rights reserved. * Copyright 2008-2009 David G. Lowe (lowe@cs.ubc.ca). All rights reserved. * * THE BSD LICENSE * * Redistribution an...
tree-pretty-print.c
/* Pretty formatting of GENERIC trees in C syntax. Copyright (C) 2001-2020 Free Software Foundation, Inc. Adapted from c-pretty-print.c by Diego Novillo <dnovillo@redhat.com> 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 Licens...
binarytrees-7.c
/* The Computer Language Benchmarks Game * http://benchmarksgame.alioth.debian.org/ * * contributed by Francesco Abbate */ #include <stdlib.h> #include <stdio.h> typedef off_t off64_t; #include <apr_pools.h> const size_t LINE_SIZE = 64; struct node { int i; struct node *left; struct node *right; }; int ...
wpapsk.h
/* * This software is Copyright (c) 2012 Lukas Odzioba <lukas dot odzioba at gmail dot com> * and Copyright (c) 2012-2014 magnum * and it is hereby released to the general public under the following terms: * Redistribution and use in source and binary forms, with or without modification, are permitted. * * hccap ...
utils.h
// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT license. #pragma once #include <fcntl.h> #include <algorithm> #include <cassert> #include <cstdlib> #include <cstring> #include <fstream> #include <iostream> #include <string> #include <memory> #include <random> #include <set> #ifd...
FrameData.h
/* * This file is part of https://github.com/martinruenz/maskfusion * * 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 3 of the License, or * (at your option) any later versi...
convolution_3x3_pack8_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 ...
full_verify.c
// A test case based on IS/is.c of npb3.2-omp // to test the handling of #if #endif during OpenMP translation // // 6/9/2010, Liao // #include <stdio.h> #define NUM_KEYS 1000 int key_array[NUM_KEYS], key_buff_ptr_global[NUM_KEYS]; void full_verify() { int i, j; int k; int passed_verification =0; /* ...
solver_dcmt_omp.c
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Copyright 2021, Liheng Zheng This file is part of UBER. UBER is free software: you can redistribute it and/or modify it under the terms of the MIT License as published by Massachusetts Institute of Technology. UBER is di...
ep.c
/*-------------------------------------------------------------------- NAS Parallel Benchmarks 3.0 structured OpenMP C versions - EP This benchmark is an OpenMP C version of the NPB EP code. The OpenMP C 2.3 versions are derived by RWCP from the serial Fortran versions in "NPB 2.3-serial" developed by NA...
GB_unop__identity_uint32_int32.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-Li...
pi_parallel.c
#include <omp.h> #include <stdio.h> #include <stdlib.h> #include <math.h> #define N 10000 //[PARALLEL] //Algoritmo de Gauss-Legrande Iterativo para o Cálculo de PI long double pi(int iterations) { //inicializações double i; long double a = 1; long double b = sqrt(2)/2; long double t = 0.25; long double p = 1; ...
mc_funcs.h
#ifndef MC_FUNCS #define MC_FUNCS #include <stdlib.h> #include <stdio.h> #include <time.h> #include <sys/time.h> #include <assert.h> #include <string> #include <iomanip> #include <stdint.h> #include <stdlib.h> #include <unistd.h> #include <sys/time.h> #include <torch/extension.h> #include <ATen/record_function.h> #i...
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...
GB_unop__abs_uint8_uint8.c
//------------------------------------------------------------------------------ // GB_unop: hard-coded functions for each built-in unary operator //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2021, All Rights Reserved. // SPDX-Li...
CPULauncher.h
// ---------------------------------------------------------------------------- // - Open3D: www.open3d.org - // ---------------------------------------------------------------------------- // The MIT License (MIT) // // Copyright (c) 2018-2021 www.open3d.org // // Perm...
DRB003-antidep2-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...
log_progress.h
/* * * Copyright (c) 2014, Nicola Pezzotti (Delft University of Technology) * 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 ...
core_sormqr.c
/** * * @file * * PLASMA is a software package provided by: * University of Tennessee, US, * University of Manchester, UK. * * @generated from /home/luszczek/workspace/plasma/bitbucket/plasma/core_blas/core_zunmqr.c, normal z -> s, Fri Sep 28 17:38:25 2018 * **/ #include <plasma_core_blas.h> #include "pla...
masked.c
// RUN: %libomp-compile-and-run | FileCheck %s // REQUIRES: ompt // GCC generates code that does not call the runtime for the master construct // XFAIL: gcc #include "callback.h" #include <omp.h> int main() { int x = 0; #pragma omp parallel num_threads(2) { #pragma omp master { print_fuzzy_address(1); ...
staticChunk.c
#include <omp.h> #include <stdio.h> int main(void) { double a[1000]; int i; int n; scanf("%d",&n); #pragma omp for schedule(static) for (i=0;i<n;i++) { a[i]=(double)i/2.0; } printf("a[878]=%f\n",a[878]); return 0; }
3d7pt.lbpar.c
#include <omp.h> #include <math.h> #define ceild(n,d) ceil(((double)(n))/((double)(d))) #define floord(n,d) floor(((double)(n))/((double)(d))) #define max(x,y) ((x) > (y)? (x) : (y)) #define min(x,y) ((x) < (y)? (x) : (y)) /* * Order-1, 3D 7 point stencil * Adapted from PLUTO and Pochoir test bench * * Tare...
centralized_sensereversal.c
/* * CENTRALIZED SENSE REVERSAL BARRIER: OPENMP * To show correct functionality of barrier: Uncomment printf in main * To compile: gcc -o centralized_sensereversal centralized_sensereversal.c -lm -fopenmp * To run: ./centralized_sensereversal [num_threads num_barriers] */ #include <omp.h> #include <stdio.h> #incl...
XSHA512_fmt_plug.c
/* * This file is part of John the Ripper password cracker, * Copyright (c) 2008,2011 by Solar Designer */ #if FMT_EXTERNS_H extern struct fmt_main fmt_XSHA512; #elif FMT_REGISTERS_H john_register_one(&fmt_XSHA512); #else #include "sha2.h" #include "arch.h" #include "params.h" #include "common.h" #include "format...
lu-dep-timed.c
/* * Copyright (C) 2010 Computer Architecture and Parallel Systems Laboratory (CAPSL) * * Original author: Elkin E. Garcia * E-Mail: egarcia@capsl.udel.edu * * License * Redistribution of this code is allowed only after an explicit permission is * given by the original author or CAPSL and this license s...
GB_unaryop__minv_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...
mxnet_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 ...
visual-effects.c
/* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % % % % ...
channel_shuffle.h
// Copyright 2018 Xiaomi, Inc. 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 applicab...
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) ...
mero-ummap-bandwidth-mpi.c
//mpicc ioc-ummap-bandwidth-mpi.c -I$HOME/test-rdma/usr2/include -lioc-client -lummap-io -L$HOME/test-rdma/usr2/lib -Wl,-rpath,$HOME/test-rdma/usr2/lib -o ioc-ummap-bandwidth-mpi #include <stdlib.h> #include <stdio.h> #include <string.h> #include <stdbool.h> #include <ioc-client.h> #include <time.h> #include <mpi.h> #...
pooling.h
// Copyright 2018 Xiaomi, Inc. 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 applicab...
GB_subassign_10_and_18.c
//------------------------------------------------------------------------------ // GB_subassign_10_and_18: C(I,J)<M or !M,repl> = A ; using S //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2022, All Rights Reserved. // SPDX-License...
ej3reductionmejora.c
#include <stdio.h> #include <stdlib.h> #include <omp.h> #define N 1024 int main () { int memsize = N*sizeof(float); float *a = (float *) malloc (memsize); float *b = (float *) malloc (memsize); for (int i=0;i<N; ++i){ a[i]=b[i]=1.0f; } int numthreads=4; omp_set_num_threads(numthreads); float *mem = (f...
ast-dump-openmp-target-parallel-for-simd.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 simd for (int i = 0; i < x; i++) ; } void test_two(int x, int y) { #pragma omp target parallel for simd f...
edge_data.h
// | / | // ' / __| _` | __| _ \ __| // . \ | ( | | ( |\__ ` // _|\_\_| \__,_|\__|\___/ ____/ // Multi-Physics // // License: BSD License // Kratos default license: kratos/license.txt // // Main authors: Antonia Larese // #if !defined(KRATOS_EDGE_DA...
mea_pb2_traco.c
#include <stdio.h> #include <stdlib.h> #include <limits.h> #include <omp.h> #include <math.h> #define min(a,b) (((a)<(b))?(a):(b)) #define MIN(a,b) (((a)<(b))?(a):(b)) #define max(a,b) (((a)>(b))?(a):(b)) #define MAX(a,b) (((a)>(b))?(a):(b)) #define floord(n,d) floor(((double)(n))/((double)(d))) #define ceild(n,d) ce...
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 // //===---------------------------...
encrypt.c
#include "encrypt.h" #include "files.h" #include "mmap.h" #include "error.h" #include <stdlib.h> #include <inttypes.h> #include <limits.h> #include <math.h> #include <omp.h> #include <stdio.h> #define INT_LEN sizeof(int) //int length in bytes #define PAR_BLCK (256 * 1024) //dimension, in bytes, of a thread unit of...
dgetrf.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/zgetrf.c, normal z -> d, Fri Sep 28 17:38:06 2018 * **/ #include "plasma.h" #include "plasma_async.h" #inc...
pi_critical.c
#include <omp.h> #include <stdio.h> #include <stdlib.h> int main(int argc, const char *argv[]) { long steps = 1000000000; if (argc > 1) { steps = atoi(argv[1]); } else { printf("Use: %s [puntos]\n", argv[0]); } double step = 1.0 / (double)steps; double sum = 0.0; ...
acoustics_alg.c
/* * Student: Trascau Mihai * Grupa: 344C4 * * Lucrare: Ecuatia undelor pentru acustica 2D * Fisier: acoustics_alg.h * Descriere: Fisier sursa care contine implementarile pentru algoritmul utilizat (in cazul nostru MDF pentru ecuatia propagarii undei) */ #include "acoustics.h" int on_edge(int x, int y) { i...
computeGraph.c
#include "defs.h" double computeGraph(graph* G, graphSDG* SDGdata) { VERT_T* endV; LONG_T *degree, *numEdges, *pos, *pSums; WEIGHT_T* w; double elapsed_time; #ifdef _OPENMP omp_lock_t *vLock; LONG_T chunkSize; #endif elapsed_time = get_seconds(); #ifdef _OPENMP omp_set_num_threads(N...
omp_copyin.c
// Skip testing on 64 bit systems for now! #ifndef __LP64__ #include "omp_testsuite.h" #include <stdlib.h> #include <stdio.h> #include <omp.h> /* static int sum0 = 0; #pragma omp threadprivate(sum0) static int myvalue = 0; #pragma omp threadprivate(myvalue) */ static int sum1 = 789; #pragma omp threadprivate(sum1) ...
batch_norm.h
// Copyright 2018 Xiaomi, Inc. 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 applicab...
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...
GB_subassign_04.c
//------------------------------------------------------------------------------ // GB_subassign_04: C(I,J) += A ; using S //------------------------------------------------------------------------------ // SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2019, All Rights Reserved. // http://suitesparse.com See Gra...
stationary_cython.c
/* Generated by Cython 0.29.2 */ #define PY_SSIZE_T_CLEAN #include "Python.h" #ifndef Py_PYTHON_H #error Python headers needed to compile C extensions, please install development version of Python. #elif PY_VERSION_HEX < 0x02060000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03030000) #error Cython ...
MultiwayMerge.h
#include "../CombBLAS.h" /*************************************************************************** * Find indices of column splitters in a list of std::tuple in parallel. * Inputs: * tuples: an array of SpTuples each std::tuple is (rowid, colid, val) * nsplits: number of splits requested * Output: ...
GB_unop__identity_fp64_bool.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...