announcing LLpatch: arch-independent live-patch creation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



We have a new userspace live-patch creation tool, LLpatch, paralleling
kpatch-build, but without requiring its arch-specific code for ELF
analysis and manipulation.

We considered extending kpatch-build to a new target architecture
(arm64), cluttering its code with details of another architecture’s
quirky instruction sequences & relocation modes, and suspected there
might be a better way.


The LLVM suite already knows these details, and offers llvm-diff, for
comparing generated code at the LLVM-IR (internal representation)
level, which has access to much more of the code’s _intent_ than
kpatch’s create-diff-object is able to infer from ELF-level
differences.


Building on this, LLpatch adds namespace analysis, further
dead/duplicate code elimination, and creation of patch modules
compatible with kernel’s livepatch API.

Arm64 is supported - testing against a livepatch-capable v5.12 arm64
kernel, using the preliminary reliable-stacktrace work from
madvenka@xxxxxxxxxxxxxxxxxxx, LLpatch modules for x86 and arm64 behave
identically to the x86 kpatch-build modules, without requiring any
additional arch-specific code.

On x86, where both tools are available, LLpatch produces smaller patch
modules than kpatch, and already correctly handles most of the kpatch
test cases, without any arch-specific code. This suggests it can work
with any clang-supported kernel architecture.


Work is ongoing, collaboration is welcome.


See https://github.com/google/LLpatch for further details on the
technology and its benefits.


Yonghyun Hwang (yonghyun@xxxxxxxxxx freeaion@xxxxxxxxx)
Bill Wendling (morbo@xxxxxxxxxx isanbard@xxxxxxxxx)
Pete Swain (swine@xxxxxxxxxx swine@xxxxxxxxx)



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux Kernel]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux