Currently inline assembly lowering reports error as shown in https://gcc.godbolt.org/z/Kdx7e3n9M
- This doesn't fix https://github.com/llvm/llvm-project/issues/62343 but gives a workaround by tuning 'global-isel-abort'.
Differential D149211
[GlobalISel][InlineAsm][X86]Fallback on DAG ISel when lowering inline assembly mingmingl on Apr 25 2023, 3:49 PM. Authored by
Details Currently inline assembly lowering reports error as shown in https://gcc.godbolt.org/z/Kdx7e3n9M
Diff Detail Event TimelineComment Actions undo the change in CodeGen/GlobalISel/IRTranslator.cpp as they are not relevant in this patch (the call to fallback ) in IRTranslator::translate will return false so translateInlineAsm won't be executed. Comment Actions I don't understand why this needs to be special cased. The regular fallback seems to work expected as-is. Comment Actions https://gcc.godbolt.org/z/vq4nGG793 shows setting global-isel-abort to DisableWithDiag indeed works. Thinking back what I have in mind when writing this patch, I misunderstood how I shall use fallBackToDAGISel (thought the fallback path would also call this method )-> in fact, when IRTranslator handles translation error, it sets properties on machine-function; and let codegen pass builder to decide whether to restore machine function and falls back to selection-dag-based ISel (decided by -global-isel-abort mode) Comment Actions IIRC the only reason that exists was for a compile time hack for common cases that would fall back. |