Stash debug symbols for build results
v2 cover Stash debug symbols for build results
These are handy when debugging stack traces etc.
The resulting xen-syms.gz is ~1M and the resulting vmlinux.gz is ~13M on ARM. I assume x86 will be ballpark similar...
Ian.
PATCH v2 1/3 ts-kernel-build: Enable CONFIG_DEBUG_INFO_REDUCED
This makes the resulting vmlinux file with debug symbols much more manageable without compromising the usefulness for converting addresses into line numbers etc.
--- ts-kernel-build | 1 + 1 file changed, 1 insertion(+)
ts-kernel-build +1 -0
@@ -208,6 +208,7 @@ setopt CONFIG_VIDEO n setopt CONFIG_BOOTSPLASH n setopt CONFIG_DEBUG_INFO y +setopt CONFIG_DEBUG_INFO_REDUCED y setopt CONFIG_XEN_KBDDEV_FRONTEND y
Signature · 1 line
1.7.10.4
PATCH v2 2/3 TestSupport: Add interface to compress stash files
In reply to Ian CampbellUse it in ts-logs-capture
--- Osstest/TestSupport.pm | 8 +++++++- ts-logs-capture | 5 +---- 2 files changed, 8 insertions(+), 5 deletions(-)
Osstest/TestSupport.pm +7 -1
@@ -66,7 +66,7 @@ BEGIN { serial_fetch_logs propname_massage - get_stashed open_unique_stashfile + get_stashed open_unique_stashfile compress_stashed dir_identify_vcs build_clone built_stash hg_dir_revision git_dir_revision vcs_dir_revision store_revision store_vcs_revision
@@ -843,6 +843,12 @@ sub get_stashed ($$) { return "$c{Stash}/$oflight/$ojob/$path"; } +sub compress_stashed($) { + my ($path) = @_; + my $r= system 'gzip','-9vf','--',"$stash/$path"; + die "$r $!" if $r; +} + #---------- other stuff ---------- sub host_reboot ($) {
ts-logs-capture +1 -4
@@ -61,10 +61,7 @@ END target_getfile_root($lho,60, $logfile,"$stash/$llogfile"); if ($logfile !~ m/\.gz$/) { stat("$stash/$llogfile") or die "$stash/$llogfile $!"; - if ((stat _)[7] > 100000) { - my $r= system 'gzip','-9vf','--',"$stash/$llogfile"; - die "$r $!" if $r; - } + compress_stashed($llogfile) if(stat _)[7] > 100000; } 1; }) {
Signature · 1 line
1.7.10.4
PATCH v2 3/3 Stash debug symbols for build results
In reply to Ian CampbellSpecifically xen-syms (<1M compressed) and the vmlinux (~13M compressed) files.
--- Osstest/TestSupport.pm | 18 +++++++++++++++++- ts-kernel-build | 2 ++ ts-xen-build | 2 ++ 3 files changed, 21 insertions(+), 1 deletion(-)
Osstest/TestSupport.pm +17 -1
@@ -67,7 +67,8 @@ BEGIN { propname_massage get_stashed open_unique_stashfile compress_stashed - dir_identify_vcs build_clone built_stash + dir_identify_vcs build_clone built_stash built_stash_file + built_compress_stashed hg_dir_revision git_dir_revision vcs_dir_revision store_revision store_vcs_revision
@@ -1050,6 +1051,21 @@ END store_runvar("path_$item", $stashleaf); } +sub built_stash_file ($$$$) { + my ($ho, $builddir, $item, $fname) = @_; + my $build= "build"; + my $stashleaf= "$build/$item"; + ensuredir("$stash/$build"); + target_getfile($ho, 300, + "$builddir/$fname", + "$stash/$stashleaf"); +} + +sub built_compress_stashed($) { + my ($path) = @_; + compress_stashed("build/$path"); +} + sub vcs_dir_revision ($$$) { my ($ho,$builddir,$vcs) = @_; no strict qw(refs);
ts-kernel-build +2 -0
@@ -322,3 +322,5 @@ if ($r{tree_linuxfirmware}) { fwinstall(); } built_stash($ho, $builddir, 'dist', 'kerndist'); +built_stash_file($ho, $builddir, 'vmlinux', 'linux/vmlinux'); +built_compress_stashed('vmlinux');
ts-xen-build +2 -0
@@ -198,6 +198,8 @@ sub stash () { "xen-unstable/dist/${part}install", "${part}dist"); } + built_stash_file($ho, $builddir, "xen-syms", "xen-unstable/xen/xen-syms"); + built_compress_stashed("xen-syms"); } sub checkversions () {
Signature · 1 line
1.7.10.4
Ian Campbell writes ("[PATCH OSSTEST 0/3 v2] Stash debug symbols for build results"):
Quoted 4 lines
These are handy when debugging stack traces etc.
The resulting xen-syms.gz is ~1M and the resulting vmlinux.gz is ~13M on ARM. I assume x86 will be ballpark similar...
All three:
I think this and the other stuff can safely be rebased on top of current "pretest" (ie staging) and pushed right away. Would you like to do that ?
Ian.
Quoted 6 lines · Ian Jackson
Ian Campbell writes ("[PATCH OSSTEST 0/3 v2] Stash debug symbols for build results"):
Quoted 4 lines
These are handy when debugging stack traces etc.
The resulting xen-syms.gz is ~1M and the resulting vmlinux.gz is ~13M on ARM. I assume x86 will be ballpark similar...
Quoted 6 lines
All three:
Acked-by Ian Jackson <[email protected]>I think this and the other stuff can safely be rebased on top of current "pretest" (ie staging) and pushed right away. Would you like to do that ?
Sure. I'll look at it some time this evening hopefully.
Ian.
Quoted 6 lines · Ian Jackson
Ian Campbell writes ("[PATCH OSSTEST 0/3 v2] Stash debug symbols for build results"):
Quoted 4 lines
These are handy when debugging stack traces etc.
The resulting xen-syms.gz is ~1M and the resulting vmlinux.gz is ~13M on ARM. I assume x86 will be ballpark similar...
Quoted 6 lines
All three:
Acked-by Ian Jackson <[email protected]>I think this and the other stuff can safely be rebased on top of current "pretest" (ie staging) and pushed right away. Would you like to do that ?
Done. Pushed these:
$ git log --oneline a949ddb..79b27b7 79b27b7 PDU/xenuse: Support xenuse on machine not locked by current user 84be2dc Stash debug symbols for build results 9791747 TestSupport: Add interface to compress stash files f1eace5 ts-kernel-build: Enable CONFIG_DEBUG_INFO_REDUCED 768a930 Debian: Allow per-host additional u-boot script commands f6a55e3 arm boot fixes and improvements