[Issue 19946] In betterC filling an array with a non-zero value fails for types of size > 1 due to missing _memset16/_memset32/etc.

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu Jun 2 19:01:13 UTC 2022


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

mhh <maxhaton at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |maxhaton at gmail.com

--- Comment #4 from mhh <maxhaton at gmail.com> ---
The fix is easy. I wrote the code but never got around to pushing it.

It just needs to be a template in druntime. Hypothetically you could make it
inline a loop but this might hurt LDC and GDC.

arrayOp actually supports memset but making the array lowering use arrayOp
would make it end up using itself.

I also looked into using an arbitrary set memset in the backend but yuck.

--


More information about the Digitalmars-d-bugs mailing list