Skip to content

Commit 22663ed

Browse files
committed
Documentation whitespace changes
1 parent a8ba868 commit 22663ed

File tree

1 file changed

+16
-15
lines changed

1 file changed

+16
-15
lines changed

doc/manual/performance-tips.rst

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -471,7 +471,7 @@ with
471471
end
472472
y
473473
end
474-
474+
475475
Timing results::
476476

477477
julia> @time loopinc()
@@ -546,8 +546,8 @@ properties.
546546
Be certain before doing this. If the subscripts are ever out of bounds,
547547
you may suffer crashes or silent corruption.
548548
- Write ``@simd`` in front of ``for`` loops that are amenable to vectorization.
549-
**This feature is experimental** and could change or disappear in future
550-
versions of Julia.
549+
**This feature is experimental** and could change or disappear in future
550+
versions of Julia.
551551

552552
Here is an example with both forms of markup::
553553

@@ -566,7 +566,7 @@ Here is an example with both forms of markup::
566566
end
567567
s
568568
end
569-
569+
570570
function timeit( n, reps )
571571
x = rand(Float32,n)
572572
y = rand(Float32,n)
@@ -599,26 +599,27 @@ properties of the loop:
599599
possibly causing different results than without ``@simd``.
600600
- No iteration ever waits on another iteration to make forward progress.
601601

602-
A loop containing ``break``, ``continue``, or ``goto`` will cause a
602+
A loop containing ``break``, ``continue``, or ``goto`` will cause a
603603
compile-time error.
604604

605-
Using ``@simd`` merely gives the compiler license to vectorize. Whether
606-
it actually does so depends on the compiler. To actually benefit from the
607-
current implementation, your loop should have the following additional
605+
Using ``@simd`` merely gives the compiler license to vectorize. Whether
606+
it actually does so depends on the compiler. To actually benefit from the
607+
current implementation, your loop should have the following additional
608608
properties:
609609

610610
- The loop must be an innermost loop.
611-
- The loop body must be straight-line code. This is why ``@inbounds`` is
611+
- The loop body must be straight-line code. This is why ``@inbounds`` is
612612
currently needed for all array accesses. The compiler can sometimes turn
613-
short ``&&``, ``||``, and ``?:`` expressions into straight-line code,
614-
if it is safe to evaluate all operands unconditionally. Consider using
613+
short ``&&``, ``||``, and ``?:`` expressions into straight-line code,
614+
if it is safe to evaluate all operands unconditionally. Consider using
615615
``ifelse`` instead of ``?:`` in the loop if it is safe to do so.
616-
- Accesses must have a stride pattern and cannot be "gathers" (random-index reads)
616+
- Accesses must have a stride pattern and cannot be "gathers" (random-index reads)
617617
or "scatters" (random-index writes).
618618
- The stride should be unit stride.
619-
- In some simple cases, for example with 2-3 arrays accessed in a loop, the
620-
LLVM auto-vectorization may kick in automatically, leading to no further
621-
speedup with ``@simd``.
619+
- In some simple cases, for example with 2-3 arrays accessed in a loop, the
620+
LLVM auto-vectorization may kick in automatically, leading to no further
621+
speedup with ``@simd``.
622+
622623
.. raw:: html
623624
<style> .red {color:red} </style>
624625

0 commit comments

Comments
 (0)