You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Have a iree_runtime_size_benchmark target and track its size #3963
We should be able to have a minimal target that pulls in the dylib backend, no flags, no logging, etc and just uses iree_vm_invoke to call a model, similar to the existing iree/vm/bytecode_module_size_benchmark. The intent is to see what the impact of a standalone IREE build is to a user's application size. Even better would be another standard_library_size_benchmark that was just main() and pulled in a few things that we can reasonably expect any integrator to already have (like printf, std::string/std::vector as used by our current C++ code, etc). Diffing those two will give us the delta IREE adds to an average application.
@hanhanW I feel like you were playing with some benchmark tracking stuff at some point - could we potentially feed the byte size values to the same thing as time values and get size-over-time tracking?
We should be compiling with Release or MinSizeRel in cmake as that is what anyone integrating us will be using.
I looked into Mako and found that it's hard to embed bloaty report to a Mako run. However, we can still save the binary in BuildKite as artifacts. Once we hit a regression, we can pull the binary and do a diff (with command /bloaty bloaty -- oldbloaty).
I'm thinking to config IREE with -DIREE_HAL_DRIVERS_TO_BUILD="VMLA", -DIREE_HAL_DRIVERS_TO_BUILD="VMLA;DyLIB", and -DIREE_HAL_DRIVERS_TO_BUILD="VMLA;Vulkan" in Release build, then tracking the binary size of iree-run-module. What do you think?
(can consider to add MinSizeRel mode as well.)
I did it locally and got 1.8M for VMLA;DyLib config, 2.3M for VMLA;Vulkan config, and 1.8M for VMLA config.
@benvanik do you think this issue is still relevant? It looks like we also want to track the IREE runtime size in addition to the module size we are working on now.
If so, I'm happy to think about how to integrate this with the new benchmark infra.
There are like three open issues about this same thing. I'm not sure which to make canonical, but #9167, #7972 and #6161 all appear to be roughly the same
There are like three open issues about this same thing. I'm not sure which to make canonical, but #9167, #7972 and #6161 all appear to be roughly the same
I think this one is different. It wants to track the size of IREE runtime instead of the VMFB modules.
Activity
benvanik commentedon Nov 22, 2020
As a possible extension (or part of the core work) it'd be fantastic to wire up https://github.com/google/bloaty. Dumping a bloaty report would tell us what files are taking up the bytes, and per-run we could diff against base to see what the increase of was across compilation units.
hanhanW commentedon Nov 30, 2020
Yes, we can do it. The benchmarking infra just needs a number, it can be either time, or size, or whatever you want. It's really flexible. It requires a black box to generate a number (like a script). Then we can bundle the number and the git revision and make something like https://mako.dev/benchmark?benchmark_key=5538704950034432
(imaging that the time unit to be size unit instead)
hanhanW commentedon Nov 30, 2020
We can probably wire up bloaty report to a run (like: https://mako.dev/run?run_key=6234066354438144&~c=1&~v=1&~g=1) and aggregate sizes to a number and show numbers in the benchmark (like https://mako.dev/benchmark?benchmark_key=5538704950034432).
(The current usage is only one data point, we can probably have a profiling plot in a run, like https://mako.dev/run?run_key=5681260090359808&~pl=1&~pe=1&~st=1&~dl=1&~de=1&~dt=1&~pet=1&~det=1).
hanhanW commentedon Dec 3, 2020
I looked into Mako and found that it's hard to embed bloaty report to a Mako run. However, we can still save the binary in BuildKite as artifacts. Once we hit a regression, we can pull the binary and do a diff (with command
/bloaty bloaty -- oldbloaty).I'm thinking to config IREE with
-DIREE_HAL_DRIVERS_TO_BUILD="VMLA",-DIREE_HAL_DRIVERS_TO_BUILD="VMLA;DyLIB", and-DIREE_HAL_DRIVERS_TO_BUILD="VMLA;Vulkan"inReleasebuild, then tracking the binary size ofiree-run-module. What do you think?(can consider to add
MinSizeRelmode as well.)I did it locally and got 1.8M for
VMLA;DyLibconfig, 2.3M forVMLA;Vulkanconfig, and 1.8M forVMLAconfig.pzread commentedon Jun 6, 2022
@benvanik do you think this issue is still relevant? It looks like we also want to track the IREE runtime size in addition to the module size we are working on now.
If so, I'm happy to think about how to integrate this with the new benchmark infra.
GMNGeoffrey commentedon Jun 14, 2022
There are like three open issues about this same thing. I'm not sure which to make canonical, but #9167, #7972 and #6161 all appear to be roughly the same
pzread commentedon Jun 14, 2022
I think this one is different. It wants to track the size of IREE runtime instead of the VMFB modules.
GMNGeoffrey commentedon Jun 14, 2022
#6161 includes that. I'm not sure whether duping everything with "miscellaneous system states" is helpful or not though