Verified Commit a7492bd8 authored by Camil Staps's avatar Camil Staps
Browse files

Add option for callgraph profiling to IDE

parent 75200b87
Pipeline #34678 passed with stage
in 49 seconds
...@@ -294,12 +294,13 @@ where ...@@ -294,12 +294,13 @@ where
compilerPane = Pane "Compiler" compilerPane = Pane "Compiler"
( TextControl "Profiling Options" [] ( TextControl "Profiling Options" []
:+: RadioControl :+: RadioControl
[ ("Time Profile and Stack Trace",Nothing,noPS (\l->{l & ao = {l.ao & profiling = True, stack_traces = False}})) [ ("Time Profile, Call Graph, and Stack Trace",Nothing,noPS (\l->{l & ao = {l.ao & profiling = True, callgraphProfiling = True, stack_traces = False}}))
, ("Stack Trace only",Nothing,noPS (\l->{l & ao = {l.ao & profiling = True, stack_traces = True}})) , ("Time Profile and Stack Trace",Nothing,noPS (\l->{l & ao = {l.ao & profiling = True, callgraphProfiling = False, stack_traces = False}}))
, ("No Time Profiling",Nothing,noPS (\l->{l & ao = {l.ao & profiling = False, stack_traces = False}})) , ("Stack Trace only",Nothing,noPS (\l->{l & ao = {l.ao & profiling = True, callgraphProfiling = False, stack_traces = True}}))
, ("No Time Profiling",Nothing,noPS (\l->{l & ao = {l.ao & profiling = False, callgraphProfiling = False, stack_traces = False}}))
] ]
(Columns 1) (Columns 1)
(if ao.profiling (if ao.stack_traces 2 1) 3) (if ao.profiling (if ao.stack_traces 3 (if ao.callgraphProfiling 1 2)) 4)
[ControlPos (Left,zero)] [ControlPos (Left,zero)]
:+: CheckControl :+: CheckControl
[("Heap Profile",Nothing,toMark ao.memoryProfiling, noPS (\l->{l & ao.memoryProfiling = not l.ao.memoryProfiling}))] [("Heap Profile",Nothing,toMark ao.memoryProfiling, noPS (\l->{l & ao.memoryProfiling = not l.ao.memoryProfiling}))]
......
...@@ -10,7 +10,7 @@ import PmTypes ...@@ -10,7 +10,7 @@ import PmTypes
import PmCallBack import PmCallBack
standardStaticLibraries :: !Processor !LinkMethod -> List String standardStaticLibraries :: !Processor !LinkMethod -> List String
standardObjectFiles :: !Bool !Bool !Processor !Bool -> List String standardObjectFiles :: !Bool !Bool !Bool !Processor !Bool -> List String
getLibs :: ![String] !*Files -> (!(![String],![String]),!*Files) getLibs :: ![String] !*Files -> (!(![String],![String]),!*Files)
......
...@@ -3,6 +3,7 @@ implementation module PmCleanSystem ...@@ -3,6 +3,7 @@ implementation module PmCleanSystem
import StdArray, StdBool, StdChar, StdFunc, StdInt, StdList, StdEnum import StdArray, StdBool, StdChar, StdFunc, StdInt, StdList, StdEnum
import StdMaybe import StdMaybe
from StdMisc import abort, undef from StdMisc import abort, undef
import _SystemStrictLists
from Platform import DirSeparator,DirSeparatorString from Platform import DirSeparator,DirSeparatorString
...@@ -43,13 +44,19 @@ standardStaticLibraries _ method ...@@ -43,13 +44,19 @@ standardStaticLibraries _ method
morelibs // Note that these dependencies are introduced by StdEnv and should be encoded there. morelibs // Note that these dependencies are introduced by StdEnv and should be encoded there.
= "user_library" :! "gdi_library" :! "comdlg_library" :! Nil = "user_library" :! "gdi_library" :! "comdlg_library" :! Nil
standardObjectFiles :: !Bool !Bool !Processor !Bool -> List String standardObjectFiles :: !Bool !Bool !Bool !Processor !Bool -> List String
standardObjectFiles stack_traces profiling _ use_64_bit_processor standardObjectFiles stack_traces callgraph_profiling profiling _ use_64_bit_processor
#! startup1_file = if stack_traces "_startup1Trace.o" #! startup1_files =
(if profiling "_startup1Profile.o" "_startup1.o") if stack_traces
[|"_startup1Trace.o"]
(if profiling
(if callgraph_profiling
[|"_startup1ProfileGraph.o", "_startup1ProfileGraphB.o"]
[|"_startup1Profile.o"])
[|"_startup1.o"])
| not use_64_bit_processor | not use_64_bit_processor
= ("_startup0.o" :! startup1_file :! "_startup2.o" :! "_system.o" :! Nil) = Concat [|"_startup0.o" : startup1_files] [|"_startup2.o", "_system.o"]
= ("_startup0.o" :! startup1_file :! "_startup2.o" :! "_startup3.o" :! "_startup4.o" :! "_system.o" :! Nil) = Concat [|"_startup0.o" : startup1_files] [|"_startup2.o", "_startup3.o", "_startup4.o", "_system.o"]
//-- interface to static libraries... //-- interface to static libraries...
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment