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

Unified Diff: src/IceInst.cpp

Issue 1876413002: Subzero. WASM. Additional progress. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Merging with master Created 4 years, 8 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
Index: src/IceInst.cpp
diff --git a/src/IceInst.cpp b/src/IceInst.cpp
index 1265d5898b7d1118723fb78a6e36c19f35b92a26..be48916699bd3d7b3c78d2e7a768c3d2b7242e88 100644
--- a/src/IceInst.cpp
+++ b/src/IceInst.cpp
@@ -111,6 +111,7 @@ const char *Inst::getInstName() const {
X(FakeUse, "fakeuse");
X(FakeKill, "fakekill");
X(JumpTable, "jumptable");
+ X(Breakpoint, "break");
Jim Stichnoth 2016/04/14 20:03:44 sort
Eric Holk 2016/04/15 15:24:26 Done.
#undef X
default:
assert(Kind >= Target);
@@ -516,8 +517,10 @@ void InstSwitch::addBranch(SizeT CaseIndex, uint64_t Value, CfgNode *Label) {
NodeList InstSwitch::getTerminatorEdges() const {
NodeList OutEdges;
OutEdges.reserve(NumCases + 1);
+ assert(LabelDefault);
OutEdges.push_back(LabelDefault);
for (SizeT I = 0; I < NumCases; ++I) {
+ assert(Labels[I]);
OutEdges.push_back(Labels[I]);
}
std::sort(OutEdges.begin(), OutEdges.end(),
@@ -1047,6 +1050,9 @@ void InstTarget::dump(const Cfg *Func) const {
Inst::dump(Func);
}
+InstBreakpoint::InstBreakpoint(Cfg *Func)
+ : InstHighLevel(Func, Inst::Breakpoint, 0, nullptr) {}
+
bool checkForRedundantAssign(const Variable *Dest, const Operand *Source) {
const auto *SrcVar = llvm::dyn_cast<const Variable>(Source);
if (!SrcVar)

Powered by Google App Engine
This is Rietveld 408576698