tra added a comment. > Hi Artem, I think we can just delay emission of this warning to solve this > problem.
I'm not sure we can always tell whether the warning is real or if it's the consequence of failing to parse inline asm. E.g.: namespace { __host__ __device__ a() { int prev; __asm__ __volatile__("mov %0, 0" : "=a" (prev)::); return prev; } __host__ __device__ b() { int prev; return prev; } } //namespace Ideally we should always emit uninitialized diagnostics for `b`, but never for `a` in both host and device compilation modes. I think we may want to propagate assignment from the inline asm statement -- we may not know the meaning of the constraint, but we do know which argument gets used/modified by the asm statement. Perhaps we can construct a fake GCCAsmStmt but bail out before we attempt to validate the asm string. Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58463/new/ https://reviews.llvm.org/D58463 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits