Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit

Permalink
CopyBlk copyprop
Browse files Browse the repository at this point in the history
  • Loading branch information
benaadams committed Jun 5, 2019
1 parent ac70d9b commit 1ffd953
Show file tree
Hide file tree
Showing 3 changed files with 402 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,7 @@ internal void ThrowIfCompletedUnsuccessfully()
}

/// <summary>Gets an awaiter for this <see cref="ValueTask"/>.</summary>
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public ValueTaskAwaiter GetAwaiter() => new ValueTaskAwaiter(in this);

/// <summary>Configures an awaiter for this <see cref="ValueTask"/>.</summary>
Expand Down
16 changes: 16 additions & 0 deletions src/jit/compiler.h
Original file line number Diff line number Diff line change
Expand Up @@ -6233,6 +6233,22 @@ class Compiler
void optCopyProp(BasicBlock* block, GenTreeStmt* stmt, GenTree* tree, LclNumToGenTreePtrStack* curSsaName);
void optBlockCopyPropPopStacks(BasicBlock* block, LclNumToGenTreePtrStack* curSsaName);
void optBlockCopyProp(BasicBlock* block, LclNumToGenTreePtrStack* curSsaName);
void optCopyPropFoldCopyBlks(BasicBlock* block);
void optCopyPropThroughCopyBlk(BasicBlock* block);
bool optTryGetCopyPropLclVars(GenTree* expr, GenTreeLclVarCommon*& srcLclVar, GenTreeLclVarCommon*& dstLclVar);
bool optTryGetCopyPropLclVar(GenTree* op, GenTreeLclVarCommon*& lclVar);
void optCopyPropUpdateTree(GenTreeStmt* currStmt, GenTreeStmt* updatedStmt, GenTree* newOpt);
#ifndef DEBUG
bool optTryGetCopyPropNewOpt(GenTree* opt, GenTree*& newOpt);
#else
bool optTryGetCopyPropNewOpt(GenTree* opt,
GenTree*& newOpt,
GenTree* currExpr,
GenTree* updatedExpr,
GenTreeLclVarCommon* currLclVar,
GenTreeLclVarCommon* updatedLclVar,
bool isReverse);
#endif
bool optIsSsaLocal(GenTree* tree);
int optCopyProp_LclVarScore(LclVarDsc* lclVarDsc, LclVarDsc* copyVarDsc, bool preferOp2);
void optVnCopyProp();
Expand Down
Loading

0 comments on commit 1ffd953

Please sign in to comment.