Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(70)

Unified Diff: src/IceAssemblerARM32.h

Issue 1418523002: Add hybrid assembler concept to ARM assembler. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Fix nits. Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/IceAssembler.cpp ('k') | src/IceAssemblerARM32.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceAssemblerARM32.h
diff --git a/src/IceAssemblerARM32.h b/src/IceAssemblerARM32.h
index 4f2495c584c059f57b71409e496c0461584a00c9..20b4e67da28ee3f7596688728a9378cdf3a6dec5 100644
--- a/src/IceAssemblerARM32.h
+++ b/src/IceAssemblerARM32.h
@@ -53,11 +53,12 @@ public:
void alignFunction() override {
const SizeT Align = 1 << getBundleAlignLog2Bytes();
SizeT BytesNeeded = Utils::OffsetToAlignment(Buffer.getPosition(), Align);
+ constexpr uint32_t UndefinedInst = 0xe7fedef0; // udf #60896
constexpr SizeT InstSize = sizeof(int32_t);
assert(BytesNeeded % InstSize == 0);
while (BytesNeeded > 0) {
- // TODO(kschimpf) Should this be NOP or some other instruction?
- bkpt(0);
+ AssemblerBuffer::EnsureCapacity ensured(&Buffer);
+ emitInst(UndefinedInst);
BytesNeeded -= InstSize;
}
}
@@ -91,7 +92,8 @@ public:
bool fixupIsPCRel(FixupKind Kind) const override {
(void)Kind;
- llvm_unreachable("Not yet implemented.");
+ // TODO(kschimpf) Decide if we need this.
+ return false;
}
void bind(Label *label);
@@ -118,6 +120,8 @@ public:
return Asm->getKind() == Asm_ARM32;
}
+ void emitTextInst(const std::string &Text);
+
private:
// A vector of pool-allocated x86 labels for CFG nodes.
using LabelVector = std::vector<Label *>;
« no previous file with comments | « src/IceAssembler.cpp ('k') | src/IceAssemblerARM32.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698