search for: outlined

Displaying 20 results from an estimated 2809 matches for "outlined".

2017 Sep 05
5
[RFC] PT.2 Add IR level interprocedural outliner for code size.
...try to match the IR cost to the MIR cost as closely as possible and in practice we can get fairly close(Graph[1]). Taking this a step further we need to estimate the cost/setup of having x amount of parameters and y outputs, as well as the register pressure from both the call and the potentially outlined function. Parameterization Optimizations: - Machine Outliner The Machine outliner uses exact equivalence, which does not allow for any form of parameterization. - IR Outliner Being at the IR level requires us to tackle parameterization, which then brings several optimiz...
2017 Sep 22
0
[RFC] PT.2 Add IR level interprocedural outliner for code size.
...o match the IR cost to the MIR cost as closely as possible and in practice we can get fairly close(Graph[1]). > Taking this a step further we need to estimate the cost/setup of having x amount of parameters and y outputs, as well as the register pressure from both the call and the potentially outlined function. > > Parameterization Optimizations: > > - Machine Outliner > The Machine outliner uses exact equivalence, which does not allow for any form of parameterization. > > - IR Outliner > Being at the IR level requires us to tackle parameter...
2017 Sep 22
2
[RFC] PT.2 Add IR level interprocedural outliner for code size.
...cost to the MIR cost as closely as > possible and in practice we can get fairly close(Graph[1]). > Taking this a step further we need to estimate the cost/setup of having > x amount of parameters and y outputs, as well as the register pressure from > both the call and the potentially outlined function. > > Parameterization Optimizations: > > - Machine Outliner > The Machine outliner uses exact equivalence, which does not allow for any > form of parameterization. > > - IR Outliner > Being at the IR level requires us to tackle parameteriz...
2017 Sep 27
0
[RFC] PT.2 Add IR level interprocedural outliner for code size.
...tch the IR cost to the MIR cost as closely as possible and in practice we can get fairly close(Graph[1]). >> Taking this a step further we need to estimate the cost/setup of having x amount of parameters and y outputs, as well as the register pressure from both the call and the potentially outlined function. >> >> Parameterization Optimizations: >> >> - Machine Outliner >> The Machine outliner uses exact equivalence, which does not allow for any form of parameterization. >> >> - IR Outliner >> Being at the IR level...
2013 Jul 16
1
Masking oceans using polypath
Hi R-help I am trying to mask the ocean from an image plot I have made. Here is some example code: library(mapdata) image(x=110:155, y =-40:-10, z = outer(1:45, 1:30, "+"), xlab = "lon", ylab = "lat") outline <- map("worldHires", plot=FALSE) # returns a list of x/y coords xrange <- range(outline$x, na.rm=TRUE) # get bounding box yrange
2017 Aug 15
8
[RFC] Enhance Partial Inliner by using a general outlining scheme for cold blocks
...es where we are confident it will result in a performance gain. Things such as threshold on when a branch is considered cold, the minimum number of times the predecessor node has to be executed in order for an edge to be considered (confidence factor), and the minimum size of the region to be outlined (can use inlining cost analysis like we currently do) will require some level of tuning. Similar to the current implementation, we will attempt to inline the leftover (hot) parts of the code, and if for some reason we cannot then we discard the modified function and its outlined code. ### Co...
2017 Aug 15
3
[RFC] Enhance Partial Inliner by using a general outlining scheme for cold blocks
...nfident it will result in a performance gain. Things such as threshold on when a branch is considered cold, the minimum number of times the predecessor node has to be executed in order for an edge to be considered (confidence factor), and the minimum size of the region to be outlined (can use inlining cost analysis like we currently do) will require some level of tuning. Similar to the current implementation, we will attempt to inline the leftover (hot) parts of the code, and if for some reason we cannot then we discard the modified function and its out...
2017 Sep 27
3
[RFC] PT.2 Add IR level interprocedural outliner for code size.
...the IR cost to the MIR cost as closely as possible and in practice we can get fairly close(Graph[1]). >>> Taking this a step further we need to estimate the cost/setup of having x amount of parameters and y outputs, as well as the register pressure from both the call and the potentially outlined function. >>> >>> Parameterization Optimizations: >>> >>> - Machine Outliner >>> The Machine outliner uses exact equivalence, which does not allow for any form of parameterization. >>> >>> - IR Outliner >>>...
2018 Apr 21
5
[RFC] Turn the MachineOutliner on by default in AArch64 under -Oz
...er produces correct AArch64 code at -Oz. Tests include the LLVM test suite and standard external test suites such as SPEC. All tests compile and execute. We've also been making sure that the outliner produces debuggable code. Users are still guaranteed to have sane backtraces in the presence of outlined functions. Added exposure to various programs would help the outlining algorithm mature further. This, in turn, will help the overall outlining project. For example, there have been a few discussions on implementing an IR-level outlining pass [3, 4]. Ultimately, the goal is to create a shared outl...
2017 Jul 31
2
[RFC] Add IR level interprocedural outliner for code size.
...> that side basically becomes a black box to most LLVM analyses and forces > downstream dataflow meet points to give an overly conservative result, even > though our standard intraprocedural analyses would have happily dug through > the left side of the diamond if the code had not been outlined. > > Also, River's patch (the one in this thread) does parameterized outlining. > For example, two sequences containing stores can be outlined even if the > corresponding stores have different pointers. The pointer to be loaded from > is passed as a parameter to the outlined func...
2017 Aug 24
1
[RFC] Enhance Partial Inliner by using a general outlining scheme for cold blocks
...egions, then fall-back to early return peeling if (!computeOutliningInfo) { return nullptr; } } // Try to outline the identified regions // Then try to inline the cloned function My concern is during inlining, if we fail to inline the cloned function, we give up and discard all cloned and outlined functions. But with these two types of outlining we're doing, it's possible to attempt to inline the cloned function that has outlined cold regions, and if we cannot do so, try to inline a different clone that has peeled early returns (ie. the way we have it today). This would require us...
2017 Aug 24
3
[RFC] Enhance Partial Inliner by using a general outlining scheme for cold blocks
...outlining of cold regions will not degrade the performance of the function in 99.xx% of the cases, as it's unclear how much performance we'll gain from just outlining (without inlining to increase the odds of some performance gain). My initial thought was to ditch the new function and its outlined children if we cannot immediately inline it. Graham Yiu LLVM Compiler Development IBM Toronto Software Lab Office: (905) 413-4077 C2-707/8200/Markham Email: gyiu at ca.ibm.com From: Xinliang David Li <xinliangli at gmail.com> To: Graham Yiu <gyiu at ca.ibm.com> Cc: llvm-dev &lt...
2017 Aug 29
3
[RFC] Enhance Partial Inliner by using a general outlining scheme for cold blocks
...t; estimated more accurately. (With the new PM), the threshold of inlining a > hot callsite is also much higher. Without profile, the pattern matching > method won't work too well in general even though it can enable more more > inlining because the call overhead introduced to call the outlined function > may outweigh the benefit of inlining the caller. > > What ever region that can be found by the pattern matching method should > be identified by the new method as well. If there are multiple (but > mutually exclusive) candidate regions found, the cost analysis heuristic &g...
2017 Aug 15
2
[RFC] Enhance Partial Inliner by using a general outlining scheme for cold blocks
...ommon >> utilities like the code extractor to do outlining. >> > AFAIK, Code extractor is the only IR level utility for outlining, but it's > not the best and definitely needs some improvement. It currently returns > outputs via live out pointer parameters, which means that outlined > functions can't be tagged with attributes like readonly. > > There were also some known problems with extracting in the presence of > critical edges, but I don't know if thats still the case. > > >> Is that what you're referring to? I don't recall seeing an...
2017 Jul 29
7
[RFC] Add IR level interprocedural outliner for code size.
...basically becomes a black box to most LLVM analyses and forces > > downstream dataflow meet points to give an overly conservative result, even > > though our standard intraprocedural analyses would have happily dug through > > the left side of the diamond if the code had not been outlined. > > > > Also, River's patch (the one in this thread) does parameterized outlining. > > For example, two sequences containing stores can be outlined even if the > > corresponding stores have different pointers. The pointer to be loaded from > > is passed as a param...
2017 Jul 26
2
[RFC] Add IR level interprocedural outliner for code size.
...> that side basically becomes a black box to most LLVM analyses and forces > downstream dataflow meet points to give an overly conservative result, even > though our standard intraprocedural analyses would have happily dug through > the left side of the diamond if the code had not been outlined. > > Also, River's patch (the one in this thread) does parameterized outlining. > For example, two sequences containing stores can be outlined even if the > corresponding stores have different pointers. The pointer to be loaded from > is passed as a parameter to the outlined func...
2017 Jul 21
2
[RFC] Add IR level interprocedural outliner for code size.
...model for benefit estimation. - Uses a greedy algorithm for candidate pruning. - Currently supports X86, AArch64 targets. - Requires NoRedZone on supported targets. IR Outliner: - Builds a suffix array based upon relaxed equivalence between ir instrs. - Allows for inputs/outputs from an outlined function. - Complex verification of outlining candidates due to above two points(relaxed equivalency, inputs/outputs). - Tunable generic target independent cost model (estimates constant folded inputs, output condensing, etc.). - Note it uses the target info available (TargetTransformInf...
2017 Jul 26
3
[RFC] Add IR level interprocedural outliner for code size.
...int func(int t) readnone { ... } void foo(int a, int b) { int x = func(a); int y = x; } GVN will catch this, but EarlyCSE is (at least supposed to be!) cheaper. Once we have an analysis that can prove that certain functions can't trap, outlining can allow LICM etc. to speculate entire outlined regions out of loops. Generally, I think outlining exposes information that certain regions of the program are doing identical things. We should expect to get some mileage out of this information. -- Sanjoy
2017 Aug 01
4
[RFC] Add IR level interprocedural outliner for code size.
...t;>> > downstream dataflow meet points to give an overly conservative >>>> result, even >>>> > though our standard intraprocedural analyses would have happily dug >>>> through >>>> > the left side of the diamond if the code had not been outlined. >>>> > >>>> > Also, River's patch (the one in this thread) does parameterized >>>> outlining. >>>> > For example, two sequences containing stores can be outlined even if >>>> the >>>> > corresponding stores hav...
2017 Jul 20
8
[RFC] Add IR level interprocedural outliner for code size.
...rent internal input sequences or incompatible parent function attributes between occurrences. An example of incompatible internal inputs sequences is: X = W + 6; vs X = W + 6; Y = X + 4; Y = W + 4; The above two occurrences would need special control flow to exist within the same outlined function. During analysis candidates have their inputs and outputs computed along with an estimated benefit from extraction. During input calculation a constant folding step removes all inputs that are the same amongst all occurrences. * Candidate Pruning: Overlapping candidates are pruned with...