Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • openfoam openfoam
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 426
    • Issues 426
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 8
    • Merge requests 8
  • Deployments
    • Deployments
    • Releases
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Development
  • openfoamopenfoam
  • Issues
  • #232
Closed
Open
Issue created Sep 12, 2016 by Admin@OpenFOAM-adminMaintainer

metisDecomp compile error

When compiling OpenFOAM v1606, the following compilation error appears:

metisDecomp.C:211:9: error: cannot convert ‘Foam::UList<float>::iterator {aka float*}’ to ‘real_t* {aka double*}’ for argument ‘9’ to ‘int METIS_PartGraphRecursive(idx_t*, idx_t*, idx_t*, idx_t*, idx_t*, idx_t*, idx_t*, idx_t*, real_t*, real_t*, idx_t*, idx_t*, idx_t*)’

metisDecomp.C:230:9: error: cannot convert ‘Foam::UList<float>::iterator {aka float*}’ to ‘real_t* {aka double*}’ for argument ‘9’ to ‘int METIS_PartGraphKway(idx_t*, idx_t*, idx_t*, idx_t*, idx_t*, idx_t*, idx_t*, idx_t*, real_t*, real_t*, idx_t*, idx_t*, idx_t*)’

It seems that REALTYPEWIDTH 64 in metis.h should correspond to Field<scalar> processorWeights in metisDecomp.C, while REALTYPEWIDTH 32 corresponds to Field<floatScalar> processorWeights. So, in order to compile metisDecomp, I changed metisDecomp.C to have Field<scalar> instead of Field<floatScalar>(see below).

$WM_THIRD_PARTY_DIR/platforms/linux64Gcc/metis-5.1.0/include/metis.h

#define REALTYPEWIDTH 64

$WM_PROJECT_DIR/src/parallel/decompose/metisDecomp/metisDecomp.C

Field<scalar> processorWeights

For reference: this problem appears to be related to the bug report on the OpenFOAM fork's website: http://bugs.openfoam.org/view.php?id=2085.

Assignee
Assign to
Time tracking