Skip to content

Commit

Permalink
Squashed 'thirdParty/mallocMC/' content from commit c63b20ba73
Browse files Browse the repository at this point in the history
git-subtree-dir: thirdParty/mallocMC
git-subtree-split: c63b20ba7388d5d0857259cb992179b01990db24
  • Loading branch information
Third Party authored and chillenzer committed Feb 20, 2025
0 parents commit 6d77d8c
Show file tree
Hide file tree
Showing 66 changed files with 12,715 additions and 0 deletions.
165 changes: 165 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,165 @@
# General options
Language: Cpp
Standard: c++20
DisableFormat: false
AccessModifierOffset: -4
AlignAfterOpenBracket: AlwaysBreak
AlignArrayOfStructures: None
AlignConsecutiveAssignments: false
AlignConsecutiveBitFields: false
AlignConsecutiveDeclarations: false
AlignConsecutiveMacros: false
AlignEscapedNewlines: Right
AlignOperands: Align
AlignTrailingComments:
Kind: Never
AllowAllArgumentsOnNextLine: false
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortBlocksOnASingleLine: Never
AllowShortCaseLabelsOnASingleLine: false
AllowShortEnumsOnASingleLine: false
AllowShortFunctionsOnASingleLine: None
AllowShortIfStatementsOnASingleLine: Never
AllowShortLambdasOnASingleLine: All
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: Yes
BinPackArguments: false
BinPackParameters: false
BitFieldColonSpacing: Both
BreakAfterAttributes: Never
BreakBeforeBinaryOperators: All
BreakBeforeBraces: Allman
BreakBeforeConceptDeclarations: Always
BreakBeforeInlineASMColon: OnlyMultiline
BreakBeforeTernaryOperators: true
BreakConstructorInitializers: BeforeComma
BreakInheritanceList: BeforeComma
BreakStringLiterals: true
ColumnLimit: 119
CommentPragmas: '^ COMMENT pragma:'
CompactNamespaces: false
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DerivePointerAlignment: false
EmptyLineAfterAccessModifier: Never
EmptyLineBeforeAccessModifier: Always
ExperimentalAutoDetectBinPacking: false
FixNamespaceComments: true
IncludeBlocks: Regroup
IncludeIsMainRegex: '(Test)?$'
IncludeIsMainSourceRegex: ''
IndentAccessModifiers: false
IndentCaseBlocks: true
IndentCaseLabels: false
IndentExternBlock: AfterExternBlock
IndentGotoLabels: true
IndentPPDirectives: AfterHash
IndentRequiresClause: false
IndentWidth: 4
IndentWrappedFunctionNames: false
InsertBraces: false
InsertNewlineAtEOF: true
IntegerLiteralSeparator:
Binary: 4
Decimal: 3
DecimalMinDigits: 7
Hex: 4
KeepEmptyLinesAtTheStartOfBlocks: false
LambdaBodyIndentation: Signature
LineEnding: DeriveLF
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 2
NamespaceIndentation: All
PackConstructorInitializers: CurrentLine
PenaltyBreakAssignment: 2
PenaltyBreakBeforeFirstCallParameter: 19
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakOpenParenthesis: 0 # default made explicit here
PenaltyBreakString: 1000
PenaltyBreakTemplateDeclaration: 10
PenaltyExcessCharacter: 1000000
PenaltyIndentedWhitespace: 0 # default made explicit here
PenaltyReturnTypeOnItsOwnLine: 1000
PointerAlignment: Left
PPIndentWidth: -1 # follow IndentWidth
QualifierAlignment: Custom
QualifierOrder: ['friend', 'static', 'inline', 'constexpr', 'type', 'const', 'volatile', 'restrict']
ReferenceAlignment: Pointer # follow PointerAlignment
ReflowComments: true
RemoveBracesLLVM: false
RemoveSemicolon: false
RequiresClausePosition: WithPreceding
RequiresExpressionIndentation: OuterScope
ShortNamespaceLines: 0
SortIncludes: true
SortUsingDeclarations: Lexicographic
SeparateDefinitionBlocks: Always
SpaceAfterCStyleCast: true
SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: false
SpaceAroundPointerQualifiers: Default # follow PointerAlignment
SpaceBeforeAssignmentOperators: true
SpaceBeforeCaseColon: false
SpaceBeforeCpp11BracedList: false
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: true
SpaceBeforeParens: Never
SpaceBeforeRangeBasedForLoopColon: true
SpaceBeforeSquareBrackets: false
SpaceInEmptyBlock: false
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesInAngles: false
SpacesInConditionalStatement: false
SpacesInContainerLiterals: false
SpacesInCStyleCastParentheses: false
SpacesInLineCommentPrefix:
Minimum: 1
Maximum: -1
SpacesInParentheses: false
SpacesInSquareBrackets: false
TabWidth: 4
UseCRLF: false
UseTab: Never
# Project specific options
#AttributeMacros: []
#ForEachMacros: []
#IfMacros: []
IncludeCategories:
# Local headers (in "") above all else
- Regex: '"([A-Za-z0-9.\/-_])+"'
Priority: 1
# "alpaka/foo.hpp" after local headers (occur inside alpaka)
- Regex: '"alpaka/([A-Za-z0-9.\/-_])+"'
Priority: 2
# <alpaka/foo.hpp> after local headers (occur outside alpaka in examples and test)
- Regex: '<alpaka/([A-Za-z0-9.\/-_])+>'
Priority: 3
# C++ standard library headers are the last group to be included
- Regex: '<([A-Za-z0-9\/-_])+>'
Priority: 5
# Includes that made it this far are third-party headers and will be placed
# below alpaka's includes
- Regex: '<([A-Za-z0-9.\/-_])+>'
Priority: 4
# Macros: []
# NamespaceMacros: []
StatementAttributeLikeMacros:
- 'ALPAKA_DEVICE_VOLATILE'
- 'ALPAKA_FN_ACC'
- 'ALPAKA_FN_EXTERN'
- 'ALPAKA_FN_HOST'
- 'ALPAKA_FN_HOST_ACC'
- 'ALPAKA_FN_INLINE'
- 'ALPAKA_STATIC_ACC_MEM_CONSTANT'
- 'ALPAKA_STATIC_ACC_MEM_GLOBAL'
- 'ALPAKA_UNROLL'
- 'ALPAKA_VECTORIZE_HINT'
#StatementMacros: []
#TypenameMacros: []
#WhitespaceSensitiveMacros: []
13 changes: 13 additions & 0 deletions .clang-tidy
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Checks: |
*,
-*-avoid-c-arrays,
-altera*,
-*avoid-do-while,
-*constant-array-index,
-*pointer*arithmetic*,
-llvmlibc*,
-llvm-header-guard,
-fuchsia*,
-misc-non-private-member-variables-in-classes,
-cppcoreguidelines-pro-type-reinterpret-cast
HeaderFilterRegex: ".*"
46 changes: 46 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Continuous Integration
on: [push, pull_request]
env:
CPM_SOURCE_CACHE: ${{ github.workspace }}/cpm_modules
CTEST_OUTPUT_ON_FAILURE: 1
SKIP: no-commit-to-branch
jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.x
- uses: pre-commit/action@v3.0.1
- uses: pre-commit-ci/lite-action@v1.0.2
if: always()
cpu-tests:
# This action only runs on various CPU backends.
# As such, this is not a fully-fletched production-like test.
# Hopefully, it will still save us from a few stupid mistakes.
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/cache@v3
with:
path: "**/cpm_modules"
key: ${{ github.workflow }}-cpm-modules-${{ hashFiles('**/CMakeLists.txt', '**/*.cmake') }}
- run: sudo apt update && sudo apt install libboost-all-dev
- run: |
cmake -S. -Bbuild \
-Dalpaka_ACC_CPU_B_OMP2_T_SEQ_ENABLE:BOOL=ON \
-Dalpaka_ACC_CPU_B_SEQ_T_OMP2_ENABLE:BOOL=ON \
-Dalpaka_ACC_CPU_B_SEQ_T_SEQ_ENABLE:BOOL=ON \
-Dalpaka_ACC_CPU_B_SEQ_T_THREADS_ENABLE:BOOL=ON \
-DmallocMC_BUILD_TESTING:BOOL=ON \
-DmallocMC_BUILD_EXAMPLES:BOOL=ON
- working-directory: build
run: cmake --build . -j
- working-directory: build
run: ctest
- working-directory: build
run: |
for example in examples/[^C]*/mallocMCExample*; do
./${example}
done
37 changes: 37 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# tmp files
*~

