Bug 17665 – Win64 atomicLoad for T[] cannot be cast from size_t[2]

Status
RESOLVED
Resolution
FIXED
Severity
trivial
Priority
P1
Component
druntime
Product
D
Version
D2
Platform
x86_64
OS
Windows
Creation time
2017-07-19T13:00:00Z
Last change time
2017-08-07T12:26:12Z
Assigned to
nobody
Creator
alphaglosined

Comments

Comment #0 by alphaglosined — 2017-07-19T13:00:06Z
A special case where by atomicLoad has a return variable for the inline assembly. With the results being casted. For arrays it cannot cast from the static variant of the slice to dynamic. Where T == U[] on Windows x86_64. --- size_t[2] retVal; asm { ... } return cast(T)retVal; Into (essentially): return *cast(T*)&retVal; ---
Comment #1 by github-bugzilla — 2017-08-02T16:04:07Z
Commits pushed to master at https://github.com/dlang/druntime https://github.com/dlang/druntime/commit/1ab473d1314960dfb6a4732fd55218ac2095a663 Fix issue 17665 https://github.com/dlang/druntime/commit/03b70be5bf3c76a9e7461d0e20afbbec030c5308 Merge pull request #1884 from rikkimax/rikkimax-patch-17665 Fixes issue #17665 merged-on-behalf-of: Petar Kirov <[email protected]>
Comment #2 by github-bugzilla — 2017-08-07T12:26:12Z