This is an archive of the discontinued LLVM Phabricator instance.

[XRay][clang] Fix the -fxray-instruction-threshold flag processing
ClosedPublic

Authored by dberris on Mar 30 2017, 2:17 AM.

Details

Summary

The refactoring introduced a regression in the flag processing for
-fxray-instruction-threshold which causes it to not get passed properly.
This change should restore the previous behaviour.

Diff Detail

Repository
rL LLVM

Event Timeline

dberris created this revision.Mar 30 2017, 2:17 AM
rnk accepted this revision.Mar 30 2017, 11:38 AM

lgtm

test/CodeGen/xray-instruction-threshold.cpp
11 ↗(On Diff #93454)

Any reason to use -DAG on the decls? The IR should be in source order, with the attributes always at the end. The attribute sets need -DAG, of course.

This revision is now accepted and ready to land.Mar 30 2017, 11:38 AM
This revision was automatically updated to reflect the committed changes.
dberris marked an inline comment as done.
dberris added inline comments.Mar 30 2017, 3:59 PM
test/CodeGen/xray-instruction-threshold.cpp
11 ↗(On Diff #93454)

Good question. I hadn't thought that through, I was just thinking that the attribute set -DAG needed to depend on variables captured from a -DAG earlier. Changed this now since it seems it's unnecessary. :)