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

Unified Diff: src/IceTargetLowering.h

Issue 456033003: Subzero: Randomize register assignment. (Closed) Base URL: https://gerrit.chromium.org/gerrit/p/native_client/pnacl-subzero.git@master
Patch Set: Typo Created 6 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/IceRegAlloc.cpp ('k') | src/IceTargetLowering.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceTargetLowering.h
diff --git a/src/IceTargetLowering.h b/src/IceTargetLowering.h
index 39e08def9b2c1a684d2437773f4ff76312e9ae80..d39b8e2ce82e513da8d0cec9710be29fa0c9632c 100644
--- a/src/IceTargetLowering.h
+++ b/src/IceTargetLowering.h
@@ -156,6 +156,10 @@ public:
virtual const llvm::SmallBitVector &getRegisterSetForType(Type Ty) const = 0;
void regAlloc();
+ virtual void makeRandomRegisterPermutation(
+ llvm::SmallVectorImpl<int32_t> &Permutation,
+ const llvm::SmallBitVector &ExcludeRegisters) = 0;
+
virtual void emitVariable(const Variable *Var, const Cfg *Func) const = 0;
// Performs target-specific argument lowering.
@@ -169,9 +173,7 @@ public:
virtual ~TargetLowering() {}
protected:
- TargetLowering(Cfg *Func)
- : Func(Func), Ctx(Func->getContext()), HasComputedFrame(false),
- StackAdjustment(0) {}
+ TargetLowering(Cfg *Func);
virtual void lowerAlloca(const InstAlloca *Inst) = 0;
virtual void lowerArithmetic(const InstArithmetic *Inst) = 0;
virtual void lowerAssign(const InstAssign *Inst) = 0;
@@ -208,6 +210,7 @@ protected:
// natural location, as arguments are pushed for a function call.
int32_t StackAdjustment;
LoweringContext Context;
+ const bool RandomizeRegisterAllocation;
private:
TargetLowering(const TargetLowering &) LLVM_DELETED_FUNCTION;
« no previous file with comments | « src/IceRegAlloc.cpp ('k') | src/IceTargetLowering.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698