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

segfaults when running TCC on some inputs #12

Closed
fnuecke opened this issue Jul 17, 2022 · 1 comment
Closed

segfaults when running TCC on some inputs #12

fnuecke opened this issue Jul 17, 2022 · 1 comment
Labels
bug Something isn't working

Comments

@fnuecke
Copy link
Owner

fnuecke commented Jul 17, 2022

This typically happens when trying to compile larger programs with TCC (such as the cJSON library). There also appear to happen segfaults in other applications. The TCC segfault does not happen when running the same rootfs and kernel image in qemu, leading me to suspect it's a bug in sedna somewhere. Could be the memory virtualization, could be an instruction not doing quite the right thing in some edge case, sadly no hard leads right now.

@fnuecke fnuecke added the bug Something isn't working label Jul 17, 2022
@IiTossiI
Copy link

Issue still here but I found a temporary workaround until the issue is fixed
First run tcc with the preprocessing flag
# tcc main.c -E
And then you spam the tcc program until it compiles
# tcc main.c
And it will compile to a working program

But its unbearable to make programs like this so I'm looking forward for this issue to be fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants