mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Upgrade Pybind submodule to 2.10.4 (#103989)
This is not ready for review, this is to make sure asan is fixed.
Not sure what is the most effective way to track down the bad dec_ref within deploy yet.
The asan silencing is done to match this comment:
1c79003b3c/test/test_cpp_extensions_jit.py (L749-L752)
EDIT: since the final failing function is in libtorch_python.so, we would need to skip that whole lib (not ok). So now we're skipping based on the function name which should be restrictive enough to not hide any real bug.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/103989
Approved by: https://github.com/malfet
This commit is contained in:
@ -140,7 +140,7 @@ fi
|
|||||||
# ASAN test is not working
|
# ASAN test is not working
|
||||||
if [[ "$BUILD_ENVIRONMENT" == *asan* ]]; then
|
if [[ "$BUILD_ENVIRONMENT" == *asan* ]]; then
|
||||||
export ASAN_OPTIONS=detect_leaks=0:symbolize=1:detect_stack_use_after_return=true:strict_init_order=true:detect_odr_violation=1:detect_container_overflow=0:check_initialization_order=true:debug=true
|
export ASAN_OPTIONS=detect_leaks=0:symbolize=1:detect_stack_use_after_return=true:strict_init_order=true:detect_odr_violation=1:detect_container_overflow=0:check_initialization_order=true:debug=true
|
||||||
export UBSAN_OPTIONS=print_stacktrace=1
|
export UBSAN_OPTIONS=print_stacktrace=1:suppressions=$PWD/ubsan.supp
|
||||||
export PYTORCH_TEST_WITH_ASAN=1
|
export PYTORCH_TEST_WITH_ASAN=1
|
||||||
export PYTORCH_TEST_WITH_UBSAN=1
|
export PYTORCH_TEST_WITH_UBSAN=1
|
||||||
# TODO: Figure out how to avoid hard-coding these paths
|
# TODO: Figure out how to avoid hard-coding these paths
|
||||||
|
2
third_party/pybind11
vendored
2
third_party/pybind11
vendored
Submodule third_party/pybind11 updated: 80dc998efc...5b0a6fc201
@ -141,6 +141,7 @@ PyRRef::PyRRef(const py::object& value, const py::object& type_hint)
|
|||||||
|
|
||||||
PyRRef::~PyRRef() {
|
PyRRef::~PyRRef() {
|
||||||
if (type_.has_value()) {
|
if (type_.has_value()) {
|
||||||
|
pybind11::gil_scoped_acquire ag;
|
||||||
(*type_).dec_ref();
|
(*type_).dec_ref();
|
||||||
// explicitly setting PyObject* to nullptr to prevent py::object's dtor to
|
// explicitly setting PyObject* to nullptr to prevent py::object's dtor to
|
||||||
// decref on the PyObject again.
|
// decref on the PyObject again.
|
||||||
|
1
ubsan.supp
Normal file
1
ubsan.supp
Normal file
@ -0,0 +1 @@
|
|||||||
|
vptr:pybind11::detail::translate_exception
|
Reference in New Issue
Block a user