Add more Python-related leak suppressions.#6370
Conversation
|
CI MESSAGE: [52651772]: BUILD STARTED |
|
| Filename | Overview |
|---|---|
| qa/leak.sup | Adds Python 3.12 leak suppressions (Python runtime, compiler toolchain, system binaries), removes specific PyObject_GC entries superseded by the new wildcard, and adds a trailing newline. All previous review issues (xargs typo, redundant GC entries) are addressed. |
| qa/test_template_impl.sh | Reorders enable_sanitizer() so Python helper invocations (nvjpeg2k/nvtiff/nvimgcodec path discovery) run before ASAN_OPTIONS is updated, preventing ASAN from intercepting those helper processes. Also changes start_deactivated from true to false so ASAN is fully active during actual test execution, and adds dependency library paths for nvjpeg2k and nvtiff. |
| qa/TL0_cpu_only/test_nofw.sh | Expands LD_LIBRARY_PATH to include nvjpeg2k and nvtiff library directories as prerequisites for nvimgcodec, now appending to existing LD_LIBRARY_PATH instead of replacing it. |
| qa/TL0_cpu_only/test_pytorch.sh | Same LD_LIBRARY_PATH expansion as test_nofw.sh: adds nvjpeg2k and nvtiff lib paths before nvimgcodec, appending to the existing variable rather than overwriting it. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[test_body_wrapper called] --> B{DALI_ENABLE_SANITIZERS set?}
B -- No --> C[run test_body normally]
B -- Yes --> D[enable_sanitizer]
D --> D1[export PYTHONMALLOC=malloc]
D1 --> D2[build libfakeclose.so]
D2 --> D3[set LD_PRELOAD with libasan]
D3 --> D4["Python: discover nvjpeg2k path\nASAN_OPTIONS still = start_deactivated=true"]
D4 --> D5["Python: discover nvtiff path\n(ASAN deactivated)"]
D5 --> D6["Python: discover nvimgcodec path\n(ASAN deactivated)"]
D6 --> D7["set ASAN_OPTIONS\nstart_deactivated=false, detect_leaks=1\nsuppressions=address.sup"]
D7 --> D8[set ASAN_SYMBOLIZER_PATH]
D8 --> E[run test_body]
E --> F[disable_sanitizer]
F --> G[process_sanitizers_logs]
G --> H{ERROR in log?}
H -- Yes --> I[exit 1]
H -- No --> J[continue]
Reviews (12): Last reviewed commit: "More leaks suppresed" | Re-trigger Greptile
| export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:"$(python -c 'import nvidia.nvjpeg2k as n, os; print(os.path.dirname(n.__file__) + "/lib")' 2>/dev/null)" | ||
| export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:"$(python -c 'import nvidia.nvtiff as n, os; print(os.path.dirname(n.__file__) + "/lib")' 2>/dev/null)" | ||
| export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:"$(python -c 'import nvidia.nvimgcodec as n, os; print(os.path.dirname(n.__file__))' 2>/dev/null)" |
There was a problem hiding this comment.
[Nit] The two new lines in
enable_sanitizer() use 2>/dev/null without || echo '', while the equivalent lines in test_nofw.sh and test_pytorch.sh use 2>/dev/null || echo ''. Both produce an empty string on failure, so the behaviour is identical, but the inconsistency may surprise a future reader. Consider aligning the style.
Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
|
CI MESSAGE: [52651772]: BUILD FAILED |
|
CI MESSAGE: [52687092]: BUILD STARTED |
|
CI MESSAGE: [52701305]: BUILD FAILED |
|
CI MESSAGE: [52702362]: BUILD STARTED |
|
CI MESSAGE: [52752780]: BUILD STARTED |
|
CI MESSAGE: [52702362]: BUILD FAILED |
- After moving to Python 3.12 for the sanitized build, new false positives have started appearing. This requires adding additional suppression entries and modifies sanitizer options. Signed-off-by: Janusz Lisiecki <jlisiecki@nvidia.com>
|
CI MESSAGE: [52760946]: BUILD STARTED |
|
CI MESSAGE: [52687092]: BUILD FAILED |
|
CI MESSAGE: [52760946]: BUILD FAILED |
|
CI MESSAGE: [52953311]: BUILD STARTED |
|
CI MESSAGE: [52953745]: BUILD STARTED |
|
CI MESSAGE: [52953745]: BUILD FAILED |
Signed-off-by: Janusz Lisiecki <jlisiecki@nvidia.com>
|
CI MESSAGE: [53052736]: BUILD FAILED |
|
CI MESSAGE: [53053372]: BUILD STARTED |
|
CI MESSAGE: [53053372]: BUILD FAILED |
Signed-off-by: Janusz Lisiecki <jlisiecki@nvidia.com>
|
CI MESSAGE: [53173151]: BUILD STARTED |
|
CI MESSAGE: [53173151]: BUILD FAILED |
|
CI MESSAGE: [53258917]: BUILD STARTED |
| leak:/usr/bin/sort | ||
| leak:/usr/bin/tr | ||
| leak:/usr/bin/fc-list | ||
| leak:/usr/bin/xarg |
There was a problem hiding this comment.
[Bug] Typo in suppression path:
/usr/bin/xarg does not exist on Linux — the tool is /usr/bin/xargs. Because the path never matches any frame, this suppression is silently inert. If xargs genuinely produces a false-positive leak report in CI, the test will continue to fail despite this entry.
| leak:/usr/bin/xarg | |
| leak:/usr/bin/xargs |
Signed-off-by: Janusz Lisiecki <jlisiecki@nvidia.com>
|
CI MESSAGE: [53260113]: BUILD STARTED |
|
CI MESSAGE: [53260113]: BUILD PASSED |
new false positives have started appearing. This requires
adding additional suppression entries and modifies sanitizer
options.
Category:
Other (e.g. Documentation, Tests, Configuration)
Description:
new false positives have started appearing. This requires
adding additional suppression entries.
Additional information:
Affected modules and functionalities:
Key points relevant for the review:
Tests:
Checklist
Documentation
DALI team only
Requirements
REQ IDs: N/A
JIRA TASK: N/A