|
|
Subscribe / Log in / New account

The Compact C Type Format in the GNU toolchain

The Compact C Type Format in the GNU toolchain

Posted Aug 6, 2019 21:38 UTC (Tue) by dw (subscriber, #12017)
Parent article: The Compact C Type Format in the GNU toolchain

Can anyone explain the relationship between this work and the (AFAIK still presently ongoing) work to add BTF support to the kernel? It seems they duplicate each other. As I understand it, in FreeBSD and Solaris CTF serves both roles that we appear to be ending up with two very similar syntaxes for in Linux, depending on whether you are inspecting userspace or the kernel.


to post comments

The Compact C Type Format in the GNU toolchain

Posted Aug 7, 2019 0:13 UTC (Wed) by nix (subscriber, #2304) [Link]

I don't think they are really duplicates. BTF is describing the BPF type system: maps maps maps. CTF is describing the C type system: it can already handle floats, for instance, and things like 'restrict', and I am definitely going to add everything in GNU C, including things like vector and fixed-point types.

(And, honestly, I see no reason why we can't translate one into the other anyway. If BTF can be translated from DWARF, I'm sure I can write a CTF->BTF translator :) ).


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds