Skip to content

Commit d9e80ec

Browse files
authored
Update autovectorization-limits.md
1 parent 36ed824 commit d9e80ec

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

content/learning-paths/cross-platform/loop-reflowing/autovectorization-limits.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ for (size_t i=0; i < N; i++) {
2222
}
2323
```
2424

25-
This loop is not countable and cannot be vectorized:
25+
But this loop is not countable and cannot be vectorized:
2626

2727
```C
2828
i = 0;
@@ -46,7 +46,7 @@ while(1) {
4646
}
4747
```
4848

49-
This loop is not vectorizable:
49+
But this loop is not vectorizable:
5050

5151
```C
5252
i = 0;
@@ -59,7 +59,7 @@ while(1) {
5959

6060
#### No function calls inside the loop
6161

62-
If `f()` and `g()` are functions that take `float` arguments this loop cannot be autovectorized:
62+
If `f()` and `g()` are functions that take `float` arguments, the loop cannot be autovectorized:
6363

6464
```C
6565
for (size_t i=0; i < N; i++) {
@@ -69,7 +69,7 @@ for (size_t i=0; i < N; i++) {
6969

7070
There is a special case with the math library trigonometry and transcendental functions (like `sin`, `cos`, `exp`, etc). There is work underway to enable these functions to be autovectorized, as the compiler will use their vectorized counterparts in the `mathvec` library (`libmvec`).
7171

72-
The loop below is *already autovectorized* in current gcc trunk for Arm (note you have to add `-Ofast` to the compilation flags to enable autovectorization):
72+
The loop below is *already autovectorized* in current gcc trunk for Arm (note, you have to add `-Ofast` to the compilation flags to enable autovectorization):
7373

7474
```C
7575
void addfunc(float *restrict C, float *A, float *B, size_t N) {

0 commit comments

Comments
 (0)