File tree Expand file tree Collapse file tree 1 file changed +11
-4
lines changed
src/doc/rustc/src/codegen-options Expand file tree Collapse file tree 1 file changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -212,15 +212,22 @@ with coverage tools other than those built and shipped with the compiler.
212212## jump-tables
213213
214214This option is used to allow or prevent the LLVM or GCC codegen backend from
215- creating jump tables when lowering switches.
215+ creating jump tables when lowering switches from Rust code .
216216
217217* ` y ` , ` yes ` , ` on ` , ` true ` or no value: allow jump tables (the default).
218218* ` n ` , ` no ` , ` off ` or ` false ` : disable jump tables.
219219
220+ To prevent jump tables being created from Rust code, a target must ensure
221+ all crates are compiled with jump tables disabled.
222+
223+ Note, in many cases the rust toolchain is distributed with precompiled
224+ crates which could possibly include jump tables. Furthermore, this option
225+ does not guarantee a target will be free of jump tables. They could arise
226+ from external dependencies, inline asm, or other complicated interactions
227+ when using crates which are compiled with jump table support.
228+
220229Disabling jump tables can be used to help provide protection against
221- jump-oriented-programming (JOP) attacks. However, this option makes
222- no guarantee any precompiled or external dependencies are compiled
223- with or without jump tables.
230+ jump-oriented-programming (JOP) attacks.
224231
225232## link-arg
226233
You can’t perform that action at this time.
0 commit comments