mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-12 17:32:19 +00:00
New testcase: check that the inliner constant folds instructions on the
fly if it can. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28515 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
729c6d1da8
commit
5ca32a6d6c
15
test/Transforms/Inline/inline_constprop.ll
Normal file
15
test/Transforms/Inline/inline_constprop.ll
Normal file
@ -0,0 +1,15 @@
|
||||
; RUN: llvm-as < %s | opt -inline -disable-output &&
|
||||
; RUN: llvm-as < %s | opt -inline | llvm-dis | not grep callee &&
|
||||
; RUN: llvm-as < %s | opt -inline | llvm-dis | not grep div
|
||||
|
||||
implementation
|
||||
|
||||
internal int %callee(int %A, int %B) {
|
||||
%C = div int %A, %B
|
||||
ret int %C
|
||||
}
|
||||
|
||||
int %test() {
|
||||
%X = call int %callee(int 10, int 3)
|
||||
ret int %X
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user