]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
oe/elf: don't regenerate machine data on every call
authorRoss Burton <ross.burton@arm.com>
Thu, 10 Oct 2024 16:06:16 +0000 (17:06 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 11 Oct 2024 11:16:59 +0000 (12:16 +0100)
commitdca4455aa4f870bad900a0214c4e95e09a055295
tree53578b0676a7a31d0cf2a24dd5d26ad2163ac9bb
parent6cccf6b02f92dad514e65fd779ff659b19eb6be7
oe/elf: don't regenerate machine data on every call

Every time oe.elf.machine_dict() is called a large dictionary is created
and returned. However, the "arch" package_qa test will call this method
for every binary in a package, which results in a lot of dictionary
creation.

Concrete exmaple: in running ltp:do_package_qa, the arch test takes 25%
of the runtime, and opitimising the machine_dict() call to cache the
generated dictionary reduces the runtime from 57s to 44s.

Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/lib/oe/elf.py