From 0ea62d5d8e73c12c19d6dbc63f2a41354c980976 Mon Sep 17 00:00:00 2001 From: Michael Hayes Date: Sat, 27 Aug 2011 22:38:44 +0000 Subject: [PATCH] Add indirect calls --- etc/makemake.py | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/etc/makemake.py b/etc/makemake.py index f8ef0c8..eacc93a 100755 --- a/etc/makemake.py +++ b/etc/makemake.py @@ -249,7 +249,7 @@ def functions_find (gcc, filepath, functiondeps = {}): function = matches[0] functiondeps[function] = [] # print >> sys.stderr, 'DEF', function - matches = re.findall (r'.*gimple_call [<]([\w]*)[,]', line) + matches = re.findall (r'.*gimple_call <([\w]*),', line) if matches: # print >> sys.stderr, 'USE', matches[0] if function: @@ -257,6 +257,18 @@ def functions_find (gcc, filepath, functiondeps = {}): else: print >> sys.stderr, matches[0], 'used outside function in', filepath + # Search for where a function address is taken + function = None + for line in text: + matches = re.findall (r'^;; Function (.*)\s[(]', line) + if matches: + function = matches[0] + # gimple_assign + matches = re.findall (r'.*gimple_assign > sys.stderr, command # os.system (command)