2002-11-06 06:20:53 +00:00
|
|
|
; This file contains a list of cases where node folding should NOT happen
|
|
|
|
;
|
2006-08-27 22:41:58 +00:00
|
|
|
; RUN: llvm-as < %s | opt -analyze -tddatastructure
|
2003-10-03 18:42:25 +00:00
|
|
|
;
|
2002-11-06 06:20:53 +00:00
|
|
|
|
|
|
|
implementation
|
|
|
|
|
|
|
|
void %test1({int, int}* %X) {
|
|
|
|
getelementptr {int, int} * %X, long 0
|
|
|
|
%Y = cast {int, int}* %X to uint*
|
|
|
|
store uint 5, uint* %Y
|
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
|
|
|
; Test that "structural" equality works. Pointers can land in pointers n
|
|
|
|
; stuff.
|
|
|
|
void %test2({int*, int*}* %X) {
|
|
|
|
getelementptr {int*, int*}* %X, long 0
|
|
|
|
%Y = cast {int*, int*}* %X to {uint*, long*}*
|
|
|
|
getelementptr {uint*, long*}* %Y, long 0
|
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|