Improvements to LoadRegValue for non-standard int types
Per my comments made here, I'm not super satisfied with a solution where we are loading arrays just to immediately store them, loading again after a bitcast. Theoretically, alloca should be optimized out, but this seems like a design flaw in trying to support 80-bit floating point numbers when compiling x87 support on Windows.
Ref: 7b89593bf23ff48c29dd4617f453b49642be5b48 Ref: 4393ce6c6b5ecd11fd89e262d956395c08456699
cc @fvrmatteo @mrexodia @Ninja3047
Personally I have never lifted any x87 code (although Windows has nothing to do with it), @momo5502 might have insights.
Personally I have never lifted any x87 code (although Windows has nothing to do with it), @momo5502 might have insights.
The only X87 code I'm lifting is float stack pushes/pops, because of the way calling conventions return floating point values on 32 bit windows, so I'm not an expert either :P
Regarding the comment, I personally don't think it's that relevant. The alloca will be optimized as soon as the IR code is being lowered. However, it surely would be much cleaner if LoadRegValue dealt with the conversion without having to create the alloca. If there is time for such a refactoring, then why not do it :D