2458bf3ea4423a07fd6acfc1b87cebdf03ba4aa2
[oota-llvm.git] / test / Transforms / InstCombine / cast-malloc.ll
1 ; test that casted mallocs get converted to malloc of the right type
2 ; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine | llvm-dis | not grep bitcast
3
4 int* %test(uint %size) {
5         %X = malloc long, uint %size
6         %ret = bitcast long* %X to int*
7         ret int* %ret
8 }