diff options
author | 2017-01-19 14:48:48 -0800 | |
---|---|---|
committer | 2017-01-20 15:47:06 -0800 | |
commit | a2f526f889be06f96ea59624c9dfb1223b3839f3 (patch) | |
tree | 769f517e6664de0e89abeadf07a39d5410fcee42 /runtime/arch/instruction_set_test.cc | |
parent | 64e50021845b1ad9d8851596e8aaddf18be217c2 (diff) |
Compressed native PC for stack maps
Compress native PC based on instruction alignment. This reduces the
size of stack maps, boot.oat is 0.4% smaller for arm64.
Test: test-art-host, test-art-target, N6P booting
Change-Id: I2b70eecabda88b06fa80a85688fd992070d54278
Diffstat (limited to 'runtime/arch/instruction_set_test.cc')
-rw-r--r-- | runtime/arch/instruction_set_test.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/runtime/arch/instruction_set_test.cc b/runtime/arch/instruction_set_test.cc index 5aae93acc5..b251b57c99 100644 --- a/runtime/arch/instruction_set_test.cc +++ b/runtime/arch/instruction_set_test.cc @@ -44,6 +44,15 @@ TEST(InstructionSetTest, GetInstructionSetString) { EXPECT_STREQ("none", GetInstructionSetString(kNone)); } +TEST(InstructionSetTest, GetInstructionSetInstructionAlignment) { + EXPECT_EQ(GetInstructionSetInstructionAlignment(kThumb2), kThumb2InstructionAlignment); + EXPECT_EQ(GetInstructionSetInstructionAlignment(kArm64), kArm64InstructionAlignment); + EXPECT_EQ(GetInstructionSetInstructionAlignment(kX86), kX86InstructionAlignment); + EXPECT_EQ(GetInstructionSetInstructionAlignment(kX86_64), kX86_64InstructionAlignment); + EXPECT_EQ(GetInstructionSetInstructionAlignment(kMips), kMipsInstructionAlignment); + EXPECT_EQ(GetInstructionSetInstructionAlignment(kMips64), kMips64InstructionAlignment); +} + TEST(InstructionSetTest, TestRoundTrip) { EXPECT_EQ(kRuntimeISA, GetInstructionSetFromString(GetInstructionSetString(kRuntimeISA))); } |