-
Notifications
You must be signed in to change notification settings - Fork 432
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dynamic: Refactor logic to perform multiple updates #1702
Open
clementguidi
wants to merge
9
commits into
namhyung:master
Choose a base branch
from
clementguidi:dynamic-runtime-init
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Commits on Mar 11, 2024
-
dynamic: Load dynamic info only once
This is in preparation of runtime dynamic patching. This commit guarantees that dynamic info is read only once for the target binary and for each module. Co-authored-by: Gabriel-Andrew Pollo-Guilbert <gabrielpolloguilbert@gmail.com> Signed-off-by: Clément Guidi <cguidi@ciena.com> Signed-off-by: Seyed-Vahid Azhari <vazhari@ciena.com>
Configuration menu - View commit details
-
Copy full SHA for 62cefa1 - Browse repository at this point
Copy the full SHA 62cefa1View commit details -
dynamic: Initialize size filter only once
If 'mcount_dynamic_update' is called multiple times (e.g. at runtime), it initializes the size filter only once. Signed-off-by: Clément Guidi <cguidi@ciena.com>
Configuration menu - View commit details
-
Copy full SHA for 671829d - Browse repository at this point
Copy the full SHA 671829dView commit details -
dynamic: arch: Initialize disassembly engine once
Skip the initialization of the disassembly engine with it has already been performed. Signed-off-by: Clément Guidi <cguidi@ciena.com>
Configuration menu - View commit details
-
Copy full SHA for a4466df - Browse repository at this point
Copy the full SHA a4466dfView commit details -
dynamic: Archive pattern list after update
After patching, clear the pattern list for reuse. However, archive its content in a separate aggregated list. This list contains all applied patterns and is used applied again when when opening a dynamic library. Co-authored-by: Gabriel-Andrew Pollo-Guilbert <gabrielpolloguilbert@gmail.com> Signed-off-by: Clément Guidi <cguidi@ciena.com>
Configuration menu - View commit details
-
Copy full SHA for 1654b9c - Browse repository at this point
Copy the full SHA 1654b9cView commit details -
dynamic: Refactor 'mcount_dynamic_update'
The 'mcount_dynamic_update' is now safe to call multiple times, including at runtime. On each call, it will perform patching and unpatching of the target (not implemented yet). Signed-off-by: Clément Guidi <cguidi@ciena.com>
Configuration menu - View commit details
-
Copy full SHA for 3e5ae01 - Browse repository at this point
Copy the full SHA 3e5ae01View commit details -
dynamic: Streamline trampoline life cycle
Install a trampoline for each loaded module map, on initialization. Keep the trampolines in memory to allow for dynamic patching at runtime. Clear the trampolines on libmcount exit. Co-authored-by: Gabriel-Andrew Pollo-Guilbert <gabrielpolloguilbert@gmail.com> Signed-off-by: Clément Guidi <cguidi@ciena.com>
Configuration menu - View commit details
-
Copy full SHA for 3e89e6d - Browse repository at this point
Copy the full SHA 3e89e6dView commit details -
mcount: Use flag to indicate if target is running
Use a global flag to indicate the state of the target. When the target is not running, tasks such as dynamic patching can be performed with less constraints. If libmcount.so is dynamically injected (not implemented yet), the 'mcount_target_running' flag indicates that libmcount has to be initialized in a running target. Signed-off-by: Clément Guidi <cguidi@ciena.com>
Configuration menu - View commit details
-
Copy full SHA for 5a150da - Browse repository at this point
Copy the full SHA 5a150daView commit details -
dynamic: Init arch-specific structures
Trigger architecture specific dynamic initialization when initializing the dynamic instrumentation mechanics. Co-authored-by: Gabriel-Andrew Pollo-Guilbert <gabrielpolloguilbert@gmail.com> Signed-off-by: Clément Guidi <cguidi@ciena.com>
Configuration menu - View commit details
-
Copy full SHA for ad3cbf6 - Browse repository at this point
Copy the full SHA ad3cbf6View commit details -
dynamic: Save original instructions only once
Don't save instructions if they are already present in the code hmap. Signed-off-by: Clément Guidi <cguidi@ciena.com>
Configuration menu - View commit details
-
Copy full SHA for c4ba8e1 - Browse repository at this point
Copy the full SHA c4ba8e1View commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.