<div dir="ltr">i know when rob's talked about "toybox strace", he meant one with no decoding, just raw numbers. that doesn't really let me replace "real" strace though (which was already a PITA to update, and switched to GPL a year or two back anyway). the hope here is to show that we can actually decode without being _too_ large/complicated...<div><br></div><div>the TODO about cases where glibc doesn't use the same structs as the kernel points to one of the hairiest issues, plus this would be the first toy where we actually need to add a few lines of code for *every* architecture that we want "allyesconfig" to build on. i haven't even added arm/arm64 yet! (but i will do so if this gets committed.)</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Sep 17, 2021 at 3:46 PM enh <<a href="mailto:enh@google.com">enh@google.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">This is most notably lacking -p and -f, and only covers a small subset<br>of system calls, but it's "useful" in the sense that you can strace<br>something like toybox date, say, and see everything.<br><br>There's a fundamental assumption here that we don't need to worry about<br>multiple personalities. (This is what makes "real" strace's build so<br>complex, and why Android has _never_ actually shipped a fully correct<br>strace build.) Given that the desktop's already been 64-bit only<br>for a while, microcontrollers are likely to stay 32-bit only for a<br>while, and the odd one out -- mobile -- is moving to be 64-bit only<br>(<a href="https://www.arm.com/blogs/blueprint/64-bit" target="_blank">https://www.arm.com/blogs/blueprint/64-bit</a>), so by the time this is<br>ready to graduate from pending, I'm assuming no-one will care!<br>---<br> lib/portability.h | 2 +<br> toys/pending/strace.c | 618 ++++++++++++++++++++++++++++++++++++++++++<br> 2 files changed, 620 insertions(+)<br> create mode 100644 toys/pending/strace.c<br></div>
</blockquote></div>