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

Unified Diff: src/IceTargetLoweringX8632.cpp

Issue 1260183008: Order jump tables for deterministic or randomized emission. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Fix sort comparison. Created 5 years, 4 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/IceSwitchLowering.h ('k') | src/IceTargetLoweringX8664.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceTargetLoweringX8632.cpp
diff --git a/src/IceTargetLoweringX8632.cpp b/src/IceTargetLoweringX8632.cpp
index e8e89dd88f7429931fcf2fe07382eca35f350dcf..a42e12288bbf59a24fb3491d65bb9483081d4e47 100644
--- a/src/IceTargetLoweringX8632.cpp
+++ b/src/IceTargetLoweringX8632.cpp
@@ -243,8 +243,8 @@ void TargetDataX8632::lowerJumpTables() {
switch (Ctx->getFlags().getOutFileType()) {
case FT_Elf: {
ELFObjectWriter *Writer = Ctx->getObjectWriter();
- for (const JumpTableData &JumpTable : *Ctx->getJumpTables())
- Writer->writeJumpTable(JumpTable, llvm::ELF::R_386_32);
+ for (const JumpTableData &JT : Ctx->getJumpTables())
+ Writer->writeJumpTable(JT, llvm::ELF::R_386_32);
} break;
case FT_Asm:
// Already emitted from Cfg
@@ -253,7 +253,7 @@ void TargetDataX8632::lowerJumpTables() {
if (!BuildDefs::dump())
return;
Ostream &Str = Ctx->getStrEmit();
- for (const JumpTableData &JT : *Ctx->getJumpTables()) {
+ for (const JumpTableData &JT : Ctx->getJumpTables()) {
Str << "\t.section\t.rodata." << JT.getFunctionName()
<< "$jumptable,\"a\",@progbits\n";
Str << "\t.align\t" << typeWidthInBytes(getPointerType()) << "\n";
« no previous file with comments | « src/IceSwitchLowering.h ('k') | src/IceTargetLoweringX8664.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698