Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

fix Issue 12800 - Fibers are broken on Win64 #809

Merged
merged 2 commits into from
May 25, 2014
Merged

fix Issue 12800 - Fibers are broken on Win64 #809

merged 2 commits into from
May 25, 2014

Conversation

jblume
Copy link
Contributor

@jblume jblume commented May 25, 2014

Win64 version of the context switch used the wrong registers for parameters.

https://issues.dlang.org/show_bug.cgi?id=12800

Note that when the example in the bug report is built in VisualD with standard debug settings, it still crashes. But that crash is caused by the default setting of only 4k stack space per Fiber, which isn't enough with all the debug switches VisualD sets. Compiling directly with DMD without any special switches works.

Win64 version of the context switch used the wrong registers for parameters
@MartinNowak
Copy link
Member

Thanks a lot, please enable the Fiber unittests on Win64 though.
https://github.com/jblume/druntime/blob/master/src/core/thread.d#L4496

@jblume
Copy link
Contributor Author

jblume commented May 25, 2014

I also extended the stack alignment test which originally only ran for Posix, as the Windows 64 calling convention demands alignment to 16 byte as well.

I have only started working with DMD a few days ago, so I hope the unit tests actually ran through correctly on my machine. After inserting an assert(0) they failed as expected, so I have some hope it actually worked.

@MartinNowak
Copy link
Member

Auto-merge toggled on

MartinNowak added a commit that referenced this pull request May 25, 2014
fix Issue 12800 - Fibers are broken on Win64
@MartinNowak MartinNowak merged commit 591b8d4 into dlang:master May 25, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants