# New Ticket Created by  William Herrera 
# Please include the string:  [perl #127102]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org/Ticket/Display.html?id=127102 >


This bug (a MoarVM bug or ?) occurs while using 32-bit perl6 (MoarVM, no JIT), 
perl6 version 2015.09 built on MoarVM version 2015.09.

It occurs while using NativeCall to call a proprietary 32-bit .dll in Windows 
10, which is being used for a specialized BIOS hardware interface, so the 
source will not work on a generic Windows setup.

This native call works under Julia with similar parameters. The code "works" 
without an error trap if the line for the native call, which is the line
AsWMI_DeviceControl($pos, $colr +& 0xffffff);

which does the NativeCall to 
sub AsWMI_DeviceControl(int32, int32) is native("ACPIWMI") { * }

 is commented out, so it is not in the other code.

In perl6, the code exits after about 50 calls with the error message:

 ==========
Internal error: invalid thread ID 31457303 in GC work pass
 ==========

The thread ID varies from run to run, but the error consistently occurs after 
about 15 seconds of calling about 4 times a second. Before the error, the call 
works properly, setting the hardware without problems.

Reply via email to