mirror of
https://github.com/varun-r-mallya/Python-BPF.git
synced 2025-12-31 21:06:25 +00:00
fix structure for IR generation separation.
This commit is contained in:
@ -2,6 +2,8 @@ import ast
|
||||
import logging
|
||||
from functools import lru_cache
|
||||
import importlib
|
||||
from .dependency_handler import DependencyHandler
|
||||
from .dependency_node import DependencyNode
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
@ -10,6 +12,12 @@ def get_module_symbols(module_name: str):
|
||||
module = importlib.import_module(module_name)
|
||||
return [name for name in dir(module)]
|
||||
|
||||
def process_vmlinux_class(node, module, num=0):
|
||||
def process_vmlinux_class(node, module, handler: DependencyHandler, parent=""):
|
||||
symbols_in_module = get_module_symbols("vmlinux")
|
||||
current_symbol_name = node.name
|
||||
if current_symbol_name not in symbols_in_module:
|
||||
raise ImportError(f"{current_symbol_name} not present in module vmlinux")
|
||||
logger.info(f"Resolving vmlinux class {current_symbol_name}")
|
||||
# Now we find fields present in current class
|
||||
pass
|
||||
|
||||
|
||||
Reference in New Issue
Block a user