Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions tests/ui/autodiff/no_lto_flag.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
//@ needs-enzyme
//@ no-prefer-dynamic
//@ revisions: with_lto no_lto
rollup-ktha5ha
//@[with_lto] compile-flags: -Zautodiff=Enable -C opt-level=3 -Clto=fat
=======
//@[with_lto] compile-flags: -Zautodiff=Enable -C opt-level=3 -Clto=fat
main
//@[no_lto] compile-flags: -Zautodiff=Enable -C opt-level=3 -Clto=thin

#![feature(autodiff)]
Expand All @@ -10,7 +14,11 @@

// Autodiff requires users to enable lto=fat (for now).
// In the past, autodiff did not run if users forget to enable fat-lto, which caused functions to
rollup-ktha5ha
// return zero-derivatives. That's obviously wrong and confusing to users. We now added a check
=======
// returning zero-derivatives. That's obviously wrong and confusing to users. We now added a check
main
// which will abort compilation instead.

use std::autodiff::autodiff_reverse;
Expand Down
Loading