System/ReleaseNotes/J902

From J Wiki
Jump to navigation Jump to search

>> << Pri JfC LJ Phr Dic Voc !: Rel NuVoc wd Help 


J902 beta development started in Dec 2019, and 902-beta-a was released 14 May 2020.

Changes to the J engine

  • Windows releases built with Visual Studio 2019 clang compiler. Previous releases were built with VS2013 and MS compiler.

Summary of Changes to the J Language in the release

  • Explicit entities can be defined using direct definition. The digraphs {{ and }} are reserved for delimiters, and text found between {{ }} is taken to define a verb/adverb/conjunction. The text may be multiple lines long and may contain other embedded definitions. The part of speech of the defined entity is inferred from the words in it. More detail is here. For the beta period only, direct definition can be disabled by executing (9!:63 (0)).
  • Incompatible language change - Fold family: to make the execution match the right-to-left orientation of J, in the Fold primitives (u F.: v etc) v is executed first, then u.
  • Incompatible language change - m@.v: m@.v is now defined to have infinite rank. Its implementation is like the other partitioning modifiers:
    • v is applied at infinite rank
    • the rank of the result of v indicates the rank at which verbs in m are applied
    • cells being submitted to the same verb may be collected into a list of such cells and submitted to the verb in one execution
  • Language extension - semiduals: x u&.:(a:`v) y is equivalent to v^:_1 x u v y . That is, it is like x u&.:v y except that v is applied only to y . Similarly, x u&.:(v`a:) y is equivalent to v^:_1 (v x) u y . Forms with &. are also supported, with the verb having ranks taken from the verb that is applied to the argument.
  • Incompatible language change - support for legacy modifiers dropped: previously, adverbs and conjunctions that did not refer to the names u, v, m, or n were given special treatment: x and y were assigned with the values of u and v. This was to support an early version the language. This special treatment is withdrawn.
  • backtrack function added to (x ;: y)

unreleased work in progress

  • None

beta-o (the current beta)

  • x and y in modifiers are now always processed as noun arguments, regardless of the presence of uvmn

beta-n

  • bug fixes only, no new features

beta-m

  • backtrack function added to (x ;: y)

beta-l

  • Special code for x (,<) y, x (;<) y, x ,&< y, and x ,&:< y. Avoids most boxing during right-to-left processing (like x ; y).

beta-k withdrawn

  • bug found in u each each, fixed in beta-l

beta-j

  • x ; y rewritten, much faster, especially when several are used in a row
  • Direct Definition expanded to include multiline noun forms

