The type i1imm serves the same purpose as u1imm. Both types are not required.
This patch removes the u1imm type.
Paths
| Differential D57759
[PowerPC] Code Cleanup Remove u1imm AbandonedPublic Authored by stefanp on Feb 5 2019, 9:05 AM.
Details
Diff Detail Event TimelineComment Actions LGTM. I suppose that I thought that this was needed at some point to parse (1, 0) instead of (-1, 0), but if this is not needed in practice, then it should be simplified. This revision is now accepted and ready to land.Feb 5 2019, 10:41 AM Comment Actions Hi Hal, Comment Actions
Okay. This is just a question of parsing and text formatting. A 1-bit signed number is -1 or 0, and an unsigned 1-bit number is 1 or 0. Comment Actions Hi Hal, The u1imm type is actually an i32 which is later restricted to be either a 0 or a 1. On the other hand the i1imm type is an i1. This is an important difference. The issue is that some of the instructions that use this type have builtins. For example: vshasigmaw. The builtin requires that the single bit be passed in as a parameter and that means we need to use an i32. Anyway I'm going to leave the type in.
Revision Contents
Diff 185325 llvm/lib/Target/PowerPC/AsmParser/PPCAsmParser.cpp
llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.h
llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp
llvm/lib/Target/PowerPC/PPCInstr64Bit.td
llvm/lib/Target/PowerPC/PPCInstrAltivec.td
llvm/lib/Target/PowerPC/PPCInstrHTM.td
llvm/lib/Target/PowerPC/PPCInstrInfo.td
llvm/lib/Target/PowerPC/PPCInstrVSX.td
|