From fc52c11d803d3975f17d443f504344d80cef70ed Mon Sep 17 00:00:00 2001 From: Colin LeMahieu Date: Thu, 4 Jun 2015 21:16:16 +0000 Subject: [Hexagon] Adding functionality for duplexing. Duplexing is a way to compress commonly used pairs of instructions in order to reduce code size. The test case duplex.ll normally would be 8 bytes, assign register to 0 and jump to link register. After duplexing this is only 4 bytes. This also tests the HexagonMCShuffler code path which is used to make sure duplexed instructions still follow slot requirements. llvm-svn: 239095 --- llvm/test/CodeGen/Hexagon/duplex.ll | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 llvm/test/CodeGen/Hexagon/duplex.ll (limited to 'llvm/test') diff --git a/llvm/test/CodeGen/Hexagon/duplex.ll b/llvm/test/CodeGen/Hexagon/duplex.ll new file mode 100644 index 00000000000..80fe61ceccc --- /dev/null +++ b/llvm/test/CodeGen/Hexagon/duplex.ll @@ -0,0 +1,7 @@ +; RUN: llc -march=hexagon -filetype=obj -o - %s | llvm-objdump -d - | FileCheck %s + +; CHECK: c0 3f 00 48 48003fc0 + +define i32 @foo() { +ret i32 0 +} \ No newline at end of file -- cgit v1.2.3