Skip to content
Snippets Groups Projects
Commit fdd57589 authored by Andreas Klöckner's avatar Andreas Klöckner
Browse files

Some documentation work.

parent a4ee6435
No related branches found
No related tags found
No related merge requests found
......@@ -54,8 +54,6 @@ To-do
- Expose iname-duplicate-and-rename as a primitive.
- add_prefetch gets a flag to separate out each access
- Allow parameters to be varying during run-time, substituting values
that depend on other inames?
......@@ -63,11 +61,15 @@ To-do
- Scalar insn priority
- : in prefetches
- add_prefetch tagging
- : (as in, Matlab full-sclice) in prefetches
Future ideas
^^^^^^^^^^^^
- (Web) UI
- Check for unordered (no-dependency) writes to the same location
- String instructions?
......
......@@ -8,7 +8,16 @@ This guide defines all functionality exposed by loopy. If you would like
a more gentle introduction, you may consider reading the example-based
guide :ref:`guide` instead.
.. _tags:
Inames
------
Loops are (by default) entered exactly once. This is necessary to preserve
depdency semantics--otherwise e.g. a fetch could happen inside one loop nest,
and then the instruction using that fetch could be inside a wholly different
loop nest.
Integer Domain
--------------
Expressions
-----------
......@@ -17,17 +26,40 @@ Expressions
* `reductions`
* duplication of reduction inames
* complex-valued arithmetic
* tagging of array access and substitution rule use ("$")
Assignments and Substitution Rules
----------------------------------
Inames
------
Syntax of an instruction::
Loops are (by default) entered exactly once. This is necessary to preserve
depdency semantics--otherwise e.g. a fetch could happen inside one loop nest,
and then the instruction using that fetch could be inside a wholly different
loop nest.
label: [i,j|k,l] <float32> lhs[i,j,k] = EXPRESSION : dep_label, dep_label_2
The above example illustrates all the parts that are allowed in loo.py's
instruction syntax. All of these except for `lhs` and `EXPRESSION` are
optional.
* `label` is a unique identifier for this instruction, enabling you to
refer back to the instruction uniquely during further transformation
as well as specifying ordering dependencies.
* `dep_label,dep_label_2` are dependencies of the current instruction.
Loo.py will enforce that the instructions marked with these labels
are scheduled before this instruction.
* `<float32>` declares `lhs` as a temporary variable, with shape given
by the ranges of the `lhs` subscripts. (Note that in this case, the
`lhs` subscripts must be pure inames, not expressions, for now.)
* `[i,j|k,l]` specifies the inames within which this instruction is run.
Independent copies of the inames `k` and `l` will be made for this
instruction.
Syntax of an substitution rule::
rule_name(arg1, arg2) := EXPRESSION
.. _tags:
Tags
----
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment