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

Add wasm_runtime_detect_native_stack_overflow_size #3355

Merged
merged 21 commits into from
Apr 26, 2024

Commits on Apr 26, 2024

  1. Configuration menu
    Copy the full SHA
    df96828 View commit details
    Browse the repository at this point in the history
  2. consume wasm_runtime_detect_native_stack_overflow

    this changes the accounting by one small function call.
    i don't think it can cause real problems though.
    yamt committed Apr 26, 2024
    Configuration menu
    Copy the full SHA
    ffa17f3 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    49d2a64 View commit details
    Browse the repository at this point in the history
  4. samples/native-stack-overflow: use wasm_runtime_detect_native_stack_o…

    …verflow
    
    replace homegrown check.
    yamt committed Apr 26, 2024
    Configuration menu
    Copy the full SHA
    81e5d03 View commit details
    Browse the repository at this point in the history
  5. Add wasm_runtime_detect_native_stack_overflow_size

    This allows each native function to require more native stack.
    
    cf. bytecodealliance#3325
    yamt committed Apr 26, 2024
    Configuration menu
    Copy the full SHA
    0c95ad0 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    2107dba View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    32e5b5d View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    5b22812 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    b373c27 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    9d5c3ac View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    a8ca169 View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    0397d4f View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    725aac3 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    a887eca View commit details
    Browse the repository at this point in the history
  15. fix build with GCC

    yamt committed Apr 26, 2024
    Configuration menu
    Copy the full SHA
    71d02fd View commit details
    Browse the repository at this point in the history
  16. samples/native-stack-overflow: use size_level=0

    To avoid:
    LLVM ERROR: Only small, tiny and large code models are allowed on AArch64
    yamt committed Apr 26, 2024
    Configuration menu
    Copy the full SHA
    74be598 View commit details
    Browse the repository at this point in the history
  17. CI: skip samples/native-stack-overflow on macOS arm64

    as i have no good way to debug right now.
    
    the failure seen on the CI:
    ```
    ====== Interpreter test1
     stack size   | fail?  | leak?  | exception
    ---------------------------------------------------------------------------
        0 - 24576 | failed |     ok | Exception: native stack overflow
    
    ====== Interpreter WAMR_DISABLE_HW_BOUND_CHECK=1 test1
     stack size   | fail?  | leak?  | exception
    ---------------------------------------------------------------------------
        0 -  3568 | failed |     ok | Exception: native stack overflow
     3568 - 24576 | failed |     ok | Exception: wasm operand stack overflow
    
    ====== AOT test1
     stack size   | fail?  | leak?  | exception
    ---------------------------------------------------------------------------
        0 - 24576 | failed |     ok | Exception: native stack overflow
    
    ====== AOT WAMR_DISABLE_HW_BOUND_CHECK=1 test1
     stack size   | fail?  | leak?  | exception
    ---------------------------------------------------------------------------
        0 -  4000 | failed |     ok | Exception: native stack overflow
     4000 - 24576 |     ok |     ok |
    ====== Interpreter test2
     stack size   | fail?  | leak?  | exception
    ---------------------------------------------------------------------------
        0 - 24576 | failed |     ok | Exception: native stack overflow
    
    ====== Interpreter WAMR_DISABLE_HW_BOUND_CHECK=1 test2
    ./run.sh: line 12: 14708 Segmentation fault: 11  out/native-stack-overflow.WAMR_DISABLE_HW_BOUND_CHECK out/wasm-apps/testapp.wasm ${NAME}
    ```
    yamt committed Apr 26, 2024
    Configuration menu
    Copy the full SHA
    fcfff69 View commit details
    Browse the repository at this point in the history
  18. disable tail-call for gcc

    fix an infinite loop in consume_stack1
    yamt committed Apr 26, 2024
    Configuration menu
    Copy the full SHA
    6607b2f View commit details
    Browse the repository at this point in the history
  19. minor comment fixes

    yamt committed Apr 26, 2024
    Configuration menu
    Copy the full SHA
    f6b57ab View commit details
    Browse the repository at this point in the history
  20. simplify

    yamt committed Apr 26, 2024
    Configuration menu
    Copy the full SHA
    be17b3f View commit details
    Browse the repository at this point in the history
  21. Configuration menu
    Copy the full SHA
    6196f1c View commit details
    Browse the repository at this point in the history