[PATCH] D42568: [AArch64] Don't enable GlobalISel automatically for windows

Martin Storsjö via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 26 01:56:13 PST 2018


mstorsjo added a comment.

In https://reviews.llvm.org/D42568#988786, @kristof.beyls wrote:

> Hi Martin,
>
> Do I understand correctly that this patch both has code to disable globalisel when targeting windows, and also when a function is marked as "dllimport"?
>  Wouldn't one of these checks be enough?
>  From your description, I would have thought that just the "dllimport" check would be enough?
>  I'm probably missing quite a bit of background info here - but I thought I'd ask to understand this better.


Just disabling globalisel for individual function calls to dllimport functions would indeed be the most elegant solution. However, the "return false;" in translateCall doesn't cause such fallbacking, but insteads makes the build abort with this error message:

LLVM ERROR: unable to translate instruction: call (in function: call_external)

So that part is kept as a reminder/check to whoever manually enables globalisel on windows, that the output isn't right in those cases. The generic disabling makes sure we don't trigger this and don't error out. If we on the other hand could do partial fallbacks to SelectionDAG for those function calls, that'd be even better.


https://reviews.llvm.org/D42568





More information about the llvm-commits mailing list