[pool-manager] Integration with aarch32.
Key points of this patch:
- renames LabelBase to LocationBase
- makes the Location class derive from LoctionBase
- moves the code for Location, Label and RawLiteral/Literal to a shared file
- moves ReferenceInfo out of Assembler
- removes all the old veneer pool and literal pool code
- updates the macro assembler to use the new pool manager
- updates existing tests that expect a certain behaviour from the pool manager
- adds new tests for corner cases that came up during integration
- adds tests for issues that the new pool manager addresses (literal_and_veneer_interaction_*)
Change-Id: Ied81401d40f88cb988ff95e85fe832851f171f77
diff --git a/src/code-buffer-vixl.cc b/src/code-buffer-vixl.cc
index e88419a..0fdd373 100644
--- a/src/code-buffer-vixl.cc
+++ b/src/code-buffer-vixl.cc
@@ -1,4 +1,4 @@
-// Copyright 2014, VIXL authors
+// Copyright 2017, VIXL authors
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
@@ -133,12 +133,15 @@
byte* end = AlignUp(cursor_, 4);
const size_t padding_size = end - cursor_;
VIXL_ASSERT(padding_size <= 4);
- EnsureSpaceFor(padding_size);
- dirty_ = true;
- memset(cursor_, 0, padding_size);
- cursor_ = end;
+ EmitZeroedBytes(static_cast<int>(padding_size));
}
+void CodeBuffer::EmitZeroedBytes(int n) {
+ EnsureSpaceFor(n);
+ dirty_ = true;
+ memset(cursor_, 0, n);
+ cursor_ += n;
+}
void CodeBuffer::Reset() {
#ifdef VIXL_DEBUG