Add a pattern for matching zero-store with 64-bit address. The pattern is enabled

only when the target ABI is N64. 

llvm-svn: 146992
This commit is contained in:
Akira Hatanaka 2011-12-20 21:50:49 +00:00
parent 2c59052984
commit 9b9bd1cc15
1 changed files with 4 additions and 1 deletions

View File

@ -1015,7 +1015,10 @@ def : Pat<(extloadi16_a addr:$src), (LHu addr:$src)>;
def : Pat<(extloadi16_u addr:$src), (ULHu addr:$src)>;
// peepholes
def : Pat<(store (i32 0), addr:$dst), (SW ZERO, addr:$dst)>;
def : Pat<(store (i32 0), addr:$dst), (SW ZERO, addr:$dst)>,
Requires<[NotN64]>;
def : Pat<(store (i32 0), addr:$dst), (SW_P8 ZERO, addr:$dst)>,
Requires<[IsN64]>;
// brcond patterns
multiclass BrcondPats<RegisterClass RC, Instruction BEQOp, Instruction BNEOp,