beta-i

  • Special code for ((#,{.)/. i.@#) y and (({.,#)/. i.@#) y. These forms find the equal values of y, giving the number of occurrences and the index of the first occurrence.
  • Old-style modifiers now give nonce error rather than a warning message
  • JE now allows controlled recursive calls when the JE is waiting for a prompt or a reply from wd
  • invalid number in a script now prints the offending word
  • Explicit entities can be defined using direct definition. The digraphs {{ and }} are reserved for delimiters, and text found between {{ }} is taken to define a verb/adverb/conjunction. The text may be multiple lines long and may contain other embedded definitions. The part of speech of the defined entity is inferred from the words in it. More detail is here. For the beta period only, direct definition can be disabled by executing (9!:63 (0)).

beta-h

  • fixes bugs found in beta-g
  • Atomic dyad setup rewritten yet again. It now runs the entire main line with no data-dependent branches and with all variables in registers. La commedia è finita.

beta-g withdrawn

  • fixes bugs found in beta-f
  • bug found: error in (x ]\ y) on boxed y (caused isigraph demo to fail)

beta-f withdrawn

  • bug found: error in (x {:: y) when rank of x>1
  • An adverb whose value contains no name references is stacked by value rather than by name. This saves the overhead of looking up the name and starting a named entity. The Dictionary specifies that all modifiers be stacked by value, but to do so would make debugging difficult.
  • Faster code for u@] and u@[
  • Major improvements in space required during execution. The space reported by 7!:2 is the amount of temporary space allocated by the sentence. This space adds to the cache footprint of the sentence. Reductions in this space translate into faster execution to the extent that they make cache usage more efficient.
    • Inplacing is extended to the form u&.v. Inplaceable boxed arguments are produced by u&.v, <"n y, and most partitioning modifiers when the verb is of the form <@(v). Example:
         a =: <"1 i. 100 10000
        7!:2 'a =: >:&.> a'
      J9.01: 13109760
      new code: 2304
    • The parser now frees spent arguments immediately after they are used, rather than waiting until the sentence is finished. This is the culmination of a long quest to reduce cache footprint. Example:
         a =: 8000 ?@$ 0
         7!:2 '(+: a) + (-: a) + (%: a) + (*: a) + a'
      J6.02: 525888
      J9.01: 264320
      new code: 133248
    • Virtual x/y arguments passed into explicit definitions are no longer realized
    • Inplaceable x/y arguments passed into explicit definitions are eligible for assignment-in-place inside the explicit definition
    • The result of an explicit definition is inplaceable whenever possible
    • assembly of non-direct results releases some memory earlier
  • faster looping used in (list u"0 _ atom) and (table u"1 same-shape-table), for atomic primitive u

beta-e

  • known bugs in this beta, fixed in beta-f:
    • (;: y) crashes if 1<#@$y. Workaround: use ;:"1"1 y
  • Incompatible language change - support for legacy modifiers dropped: previously, adverbs and conjunctions that did not refer to the names u, v, m, or n were given special treatment: x and y were assigned with the values of u and v. This was to support an early version the language. This special treatment is withdrawn. During the beta, modifiers that would have been given the special treatment will fail with nonce error; after the release, they will be allowed again. If you see messages download this script to see what you need to change.

beta-d

  • special code for x +//. y, x <.//. y, x >.//. y, and x (+/%#)/. y, except for + when y is integer
  • special code for x </. y
  • special code for x (</. i.@#) y rewritten, faster
  • base64 optimization using ssse3,avx2,neon and OpenMP

beta-c

  • x u/. y code to find cells rewritten, faster
  • x #/. y, x ({.,#)/. y, and x (#,{.)/. y rewritten, faster
  • </\ y, <:/\ y, >/\ y, >:/\ y, +:/\ y, and *:/\ y faster when cell-rank > 1
  • avx/avx2 emulation to enable running codes written for AVX and AVX2
    • 64-bit x86_64 avx and non-avx cpu using sse2/sse3 instructions
    • arm64 cpu using neon asimd instructions
  • SLEEF function library extended to 32-bit x86, 64-bit x86_64 and arm64. Only 32-bit Raspberry and armv7 Android platforms do not support SLEEF.

beta-b

  • x E. y and allied compounds on boolean and literal arguments rewritten, much faster (x I.@E. y about 40x faster) (AVX2 only)
  • 3!:1 (create binary representation) recoded to use less space
  • 3!:3 (create hex representation) recoded to use less space
  • SLEEF function library used for elementary math functions, 2-3x faster (AVX and AVX2 only)
  • x #/. y rewritten, 2x faster
  • x (#,{.)/. y and x ({.,#)/. y rewritten, 3x faster
  • x ^@:p. y special code for boolean, integer, and floating-point types (AVX and AVX2 only)
  • i.-family improved when searching integer lists (AVX2 only)
  • x -: y recoded (AVX2 only), 4-10x faster for integers, 8-15x faster for floats

beta-a

  • Incompatible language change - Fold family: to make the execution match the right-to-left orientation of J, in the Fold primitives (u F.: v etc) v is executed first, then u.
  • Language extension - semiduals: x u&.:(a:`v) y is equivalent to v^:_1 x u v y . That is, it is like x u&.:v y except that v is applied only to y . Similarly, x u&.:(v`a:) y is equivalent to v^:_1 (v x) u y . Forms with &. are also supported, with the verb having ranks taken from the verb that is applied to the argument.
  • Incompatible language change - m@.v: m@.v is now defined to have infinite rank. Its implementation is like the other partitioning modifiers:
    • v is applied at infinite rank
    • the rank of the result of v indicates the rank at which verbs in m are applied
    • cells being submitted to the same verb may be collected into a list of such cells and submitted to the verb in one execution
  • u^:n now gives domain error if n is empty. Same for u^:v when v produces empty.
  • Improvement to x = y and x ~: y on character data (AVX2 only)
  • 256-bit instructions used for floating-point x * y and x % y (AVX2 only)
  • 256-bit instructions used for integer x + y and x - y (AVX2 only)
  • 256-bit instructions used for integer x <. y and x >. y (AVX2 only)
  • [x] u^:v y recoded to guarantee no reexecution of u
  • word formation (;: y) rewritten for speed

Changes to the base system

Changes to the Qt IDE


>> << Pri JfC LJ Phr Dic Voc !: Rel NuVoc wd Help