Ann: SWI-Prolog 8.1.18

Dear SWI-Prolog user,

I have uploaded SWI-Prolog 8.1.18. This is mostly a bug-fixing release,
some of which are critical. The important bug fixes:

  • Fixed a bug that could cause retractall/1 to fail. This bug was
    introduced with the event hook to trap changes to dynamic predicates
    for incremental tabling support, version 8.1.11. It surfaced as
    spurious 404 pages from the SWI-Prolog web server as it can cause
    failure in absolute_file_name/3 if two threads use this at the same
    time.
  • Fixed several possible (but rather unlikely) race conditions in
    translation of local paths to absolute and canonical paths (Unix
    only). Avoid make_library_index/1 (called by make/0) from changing
    the working directory temporarily, also causing problems resolving
    files in threads.
  • Fixed exiting Prolog after using PceEmacs (bug introduced with
    new XDG directory conventions).
  • Fixed get_time/1 for 32-bit Windows.
  • Avoid profiling to deadlock if Prolog’s image is large and performs
    fork() calls (i.e., uses process_create/3 or shell/1 and friends).
    The high frequency profiling signals can cause fork() to never complete.

There is also some new stuff:

  • Matt Lilley changed SSL certificate handling to represent certificates
    as blobs. This allows exposing more of the OpenSSL certificate
    handling functionality. Code that directly accessed the Prolog content
    of the old certificates must be re-written to use certificate_field/2.

  • Call subsumption in tabling now performs much better.

  • Updated dependencies for the binary releases for Windows 32 and 64 bits
    as well as for MacOS.

    Enjoy — Jan

SWI-Prolog Changelog since version 8.1.17

  • PORT: Disabled PGO compilation for the Windows binary because it is
    not supported in recent Ubuntu versions.

  • PORT: Updated MacOS dependencies to their latest version

  • ENHANCED: Hash canonical directory lookup.

  • FIXED: Avoid a race condition in directory canonicalization.

  • FIXED: retractall/1 could fail if a clause was already retracted
    somehow. This bug was introduced with the introduction of the event
    interface on dynamic database changes required for incremental tabling.

  • PORT: Add -DO_DEBUG to Debug build type on MacOS

  • FIXED: Thread-safety of cached notion of the working directory.
    Should not be a big issue as multi-threaded applications are not
    supposed to change working directory after initialization.

  • MODIFIED: make_libary_index/1, called by make/0 no longer changes
    to the target library directory if this directory contains a file
    MKINDEX.pl. This ensures that make/0 is safe in a multi-threaded
    environment. Existing MKINDEX.pl should use the folowing pattern:

    :- prolog_load_context(directory, Dir), make_library_index(Dir, ...).
    
  • FIXED: library(dcg/high_order): determinism handling and final
    element handling for sequences. Also clarified the documentation.
    Raised by Boris Vassilev on the forum.

  • FIXED: get_time/1 for 32-bit Windows. This is a work-around for
    a broken clock_gettime() in MinGW32. Comes with a test case to
    ensure get_time/1 is not subject to 32/64 bit issues.

  • ENHANCED: Tabling with call subsumption: add a quick test to decide
    whether new answers apply to subsumed consumers. This still results
    in quadradic behaviour of some goals, but this now only shows at
    much larger number of consumers, staying practically linear as long
    as the fraction of applicable consumers is more than 1 in 1,000.

  • PORT: Bumped most Windows dependencies to their latest release

  • ENHANCED: SICStus time_out/3 emulation: documentation and allow for
    nested calls.

Package clib

  • FIXED: Request for HAVE_SIGPROCMASK to be added to clib packge’s
    config.h

Package semweb

  • FIXED: incorrect detection of empty RDF list

Package ssl

  • ADDED: same_certificate/2 to allow comparing certificates

  • FIXED: verify_certificate_issuer/2. When x509_check_issued succeeds,
    it returns 0

  • MODIFIED: SSL certificates are no longer represented as Prolog terms
    but as blobs a predicate certificate_field/2 to query fields of the
    certificate. Any old code which obtains fields from the certificate
    using memberchk/2 should be modified to use certificate_field/2
    instead. Typical SSL applications rarely examine certificates directly
    and therefore we expect the implications on user code to be minor.

Package xpce

  • COMPAT: Avoid MKINDEX.pl from depending on the working directory.

  • FIXED: PceEmacs: save bookmarks

1 Like

Oops. Ubuntu PPA build failed on what turns out to be a forgotten initialization of the new mutex that deals with path canonicalization. Pushed 2f2e6ec94f9666951da55fa97d1b721fbcd94bc7 to fix this. I fear this implies releasing 8.1.19 very soon :frowning: