From: shyouhei@... Date: 2020-12-01T22:28:40+00:00 Subject: [ruby-core:101197] [Ruby master Feature#17356] Alignment of memory allocated through Fiddle struct's malloc Issue #17356 has been updated by shyouhei (Shyouhei Urabe). My proposal I wrote in #note-1 is basically the same as @kou���s in #note-5. I think it���s quite possible to add such things. ---------------------------------------- Feature #17356: Alignment of memory allocated through Fiddle struct's malloc https://bugs.ruby-lang.org/issues/17356#change-88878 * Author: AndreaRibuoli (Andrea Ribuoli) * Status: Open * Priority: Normal ---------------------------------------- I am testing a low-level patch for **Ruby 3** that inside *gc.c* replaces: `TRY_WITH_GC(size, mem = malloc(size));` with: `TRY_WITH_GC(size, mem = aligned_alloc(16,size));` This should allow me to control that Fiddle returns pointers quad-words aligned. Is it possible to introduce a configure parameter to control this kind of setting? Refer to [issue opened on Fiddle](https://github.com/ruby/fiddle/issues/53). Kind regards, Andrea Ribuoli -- https://bugs.ruby-lang.org/ Unsubscribe: