Skip to content
Snippets Groups Projects
  1. Nov 21, 2021
    • Jan Trávníček's avatar
      algo: fix MP algo · e2929988
      Jan Trávníček authored and Tomáš Pecka's avatar Tomáš Pecka committed
      MP algorithm was always resetting the pattern index to 0 whereas it should be
      reused. This revealed that Spos should also take into account node wildcards
      otherwise the presumed not-necessary-to-be-parsed part of the pattern does not
      have to be matching the pattern. Which caused the computation of what does not
      need to be matched to underflow.
      e2929988
  2. Nov 20, 2021
  3. Oct 15, 2021
  4. Jul 20, 2021
  5. May 28, 2021
  6. Apr 03, 2021
  7. Mar 25, 2021
  8. Mar 11, 2021
    • Tomáš Pecka's avatar
      tests: Fix wrong select timeout handling since glibc=2.33 · 172f6acd
      Tomáš Pecka authored
      In recent Arch Linux builds we encountered some timeouts in tests.
      Interestingly, the 30s timeouts were encountered not after 30s but
      right-away. See the ctest output attached at the end of the message.
      
      I remembered that Arch switched to glibc=2.33 recently. And by stracing
      the test process I have noticed that indeed, the select in waitSignalTimeout
      function timeouted early.
      It seemed that the timeval struct is the problem and indeed it was. It
      didn't like setting the 30s timeout as {.tv_sec = 0, .tv_usec = 30 *
      1000 * 1000}. However, I can't find in any manpage why this is wrong...
      
      It seems to be fixed by limiting tv_usec to be from [0; 1000*1000)
      range and transfer the whole seconds into the tv_sec field.
      And the glibc docs [1] says it so explicitely:
      
      > When struct timeval values are produced by GNU C Library functions,
      > the value in this field will always be greater than or equal to zero,
      > and less than 1,000,000. When struct timeval values are supplied to GNU
      > C Library functions, the value in this field must be in the same range.
      
      [1] https://www.gnu.org/software/libc/manual/html_mono/libc.html#Time-Types
      
       -------------------------------------------------------------------------------
       aql/AutomatonIteration.aql
       -------------------------------------------------------------------------------
       /builds/algorithms-library-toolkit/infrastructure/cd-release/src/algorithms-library-snapshot/build/tests/AutomatonIteration.cpp:17
       ...............................................................................
      
       /builds/algorithms-library-toolkit/infrastructure/cd-release/src/algorithms-library-snapshot/tests/testing/TimeoutAqlTest.cpp:206: warning:
         AqlTest: timeout (30000000 us) reached
         Trying to execute testfile /builds/algorithms-library-toolkit/infrastructure/cd-release/src/algorithms-library-snapshot/tests/aql/AutomatonIteration.aql
      
       Seed was: 1053288110
         Child aqlout was: ><
         Child stdout was: ><
         Child stderr was: ><
      
       /builds/algorithms-library-toolkit/infrastructure/cd-release/src/algorithms-library-snapshot/tests/testing/TimeoutAqlTest.cpp:208: FAILED:
      
       ===============================================================================
       test cases: 1 | 1 failed
       assertions: 3 | 2 passed | 1 failed
      172f6acd
  9. Mar 08, 2021
  10. Jan 31, 2021
    • Tomáš Pecka's avatar
      algo: Add integration aql test for FA iteration algorithms · 6ff8fe45
      Tomáš Pecka authored
      This test generates a random automaton, runs both iteration algorithms on
      it and then tests that both these automata accept equal language.
      
      This is first of the aql integration tests (which support was added in
      commit d79fe028). This should serve as
      an example how to write aql integration tests.
      Also, this is something that should not be in the unit tests (and it
      was removed in the previous commits).
      6ff8fe45
  11. Jan 30, 2021
  12. Jan 15, 2021
  13. Oct 08, 2020
  14. Aug 06, 2020
  15. Aug 04, 2020
  16. Aug 03, 2020
Loading