Skip to content
Snippets Groups Projects
  1. Dec 23, 2024
  2. Dec 18, 2024
  3. Dec 15, 2024
  4. Dec 12, 2024
  5. Dec 11, 2024
  6. Dec 10, 2024
  7. Nov 27, 2024
  8. Nov 25, 2024
  9. Nov 20, 2024
  10. Nov 04, 2024
  11. Oct 23, 2024
  12. Oct 16, 2024
  13. Jul 04, 2024
  14. Jun 10, 2024
    • Mark OLESEN's avatar
      ENH: add comparison operators to exprValue, integrate exprValueFieldTag · d859f7b0
      Mark OLESEN authored
      - exprValueFieldTag is an extended version of exprValue,
        with additional Field/List uniformity handling
      
      - the exprValueFieldTag reduce() method provides a more efficient
        method than using a regular combine operator. Since fields are
        usually non-uniform, will mostly only need the bitwise reduce and
        not a more expensive gather/combine.
      
      ENH: output of exprValue (scalar type) now includes '.'
      
      - prevents scalar/label ambiguity for values like '100.0', which would
        otherwise be written as '100' and thus interpreted as a label value
        when re-reading.
      d859f7b0
  15. Jun 03, 2024
  16. May 31, 2024
  17. May 30, 2024
  18. May 29, 2024
    • Mark OLESEN's avatar
      ENH: improve OFstream append behaviour (#3160) · ee895577
      Mark OLESEN authored and Kutalmış Berçin's avatar Kutalmış Berçin committed
      - previous support for file appending (largely unused) always
        specified opening with the std::ios_base::app flag.
      
        Now differentiate between append behaviours:
      
        APPEND_APP
        ~~~~~~~~~~
        Corresponds to std::ios_base::app behaviour:
      
        - Existing files will be preserved and a seek-to-end is performed at
          every write. With this mode seeks/repositioning within the file
          will effectively be ignored on output.
      
        APPEND_ATE
        ~~~~~~~~~~
        Largely approximates std::ios_base::ate behaviour:
      
        - Existing files will be preserved and a seek-to-end is performed
          immediately after opening, but not subsequently. Can use seekp()
          to overwrite parts of a file.
      ee895577
  19. May 28, 2024
    • Mark OLESEN's avatar
      ENH: GeometricBoundaryField evaluate with specified communication type · 9335b641
      Mark OLESEN authored
      - evaluate()
        the communication type is exposed as a parameter to allow for more
        tuning, but default parameter remains defaultCommsType so there is
        no change in behaviour for existing code
      
      - evaluate_if()
        supports a general selection predicate
      
      - evaluateSelected()
        now does initEvaluate() for all patches, waits and then calls
        evaluate(). This avoids potential deadlocks when multiple patches
        are inter-communicating.
      
      ENH: align DimensionedField reading with GeometricField treatment
      
      - use localIOdictionary to obtain the dictionary contents
      
      ENH: update GeometricField code
      
      - change GeometricField writeData() as primary output method
        (not operator<<) for better clarity of purpose
      
      - use unique_ptr for GeometricField demand-driven data
      9335b641
    • Mark OLESEN's avatar
      STYLE: more consistency in writeEntry() signatures · ffc98940
      Mark OLESEN authored
      - boundary entries with writeEntry(const word&, ...) instead of
        writeEntry(const keyType&, ...) to match with most other
        writeEntry() signatures. Also, this content will not be used
        to supply regex matched sub-dictionaries.
      
      STYLE: more consistent patch initEvaluate()/evaluate() coding
      ffc98940
  20. May 23, 2024
  21. May 22, 2024
  22. May 07, 2024
    • Mark OLESEN's avatar
      ENH: improve handling of multi-pass send/recv (#3152) · d9c73ae4
      Mark OLESEN authored
      - the maxCommsSize variable is used to 'chunk' large data transfers
        (eg, with PstreamBuffers) into a multi-pass send/recv sequence.
      
        The send/recv windows for chunk-wise transfers:
      
            iter    data window
            ----    -----------
            0       [0, 1*chunk]
            1       [1*chunk, 2*chunk]
            2       [2*chunk, 3*chunk]
            ...
      
        Since we mostly send/recv in bytes, the current internal limit
        for MPI counts (INT_MAX) can be hit rather quickly.
      
        The chunking limit should thus also be INT_MAX, but since it is
        rather tedious to specify such large numbers, can instead use
      
            maxCommsSize = -1
      
        to specify (INT_MAX-1) as the limit.
        The default value of maxCommsSize = 0 (ie, no chunking).
      
      Note
      ~~~~
        In previous versions, the number of chunks was determined by the
        sender sizes. This required an additional MPI_Allreduce to establish
        an overall consistent number of chunks to walk. This additional
        overhead each time meant that maxCommsSize was rarely actually
        enabled.
      
        We can, however, instead rely on the send/recv buffers having been
        consistently sized and simply walk through the local send/recvs until
        no further chunks need to be exchanged. As an additional enhancement,
        the message tags are connected to chunking iteration, which allows
        the setup of all send/recvs without an intermediate Allwait.
      
      ENH: extend UPstream::probeMessage to use int64 instead of int for sizes
      d9c73ae4
    • Mark OLESEN's avatar
      STYLE: use Perr instead of Pout for UPstream::debug and warnComm · e15d696a
      Mark OLESEN authored
      - avoids polluting standard output for utilities such as
        foamDictionary etc
      e15d696a
  23. May 06, 2024
    • Mark OLESEN's avatar
      ENH: add single-time handling to timeSelector · dbfd1f90
      Mark OLESEN authored
      - the timeSelector is often used to select single or multiple times
        (eg, for post-processing). However, there are a few applications
        where only a *single* time should be selected and set.
      
        These are now covered by this type of use:
      
            timeSelector::addOptions_singleTime();  // Single-time options
            ...
            // Allow override of time from specified time options, or no-op
            timeSelector::setTimeIfPresent(runTime, args);
      
         In some cases, if can be desirable to force starting from the
         initial Time=0 when no time options have been specified:
      
            // Set time from specified time options, or force start from Time=0
            timeSelector::setTimeIfPresent(runTime, args, true);
      
         These changes make a number of includes redundant:
      
           * addTimeOptions.H
           * checkConstantOption.H
           * checkTimeOption.H
           * checkTimeOptions.H
           * checkTimeOptionsNoConstant.H
      
      ENH: add time handling to setFields, setAlphaField (#3143)
      
          Co-authored-by: Johan Roenby <>
      
      STYLE: replace instant("constant") with instant(0, "constant")
      
      - avoids relying on atof parse behaviour returning zero
      dbfd1f90
  24. May 02, 2024
    • Mark OLESEN's avatar
      ENH: add offset support to stringOps::split functions · 88319698
      Mark OLESEN authored
      - for example,
      
           string buffer = ...;
           SubStrings<string> split;
           {
               auto colon = buffer.find(':');
      
               if (colon != std::string::npos)
               {
                   split = stringOps::splitSpace(buffer, colon+1);
               }
           }
      
          Not really possible with a substr() since that would create a new
          temporary which then disappears.  Similarly awkward to split and
          then scan for the ':' to decide how many to discard.
      
      ENH: add pop_front() and pop_back() methods to SubStrings
      
      - the content is trivial enough (a pair of iterators) and the total
        number of elements is usually reasonable short so that removal of
        elements is inexpensive
      
        For example,
      
           string buffer = ...;
           auto split = stringOps::splitSpace(buffer);
      
           if (!split.empty() && split[0].str() == "face")
           {
               split.pop_front();
           }
      88319698
    • Mark OLESEN's avatar
      COMP: remove template-id for constructor/destructor · 3fed4154
      Mark OLESEN authored
      - not allowed in C++20
      
      COMP: avoid hidden overloaded-virtual (edgeMesh, surfMesh)
      3fed4154
  25. Apr 29, 2024
    • Mark OLESEN's avatar
      STYLE: use PstreamBuffers default construct · 7b38b148
      Mark OLESEN authored
      - PstreamBuffers are nonBlocking by default, so no need to re-specify
      7b38b148
    • Mark OLESEN's avatar
      STYLE: communication name "buffered" instead of "blocking" · 7f355ba3
      Mark OLESEN authored
      - "buffered" corresponds to MPI_Bsend (buffered send),
        whereas the old name "blocking" is misleading since the
        regular MPI_Send also blocks until completion
        (ie, buffer can be reused).
      
      ENH: IPstream::read() returns std::streamsize instead of label (#3152)
      
      - previously returned a 'label' but std::streamsize is consistent with
        the input parameter and will help with later adjustments.
      
      - use <label> instead of <int> for internal accounting of the message
        size, for consistency with the underyling List<char> buffers used.
      
      - improve handling for corner case of IPstream receive with
        non-blocking, although this combination is not used anywhere
      7f355ba3
  26. Apr 24, 2024
    • Mark OLESEN's avatar
      ENH: improve code consistency for {cell,face,point}Mapper (#3147) · f04ccef5
      Mark OLESEN authored
      - robuster and more reliable determination of inserted objects
        (previous code could produce false positives).
      
        Now also determine the number of inserted objects within the
        constructor (instead of simply storing a bool). This allows reuse
        in the address calculations to reduce overheads there.
      
      BUG: dodgy short-circuit logic for insertedObjectLabels()
      
      - as a quick short-circuit it previously created as demand-driven
        pointer with a zero elements. However, this meant that if this code
        was called first (before any other addressing), subsequent calls to
        the addressing would fail.
      
      BUG: bad logic and lookup for faAreaMapper (#3147)
      
      - was using labelHashSet but returning a bool and set using the
        addressing using the unfiltered objects!
        This is a latent bug since interpolated/inserted faces not
        currently supported anyhow.
      
      ENH: use std::unique_ptr for demand-driven data
      f04ccef5