2002-07-16 19:10:00 +00:00
|
|
|
; This case fails raise because the store requires that it's argument is of a
|
|
|
|
; particular type, but the gep is unable to propogate types backwards through
|
|
|
|
; it, because it doesn't know what type to ask it's operand to be.
|
|
|
|
;
|
|
|
|
; This could be fixed by making all stores add themselves to a list, and check
|
|
|
|
; their arguments are consistent AFTER all other values are propogated.
|
2004-11-06 20:38:27 +00:00
|
|
|
; XFAIL: *
|
2003-09-16 15:29:54 +00:00
|
|
|
; RUN: llvm-as < %s | opt -raise | llvm-dis | not grep '= cast'
|
2002-07-16 19:10:00 +00:00
|
|
|
|
|
|
|
%Tree = type %struct.tree*
|
|
|
|
%struct.tree = type { int, double, double, %Tree, %Tree, %Tree, %Tree }
|
|
|
|
|
|
|
|
void %reverse(%Tree %t) {
|
|
|
|
bb0: ;[#uses=0]
|
|
|
|
%cast219 = cast %Tree %t to sbyte*** ; <sbyte***> [#uses=2]
|
2002-10-15 21:39:49 +00:00
|
|
|
%reg2221 = getelementptr sbyte*** %cast219, long 6 ; <sbyte***> [#uses=1]
|
2002-07-16 19:10:00 +00:00
|
|
|
%reg108 = load sbyte*** %reg2221 ; <sbyte**> [#uses=2]
|
2002-10-15 21:39:49 +00:00
|
|
|
%reg247 = getelementptr sbyte*** %cast219, long 5 ; <sbyte***> [#uses=1]
|
2002-07-16 19:10:00 +00:00
|
|
|
store sbyte** %reg108, sbyte*** %reg247
|
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|