Skip to content
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

cpu/avr8_common: Optimize context switch #19799

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from

Commits on Dec 3, 2023

  1. tests: add test for context switch from ISR

    This try to explore a potential issue that may happen at context switch
    inside ISR.
    
    Signed-off-by: Gerson Fernando Budke <[email protected]>
    nandojve committed Dec 3, 2023
    Configuration menu
    Copy the full SHA
    51f4e57 View commit details
    Browse the repository at this point in the history
  2. cpu/avr8_common: Rework avr-8 interrupts

    AVR-8 supports nested interrupts but there is no infrastructure to
    use that.  This refactor infraestrocuture and enable the enhancement.
    It rework the ISR processing to use a shared stack implemeting the
    isr prolog/epilog/return.
    
    Signed-off-by: Gerson Fernando Budke <[email protected]>
    nandojve committed Dec 3, 2023
    Configuration menu
    Copy the full SHA
    2fc698a View commit details
    Browse the repository at this point in the history
  3. cpu/avr8_common: Fix assembly code style

    Adjust the code style of cpu_get_caller_pc function.
    
    Signed-off-by: Gerson Fernando Budke <[email protected]>
    nandojve committed Dec 3, 2023
    Configuration menu
    Copy the full SHA
    8db0bfc View commit details
    Browse the repository at this point in the history
  4. cpu/avr8_common: Optimize context ISR switch

    The current context switch implementaion don't take in consideration
    the call-used registers.  This means that ISR and context switch can
    not be optimized.  This rework both context switch and ISR save/restore
    order to optimize the context switch on ISR and reduce code size.
    
    This chance should improve the performance of AVR platform on RIOT-OS
    if is compared with the 2023.04 release.
    
    Signed-off-by: Gerson Fernando Budke <[email protected]>
    nandojve committed Dec 3, 2023
    Configuration menu
    Copy the full SHA
    cd5f955 View commit details
    Browse the repository at this point in the history
  5. cpu/avr8_common: Add dedicated ISR stack

    Signed-off-by: Gerson Fernando Budke <[email protected]>
    nandojve committed Dec 3, 2023
    Configuration menu
    Copy the full SHA
    4503f2e View commit details
    Browse the repository at this point in the history