Skip to content

Commit 8e09f9c

Browse files
authored
Removing reference to /Oa
The `/Oa` switch hasn't been in the compiler for more than a decade (nearly two decades). This reference to /Oa is, i believe, the only reference to this long gone switch; i believe referencing /Oa in this context is actually more harmful then helpful.
1 parent 851212c commit 8e09f9c

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

docs/build/optimization-best-practices.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,6 @@ A pointer that is modified with **`__restrict`** is referred to as a *__restrict
9494
9595
**`__restrict`** can be a powerful tool for the Microsoft C++ optimizer, but use it with great care. If used improperly, the optimizer might perform an optimization that would break your application.
9696
97-
The **`__restrict`** keyword replaces the **/Oa** switch from previous versions.
98-
9997
With **`__assume`**, a developer can tell the compiler to make assumptions about the value of some variable.
10098
10199
For example `__assume(a < 5);` tells the optimizer that at that line of code the variable `a` is less than 5. Again this is a promise to the compiler. If `a` is actually 6 at this point in the program then the behavior of the program after the compiler has optimized may not be what you would expect. **`__assume`** is most useful prior to switch statements and/or conditional expressions.

0 commit comments

Comments
 (0)