Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • D dynamorio
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,467
    • Issues 1,467
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 44
    • Merge requests 44
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • DynamoRIO
  • dynamorio
  • Merge requests
  • !2497

i#1621 AArch64 CC opt: Make analyze_callee_save_reg more conservative.

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Administrator requested to merge i1621-callee-saved-analysis into master Jul 04, 2017
  • Overview 3
  • Commits 1
  • Pipelines 0
  • Changes 1

Created by: fhahn

The current behavior is to walk from the bottom instruction up to the current top instruction to find instructions that pop registers. This is too permissive and may remove instructions not used to save/restore callee-saved registers, e.g. spills of local variables to the stack.

This patches switches to a more conservative approach in which requires callee-saved registers to be popped in reverse order they have been pushed.

Both LLVM and GCC commonly use this pattern to save/restore callee-saved registers on AArch64, but they might use different patterns if that is more efficient. I think we should use this conservative approach for now, and maybe make it more permissive once we have clean call inlining implemented on AArch64 and solid test coverage.

This patch has no effect unless opt_cleancall > 1. I will put up a patch implementing clean call inlining for AArch64 soon and this patch will include a test case for analyze_callee_save_reg.

Change-Id: I5723db8d24fbf23f1687bb63c42c9084286bbb23

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: i1621-callee-saved-analysis