<HTML>
<style> BODY { font-family:Arial, Helvetica, sans-serif;font-size:12px; }</style>Hi everyone,<br>
<br>
Sorry for the slightly long-winded title. This was something I've been working on for the past few weeks to allow the use of "inline" with certain x86 assembler routines, subject to restrictions for safety reasons. I have successfully written code that implements this support while ensuring it doesn't affect platforms with a different assembly languages. Regression tests have passed, as have some new tests, some of which test modified RTL assembler functions that have had "inline" added to their list of directives.<br>
<br>
<div>There was a previous concern about it breaking too much and it being impossible to implement on all platforms - the latter point may be true, but through the careful use of virtual methods within the compiler, it should be possible to extend the inline support one platform at a time without breaking the others.</div><div><br>
</div><div>All the details, including a PDF specification that explains the design and implementation choices, a couple of existing tests that touch on the functionality, along with any new tests, limitations or problems found, can be found here: https://bugs.freepascal.org/view.php?id=35232</div><div><br>
</div><div>I hope it proves to be insightful and useful.</div><div><br>
</div><div>Gareth aka. Kit<br>
<br>
P.S. Though this feature can be used for implementing intrinsics, it is not a direct replacement for them because instructions like SHUFPS cannot be flexibly encoded due to its immediate operand (i.e. it has to be a raw number... it can't take its value from a parameter).<br>
</div> </HTML>