Skip to content

Releases: diku-dk/futhark

0.7.3

26 Oct 13:18
Compare
Choose a tag to compare

Added

  • Significant performance changes: there is now a constant extra
    compilation overhead (less than 200ms on most machines). However,
    the rest of the compiler is 30-40% faster (or more in some cases).

  • A warning when ambiguously typed expressions are assigned a
    default (i32 or f64).

  • In-place updates and record updates are now written with =
    instead of <-. The latter is deprecated and will be removed in
    the next major version (#650).

Fixed

  • Polymorphic value bindings now work properly with module type
    ascription.

  • The type checker no longer requires types used inside local
    functions to be unambiguous at the point where the local function
    is defined. They must still be unambiguous by the time the
    top-level function ends. This is similar to what other ML
    languages do.

  • futhark-bench now writes "μs" instead of "us".

  • Type inference for infix operators now works properly.

0.7.2

08 Oct 07:37
Compare
Choose a tag to compare

Added

  • futhark-pkg now supports GitLab.

  • futhark-tests --notty option now has a --no-terminal alias.
    --notty is deprecated, but still works.

  • futhark-test now supports multiple entry points per test block.

  • Functional record updates: r with f <- x.

Fixed

  • Fix the -C option for futhark-test.

  • Fixed incorrect type of reduce_by_index.

  • Segmented reduce_by_index now uses much less memory.

0.7.1

21 Sep 14:30
Compare
Choose a tag to compare

Added

  • C# backend by Mikkel Storgaard Knudsen (futhark-cs/futhark-csopencl).

  • futhark-test and futhark-bench now take a --runner option.

  • futharki now uses a new interpreter that directly interprets the
    source language, rather than operating on the desugared core
    language. In practice, this means that the interactive mode is
    better, but that interpretation is also much slower.

  • A trace function that is semantically id, but makes futharki
    print out the value.

  • A break function that is semantically id, but makes futharki
    stop and provide the opportunity to inspect variables in scope.

  • A new SOAC, reduce_by_index, for expressing generalised
    reductions (sometimes called histograms). Designed and
    implemented by Sune Hellfritzsch.

Removed

Changed

  • The largest/smallest values for numeric modules have been
    renamed highest/lowest.

Fixed

  • Many small things.

0.6.3

24 Aug 09:07
Compare
Choose a tag to compare

Added

  • Added a package manager: futhark-pkg. See also the
    documentation
    .

  • Added log2 and log10 functions to f32 and f64.

  • Module type refinement (with) now permits refining parametric
    types.

  • Better error message when invalid values are passed to generated
    Python entry points.

  • futhark-doc now ignores files whose doc comment is the word
    "ignore".

  • copy now works on values of any type, not just arrays.

  • Better type inference for array indexing.

Fixed

  • Floating-point numbers are now correctly rounded to nearest even
    integer, even in exotic cases (#377).

  • Fixed a nasty bug in the type checking of calls to consuming
    functions (#596).

0.6.2

16 Jul 09:42
Compare
Choose a tag to compare

Added

  • Bounds checking errors now show the erroneous index and the size
    of the indexed array. Some other size-related errors also show
    more information, but it will be a while before they are all
    converted (and say something useful - it's not entirely
    straightforward).

  • Opaque types now have significantly more readable names,
    especially if you add manual size annotations to the entry point
    definitions.

  • Backticked infix operators can now be used in operator sections.

Fixed

  • f64.e is no longer pi.

  • Generated C library code will no longer abort() on application
    errors (#584).

  • Fix file imports on Windows.

  • futhark-c and futhark-opencl now generates thread-safe code (#586).

  • Significantly better behaviour in OOM situations.

  • Fixed an unsound interaction between in-place updates and
    parametric polymorphism (#589).

0.6.1

09 Jul 17:17
Compare
Choose a tag to compare

Added

  • The real module type now specifies tan.

  • futharki now supports entering declarations.

  • futharki now supports a :type command (or :t for short).

  • futhark-test and futhark-benchmark now support gzipped data
    files. They must have a .gz extension.

  • Generated code now frees memory much earlier, which can help
    reduce the footprint.

  • Compilers now accept a --safe flag to make them ignore unsafe.

  • Module types may now define lifted abstract types, using the
    notation type ^t. These may be instantiated with functional
    types. A lifted abstract type has all the same restrictions as a
    lifted type parameter.

Removed

  • The rearrange construct has been removed. Use transpose instead.

  • futhark-mode.el has been moved to a separate
    repository
    .

  • Removed |>> and <<|. Use >-> and <-< instead.

  • The empty construct is no longer supported. Just use empty
    array literals.

Changed

  • Imports of the basis library must now use an absolute path
    (e.g. /futlib/fft, not simply futlib/fft).

  • /futlib/vec2 and /futlib/vec3 have been replaced by a new
    /futlib/vector file.

  • Entry points generated by the C code backend are now prefixed with
    futhark_entry_ rather than just futhark_.

  • zip and unzip are no longer language constructs, but library
    functions, and work only on two arrays and pairs, respectively.
    Use functions zipN/unzipN (for 2<=n<=8).

Fixed

  • Better error message on EOF.

  • Fixed handling of .. in import paths.

  • Type errors (and other compiler feedback) will no longer contain
    internal names.

  • futhark-test and friends can now cope with infinities and NaNs.
    Such values are printed and read as f32.nan, f32.inf,
    -f32.inf, and similarly for f32. In futhark-test, NaNs
    compare equal.

0.5.2

03 Jun 19:12
Compare
Choose a tag to compare

Added

  • Array index section: (.[i]) is shorthand for (\x -> x[i]).
    Full slice syntax supported. (#559)

  • New assert construct. (#464)

  • futhark-mode.el now contains a definition for flycheck.

Fixed

  • The index produced by futhark-doc now contains correct links.

  • Windows linebreaks are now fully supported for test files (#558).

0.5.1

30 May 20:33
Compare
Choose a tag to compare

Added

  • Entry points need no longer be syntactically first-order.

  • Added overloaded numeric literals (#532). This means type
    suffixes are rarely required.

  • Binary and unary operators may now be bound in patterns by
    enclosing them in parenthesis.

  • futhark-doc now produces much nicer documentation. Markdown is
    now supported in documentation comments.

  • /futlib/functional now has operators >-> and <-< for
    function composition. <<| are |>> are deprecated.

  • /futlib/segmented now has a segmented_reduce.

  • Scans and reductions can now be horizontally fused.

  • futhark-bench now supports multiple entry points, just like
    futhark-test.

  • ".." is now supported in include paths.

Removed

  • The reshape construct has been removed. Use the
    flatten/unflatten functions instead.

  • concat and rotate no longer support the @ notation. Use
    map nests instead.

  • Removed -I/--library. These never worked with
    futhark-test/futhark-bench anyway.

Changed

  • When defining a module type, a module of the same name is no
    longer defined (#538).

  • The default keyword is no longer supported.

  • /futlib/merge_sort and /futlib/radix_sort now define
    functions instead of modules.

Fixed

  • Better type inference for rearrange and rotate.

  • import path resolution is now much more robust.

0.4.1

13 Apr 19:05
Compare
Choose a tag to compare

Added

  • Unused-result elimination for reductions; particularly useful when
    computing with dual numbers for automatic differentiation.

  • Record field projection is now possible for variables of (then)
    unknown types. A function parameter must still have an
    unambiguous (complete) type by the time it finishes checking.

Fixed

  • Fixed interaction between type ascription and type inference (#529).

  • Fixed duplication when an entry point was also called as a function.

  • Futhark now compiles cleanly with GHC 8.4.1 (this is also the new default).

0.4.0

10 Apr 11:50
Compare
Choose a tag to compare

Added

  • The constructor for generated PyOpenCL classes now accepts a
    command_queue parameter (#480).

  • Transposing small arrays is now much faster when using OpenCL
    backend (#478).

  • Infix operators can now be defined in prefix notation, e.g.:

    let (+) (x: i32) (y: i32) = x - y
    

    This permits them to have type- and shape parameters.

  • Comparison operators (<=, <, >, >=) are now valid for boolean
    operands.

  • Ordinary functions can be used as infix by enclosing them in
    backticks, as in Haskell. They are left-associative and have
    lowest priority.

  • Numeric modules now have largest/smallest values.

  • Numeric modules now have sum, product, maximum, and
    minimum functions.

  • Added --Werror command line option to compilers.

  • Higher-order functions are now supported (#323).

  • Type inference is now supported, although with some limitations
    around records, in-place updates, and unzip. (#503)

  • Added a range of higher-order utility functions to the prelude,
    including (among others):

    val (|>) '^a '^b: a ->  (a -> b) -> b
    
    val (<|) '^a '^b: (a -> b) -> a -> b
    
    val (|>>) '^a 'b '^c: (a -> b) -> (b -> c) -> a -> c
    
    val (<<|) '^a 'b '^c: (b -> c) -> (a -> b) a -> c
    

Changed

  • FUTHARK_VERSIONED_CODE is now FUTHARK_INCREMENTAL_FLATTENING.

  • The SOACs map, reduce, filter, partition, scan,
    stream_red, and stream_map have been replaced with library
    functions.

  • The futlib/mss and futlib/lss modules have been rewritten to use
    higher-order functions instead of modules.

Fixed

  • Transpositions in generated OpenCL code no longer crashes on
    large but empty arrays (#483).

  • Booleans can now be compared with relational operators without
    crashing the compiler (#499).