-
Notifications
You must be signed in to change notification settings - Fork 0
Fix resource leak #10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
WalkthroughAdds explicit GPU window binding release calls in two cleanup locations within main.cpp—after graphics pipeline release in both the main loop and quit function. These changes establish proper resource cleanup sequencing for GPU window bindings. Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~5 minutes
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (20)
🔇 Additional comments (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Here's the code health analysis summary for commits Analysis Summary
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
main.cpp(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (20)
- GitHub Check: build (windows-latest, Release, cl)
- GitHub Check: build (windows-latest, Release, gcc)
- GitHub Check: build (windows-latest, Debug, cl)
- GitHub Check: build (windows-latest, Debug, gcc)
- GitHub Check: build (windows-latest, Debug, clang)
- GitHub Check: build (Release, gcc)
- GitHub Check: build (windows-latest, Release, clang)
- GitHub Check: build (Release, clang)
- GitHub Check: build (Debug, clang)
- GitHub Check: build (Debug, gcc)
- GitHub Check: build (Debug, gcc)
- GitHub Check: build (Release, gcc)
- GitHub Check: build (Release, clang)
- GitHub Check: build (Debug, clang)
- GitHub Check: build (windows-latest, Release, cl)
- GitHub Check: build (windows-latest, Release, clang)
- GitHub Check: build (windows-latest, Debug, gcc)
- GitHub Check: build (windows-latest, Debug, cl)
- GitHub Check: build (windows-latest, Debug, clang)
- GitHub Check: build (windows-latest, Release, gcc)
🔇 Additional comments (1)
main.cpp (1)
364-364: AI summary inconsistency: Only one reset call added, not two.The AI summary states that
gpu_wrapper.reset()is added at two cleanup points (in the main loop and in quit), but only one addition is visible in the code at line 364 in thequit()function. There is no marked addition in theiterate()function (the main loop).
* feat: add class PileLineWrapper * feat: add pipe line wrapper to User App * refactor: rename class * feat:code rabbit enable auto_apply_labels * fix: add check before release pipeline Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> * fix:handle SDL_CreateGPUGraphicsPipeline error * fix:call sdl init before app init * feat: add class gpu wrapper * style: format code with ClangFormat This commit fixes the style issues introduced in 46e77a7 according to the output from ClangFormat. Details: #7 * 📝 Add docstrings to `pipiline` (#8) * 📝 Add docstrings to `pipiline` Docstrings generation was requested by @WSQS. * #7 (comment) The following files were modified: * `main.cpp` * `sdl_wrapper/sdl_callback_implement.cpp` * style: format code with ClangFormat This commit fixes the style issues introduced in 49e577b according to the output from ClangFormat. Details: #8 --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com> * fix:change log * fix:cadd check for gpu wrapper * fix:using gpu wrapper in buffer wrapper * fix:rename variable * fix:change vertex buffer to value semantics * style: format code with ClangFormat This commit fixes the style issues introduced in 9cd5876 according to the output from ClangFormat. Details: #7 * fix: remote typo * break: split implement unit of module * style: format code with ClangFormat This commit fixes the style issues introduced in 9796426 according to the output from ClangFormat. Details: #7 * fix: add log for windows ci * fix: rename log name * fix: Add type * style: format code with ClangFormat This commit fixes the style issues introduced in f75fa22 according to the output from ClangFormat. Details: #7 * fix: Add module unit sdl_wrapper:decl * Fix resource leak (#10) * feat:release gpu before windows * feat:release window from gpu devices --------- Co-authored-by: Sophomore <sophomore@duck.com> * fix: remove todo, the destroy order is defined by shared_ptr * feat: add function create_buffer to GpuWrapper * style: format code with ClangFormat This commit fixes the style issues introduced in 60d5ebd according to the output from ClangFormat. Details: #7 * 📝 Add docstrings to `pipiline` (#9) * 📝 Add docstrings to `pipiline` Docstrings generation was requested by @WSQS. * #7 (comment) The following files were modified: * `main.cpp` * `sdl_wrapper/sdl_callback_implement.cpp` * `sdl_wrapper/sdl_wrapper.buffer.cpp` * style: format code with ClangFormat This commit fixes the style issues introduced in 32e7ade according to the output from ClangFormat. Details: #9 --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com> Co-authored-by: WSQS <17792626+WSQS@users.noreply.github.com> * Add workflow clang-tidy-review * fix:workflow set compiler * fix:install package for ubuntu * fix:add parameter * fix:add parameter * fix:add permission * fix:remove bom * fix:change command * Add workflow Gen pr (#16) * Add workflow * feat: Add permission * feat: change model * feat: add include file * feat: change key word * feat: set workflow in aider * feat: enable verbose * feat: enable verbose * feat: enable verbose * feat: remove bom --------- Co-authored-by: Sophomore <sophomore@duck.com> * feat: let gpu create pipeline * style: format code with ClangFormat This commit fixes the style issues introduced in db03e22 according to the output from ClangFormat. Details: #7 * Remove unused headfile Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * style: format code with ClangFormat This commit fixes the style issues introduced in 721f0ef according to the output from ClangFormat. Details: #7 * fix: change comment * fix: add header file * style: format code with ClangFormat This commit fixes the style issues introduced in d9851ce according to the output from ClangFormat. Details: #7 * fix: remove unused file. * 📝 Add docstrings to `pipiline` (#17) * 📝 Add docstrings to `pipiline` Docstrings generation was requested by @WSQS. * #7 (comment) The following files were modified: * `main.cpp` * `sdl_wrapper/sdl_wrapper.buffer.cpp` * `sdl_wrapper/sdl_wrapper.pipeline.cpp` * style: format code with ClangFormat This commit fixes the style issues introduced in c7383b5 according to the output from ClangFormat. Details: #17 --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com> * fix: from optional to value * feat: add compile command * feat:implement pipeline_wrapper * style: format code with ClangFormat This commit fixes the style issues introduced in b70c22e according to the output from ClangFormat. Details: #7 * fix: shader length error * fix: rename variable * fix: rename function * fix: change shader code * fix: avoid resource leak * fix: change primitive type * 📝 Add docstrings to `pipiline` (#19) * 📝 Add docstrings to `pipiline` Docstrings generation was requested by @WSQS. * #7 (comment) The following files were modified: * `main.cpp` * `sdl_wrapper/sdl_wrapper.buffer.cpp` * `sdl_wrapper/sdl_wrapper.pipeline.cpp` * style: format code with ClangFormat This commit fixes the style issues introduced in 66165a8 according to the output from ClangFormat. Details: #19 --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com> --------- Co-authored-by: Sophomore <sophomore@duck.com> Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Summary by CodeRabbit