r277492 - Revert "[Order Files] Remove dtrace predicate"

Chris Bieneman via cfe-commits cfe-commits at lists.llvm.org
Tue Aug 2 11:23:57 PDT 2016


Author: cbieneman
Date: Tue Aug  2 13:23:56 2016
New Revision: 277492

URL: http://llvm.org/viewvc/llvm-project?rev=277492&view=rev
Log:
Revert "[Order Files] Remove dtrace predicate"

This reverts commit r277487.

Removing the probe predicate was a red herring. It results in more symbols being placed in the final order file, but they are symbols from outside the clang image.

Modified:
    cfe/trunk/utils/perf-training/perf-helper.py

Modified: cfe/trunk/utils/perf-training/perf-helper.py
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/utils/perf-training/perf-helper.py?rev=277492&r1=277491&r2=277492&view=diff
==============================================================================
--- cfe/trunk/utils/perf-training/perf-helper.py (original)
+++ cfe/trunk/utils/perf-training/perf-helper.py Tue Aug  2 13:23:56 2016
@@ -75,12 +75,13 @@ def dtrace(args):
       target = "oneshot$target:::entry"
   else:
       target = "pid$target:::entry"
+  predicate = '%s/probemod=="%s"/' % (target, os.path.basename(cmd[0]))
   log_timestamp = 'printf("dtrace-TS: %d\\n", timestamp)'
   if opts.use_ustack:
       action = 'ustack(1);'
   else:
       action = 'printf("dtrace-Symbol: %s\\n", probefunc);'
-  dtrace_script = "%s { %s; %s }" % (target, log_timestamp, action)
+  dtrace_script = "%s { %s; %s }" % (predicate, log_timestamp, action)
 
   dtrace_args = []
   if not os.geteuid() == 0:




More information about the cfe-commits mailing list