allow windows-gnu targets to embed gdb visualizer scripts#154840
allow windows-gnu targets to embed gdb visualizer scripts#154840rust-bors[bot] merged 1 commit intorust-lang:mainfrom
windows-gnu targets to embed gdb visualizer scripts#154840Conversation
|
These commits modify compiler targets. |
|
r? @chenyukang rustbot has assigned @chenyukang. Use Why was this reviewer chosen?The reviewer was selected based on:
|
|
IIRC this was because it requires GDB with Python support, which was not that common back in the day. Considering that https://github.com/niXman/mingw-builds-binaries now provides Python3 this is probably fine. I'll test it next week, r? @mati865 |
|
@bors try jobs=dist-x86_64-llvm-mingw,dist-x86_64-mingw |
This comment has been minimized.
This comment has been minimized.
allow `windows-gnu` targets to embed gdb visualizer scripts try-job: dist-x86_64-llvm-mingw try-job: dist-x86_64-mingw
|
How did you test that? LLD discards this section, so building for Then testing with windows-gnu and the default ld.bfd linker, and regular GDB binary there is a warning about missing scripts: It appears to load fine when using rust-gdb which is non-trivial on this target and requires specifying exact path: So, there is a benefit from this change, but only when doing additional setup, otherwise this results in a warning each time you start the debugger. @rustbot author |
|
Reminder, once the PR becomes ready for a review, use |
Yeah, that's definitely weird. I dont know enough about linkers to know why it's happening.
As I understand it, since these are arbitrary python scripts being run automatically, there's a huge security risk. That means all auto-load scripts are opt-in, even when they're embedded. The rust-distributed scripts are embedded via a reference to the script file's location, rather than embedding the full script source code (which is what happens via
Without this change, the only way to use the rust visualizers is While there is friction even with the change, i dont think it's a huge deal. I havent gotten to look at the debug info survey results, but i'd hazard a guess and say that the population that uses GDB on windows is absolutely minuscule. Anyone that's doing it is jumping through hoops to use gdb anyway, so they'll probably be more tolerant of a few bumps. |
|
@rustbot ready |
I guess this section is not marked as excluded from GC in MinGW/COFF backend, but I haven't tested it. Thanks for the explanation, I have tested it on Linux and it behaves the same way.
FWIW, without this change even using @bors r+ rollup |
This comment has been minimized.
This comment has been minimized.
What is this?This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.Comparing dab8d9d (parent) -> 14196db (this PR) Test differencesShow 2 test diffs2 doctest diffs were found. These are ignored, as they are noisy. Test dashboardRun cargo run --manifest-path src/ci/citool/Cargo.toml -- \
test-dashboard 14196dbfa3eb7c30195251eac092b1b86c8a2d84 --output-dir test-dashboardAnd then open Job duration changes
How to interpret the job duration changes?Job durations can vary a lot, based on the actual runner instance |
|
Finished benchmarking commit (14196db): comparison URL. Overall result: ❌ regressions - no action needed@rustbot label: -perf-regression Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (secondary 2.9%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary 2.2%, secondary -20.5%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeResults (secondary 0.1%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Bootstrap: 489.963s -> 491.114s (0.23%) |
|
Could this be the cause of #155277? It's a PR that vaguely matches the symptoms we see and I think it's part of the right nightly range. |
|
Yeah, we will have to revert this PR. |
…tdev Revert "allow `windows-gnu` targets to embed gdb visualizer scripts" Fixes rust-lang#155277 This reverts commit 472b966. This was merged as rust-lang#154840, but causes linker errors in the wild. cc @Walnut356 @mati865 r? @ghost
Pretty straigthforward, works exactly the same as any other
*-gnutarget so i'm not sure why it wasn't enabled already.