# Compiled Object files
*.slo
*.lo
*.o
/build

# Compiled Dynamic libraries
*.so
*.dylib

# Compiled Static libraries
*.lai
*.la
*.a

# netbeans project files
/nbproject/

# Code::Blocks project files
/*.cbp
/*.layout

# Visual Studio Code configuration files
.vscode
.vs

# JetBrains project files
.idea/

# original backup files
*.orig

.cache
compile_commands.json
40 changes: 40 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
minimum_pre_commit_version: 3.2.0 # necessitated by Lucas-C's hooks
default_install_hook_types: [pre-commit, pre-push]
repos:
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: v19.1.7
hooks:
- id: clang-format
files: \.(cpp|hpp)
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: no-commit-to-branch
args: [-b, dev]
- id: check-merge-conflict
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-toml
- id: check-yaml
args: ["--allow-multiple-documents"]
- id: mixed-line-ending
- id: check-executables-have-shebangs
- id: check-shebang-scripts-are-executable
- repo: https://github.com/Lucas-C/pre-commit-hooks
rev: v1.5.5
hooks:
- id: forbid-tabs
- id: remove-tabs
- id: forbid-crlf
- id: remove-crlf
- repo: meta
hooks:
- id: check-useless-excludes
- repo: https://github.com/google/yamlfmt
rev: v0.15.0
hooks:
- id: yamlfmt
- repo: https://github.com/adrienverge/yamllint
rev: v1.35.1
hooks:
- id: yamllint
6 changes: 6 additions & 0 deletions .yamllint
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
extends: default
rules:
document-start: disable
truthy: disable
comments: disable
line-length: disable
64 changes: 64 additions & 0 deletions .zenodo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
{
"title": "mallocMC - Memory Allocator for Many Core Architectures",
"description": "This project provides a framework for fast memory managers on many core accelerators. It is based on alpaka to run on many different accelerators and implements multiple algorithms.",
"keywords": [
"mallocMC",
"CUDA",
"manycore",
"GPU",
"allocator"
],
"language": "eng",
"access_right": "open",
"license": {
"id": "MIT"
},
"creators": [
{
"name": "Widera, René",
"affiliation": "Helmholtz-Zentrum Dresden-Rossendorf",
"orcid": "0000-0003-1642-0459"
},
{
"name": "Lenz, Julian",
"affiliation": "CASUS, Helmholtz-Zentrum Dresden-Rossendorf",
"orcid": "0000-0001-5250-0005"
}
],
"contributors": [
{
"name": "Eckert, Carlchristian",
"affiliation": "Helmholtz-Zentrum Dresden-Rossendorf, TU Dresden",
"orcid": "0000-0002-6459-0842",
"type": "Other"
},
{
"name": "Worpitz, Benjamin",
"type": "Other"
},
{
"name": "Grund, Alexander",
"affiliation": "Helmholtz-Zentrum Dresden-Rossendorf",
"orcid": "0000-0002-7196-8452",
"type": "Other"
},
{
"name": "Huebl, Axel",
"affiliation": "Helmholtz-Zentrum Dresden-Rossendorf",
"orcid": "0000-0003-1943-7141",
"type": "Other"
},
{
"name": "Gruber, Bernhard Manfred",
"affiliation": "Helmholtz-Zentrum Dresden-Rossendorf, CASUS, CERN",
"orcid": "0000-0001-7848-1690",
"type": "Other"
},
{
"name": "Bastrakov, Sergei",
"affiliation": "Helmholtz-Zentrum Dresden-Rossendorf",
"orcid": "0000-0003-3396-6154",
"type": "Other"
}
]
}
Loading

0 comments on commit 6d77d8c

Please sign in to comment.