summaryrefslogtreecommitdiff
path: root/tools/stacktrace_resolve.awk
blob: 1b4742d7e38292e80a31b8a55e1b14ec8e218a34 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/k\/[0-9A-Fa-f]{8}/ {
	print;
	while (match($0, /k\/[0-9A-Fa-f]{8}/)) {
		addr = substr($0, RSTART + 2, RLENGTH - 2);
		if (addr != "00000000") {
			printf "    ";
			system("addr2line -psfe out/fs/boot/kernel.bin 0x" addr);
		}
		$0 = substr($0, RSTART + RLENGTH);
	}
	next;
}

{ print; }