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

[BUG] Program crash with mojo 24.3.0 (9882e19d) #2513

Closed
mortax opened this issue May 4, 2024 · 3 comments
Closed

[BUG] Program crash with mojo 24.3.0 (9882e19d) #2513

mortax opened this issue May 4, 2024 · 3 comments
Labels
bug Something isn't working mojo-repo Tag all issues with this label regression Regression

Comments

@mortax
Copy link

mortax commented May 4, 2024

Bug description

i have a small program that worked perfectly using mojo 24.2.1 but crashes (segmentation fault) when compiled with mojo 24.3.0`.

it's interesting to note that the previous executable is quite a bit larger than the current one:

  • older (working) binary: 578872
  • new (crashing) binary: 305912

Steps to reproduce

  • Include relevant code snippet or link to code that did not work as expected.

the hard thing for me is that i would prefer to not share the code (at least for the foreseeable future).

  • If using the Playground, name the pre-existing notebook that failed and the steps that led to failure.

i will have a look at Playgrounds to see if they can help me.

  • Include anything else that might help us debug the issue.

i was able to generate a core dump. i'm happy to look at that myself -- or pass it along (it is, off course, huge!).

System information

  • On what OS did you do install Mojo?
Architecture:       arm64

ProductName:        macOS
ProductVersion:     14.4.1
BuildVersion:       23E224
  • Provide version information for Mojo by pasting the output of mojo -v

mojo 24.3.0 (9882e19d)

  • Provide Modular CLI version by pasting the output of modular -v

modular 0.7.4 (df7a9e8b)

@mortax mortax added bug Something isn't working mojo-repo Tag all issues with this label labels May 4, 2024
@JoeLoser JoeLoser added the regression Regression label May 4, 2024
@JoeLoser
Copy link
Collaborator

JoeLoser commented May 4, 2024

Can you provide the source code by chance? That'll be the easiest to figure out what the problem is and a solution.

@mortax
Copy link
Author

mortax commented May 5, 2024

thanks @JoeLoser. i should probably note that the crashing program performs a fairly large recursive calculation. i'm investigating whether i can provide some version of the source code. if so, i would only be comfortable doing that privately.

in the meantime, i tried using a Playground and it only indicates that the program failed. i also found that running the program using mojo run provides slightly more information:

[2950:31950374:20240505,123447.014769:WARNING in_range_cast.h:38] value -634136515 out of range
[2950:31950377:20240505,123447.041191:ERROR directory_reader_posix.cc:42] opendir /Users/jrd/.modular/crashdb/attachments/d8457116-9460-4fec-8387-c5b9c232eaeb: No such file or directory (2)
[2950:31950374:20240505,123447.041235:WARNING crash_report_exception_handler.cc:257] UniversalExceptionRaise: (os/kern) failure (5)
zsh: illegal hardware instruction  source/recursive/program.mojo 1 3999999
{132} [univac]$ 

the crash above happens at/during the next recursive all. let me know is that helps at all.

i am also happy to provide one (or more) of these:

[univac]$ ls -lt /Users/jrd/.modular/crashdb/completed/* | head -1
-rw-------@ 1 jrd  staff  176557824 May  5 12:44 /Users/jrd/.modular/crashdb/completed/dca35d71-fa5e-497b-8b7e-a37bd0b312f0.dmp
[univac]$ file /Users/jrd/.modular/crashdb/completed/dca35d71-fa5e-497b-8b7e-a37bd0b312f0.dmp
/Users/jrd/.modular/crashdb/completed/dca35d71-fa5e-497b-8b7e-a37bd0b312f0.dmp: Mini DuMP crash report, 8 streams, Sun May  5 19:44:10 2024, 0 type

aside - i find this amusing:

[2950:31950377:20240505,123447.041191:ERROR directory_reader_posix.cc:42] opendir /Users/jrd/.modular/crashdb/attachments/d8457116-9460-4fec-8387-c5b9c232eaeb: No such file or directory (2)

because mkdir -p /Users/jrd/.modular/crashdb/attachments fixed it:

[3766:31966598:20240505,124410.952548:WARNING in_range_cast.h:38] value -634136515 out of range
[3766:31966598:20240505,124411.031207:WARNING crash_report_exception_handler.cc:257] UniversalExceptionRaise: (os/kern) failure (5)
zsh: illegal hardware instruction (core dumped)  source/recursive/program.mojo 1 3999999

@mortax
Copy link
Author

mortax commented May 8, 2024

@JoeLoser i guess that doesn't help.

@linear linear bot closed this as not planned Won't fix, can't repro, duplicate, stale May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working mojo-repo Tag all issues with this label regression Regression
Projects
None yet
Development

No branches or pull requests

2 participants