Skip to content

Commit 0e4f9a3

Browse files
committed
fix build error
1 parent 8654659 commit 0e4f9a3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

aten/src/ATen/Context.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -701,10 +701,10 @@ struct Fp32PrecisonGuard {
701701
if (new_precision == Float32Precision::NONE) {
702702
return ;
703703
}
704-
saved_precision = float32Precision(target_backend, target_op);
704+
saved_precision = globalContext().float32Precision(target_backend, target_op);
705705
changed = (new_precision == saved_precision);
706706
if (changed) {
707-
setFloat32Precision(target_backend, target_op, new_precision);
707+
globalContext().setFloat32Precision(target_backend, target_op, new_precision);
708708
}
709709
}
710710
Fp32PrecisonGuard(Fp32PrecisonGuard&& other) = delete;
@@ -713,7 +713,7 @@ struct Fp32PrecisonGuard {
713713
Fp32PrecisonGuard& operator=(Fp32PrecisonGuard&&) = delete;
714714
~Fp32PrecisonGuard() {
715715
if (changed) {
716-
setFloat32Precision(target_backend, target_op, saved_precision);
716+
globalContext().setFloat32Precision(target_backend, target_op, saved_precision);
717717
}
718718
}
719719
private:

0 commit comments

Comments
 (0)