diff options
author | Francis Visoiu Mistrih <francisvm@yahoo.com> | 2017-12-07 10:40:31 +0000 |
---|---|---|
committer | Francis Visoiu Mistrih <francisvm@yahoo.com> | 2017-12-07 10:40:31 +0000 |
commit | a8a83d150f489733353b3bff0891248f59a0794c (patch) | |
tree | aa7c9a64cb3f5d7982b775f2e082c07ebfe74b49 /llvm/test/CodeGen/X86/urem-power-of-two.ll | |
parent | 62ef18562b5494567c601be41761cf8449960ad4 (diff) | |
download | bcm5719-llvm-a8a83d150f489733353b3bff0891248f59a0794c.tar.gz bcm5719-llvm-a8a83d150f489733353b3bff0891248f59a0794c.zip |
[CodeGen] Use MachineOperand::print in the MIRPrinter for MO_Register.
Work towards the unification of MIR and debug output by refactoring the
interfaces.
For MachineOperand::print, keep a simple version that can be easily called
from `dump()`, and a more complex one which will be called from both the
MIRPrinter and MachineInstr::print.
Add extra checks inside MachineOperand for detached operands (operands
with getParent() == nullptr).
https://reviews.llvm.org/D40836
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/kill: ([^ ]+) ([^ ]+)<def> ([^ ]+)/kill: \1 def \2 \3/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/kill: ([^ ]+) ([^ ]+) ([^ ]+)<def>/kill: \1 \2 def \3/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/kill: def ([^ ]+) ([^ ]+) ([^ ]+)<def>/kill: def \1 \2 def \3/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/<def>//g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/([^ ]+)<kill>/killed \1/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/([^ ]+)<imp-use,kill>/implicit killed \1/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/([^ ]+)<dead>/dead \1/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/([^ ]+)<def[ ]*,[ ]*dead>/dead \1/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/([^ ]+)<imp-def[ ]*,[ ]*dead>/implicit-def dead \1/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/([^ ]+)<imp-def>/implicit-def \1/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/([^ ]+)<imp-use>/implicit \1/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/([^ ]+)<internal>/internal \1/g'
* find . \( -name "*.mir" -o -name "*.cpp" -o -name "*.h" -o -name "*.ll" -o -name "*.s" \) -type f -print0 | xargs -0 sed -i '' -E 's/([^ ]+)<undef>/undef \1/g'
llvm-svn: 320022
Diffstat (limited to 'llvm/test/CodeGen/X86/urem-power-of-two.ll')
-rw-r--r-- | llvm/test/CodeGen/X86/urem-power-of-two.ll | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/llvm/test/CodeGen/X86/urem-power-of-two.ll b/llvm/test/CodeGen/X86/urem-power-of-two.ll index 8dc5e5338aa..2610beda415 100644 --- a/llvm/test/CodeGen/X86/urem-power-of-two.ll +++ b/llvm/test/CodeGen/X86/urem-power-of-two.ll @@ -56,7 +56,7 @@ define i16 @shift_right_pow_2(i16 %x, i16 %y) { ; X86-NEXT: shrl %cl, %eax ; X86-NEXT: decl %eax ; X86-NEXT: andw {{[0-9]+}}(%esp), %ax -; X86-NEXT: # kill: %ax<def> %ax<kill> %eax<kill> +; X86-NEXT: # kill: def %ax killed %ax killed %eax ; X86-NEXT: retl ; ; X64-LABEL: shift_right_pow_2: @@ -66,7 +66,7 @@ define i16 @shift_right_pow_2(i16 %x, i16 %y) { ; X64-NEXT: shrl %cl, %eax ; X64-NEXT: decl %eax ; X64-NEXT: andl %edi, %eax -; X64-NEXT: # kill: %ax<def> %ax<kill> %eax<kill> +; X64-NEXT: # kill: def %ax killed %ax killed %eax ; X64-NEXT: retq %shr = lshr i16 -32768, %y %urem = urem i16 %x, %shr @@ -81,20 +81,20 @@ define i8 @and_pow_2(i8 %x, i8 %y) { ; X86-NEXT: movb {{[0-9]+}}(%esp), %cl ; X86-NEXT: andb $4, %cl ; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax -; X86-NEXT: # kill: %eax<def> %eax<kill> %ax<def> +; X86-NEXT: # kill: def %eax killed %eax def %ax ; X86-NEXT: divb %cl ; X86-NEXT: movzbl %ah, %eax # NOREX -; X86-NEXT: # kill: %al<def> %al<kill> %eax<kill> +; X86-NEXT: # kill: def %al killed %al killed %eax ; X86-NEXT: retl ; ; X64-LABEL: and_pow_2: ; X64: # %bb.0: ; X64-NEXT: andb $4, %sil ; X64-NEXT: movzbl %dil, %eax -; X64-NEXT: # kill: %eax<def> %eax<kill> %ax<def> +; X64-NEXT: # kill: def %eax killed %eax def %ax ; X64-NEXT: divb %sil ; X64-NEXT: movzbl %ah, %eax # NOREX -; X64-NEXT: # kill: %al<def> %al<kill> %eax<kill> +; X64-NEXT: # kill: def %al killed %al killed %eax ; X64-NEXT: retq %and = and i8 %y, 4 %urem = urem i8 %x, %and |