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

options test fails with SIGTRAP on macOS / arm64 #431

Open
barracuda156 opened this issue Jun 1, 2024 · 6 comments
Open

options test fails with SIGTRAP on macOS / arm64 #431

barracuda156 opened this issue Jun 1, 2024 · 6 comments

Comments

@barracuda156
Copy link

Running tests...
/opt/local/bin/ctest --force-new-ctest-process 
Test project /opt/local/var/macports/build/_opt_svacchanda_SonomaPorts_devel_cxxopts/cxxopts/work/build
    Start 1: options
1/3 Test #1: options ..........................SIGTRAP***Exception:   0.30 sec
    Start 2: find-package-test
2/3 Test #2: find-package-test ................   Passed    1.37 sec
    Start 3: add-subdirectory-test
3/3 Test #3: add-subdirectory-test ............   Passed    1.34 sec

67% tests passed, 1 tests failed out of 3

Total Test time (real) =   3.02 sec
@jarro2783
Copy link
Owner

Can you tell me what platform and architecture? Can you run it with gdb and get a stack trace?

@barracuda156
Copy link
Author

Can you tell me what platform and architecture? Can you run it with gdb and get a stack trace?

This is on macOS 14.5 arm64.

I am not sure gdb is working on arm64 now, but I can do it on PowerPC.

@jarro2783
Copy link
Owner

I don't have the ability to debug on that platform, so any extra info you can give me will help. I can try address sanitizer and see if it comes up with anything.

@barracuda156
Copy link
Author

Has it been confirmed to work on any non-x86 platform?

@barracuda156
Copy link
Author

barracuda156 commented Jun 3, 2024

@jarro2783 Looks like the problem is specific to arm64 or Sonoma. At least on 10.6 powerpc everything works fine, both for 3.2.1 and 5965670 (current master):

--->  Testing cxxopts
Executing:  cd "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_devel_cxxopts/cxxopts/work/build" && /usr/bin/make test 
Running tests...
/opt/local/bin/ctest --force-new-ctest-process 
Test project /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_devel_cxxopts/cxxopts/work/build
    Start 1: options
1/3 Test #1: options ..........................   Passed    0.04 sec
    Start 2: find-package-test
2/3 Test #2: find-package-test ................   Passed   26.79 sec
    Start 3: add-subdirectory-test
3/3 Test #3: add-subdirectory-test ............   Passed   26.74 sec

100% tests passed, 0 tests failed out of 3

Total Test time (real) =  53.59 sec

@barracuda156 barracuda156 changed the title options test fails with SIGTRAP options test fails with SIGTRAP on macOS / arm64 Jun 3, 2024
@jarro2783
Copy link
Owner

The UB sanitizer found an potential integer overflow. I don't know if arm aborts on that. If you can get a stack trace that would be great.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants