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

Update nim.cfg #21204

Merged
merged 1 commit into from
Jan 2, 2023
Merged

Update nim.cfg #21204

merged 1 commit into from
Jan 2, 2023

Conversation

ci4ic4
Copy link
Contributor

@ci4ic4 ci4ic4 commented Dec 30, 2022

tlsEmulation:on under NetBSD-10Beta and NetBSD-current produces an executable which crashes immediately as follows:

Core was generated by `koch'.
Program terminated with signal SIGSEGV, Segmentation fault. #0 0x000000000047b4c2 in nimZeroMem ()
(gdb) bt
#0 0x000000000047b4c2 in nimZeroMem ()
#1 0x00000000004897b2 in threadVarAlloc__system_2162 () #2 0x000000000048980e in initThreadVarsEmulation () #3 0x0000000000489848 in PreMain ()
#4 0x000000000048986a in NimMain ()
#5 0x00000000004898a9 in main ()

I can't speak about the other BSDs.

tlsEmulation:on under NetBSD-10Beta and NetBSD-current produces an executable which crashes immediately as follows:

Core was generated by `koch'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x000000000047b4c2 in nimZeroMem ()
(gdb) bt
#0  0x000000000047b4c2 in nimZeroMem ()
nim-lang#1  0x00000000004897b2 in threadVarAlloc__system_2162 ()
nim-lang#2  0x000000000048980e in initThreadVarsEmulation ()
nim-lang#3  0x0000000000489848 in PreMain ()
nim-lang#4  0x000000000048986a in NimMain ()
nim-lang#5  0x00000000004898a9 in main ()

I can't speak about the other BSDs.
@rockcavera
Copy link
Contributor

Well, I've been testing a package of mine on NetBSD 9.3 and I haven't had any problems and the default setting is tlsEmulation:on. I'm using devel. It would be interesting to create an issue reporting better.

@ci4ic4
Copy link
Contributor Author

ci4ic4 commented Jan 1, 2023

Under NetBSD 9.3 tlsEmulation:on still works. The reason why this was elected for NetBSD on some earlier version however, does not exist - it works with both tlsEmulation:on or tlsEmulation:off.

Subsequent NetBSD versions behave differently - at least for the moment, the tlsEmulation:on version does not work. I have tested this on both NetBSD-10Beta and -current from yesterday. They require tlsEmulation:off, same as FreeBSD.

Hence, switching to native tls, instead of emulated one, will not affect NetBSD 9.3 and is at least for now required for subsequent versions.

tlsEmulation:on also adds some 1.3K to every executable.

@Araq Araq merged commit e9ed090 into nim-lang:devel Jan 2, 2023
@Araq
Copy link
Member

Araq commented Jan 2, 2023

Backport to 2.0 please. @narimiran

@github-actions
Copy link
Contributor

github-actions bot commented Jan 2, 2023

Thanks for your hard work on this PR!
The lines below are statistics of the Nim compiler built from e9ed090

Hint: mm: orc; opt: speed; options: -d:release
165744 lines; 8.219s; 611.531MiB peakmem

@ci4ic4 ci4ic4 deleted the patch-2 branch January 2, 2023 11:02
narimiran pushed a commit that referenced this pull request Jan 2, 2023
tlsEmulation:on under NetBSD-10Beta and NetBSD-current produces an executable which crashes immediately as follows:

Core was generated by `koch'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x000000000047b4c2 in nimZeroMem ()
(gdb) bt
#0  0x000000000047b4c2 in nimZeroMem ()
#1  0x00000000004897b2 in threadVarAlloc__system_2162 ()
#2  0x000000000048980e in initThreadVarsEmulation ()
#3  0x0000000000489848 in PreMain ()
#4  0x000000000048986a in NimMain ()
#5  0x00000000004898a9 in main ()

I can't speak about the other BSDs.

(cherry picked from commit e9ed090)
survivorm pushed a commit to survivorm/Nim that referenced this pull request Feb 28, 2023
tlsEmulation:on under NetBSD-10Beta and NetBSD-current produces an executable which crashes immediately as follows:

Core was generated by `koch'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x000000000047b4c2 in nimZeroMem ()
(gdb) bt
#0  0x000000000047b4c2 in nimZeroMem ()
#1  0x00000000004897b2 in threadVarAlloc__system_2162 ()
#2  0x000000000048980e in initThreadVarsEmulation ()
#3  0x0000000000489848 in PreMain ()
#4  0x000000000048986a in NimMain ()
#5  0x00000000004898a9 in main ()

I can't speak about the other BSDs.
capocasa pushed a commit to capocasa/Nim that referenced this pull request Mar 31, 2023
tlsEmulation:on under NetBSD-10Beta and NetBSD-current produces an executable which crashes immediately as follows:

Core was generated by `koch'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x000000000047b4c2 in nimZeroMem ()
(gdb) bt
#0  0x000000000047b4c2 in nimZeroMem ()
nim-lang#1  0x00000000004897b2 in threadVarAlloc__system_2162 ()
nim-lang#2  0x000000000048980e in initThreadVarsEmulation ()
nim-lang#3  0x0000000000489848 in PreMain ()
nim-lang#4  0x000000000048986a in NimMain ()
nim-lang#5  0x00000000004898a9 in main ()

I can't speak about the other BSDs.
bung87 pushed a commit to bung87/Nim that referenced this pull request Jul 29, 2023
tlsEmulation:on under NetBSD-10Beta and NetBSD-current produces an executable which crashes immediately as follows:

Core was generated by `koch'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x000000000047b4c2 in nimZeroMem ()
(gdb) bt
#0  0x000000000047b4c2 in nimZeroMem ()
#1  0x00000000004897b2 in threadVarAlloc__system_2162 ()
#2  0x000000000048980e in initThreadVarsEmulation ()
nim-lang#3  0x0000000000489848 in PreMain ()
nim-lang#4  0x000000000048986a in NimMain ()
nim-lang#5  0x00000000004898a9 in main ()

I can't speak about the other BSDs.
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

Successfully merging this pull request may close these issues.

3 participants