Skip to content

Commit

Permalink
Update to nvc++ 24.11 and compile as c++23 (#153)
Browse files Browse the repository at this point in the history
  • Loading branch information
lukeshingles authored Nov 15, 2024
1 parent 1c3be6c commit 1d6cf2f
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ jobs:
{name: gcc, ver: 12},
{name: gcc, ver: 13},
{name: gcc, ver: 14},
{name: nvc++, ver: '24.9'},
{name: nvc++, ver: '24.11'},
]
fail-fast: false

Expand Down
16 changes: 10 additions & 6 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,18 +1,22 @@
{
"[cpp]": {
"editor.tabSize": 2,
"editor.codeActionsOnSave": {
"source.fixAll": "always"
},
"editor.formatOnSave": true
"editor.defaultFormatter": "llvm-vs-code-extensions.vscode-clangd",
"editor.formatOnSave": true,
"editor.semanticHighlighting.enabled": true,
"editor.suggest.insertMode": "replace",
"editor.tabSize": 2,
"editor.wordBasedSuggestions": "off"
},
"[yaml]": {
"editor.tabSize": 4
},
"editor.formatOnSave": true,
"editor.formatOnType": true,
"files.eol": "\n",
"files.trimFinalNewlines": true,
"files.insertFinalNewline": true,
"files.trimTrailingWhitespace": true,
"editor.formatOnType": true,
"editor.formatOnSave": true
"files.trimFinalNewlines": true,
"files.trimTrailingWhitespace": true
}
9 changes: 4 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,12 @@ endif

$(info detected compiler is $(COMPILER_NAME) major version $(COMPILER_VERSION_NUMBER_MAJOR))

ifeq ($(COMPILER_NAME),NVHPC)
CXXFLAGS += -std=c++20
else
CXXFLAGS += -std=c++23 -ftree-vectorize -Wunused-macros -Werror -Wno-error=unknown-pragmas -Wno-error=cast-function-type -MD -MP -ftrivial-auto-var-init=pattern
CXXFLAGS += -std=c++23 -fstrict-aliasing

ifneq ($(COMPILER_NAME),NVHPC)
CXXFLAGS += -ftree-vectorize -Wunused-macros -Werror -Wno-error=unknown-pragmas -Wno-error=cast-function-type -MD -MP -ftrivial-auto-var-init=pattern
endif

CXXFLAGS += -fstrict-aliasing
# CXXFLAGS += -DUSE_SIMPSON_INTEGRATOR=true

# profile-guided optimisation
Expand Down

0 comments on commit 1d6cf2f

Please sign in to comment.