tinygo/transform/testdata
Ayke van Laethem 603fff78d4 all: add support for ThinLTO
ThinLTO optimizes across LLVM modules at link time. This means that
optimizations (such as inlining and const-propagation) are possible
between C and Go. This makes this change especially useful for CGo, but
not just for CGo. By doing some optimizations at link time, the linker
can discard some unused functions and this leads to a size reduction on
average. It does increase code size in some cases, but that's true for
most optimizations.

I've excluded a number of targets for now (wasm, avr, xtensa, windows,
macos). They can probably be supported with some more work, but that
should be done in separate PRs.

Overall, this change results in an average 3.24% size reduction over all
the tinygo.org/x/drivers smoke tests.

TODO: this commit runs part of the pass pipeline twice. We should set
the PrepareForThinLTO flag in the PassManagerBuilder for even further
reduced code size (0.7%) and improved compilation speed.
2022-03-12 12:55:38 +01:00
..
allocs.ll compiler, runtime: add layout parameter to runtime.alloc 2021-11-02 22:16:15 +01:00
allocs.out.ll transform: allocate the correct amount of bytes in an alloca 2021-12-10 10:48:24 +01:00
allocs2.go compiler: do not emit nil checks for loading closure variables 2021-05-26 20:21:08 +02:00
gc-globals.ll transform: do not track const globals 2020-02-24 21:04:50 +01:00
gc-globals.out.ll all: drop support for LLVM 10 2021-10-31 10:44:17 +01:00
gc-stackslots.ll compiler, runtime: add layout parameter to runtime.alloc 2021-11-02 22:16:15 +01:00
gc-stackslots.out.ll compiler, runtime: add layout parameter to runtime.alloc 2021-11-02 22:16:15 +01:00
globals-function-sections.ll compiler: move ApplyFunctionSections to transform package 2020-03-19 19:56:08 +01:00
globals-function-sections.out.ll compiler: move ApplyFunctionSections to transform package 2020-03-19 19:56:08 +01:00
interface.ll compiler: remove parentHandle from calling convention 2022-01-19 14:42:02 -05:00
interface.out.ll compiler: remove parentHandle from calling convention 2022-01-19 14:42:02 -05:00
interrupt.ll compiler: remove parentHandle from calling convention 2022-01-19 14:42:02 -05:00
interrupt.out.ll compiler: remove parentHandle from calling convention 2022-01-19 14:42:02 -05:00
maps.ll all: move OptimizeMaps to transforms and add tests 2019-09-15 21:26:27 +02:00
maps.out.ll all: drop support for LLVM 10 2021-10-31 10:44:17 +01:00
panic.ll compiler: move ReplacePanicsWithTrap pass to transforms 2019-11-16 18:41:28 +01:00
panic.out.ll compiler: move ReplacePanicsWithTrap pass to transforms 2019-11-16 18:41:28 +01:00
reflect-implements.ll compiler: remove parentHandle from calling convention 2022-01-19 14:42:02 -05:00
reflect-implements.out.ll compiler: remove parentHandle from calling convention 2022-01-19 14:42:02 -05:00
reflect.go transform: split interface and reflect lowering 2021-05-03 20:10:49 +02:00
stacksize.ll arm: automatically determine stack sizes 2020-08-27 19:23:22 +02:00
stacksize.out.ll all: add support for ThinLTO 2022-03-12 12:55:38 +01:00
stringequal.ll compiler: remove parentHandle from calling convention 2022-01-19 14:42:02 -05:00
stringequal.out.ll compiler: remove parentHandle from calling convention 2022-01-19 14:42:02 -05:00
stringtobytes.ll compiler: move OptimizeStringToBytes to transform package 2019-09-22 08:25:50 +02:00
stringtobytes.out.ll compiler: move OptimizeStringToBytes to transform package 2019-09-22 08:25:50 +02:00
wasm-abi.ll compiler: move wasm ABI workaround to transform package 2020-01-28 19:29:09 +01:00
wasm-abi.out.ll all: drop support for LLVM 10 2021-10-31 10:44:17 +01:00