diff options
| author | Chris Lattner <sabre@nondot.org> | 2004-04-01 05:28:26 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2004-04-01 05:28:26 +0000 |
| commit | b28dd11e3395e4b4a1bac7040f21e40ac0ee3922 (patch) | |
| tree | 9c512a7ef9e37f25650417bc37c1ddd2a6041d6c /llvm/lib | |
| parent | bc7e35b3b1da31512e3dc03fae7b7d07bf0184b4 (diff) | |
| download | bcm5719-llvm-b28dd11e3395e4b4a1bac7040f21e40ac0ee3922.tar.gz bcm5719-llvm-b28dd11e3395e4b4a1bac7040f21e40ac0ee3922.zip | |
Add support for select constant expressions to the CBE, fixing SIOD
llvm-svn: 12589
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Target/CBackend/Writer.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/llvm/lib/Target/CBackend/Writer.cpp b/llvm/lib/Target/CBackend/Writer.cpp index 54b8bd3c19c..807f8ab92f1 100644 --- a/llvm/lib/Target/CBackend/Writer.cpp +++ b/llvm/lib/Target/CBackend/Writer.cpp @@ -388,6 +388,15 @@ void CWriter::printConstant(Constant *CPV) { gep_type_end(CPV)); Out << "))"; return; + case Instruction::Select: + Out << "("; + printConstant(CE->getOperand(0)); + Out << "?"; + printConstant(CE->getOperand(1)); + Out << ":"; + printConstant(CE->getOperand(2)); + Out << ")"; + return; case Instruction::Add: case Instruction::Sub: case Instruction::Mul: |

