This is an archive of the discontinued LLVM Phabricator instance.

[Clang][Driver] Disable llvm passes for the first host OpenMP offload compilation
ClosedPublic

Authored by sdmitriev on Jan 30 2020, 9:21 AM.

Details

Summary

With OpenMP offloading host compilation is done in two phases to capture host IR that is passed to all device compilations as input. But it turns out that we currently run entire LLVM optimization pipeline on host IR on both compilations which may have unpredictable effects on the resulting code. This patch fixes this problem by disabling LLVM passes on the first compilation, so the host IR that is passed to device compilations will be captured right after front end.

Diff Detail

Event Timeline

sdmitriev created this revision.Jan 30 2020, 9:21 AM
Herald added a project: Restricted Project. · View Herald TranscriptJan 30 2020, 9:21 AM
This revision is now accepted and ready to land.Jan 30 2020, 10:02 AM
This revision was automatically updated to reflect the committed changes.