fshahinfar1 / kashk

Generate BPF kernel offload from source code of applications
1 stars 0 forks source link

In BPF Generated file order in which functions are declared can be wrong #4

Closed fshahinfar1 closed 3 months ago

fshahinfar1 commented 8 months ago

In the generated BPF code, a function may depend on another function which is declared after it. This is not a valid C code.

fshahinfar1 commented 7 months ago

I try to track the function dependency and sort function declaration according to this. There might be issue when there are circular dependencies.

fshahinfar1 commented 5 months ago

I tried to do a topological sort, will fail when there is circular dependency among functions

fshahinfar1 commented 3 months ago

I think it is good enough for now.