Dynamic Application Image With Trampoline Pointers for Fast System Calls
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing solutions for running applications on electronic devices suffer from low efficiency and fail to meet real-time performance requirements, particularly in embedded systems, where limited system resources and potential kernel attacks compromise reliability.
Innovation Solution
The method involves generating a dynamic image of an application with a trampoline function pointer segment that directly accesses kernel or common code library interfaces, utilizing a user and kernel mode combination to mitigate attacks, and optimizing the image by removing symbol tables to reduce resource overhead.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If traditional application running methods are used, then the application can execute with full functionality, but the running efficiency is low and real-time performance requirements cannot be met
Solution Approach 1:
The patent segments the application image into multiple parts: code segment, data segment, and trampoline function pointer segment. This segmentation allows the application to directly access critical system functions through the trampoline function pointer segment without going through traditional symbol table resolution, thereby improving running efficiency and reducing system function call time.
Solution Approach 2:
The patent pre-generates the dynamic image with the trampoline function pointer segment during the compilation phase. The trampoline function pointers are预先 configured to directly point to kernel or common code library interfaces, eliminating the need for runtime symbol resolution and reducing system function call time.
2Quantity of substance
If the complete dynamic image including symbol table is used, then all application functions are available, but the memory space occupation is large and system resource overhead is high
Solution Approach 1:
The patent extracts and removes the symbol table from the traditional dynamic image structure. By taking out the symbol table which occupies most memory space, the patent significantly reduces the memory footprint of the application while maintaining full functionality through the trampoline function pointer mechanism.
Solution Approach 2:
The patent replaces the large, permanent symbol table with compact trampoline function pointers that are generated once during compilation. This substitution uses much less memory space while achieving the same function of accessing system interfaces, effectively reducing system resource overhead.
3Productivity
If direct kernel mode access is implemented, then the running efficiency is improved, but the system becomes more vulnerable to kernel attacks and reliability decreases
Solution Approach 1:
The patent introduces the trampoline function pointer segment as an intermediary layer between the application and the kernel. This intermediary enables efficient direct access to kernel interfaces while maintaining a clear boundary that isolates the application from direct kernel mode vulnerabilities, thereby preserving both running efficiency and kernel attack resistance.
Solution Approach 2:
The patent implements different access modes for different parts of the system. The trampoline function pointer segment operates in user mode with direct addressing capability for efficiency, while the kernel interfaces remain protected in kernel mode. This local differentiation allows the system to achieve high performance where needed while maintaining security where required.
Data Source
AI summary
A program running method and a device are described for improving efficiency of running an application. The method includes obtaining a dynamic image of an application, where the dynamic image includes a trampoline function pointer segment, the trampoline function pointer segment includes at least one trampoline function pointer, the at least one trampoline function pointer corresponds to at least one interface, and the at least one interface includes an interface of a kernel or an interface of a common code library The method also includes calling the interface of the kernel or the interface of the common code library based on the trampoline function pointer segment, to run the application.


